From cc920390a43b6e79caba2b113621d54bcc954d76 Mon Sep 17 00:00:00 2001 From: Matthias Andreas Benkard Date: Fri, 29 Mar 2013 22:16:50 +0100 Subject: Update to LLVM 3.2. --- MLKLexicalContext-MLKLLVMCompilation.mm | 20 ++++++++++---------- llvm_context.mm | 2 +- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/MLKLexicalContext-MLKLLVMCompilation.mm b/MLKLexicalContext-MLKLLVMCompilation.mm index 8f46a70..e426024 100644 --- a/MLKLexicalContext-MLKLLVMCompilation.mm +++ b/MLKLexicalContext-MLKLLVMCompilation.mm @@ -1,6 +1,6 @@ /* -*- mode: objc; coding: utf-8 -*- */ /* Toilet Lisp, a Common Lisp subset for the Étoilé runtime. - * Copyright (C) 2008 Matthias Andreas Benkard. + * Copyright (C) 2008, 2013 Matthias Andreas Benkard. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -58,11 +58,11 @@ id MLKDummyUseLLVMLexicalContext = nil; -(Instruction *) functionCellValueForSymbol:(id)name { - std::vector types (2, PointerType::get(PointerType::get(Int8Ty, 0), 0)); - return (new IntToPtrInst (ConstantInt::get(Int64Ty, + std::vector types (2, PointerType::get(PointerType::get(const_cast(Int8Ty), 0), 0)); + return (new IntToPtrInst (ConstantInt::get(const_cast(Int64Ty), (uint64_t)[self functionCellForSymbol:name], false), - PointerType::get(PointerType::get(FunctionType::get(PointerType::get(Int8Ty, + PointerType::get(PointerType::get(FunctionType::get(PointerType::get(const_cast(Int8Ty), 0), types, true), @@ -72,27 +72,27 @@ id MLKDummyUseLLVMLexicalContext = nil; -(Instruction *) closureDataPointerValueForSymbol:(id)name { - return (new IntToPtrInst (ConstantInt::get(Int64Ty, + return (new IntToPtrInst (ConstantInt::get(const_cast(Int64Ty), (uint64_t)[self closureDataPointerForSymbol:name], false), - PointerType::get(PointerType::get(PointerType::get(Int8Ty, 0), 0), 0))); + PointerType::get(PointerType::get(PointerType::get(const_cast(Int8Ty), 0), 0), 0))); } -(Instruction *) closureDataLengthValueForSymbol:(id)name { // The length cell isn't really a void** but an intptr_t*. - return (new IntToPtrInst (ConstantInt::get(Int64Ty, + return (new IntToPtrInst (ConstantInt::get(const_cast(Int64Ty), (uint64_t)[self closureDataLengthForSymbol:name], false), - PointerType::get(PointerType::get(Int8Ty, 0), 0))); + PointerType::get(PointerType::get(const_cast(Int8Ty), 0), 0))); } -(Instruction *) globalBindingValueForSymbol:(id)name { - return (new IntToPtrInst (ConstantInt::get(Int64Ty, + return (new IntToPtrInst (ConstantInt::get(const_cast(Int64Ty), (uint64_t)[self bindingForSymbol:name], false), - PointerType::get(Int8Ty, 0))); + PointerType::get(const_cast(Int8Ty), 0))); } -(Value *) bindingValueForSymbol:(id)name diff --git a/llvm_context.mm b/llvm_context.mm index ecf71a0..5eefdb4 100644 --- a/llvm_context.mm +++ b/llvm_context.mm @@ -12,7 +12,7 @@ #include #include -#include +//#include using namespace llvm; LLVMContext *llvm_context; -- cgit v1.2.3