JVM_IR inliner fixes: remove code that does nothing
other than randomly throw assertion errors on inline calls in synthetic functions, which have no line number attached. `lazySourceMapper.callSiteMarker` is set in `InlineCodegen.inlineCall`; `IrSourceCompilerForInline.doCreateMethodNodeFromSource` does not need to touch it.
This commit is contained in:
+1
-6
@@ -95,13 +95,8 @@ class IrSourceCompilerForInline(
|
|||||||
asmMethod: Method
|
asmMethod: Method
|
||||||
): SMAPAndMethodNode {
|
): SMAPAndMethodNode {
|
||||||
assert(callableDescriptor == callee.descriptor.original) { "Expected $callableDescriptor got ${callee.descriptor.original}" }
|
assert(callableDescriptor == callee.descriptor.original) { "Expected $callableDescriptor got ${callee.descriptor.original}" }
|
||||||
assert(codegen.lastLineNumber >= 0) { "lastLineNumber shall be not negative, but is ${codegen.lastLineNumber}" }
|
|
||||||
|
|
||||||
val irFunction = getFunctionToInline(jvmSignature, callDefault)
|
val irFunction = getFunctionToInline(jvmSignature, callDefault)
|
||||||
lazySourceMapper.callSiteMarker = CallSiteMarker(codegen.lastLineNumber)
|
return makeInlineNode(irFunction, FakeClassCodegen(irFunction, codegen.classCodegen), false)
|
||||||
val nodeAndSmap = makeInlineNode(irFunction, FakeClassCodegen(irFunction, codegen.classCodegen), false)
|
|
||||||
lazySourceMapper.callSiteMarker = null
|
|
||||||
return nodeAndSmap
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun getFunctionToInline(jvmSignature: JvmMethodSignature, callDefault: Boolean): IrFunction {
|
private fun getFunctionToInline(jvmSignature: JvmMethodSignature, callDefault: Boolean): IrFunction {
|
||||||
|
|||||||
-1
@@ -1,4 +1,3 @@
|
|||||||
// IGNORE_BACKEND: JVM_IR
|
|
||||||
// WITH_COROUTINES
|
// WITH_COROUTINES
|
||||||
// WITH_RUNTIME
|
// WITH_RUNTIME
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user