Native: fix filecheck_signext_zeroext_objc_export and enable it back
Previously filecheck_signext_zeroext_objc_export test was disabled after making one-stage compilation mode implemented through two-stage mode (KT-59245). That change made the compiler sort the methods, and filecheck patterns didn't match that order after that. This commit fixes the test by adding sorted prefixes to method names, so sorting alphabetically them doesn't really change the order.
This commit is contained in:
committed by
Space Team
parent
f77f83e741
commit
0cd91d9286
@@ -6176,8 +6176,7 @@ fileCheckTest("filecheck_signext_zeroext_interop") {
|
|||||||
fileCheckTest("filecheck_signext_zeroext_objc_export") {
|
fileCheckTest("filecheck_signext_zeroext_objc_export") {
|
||||||
annotatedSource = project.file('filecheck/signext_zeroext_objc_export.kt')
|
annotatedSource = project.file('filecheck/signext_zeroext_objc_export.kt')
|
||||||
generateFramework = true
|
generateFramework = true
|
||||||
// enabled = target.family.appleFamily
|
enabled = target.family.appleFamily
|
||||||
enabled = false // KT-58863
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fileCheckTest("filecheck_function_attributes_at_callsite") {
|
fileCheckTest("filecheck_function_attributes_at_callsite") {
|
||||||
|
|||||||
@@ -6,52 +6,55 @@
|
|||||||
//
|
//
|
||||||
// Here we check generated ObjC bridges, not original declarations.
|
// Here we check generated ObjC bridges, not original declarations.
|
||||||
//
|
//
|
||||||
|
// f$n function name prefixes help the compiler keep the function order
|
||||||
|
// whenever it decides to sort the functions alphabetically.
|
||||||
|
//
|
||||||
|
|
||||||
// CHECK-LABEL: zeroext i16 @"objc2kotlin_kfun:#heyIJustMetYou(kotlin.Char){}kotlin.Char"(i8* %0, i8* %1, i16 zeroext %2)
|
// CHECK-LABEL: zeroext i16 @"objc2kotlin_kfun:#f0HeyIJustMetYou(kotlin.Char){}kotlin.Char"(i8* %0, i8* %1, i16 zeroext %2)
|
||||||
fun heyIJustMetYou(arg: Char): Char {
|
fun f0HeyIJustMetYou(arg: Char): Char {
|
||||||
// CHECK: invoke zeroext i16 @"kfun:#heyIJustMetYou(kotlin.Char){}kotlin.Char"(i16 zeroext %2)
|
// CHECK: invoke zeroext i16 @"kfun:#f0HeyIJustMetYou(kotlin.Char){}kotlin.Char"(i16 zeroext %2)
|
||||||
return arg
|
return arg
|
||||||
}
|
}
|
||||||
|
|
||||||
// CHECK-LABEL: signext i8 @"objc2kotlin_kfun:#andThisIsCrazy(kotlin.Byte){}kotlin.Byte"(i8* %0, i8* %1, i8 signext %2)
|
// CHECK-LABEL: signext i8 @"objc2kotlin_kfun:#f1AndThisIsCrazy(kotlin.Byte){}kotlin.Byte"(i8* %0, i8* %1, i8 signext %2)
|
||||||
fun andThisIsCrazy(arg: Byte): Byte {
|
fun f1AndThisIsCrazy(arg: Byte): Byte {
|
||||||
// CHECK: invoke signext i8 @"kfun:#andThisIsCrazy(kotlin.Byte){}kotlin.Byte"(i8 signext %2)
|
// CHECK: invoke signext i8 @"kfun:#f1AndThisIsCrazy(kotlin.Byte){}kotlin.Byte"(i8 signext %2)
|
||||||
return arg
|
return arg
|
||||||
}
|
}
|
||||||
|
|
||||||
// CHECK-LABEL: signext i16 @"objc2kotlin_kfun:#butHereIsMyNumber(kotlin.Short){}kotlin.Short"(i8* %0, i8* %1, i16 signext %2)
|
// CHECK-LABEL: signext i16 @"objc2kotlin_kfun:#f2ButHereIsMyNumber(kotlin.Short){}kotlin.Short"(i8* %0, i8* %1, i16 signext %2)
|
||||||
fun butHereIsMyNumber(arg: Short): Short {
|
fun f2ButHereIsMyNumber(arg: Short): Short {
|
||||||
// CHECK: invoke signext i16 @"kfun:#butHereIsMyNumber(kotlin.Short){}kotlin.Short"(i16 signext %2)
|
// CHECK: invoke signext i16 @"kfun:#f2ButHereIsMyNumber(kotlin.Short){}kotlin.Short"(i16 signext %2)
|
||||||
return arg
|
return arg
|
||||||
}
|
}
|
||||||
|
|
||||||
// CHECK-LABEL: signext i8 @"objc2kotlin_kfun:#soCallMeMaybe(kotlin.Boolean){}kotlin.Boolean"(i8* %0, i8* %1, i8 signext %2)
|
// CHECK-LABEL: signext i8 @"objc2kotlin_kfun:#f3SoCallMeMaybe(kotlin.Boolean){}kotlin.Boolean"(i8* %0, i8* %1, i8 signext %2)
|
||||||
fun soCallMeMaybe(arg: Boolean): Boolean {
|
fun f3SoCallMeMaybe(arg: Boolean): Boolean {
|
||||||
//CHECK: invoke zeroext i1 @"kfun:#soCallMeMaybe(kotlin.Boolean){}kotlin.Boolean"(i1 zeroext {{.*}})
|
//CHECK: invoke zeroext i1 @"kfun:#f3SoCallMeMaybe(kotlin.Boolean){}kotlin.Boolean"(i1 zeroext {{.*}})
|
||||||
return arg
|
return arg
|
||||||
}
|
}
|
||||||
|
|
||||||
// CHECK-LABEL: zeroext i8 @"objc2kotlin_kfun:#itsHardToLook(kotlin.UByte){}kotlin.UByte"(i8* %0, i8* %1, i8 zeroext %2)
|
// CHECK-LABEL: zeroext i8 @"objc2kotlin_kfun:#f4ItsHardToLook(kotlin.UByte){}kotlin.UByte"(i8* %0, i8* %1, i8 zeroext %2)
|
||||||
fun itsHardToLook(arg: UByte): UByte {
|
fun f4ItsHardToLook(arg: UByte): UByte {
|
||||||
// CHECK: invoke zeroext i8 @"kfun:#itsHardToLook(kotlin.UByte){}kotlin.UByte"(i8 zeroext %2)
|
// CHECK: invoke zeroext i8 @"kfun:#f4ItsHardToLook(kotlin.UByte){}kotlin.UByte"(i8 zeroext %2)
|
||||||
return arg
|
return arg
|
||||||
}
|
}
|
||||||
|
|
||||||
// CHECK-LABEL: zeroext i16 @"objc2kotlin_kfun:#rightAtYouBaby(kotlin.UShort){}kotlin.UShort"(i8* %0, i8* %1, i16 zeroext %2)
|
// CHECK-LABEL: zeroext i16 @"objc2kotlin_kfun:#f5RightAtYouBaby(kotlin.UShort){}kotlin.UShort"(i8* %0, i8* %1, i16 zeroext %2)
|
||||||
fun rightAtYouBaby(arg: UShort): UShort {
|
fun f5RightAtYouBaby(arg: UShort): UShort {
|
||||||
// CHECK: invoke zeroext i16 @"kfun:#rightAtYouBaby(kotlin.UShort){}kotlin.UShort"(i16 zeroext %2)
|
// CHECK: invoke zeroext i16 @"kfun:#f5RightAtYouBaby(kotlin.UShort){}kotlin.UShort"(i16 zeroext %2)
|
||||||
return arg
|
return arg
|
||||||
}
|
}
|
||||||
|
|
||||||
// CHECK-LABEL: float @"objc2kotlin_kfun:#butHereIsMyNumber1(kotlin.Float){}kotlin.Float"(i8* %0, i8* %1, float %2)
|
// CHECK-LABEL: float @"objc2kotlin_kfun:#f6ButHereIsMyNumber1(kotlin.Float){}kotlin.Float"(i8* %0, i8* %1, float %2)
|
||||||
fun butHereIsMyNumber1(arg: Float): Float {
|
fun f6ButHereIsMyNumber1(arg: Float): Float {
|
||||||
// CHECK: invoke float @"kfun:#butHereIsMyNumber1(kotlin.Float){}kotlin.Float"(float %2)
|
// CHECK: invoke float @"kfun:#f6ButHereIsMyNumber1(kotlin.Float){}kotlin.Float"(float %2)
|
||||||
return arg
|
return arg
|
||||||
}
|
}
|
||||||
|
|
||||||
// CHECK-LABEL: i8* @"objc2kotlin_kfun:#soCallMeMaybe1(kotlin.Any?){}kotlin.Any?"(i8* %0, i8* %1, i8* %2)
|
// CHECK-LABEL: i8* @"objc2kotlin_kfun:#f7SoCallMeMaybe1(kotlin.Any?){}kotlin.Any?"(i8* %0, i8* %1, i8* %2)
|
||||||
fun soCallMeMaybe1(arg: Any?): Any? {
|
fun f7SoCallMeMaybe1(arg: Any?): Any? {
|
||||||
// CHECK: invoke %struct.ObjHeader* @"kfun:#soCallMeMaybe1(kotlin.Any?){}kotlin.Any?"(%struct.ObjHeader* {{.*}}, %struct.ObjHeader** {{.*}})
|
// CHECK: invoke %struct.ObjHeader* @"kfun:#f7SoCallMeMaybe1(kotlin.Any?){}kotlin.Any?"(%struct.ObjHeader* {{.*}}, %struct.ObjHeader** {{.*}})
|
||||||
return arg
|
return arg
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user