[js] Fix constant folding for unsigned aithmetic in IR

this resolves KT-44138
This commit is contained in:
Shagen Ogandzhanian
2021-03-30 16:53:12 +02:00
parent 36bc71121a
commit e0e2715864
13 changed files with 677 additions and 213 deletions
@@ -4819,6 +4819,11 @@ public class IrJsCodegenBoxES6TestGenerated extends AbstractIrJsCodegenBoxES6Tes
runTest("compiler/testData/codegen/box/constants/float.kt");
}
@TestMetadata("foldingBinaryOpsUnsigned.kt")
public void testFoldingBinaryOpsUnsigned() throws Exception {
runTest("compiler/testData/codegen/box/constants/foldingBinaryOpsUnsigned.kt");
}
@TestMetadata("kt9532.kt")
public void testKt9532() throws Exception {
runTest("compiler/testData/codegen/box/constants/kt9532.kt");
@@ -27316,11 +27321,6 @@ public class IrJsCodegenBoxES6TestGenerated extends AbstractIrJsCodegenBoxES6Tes
runTest("compiler/testData/codegen/box/unsignedTypes/kt25784.kt");
}
@TestMetadata("kt30402.kt")
public void testKt30402() throws Exception {
runTest("compiler/testData/codegen/box/unsignedTypes/kt30402.kt");
}
@TestMetadata("kt43286.kt")
public void testKt43286() throws Exception {
runTest("compiler/testData/codegen/box/unsignedTypes/kt43286.kt");
@@ -4240,6 +4240,11 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
runTest("compiler/testData/codegen/box/constants/float.kt");
}
@TestMetadata("foldingBinaryOpsUnsigned.kt")
public void testFoldingBinaryOpsUnsigned() throws Exception {
runTest("compiler/testData/codegen/box/constants/foldingBinaryOpsUnsigned.kt");
}
@TestMetadata("kt9532.kt")
public void testKt9532() throws Exception {
runTest("compiler/testData/codegen/box/constants/kt9532.kt");
@@ -26737,11 +26742,6 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
runTest("compiler/testData/codegen/box/unsignedTypes/kt25784.kt");
}
@TestMetadata("kt30402.kt")
public void testKt30402() throws Exception {
runTest("compiler/testData/codegen/box/unsignedTypes/kt30402.kt");
}
@TestMetadata("kt43286.kt")
public void testKt43286() throws Exception {
runTest("compiler/testData/codegen/box/unsignedTypes/kt43286.kt");
@@ -4240,6 +4240,11 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest {
runTest("compiler/testData/codegen/box/constants/float.kt");
}
@TestMetadata("foldingBinaryOpsUnsigned.kt")
public void testFoldingBinaryOpsUnsigned() throws Exception {
runTest("compiler/testData/codegen/box/constants/foldingBinaryOpsUnsigned.kt");
}
@TestMetadata("kt9532.kt")
public void testKt9532() throws Exception {
runTest("compiler/testData/codegen/box/constants/kt9532.kt");
@@ -26697,11 +26702,6 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest {
runTest("compiler/testData/codegen/box/unsignedTypes/kt25784.kt");
}
@TestMetadata("kt30402.kt")
public void testKt30402() throws Exception {
runTest("compiler/testData/codegen/box/unsignedTypes/kt30402.kt");
}
@TestMetadata("kt43286.kt")
public void testKt43286() throws Exception {
runTest("compiler/testData/codegen/box/unsignedTypes/kt43286.kt");
@@ -3046,6 +3046,11 @@ public class IrCodegenBoxWasmTestGenerated extends AbstractIrCodegenBoxWasmTest
runTest("compiler/testData/codegen/box/constants/constantsInWhen.kt");
}
@TestMetadata("foldingBinaryOpsUnsigned.kt")
public void testFoldingBinaryOpsUnsigned() throws Exception {
runTest("compiler/testData/codegen/box/constants/foldingBinaryOpsUnsigned.kt");
}
@TestMetadata("long.kt")
public void testLong() throws Exception {
runTest("compiler/testData/codegen/box/constants/long.kt");
@@ -14996,11 +15001,6 @@ public class IrCodegenBoxWasmTestGenerated extends AbstractIrCodegenBoxWasmTest
runTest("compiler/testData/codegen/box/unsignedTypes/iterateOverListOfBoxedUnsignedValues.kt");
}
@TestMetadata("kt30402.kt")
public void testKt30402() throws Exception {
runTest("compiler/testData/codegen/box/unsignedTypes/kt30402.kt");
}
@TestMetadata("kt43286.kt")
public void testKt43286() throws Exception {
runTest("compiler/testData/codegen/box/unsignedTypes/kt43286.kt");