Created
August 29, 2009 20:55
-
-
Save dbussink/177679 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/vm/llvm/inline_primitive.cpp b/vm/llvm/inline_primitive.cpp | |
index 3a6be9f..deee7ae 100644 | |
--- a/vm/llvm/inline_primitive.cpp | |
+++ b/vm/llvm/inline_primitive.cpp | |
@@ -101,8 +101,8 @@ namespace rubinius { | |
Value* anded = BinaryOperator::CreateAnd(lint, rint, "fixnums_anded", ops.current_block()); | |
- Value* fix_mask = ConstantInt::get(Type::Int32Ty, TAG_FIXNUM_MASK); | |
- Value* fix_tag = ConstantInt::get(Type::Int32Ty, TAG_FIXNUM); | |
+ Value* fix_mask = ConstantInt::get(ops.NativeIntTy, TAG_FIXNUM_MASK); | |
+ Value* fix_tag = ConstantInt::get(ops.NativeIntTy, TAG_FIXNUM); | |
Value* masked = BinaryOperator::CreateAnd(anded, fix_mask, "masked", ops.current_block()); | |
diff --git a/vm/llvm/jit_operations.hpp b/vm/llvm/jit_operations.hpp | |
index 8d61359..41efb58 100644 | |
--- a/vm/llvm/jit_operations.hpp | |
+++ b/vm/llvm/jit_operations.hpp | |
@@ -1,6 +1,7 @@ | |
#ifndef RBX_LLVM_JIT_OPERATIONS | |
#define RBX_LLVM_JIT_OPERATIONS | |
+#include "config.h" | |
#include "builtin/class.hpp" | |
#include "builtin/fixnum.hpp" | |
#include "builtin/symbol.hpp" | |
@@ -77,7 +78,7 @@ namespace rubinius { | |
zero_ = ConstantInt::get(Type::Int32Ty, 0); | |
one_ = ConstantInt::get(Type::Int32Ty, 1); | |
-#if __LP64__ | |
+#ifdef IS_X8664 | |
IntPtrTy = llvm::Type::Int64Ty; | |
FixnumTy = llvm::IntegerType::get(63); | |
#else | |
@@ -364,7 +365,7 @@ namespace rubinius { | |
} | |
Value* last_sp_as_int() { | |
- return ConstantInt::get(Type::Int32Ty, last_sp_); | |
+ return ConstantInt::get(NativeIntTy, last_sp_); | |
} | |
void flush_stack() { } | |
diff --git a/vm/llvm/jit_visit.hpp b/vm/llvm/jit_visit.hpp | |
index 5939323..9fd1c9b 100644 | |
--- a/vm/llvm/jit_visit.hpp | |
+++ b/vm/llvm/jit_visit.hpp | |
@@ -1188,7 +1188,7 @@ namespace rubinius { | |
sig << "VM"; | |
sig << "CallFrame"; | |
sig << "Arguments"; | |
- sig << IntPtrTy; | |
+ sig << NativeIntTy; | |
Value* call_args[] = { vm_, call_frame_, args_, sp }; | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment