[llvm-commits] CVS: llvm-java/lib/Compiler/Compiler.cpp
Alkis Evlogimenos
alkis at cs.uiuc.edu
Sun May 23 06:16:01 PDT 2004
Changes in directory llvm-java/lib/Compiler:
Compiler.cpp updated: 1.10 -> 1.11
---
Log message:
Use ConstantSInt::get instead of ConstantInt::get so that all possible
int values can be handled.
---
Diffs of the changes: (+4 -4)
Index: llvm-java/lib/Compiler/Compiler.cpp
diff -u llvm-java/lib/Compiler/Compiler.cpp:1.10 llvm-java/lib/Compiler/Compiler.cpp:1.11
--- llvm-java/lib/Compiler/Compiler.cpp:1.10 Sun May 23 05:33:37 2004
+++ llvm-java/lib/Compiler/Compiler.cpp Sun May 23 06:14:42 2004
@@ -197,11 +197,11 @@
case ICONST_3:
case ICONST_4:
case ICONST_5:
- opStack_.push(ConstantInt::get(Type::IntTy, code[i]-ICONST_0));
+ opStack_.push(ConstantSInt::get(Type::IntTy, code[i]-ICONST_0));
break;
case LCONST_0:
case LCONST_1:
- opStack_.push(ConstantInt::get(Type::LongTy, code[i]-LCONST_0));
+ opStack_.push(ConstantSInt::get(Type::LongTy, code[i]-LCONST_0));
break;
case FCONST_0:
case FCONST_1:
@@ -214,12 +214,12 @@
break;
case BIPUSH: {
int imm = readSByte(code, i);
- opStack_.push(ConstantInt::get(Type::IntTy, imm));
+ opStack_.push(ConstantSInt::get(Type::IntTy, imm));
break;
}
case SIPUSH: {
int imm = readSShort(code, i);
- opStack_.push(ConstantInt::get(Type::IntTy, imm));
+ opStack_.push(ConstantSInt::get(Type::IntTy, imm));
break;
}
case LDC: {
More information about the llvm-commits
mailing list