Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Check RBX_LLVM env to enable LLVM. Minor fixes to build.

* Added missing #include for some #defines
* Fixed to use const char* with string literals.
  • Loading branch information...
commit 555a39754eae737429861cfc68c09056611a1834 1 parent 27a0f6d
Eero Saynatkari rue authored
4 rakelib/vm.rake
View
@@ -27,7 +27,7 @@ else
LLVM_STYLE = "Release"
end
-LLVM_ENABLE = false
+LLVM_ENABLE = !!ENV['RBX_LLVM']
ENV.delete 'CDPATH' # confuses llvm_config
LLVM_CONFIG = "vm/external_libs/llvm/#{LLVM_STYLE}/bin/llvm-config"
@@ -161,7 +161,7 @@ else
end
OPTIONS = {
- LLVM_A => "--enable-targets=host-only"
+ LLVM_A => "--enable-targets=host-only --enable-bindings=none"
}
if LLVM_STYLE == "Release"
2  vm/llvm/jit.cpp
View
@@ -142,7 +142,7 @@ namespace rubinius {
Value* val = CallInst::Create(func_ae, call_args, call_args+5, "ret", arg_error);
ReturnInst::Create(val, arg_error);
- // Switch to using contuation
+ // Switch to using continuation
block = cont;
// Prepare the scope
2  vm/llvm/jit.hpp
View
@@ -2,6 +2,8 @@
#define RBX_LLVM_JIT_HPP
#include <stdint.h>
+#include <unistd.h>
+
#include <llvm/Module.h>
#include <llvm/DerivedTypes.h>
#include <llvm/Function.h>
8 vm/llvm/jit_visit.hpp
View
@@ -359,7 +359,7 @@ namespace rubinius {
types.push_back(IntPtrTy);
types.push_back(ObjArrayTy);
- char* func_name;
+ const char* func_name;
if(priv) {
func_name = "rbx_inline_cache_send_private";
} else {
@@ -396,7 +396,7 @@ namespace rubinius {
std::vector<const Type*> types;
add_send_args(types);
- char* func_name;
+ const char* func_name;
if(priv) {
func_name = "rbx_block_send_private";
} else {
@@ -431,7 +431,7 @@ namespace rubinius {
types.push_back(IntPtrTy);
types.push_back(ObjArrayTy);
- char* func_name;
+ const char* func_name;
if(priv) {
func_name = "rbx_splat_send_private";
} else {
@@ -466,7 +466,7 @@ namespace rubinius {
types.push_back(IntPtrTy);
types.push_back(ObjArrayTy);
- char* func_name;
+ const char* func_name;
int extra = 1;
if(splat) {
func_name = "rbx_super_splat_send";
Please sign in to comment.
Something went wrong with that request. Please try again.