[vmkit-commits] [vmkit] r184414 - Migrating to LLVM version 3.3 release.

Koutheir Attouchi koutheir at gmail.com
Thu Jun 20 05:38:37 PDT 2013


Author: koutheir
Date: Thu Jun 20 07:38:37 2013
New Revision: 184414

URL: http://llvm.org/viewvc/llvm-project?rev=184414&view=rev
Log:
Migrating to LLVM version 3.3 release.

Modified:
    vmkit/branches/incinerator/README.TXT
    vmkit/branches/incinerator/include/j3/JavaLLVMCompiler.h
    vmkit/branches/incinerator/include/vmkit/InlineCommon.h
    vmkit/branches/incinerator/lib/j3/Compiler/EscapeAnalysis.cpp
    vmkit/branches/incinerator/lib/j3/Compiler/J3Intrinsics.cpp
    vmkit/branches/incinerator/lib/j3/Compiler/JavaAOTCompiler.cpp
    vmkit/branches/incinerator/lib/j3/Compiler/JavaJIT.cpp
    vmkit/branches/incinerator/lib/j3/Compiler/JavaJIT.h
    vmkit/branches/incinerator/lib/j3/Compiler/JavaJITCompiler.cpp
    vmkit/branches/incinerator/lib/j3/Compiler/JavaJITOpcodes.cpp
    vmkit/branches/incinerator/lib/j3/Compiler/JavaLLVMCompiler.cpp
    vmkit/branches/incinerator/lib/j3/Compiler/LLVMInfo.cpp
    vmkit/branches/incinerator/lib/j3/Compiler/LowerConstantCalls.cpp
    vmkit/branches/incinerator/lib/static-gc-pass/StaticGCPass.cpp
    vmkit/branches/incinerator/lib/static-gc-printer/VmkitGCPrinter.cpp
    vmkit/branches/incinerator/lib/vmkit/Compiler/InlineMalloc.cpp
    vmkit/branches/incinerator/lib/vmkit/Compiler/JIT.cpp
    vmkit/branches/incinerator/lib/vmkit/JITGCPass/JITGCPass.cpp
    vmkit/branches/incinerator/mmtk/magic/LowerJavaRT.cpp
    vmkit/branches/incinerator/mmtk/magic/LowerMagic.cpp
    vmkit/branches/incinerator/patches/llvm.patch
    vmkit/branches/incinerator/tools/vmjc/vmjc.cpp

Modified: vmkit/branches/incinerator/README.TXT
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/README.TXT?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/README.TXT (original)
+++ vmkit/branches/incinerator/README.TXT Thu Jun 20 07:38:37 2013
@@ -53,24 +53,24 @@ ln -sf ../native/jni/java-util/.libs/lib
 LLVM:
 =====
 
-* Get the compatible release LLVM 3.2:
+* Get the compatible release LLVM 3.3:
 
-wget http://llvm.org/releases/3.2/llvm-3.2.src.tar.gz
-tar zxf llvm-3.2.src.tar.gz
-cd llvm-3.2.src/tools
-wget http://llvm.org/releases/3.2/clang-3.2.src.tar.gz
-tar zxf clang-3.2.src.tar.gz
-mv clang-3.2.src clang
+wget http://llvm.org/releases/3.3/llvm-3.3.src.tar.gz
+tar zxf llvm-3.3.src.tar.gz
+cd llvm-3.3.src/tools
+wget http://llvm.org/releases/3.3/cfe-3.3.src.tar.gz
+tar zxf cfe-3.3.src.tar.gz
+mv cfe-3.3.src clang
 cd ../projects
-wget http://llvm.org/releases/3.2/compiler-rt-3.2.src.tar.gz
-tar zxf compiler-rt-3.2.src.tar.gz
-mv compiler-rt-3.2.src compiler-rt
+wget http://llvm.org/releases/3.3/compiler-rt-3.3.src.tar.gz
+tar zxf compiler-rt-3.3.src.tar.gz
+mv compiler-rt-3.3.src compiler-rt
 cd ../..
 
 * Patch LLVM if you want to have a better debug support for VMKit:
   You will have to get VMKit (see the next section) to find the patch.
 
-cd llvm-3.2.src
+cd llvm-3.3.src
 patch -p1 < ../vmkit2/patches/llvm.patch
 
 NOTICE:
@@ -80,12 +80,12 @@ NOTICE:
 
 * Make it (release mode):
 
-./configure --enable-optimized --enable-assertions --enable-jit --enable-threads --enable-pthreads --enable-pic --enable-targets=x86,cpp --disable-docs --disable-doxygen
+./configure --enable-optimized --enable-assertions --enable-jit --enable-cxx11 --enable-threads --enable-pthreads --enable-pic --enable-targets=host,cpp --enable-zlib --disable-docs --disable-doxygen
 make -j12 BUILD_EXAMPLES=0 ENABLE_DOCS=0
 
 * You can also make it in debug mode, but this is is not necessary to debug compiled programs:
 
-./configure --disable-optimized --enable-assertions --enable-debug-runtime --enable-debug-symbols --enable-keep-symbols --enable-jit --enable-threads --enable-pthreads --enable-pic --enable-targets=x86,cpp --disable-docs --disable-doxygen
+./configure --disable-optimized --enable-debug-runtime --enable-debug-symbols --enable-keep-symbols --enable-assertions --enable-jit --enable-cxx11 --enable-threads --enable-pthreads --enable-pic --enable-targets=host,cpp --enable-zlib --disable-docs --disable-doxygen
 
 * Build it:
 
@@ -95,13 +95,13 @@ make -j12 BUILD_EXAMPLES=0 ENABLE_DOCS=0
 VMKit:
 ======
 
-* Get it anonymously (git):
+* Get it anonymously:
 
-git clone git://scm.gforge.inria.fr/vmkit2/vmkit2.git
+svn co http://llvm.org/svn/llvm-project/vmkit/trunk
 
-* or get as an official developer (Git):
+* or get as an official developer:
 
-git clone git+ssh://YOUR_USER_NAME@scm.gforge.inria.fr//gitroot/vmkit2/vmkit2.git
+svn co https://YOUR_USER_NAME@llvm.org/svn/llvm-project/vmkit/trunk
 
 * Make it (release mode):
 
@@ -118,4 +118,3 @@ git clone git+ssh://YOUR_USER_NAME@scm.g
 * Build it:
 
 make -j12
-

Modified: vmkit/branches/incinerator/include/j3/JavaLLVMCompiler.h
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/include/j3/JavaLLVMCompiler.h?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/include/j3/JavaLLVMCompiler.h (original)
+++ vmkit/branches/incinerator/include/j3/JavaLLVMCompiler.h Thu Jun 20 07:38:37 2013
@@ -15,8 +15,8 @@
 #include "j3/LLVMInfo.h"
 
 #include "llvm/ADT/DenseMap.h"
-#include "llvm/LLVMContext.h"
-#include "llvm/Module.h"
+#include "llvm/IR/LLVMContext.h"
+#include "llvm/IR/Module.h"
 
 #include <map>
 

Modified: vmkit/branches/incinerator/include/vmkit/InlineCommon.h
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/include/vmkit/InlineCommon.h?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/include/vmkit/InlineCommon.h (original)
+++ vmkit/branches/incinerator/include/vmkit/InlineCommon.h Thu Jun 20 07:38:37 2013
@@ -1,13 +1,13 @@
 #ifndef _INLINE_COMMON_H_
 #define _INLINE_COMMON_H_
 
-#include <llvm/CallingConv.h>
-#include <llvm/Constants.h>
-#include <llvm/DerivedTypes.h>
-#include <llvm/Instructions.h>
-#include <llvm/LLVMContext.h>
-#include <llvm/Module.h>
-#include <llvm/Type.h>
+#include <llvm/IR/CallingConv.h>
+#include <llvm/IR/Constants.h>
+#include <llvm/IR/DerivedTypes.h>
+#include <llvm/IR/Instructions.h>
+#include <llvm/IR/LLVMContext.h>
+#include <llvm/IR/Module.h>
+#include <llvm/IR/Type.h>
 
 namespace vmkit {
 	extern "C" void makeLLVMFunctions_FinalMMTk(llvm::Module*);

Modified: vmkit/branches/incinerator/lib/j3/Compiler/EscapeAnalysis.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/j3/Compiler/EscapeAnalysis.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/j3/Compiler/EscapeAnalysis.cpp (original)
+++ vmkit/branches/incinerator/lib/j3/Compiler/EscapeAnalysis.cpp Thu Jun 20 07:38:37 2013
@@ -8,12 +8,12 @@
 //===----------------------------------------------------------------------===//
 
 
-#include "llvm/Constants.h"
-#include "llvm/Function.h"
-#include "llvm/GlobalVariable.h"
-#include "llvm/Module.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/Function.h"
+#include "llvm/IR/GlobalVariable.h"
+#include "llvm/IR/Module.h"
 #include "llvm/Pass.h"
-#include "llvm/Instructions.h"
+#include "llvm/IR/Instructions.h"
 #include "llvm/Analysis/LoopInfo.h"
 #include "llvm/Support/CallSite.h"
 #include "llvm/Support/Compiler.h"
@@ -127,7 +127,7 @@ static bool escapes(Value* Ins, std::map
         CallSite::arg_iterator B = CS.arg_begin(), E = CS.arg_end();
         for (CallSite::arg_iterator A = B; A != E; ++A) {
           if (A->get() == Ins && 
-              !CS.paramHasAttr(A - B + 1, Attributes::NoCapture)) {
+              !CS.paramHasAttr(A - B + 1, Attribute::NoCapture)) {
             return true;
           }
         }

Modified: vmkit/branches/incinerator/lib/j3/Compiler/J3Intrinsics.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/j3/Compiler/J3Intrinsics.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/j3/Compiler/J3Intrinsics.cpp (original)
+++ vmkit/branches/incinerator/lib/j3/Compiler/J3Intrinsics.cpp Thu Jun 20 07:38:37 2013
@@ -7,10 +7,10 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "llvm/Constants.h"
-#include "llvm/DerivedTypes.h"
-#include "llvm/LLVMContext.h"
-#include "llvm/Module.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/DerivedTypes.h"
+#include "llvm/IR/LLVMContext.h"
+#include "llvm/IR/Module.h"
 
 #include "vmkit/JIT.h"
 

Modified: vmkit/branches/incinerator/lib/j3/Compiler/JavaAOTCompiler.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/j3/Compiler/JavaAOTCompiler.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/j3/Compiler/JavaAOTCompiler.cpp (original)
+++ vmkit/branches/incinerator/lib/j3/Compiler/JavaAOTCompiler.cpp Thu Jun 20 07:38:37 2013
@@ -7,15 +7,15 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "llvm/BasicBlock.h"
-#include "llvm/Constants.h"
-#include "llvm/Instructions.h"
-#include "llvm/LLVMContext.h"
-#include "llvm/Module.h"
+#include "llvm/IR/BasicBlock.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/Instructions.h"
+#include "llvm/IR/LLVMContext.h"
+#include "llvm/IR/Module.h"
 #include "llvm/PassManager.h"
 #include "llvm/Support/raw_ostream.h"
 #include "llvm/Support/TargetRegistry.h"
-#include "llvm/DataLayout.h"
+#include "llvm/IR/DataLayout.h"
 
 #include "vmkit/UTF8.h"
 #include "vmkit/Thread.h"

Modified: vmkit/branches/incinerator/lib/j3/Compiler/JavaJIT.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/j3/Compiler/JavaJIT.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/j3/Compiler/JavaJIT.cpp (original)
+++ vmkit/branches/incinerator/lib/j3/Compiler/JavaJIT.cpp Thu Jun 20 07:38:37 2013
@@ -16,12 +16,12 @@
 #include <sstream>
 #include <cstring>
 
-#include <llvm/Constants.h>
-#include <llvm/DerivedTypes.h>
-#include <llvm/Function.h>
-#include <llvm/Instructions.h>
-#include <llvm/Module.h>
-#include <llvm/Type.h>
+#include <llvm/IR/Constants.h>
+#include <llvm/IR/DerivedTypes.h>
+#include <llvm/IR/Function.h>
+#include <llvm/IR/Instructions.h>
+#include <llvm/IR/Module.h>
+#include <llvm/IR/Type.h>
 #include <llvm/Support/CFG.h>
 
 #include "vmkit/JIT.h"
@@ -1003,7 +1003,10 @@ llvm::Function* JavaJIT::javaCompile() {
 
   string methName, methNameLink;
   DbgSubprogram = TheCompiler->getDebugFactory()->createFunction(
-      DIDescriptor(), compilingMethod->getName(methName, false), compilingMethod->getName(methNameLink, true), DIFile(), 0, DIType(), false, false, 0);
+      DIDescriptor(), compilingMethod->getName(methName, false),
+      compilingMethod->getName(methNameLink, true), DIFile(), 0,
+      TheCompiler->getDebugFactory()->createSubroutineType(DIFile(), DIArray()),
+      false, false, 0);
 
   JavaAttribute* codeAtt = compilingMethod->lookupAttribute(JavaAttribute::codeAttribute);
   
@@ -1290,11 +1293,12 @@ llvm::Function* JavaJIT::javaCompile() {
       const UTF8* name =
         compilingClass->ctpInfo->UTF8At(AR.AnnotationNameIndex);
       if (name->equals(TheCompiler->InlinePragma)) {
-        llvmFunction->removeFnAttr(
-            Attributes::get(*llvmContext, llvm::Attributes::NoInline));
-        llvmFunction->addFnAttr(llvm::Attributes::AlwaysInline);
+        llvmFunction->removeAttributes(llvm::AttributeSet::FunctionIndex,
+          llvm::AttributeSet::get(*llvmContext,
+            llvm::AttributeSet::FunctionIndex, llvm::Attribute::NoInline));
+        llvmFunction->addFnAttr(llvm::Attribute::AlwaysInline);
       } else if (name->equals(TheCompiler->NoInlinePragma)) {
-        llvmFunction->addFnAttr(llvm::Attributes::NoInline);
+        llvmFunction->addFnAttr(llvm::Attribute::NoInline);
       }
     }
   }

Modified: vmkit/branches/incinerator/lib/j3/Compiler/JavaJIT.h
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/j3/Compiler/JavaJIT.h?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/j3/Compiler/JavaJIT.h (original)
+++ vmkit/branches/incinerator/lib/j3/Compiler/JavaJIT.h Thu Jun 20 07:38:37 2013
@@ -13,13 +13,13 @@
 #include <vector>
 #include <map>
 
-#include "llvm/BasicBlock.h"
-#include "llvm/Function.h"
-#include "llvm/Instructions.h"
-#include "llvm/LLVMContext.h"
-#include "llvm/Metadata.h"
-#include "llvm/Type.h"
-#include "llvm/Value.h"
+#include "llvm/IR/BasicBlock.h"
+#include "llvm/IR/Function.h"
+#include "llvm/IR/Instructions.h"
+#include "llvm/IR/LLVMContext.h"
+#include "llvm/IR/Metadata.h"
+#include "llvm/IR/Type.h"
+#include "llvm/IR/Value.h"
 #include "llvm/DIBuilder.h"
 #include "llvm/DebugInfo.h"
 #include "llvm/Support/DebugLoc.h"

Modified: vmkit/branches/incinerator/lib/j3/Compiler/JavaJITCompiler.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/j3/Compiler/JavaJITCompiler.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/j3/Compiler/JavaJITCompiler.cpp (original)
+++ vmkit/branches/incinerator/lib/j3/Compiler/JavaJITCompiler.cpp Thu Jun 20 07:38:37 2013
@@ -7,12 +7,12 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "llvm/Constants.h"
-#include "llvm/DerivedTypes.h"
-#include "llvm/Function.h"
-#include "llvm/Instructions.h"
-#include "llvm/LLVMContext.h"
-#include "llvm/Module.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/DerivedTypes.h"
+#include "llvm/IR/Function.h"
+#include "llvm/IR/Instructions.h"
+#include "llvm/IR/LLVMContext.h"
+#include "llvm/IR/Module.h"
 #include "llvm/DebugInfo.h"
 #include "llvm/CodeGen/GCStrategy.h"
 #include <llvm/CodeGen/JITCodeEmitter.h>
@@ -22,7 +22,7 @@
 #include "llvm/Support/ManagedStatic.h"
 #include "llvm/Support/Debug.h"
 #include "llvm/Support/raw_ostream.h"
-#include "llvm/DataLayout.h"
+#include "llvm/IR/DataLayout.h"
 #include <lib/ExecutionEngine/JIT/JIT.h>
 
 #include "VmkitGC.h"

Modified: vmkit/branches/incinerator/lib/j3/Compiler/JavaJITOpcodes.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/j3/Compiler/JavaJITOpcodes.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/j3/Compiler/JavaJITOpcodes.cpp (original)
+++ vmkit/branches/incinerator/lib/j3/Compiler/JavaJITOpcodes.cpp Thu Jun 20 07:38:37 2013
@@ -14,12 +14,12 @@
 #include <cstring>
 #include <queue>
 
-#include <llvm/Constants.h>
-#include <llvm/DerivedTypes.h>
-#include <llvm/Function.h>
-#include <llvm/Instructions.h>
-#include <llvm/Module.h>
-#include <llvm/Type.h>
+#include <llvm/IR/Constants.h>
+#include <llvm/IR/DerivedTypes.h>
+#include <llvm/IR/Function.h>
+#include <llvm/IR/Instructions.h>
+#include <llvm/IR/Module.h>
+#include <llvm/IR/Type.h>
 
 #include "vmkit/JIT.h"
 

Modified: vmkit/branches/incinerator/lib/j3/Compiler/JavaLLVMCompiler.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/j3/Compiler/JavaLLVMCompiler.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/j3/Compiler/JavaLLVMCompiler.cpp (original)
+++ vmkit/branches/incinerator/lib/j3/Compiler/JavaLLVMCompiler.cpp Thu Jun 20 07:38:37 2013
@@ -7,12 +7,12 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "llvm/LLVMContext.h"
-#include "llvm/Module.h"
+#include "llvm/IR/LLVMContext.h"
+#include "llvm/IR/Module.h"
 #include "llvm/PassManager.h"
 #include "llvm/DIBuilder.h"
 #include "llvm/Analysis/LoopPass.h"
-#include "llvm/DataLayout.h"
+#include "llvm/IR/DataLayout.h"
 
 #include "vmkit/JIT.h"
 

Modified: vmkit/branches/incinerator/lib/j3/Compiler/LLVMInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/j3/Compiler/LLVMInfo.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/j3/Compiler/LLVMInfo.cpp (original)
+++ vmkit/branches/incinerator/lib/j3/Compiler/LLVMInfo.cpp Thu Jun 20 07:38:37 2013
@@ -7,14 +7,14 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "llvm/BasicBlock.h"
-#include "llvm/CallingConv.h"
-#include "llvm/Constants.h"
-#include "llvm/Instructions.h"
-#include "llvm/Module.h"
+#include "llvm/IR/BasicBlock.h"
+#include "llvm/IR/CallingConv.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/Instructions.h"
+#include "llvm/IR/Module.h"
 #include "llvm/Support/CommandLine.h"
 #include "llvm/Support/MutexGuard.h"
-#include "llvm/DataLayout.h"
+#include "llvm/IR/DataLayout.h"
 
 
 #include "vmkit/JIT.h"
@@ -191,9 +191,9 @@ Function* LLVMMethodInfo::getMethod(Clas
    
     result->setGC("vmkit");
     if (Compiler->useCooperativeGC()) { 
-      result->addFnAttr(Attributes::NoInline);
+      result->addFnAttr(Attribute::NoInline);
     }
-    result->addFnAttr(Attributes::NoUnwind);
+    result->addFnAttr(Attribute::NoUnwind);
     
     Compiler->functions.insert(std::make_pair(result, methodDef));
     if (!Compiler->isStaticCompiling() && !customizing && methodDef->code) {
@@ -460,8 +460,8 @@ Function* LLVMSignatureInfo::createFunct
   }
   
   res->setGC("vmkit");
-  res->addFnAttr(Attributes::NoInline);
-  res->addFnAttr(Attributes::NoUnwind);
+  res->addFnAttr(Attribute::NoInline);
+  res->addFnAttr(Attribute::NoUnwind);
 
   if (virt) {
     Compiler->virtualBufs[FTy] = res;
@@ -550,8 +550,8 @@ Function* LLVMSignatureInfo::createFunct
   }
   
   res->setGC("vmkit");
-  res->addFnAttr(Attributes::NoInline);
-  res->addFnAttr(Attributes::NoUnwind);
+  res->addFnAttr(Attribute::NoInline);
+  res->addFnAttr(Attribute::NoUnwind);
   
   if (virt) {
     Compiler->virtualAPs[FTy] = res;
@@ -671,8 +671,8 @@ Function* LLVMSignatureInfo::createFunct
   }
   
   stub->setGC("vmkit");
-  stub->addFnAttr(Attributes::NoInline);
-  stub->addFnAttr(Attributes::NoUnwind);
+  stub->addFnAttr(Attribute::NoInline);
+  stub->addFnAttr(Attribute::NoUnwind);
   
   if (virt) {
     Compiler->virtualStubs[FTy] = stub;

Modified: vmkit/branches/incinerator/lib/j3/Compiler/LowerConstantCalls.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/j3/Compiler/LowerConstantCalls.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/j3/Compiler/LowerConstantCalls.cpp (original)
+++ vmkit/branches/incinerator/lib/j3/Compiler/LowerConstantCalls.cpp Thu Jun 20 07:38:37 2013
@@ -7,11 +7,11 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "llvm/Constants.h"
-#include "llvm/GlobalVariable.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/GlobalVariable.h"
 #include "llvm/Pass.h"
-#include "llvm/Function.h"
-#include "llvm/Instructions.h"
+#include "llvm/IR/Function.h"
+#include "llvm/IR/Instructions.h"
 #include "llvm/Support/CallSite.h"
 #include "llvm/Support/Compiler.h"
 #include "llvm/Support/Debug.h"

Modified: vmkit/branches/incinerator/lib/static-gc-pass/StaticGCPass.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/static-gc-pass/StaticGCPass.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/static-gc-pass/StaticGCPass.cpp (original)
+++ vmkit/branches/incinerator/lib/static-gc-pass/StaticGCPass.cpp Thu Jun 20 07:38:37 2013
@@ -9,8 +9,8 @@
 //===----------------------------------------------------------------------===//
 
 
-#include "llvm/Intrinsics.h"
-#include "llvm/Module.h"
+#include "llvm/IR/Intrinsics.h"
+#include "llvm/IR/Module.h"
 #include "llvm/Pass.h"
 #include "llvm/Support/raw_ostream.h"
 

Modified: vmkit/branches/incinerator/lib/static-gc-printer/VmkitGCPrinter.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/static-gc-printer/VmkitGCPrinter.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/static-gc-printer/VmkitGCPrinter.cpp (original)
+++ vmkit/branches/incinerator/lib/static-gc-printer/VmkitGCPrinter.cpp Thu Jun 20 07:38:37 2013
@@ -7,23 +7,23 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "llvm/Constants.h"
-#include "llvm/DerivedTypes.h"
-#include "llvm/Type.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/DerivedTypes.h"
+#include "llvm/IR/Type.h"
 #include "llvm/CodeGen/GCs.h"
 #include "llvm/CodeGen/GCStrategy.h"
 #include "llvm/CodeGen/AsmPrinter.h"
 #include "llvm/CodeGen/GCMetadataPrinter.h"
 #include "llvm/CodeGen/MachineFunction.h"
 #include "llvm/CodeGen/MachineInstrBuilder.h"
-#include "llvm/Module.h"
+#include "llvm/IR/Module.h"
 #include "llvm/MC/MCAsmInfo.h"
 #include "llvm/MC/MCContext.h"
 #include "llvm/MC/MCExpr.h"
 #include "llvm/MC/MCSymbol.h"
 #include "llvm/MC/MCStreamer.h"
 #include "llvm/Target/Mangler.h"
-#include "llvm/DataLayout.h"
+#include "llvm/IR/DataLayout.h"
 #include "llvm/Target/TargetInstrInfo.h"
 #include "llvm/Target/TargetLoweringObjectFile.h"
 #include "llvm/Target/TargetMachine.h"

Modified: vmkit/branches/incinerator/lib/vmkit/Compiler/InlineMalloc.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/vmkit/Compiler/InlineMalloc.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/vmkit/Compiler/InlineMalloc.cpp (original)
+++ vmkit/branches/incinerator/lib/vmkit/Compiler/InlineMalloc.cpp Thu Jun 20 07:38:37 2013
@@ -7,16 +7,16 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "llvm/Constants.h"
-#include "llvm/GlobalVariable.h"
-#include "llvm/Function.h"
-#include "llvm/Instructions.h"
-#include "llvm/Module.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/GlobalVariable.h"
+#include "llvm/IR/Function.h"
+#include "llvm/IR/Instructions.h"
+#include "llvm/IR/Module.h"
 #include "llvm/Pass.h"
 #include "llvm/Support/CallSite.h"
 #include "llvm/Support/Debug.h"
 #include "llvm/Support/raw_ostream.h"
-#include "llvm/DataLayout.h"
+#include "llvm/IR/DataLayout.h"
 #include "llvm/Transforms/Utils/Cloning.h"
 
 #include "vmkit/JIT.h"

Modified: vmkit/branches/incinerator/lib/vmkit/Compiler/JIT.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/vmkit/Compiler/JIT.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/vmkit/Compiler/JIT.cpp (original)
+++ vmkit/branches/incinerator/lib/vmkit/Compiler/JIT.cpp Thu Jun 20 07:38:37 2013
@@ -7,16 +7,16 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include <llvm/CallingConv.h>
-#include <llvm/Constants.h>
+#include <llvm/IR/CallingConv.h>
+#include <llvm/IR/Constants.h>
 #include <llvm/DebugInfo.h>
-#include <llvm/DerivedTypes.h>
-#include <llvm/Instructions.h>
+#include <llvm/IR/DerivedTypes.h>
+#include <llvm/IR/Instructions.h>
 #include <llvm/LinkAllPasses.h>
-#include <llvm/LLVMContext.h>
-#include <llvm/Module.h>
+#include <llvm/IR/LLVMContext.h>
+#include <llvm/IR/Module.h>
 #include <llvm/PassManager.h>
-#include <llvm/Type.h>
+#include <llvm/IR/Type.h>
 #include <llvm/Analysis/LoopPass.h>
 #include <llvm/Analysis/Verifier.h>
 #include <llvm/Assembly/Parser.h>
@@ -27,12 +27,12 @@
 #include "llvm/ExecutionEngine/JITEventListener.h"
 #include "llvm/Support/CommandLine.h"
 #include <llvm/Support/Debug.h>
-#include <llvm/Support/IRReader.h>
+#include <llvm/IRReader/IRReader.h>
 #include <llvm/Support/MutexGuard.h>
 #include <llvm/Support/PassNameParser.h>
 #include <llvm/Support/SourceMgr.h>
 #include <llvm/Support/TargetSelect.h>
-#include <llvm/DataLayout.h>
+#include <llvm/IR/DataLayout.h>
 #include <llvm/Target/TargetMachine.h>
 #include <llvm/Target/TargetOptions.h>
 #include <lib/ExecutionEngine/JIT/JIT.h>

Modified: vmkit/branches/incinerator/lib/vmkit/JITGCPass/JITGCPass.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/lib/vmkit/JITGCPass/JITGCPass.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/lib/vmkit/JITGCPass/JITGCPass.cpp (original)
+++ vmkit/branches/incinerator/lib/vmkit/JITGCPass/JITGCPass.cpp Thu Jun 20 07:38:37 2013
@@ -9,8 +9,8 @@
 //===----------------------------------------------------------------------===//
 
 
-#include "llvm/Intrinsics.h"
-#include "llvm/Module.h"
+#include "llvm/IR/Intrinsics.h"
+#include "llvm/IR/Module.h"
 #include "llvm/Pass.h"
 #include "llvm/Support/raw_ostream.h"
 

Modified: vmkit/branches/incinerator/mmtk/magic/LowerJavaRT.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/mmtk/magic/LowerJavaRT.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/mmtk/magic/LowerJavaRT.cpp (original)
+++ vmkit/branches/incinerator/mmtk/magic/LowerJavaRT.cpp Thu Jun 20 07:38:37 2013
@@ -7,11 +7,11 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "llvm/Constants.h"
-#include "llvm/Function.h"
-#include "llvm/Instructions.h"
-#include "llvm/LLVMContext.h"
-#include "llvm/Module.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/Function.h"
+#include "llvm/IR/Instructions.h"
+#include "llvm/IR/LLVMContext.h"
+#include "llvm/IR/Module.h"
 #include "llvm/Pass.h"
 #include "llvm/Support/CallSite.h"
 #include "llvm/Support/Compiler.h"

Modified: vmkit/branches/incinerator/mmtk/magic/LowerMagic.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/mmtk/magic/LowerMagic.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/mmtk/magic/LowerMagic.cpp (original)
+++ vmkit/branches/incinerator/mmtk/magic/LowerMagic.cpp Thu Jun 20 07:38:37 2013
@@ -8,11 +8,11 @@
 //===----------------------------------------------------------------------===//
 
 #include "llvm/ADT/SmallPtrSet.h"
-#include "llvm/Constants.h"
-#include "llvm/Function.h"
-#include "llvm/Instructions.h"
-#include "llvm/LLVMContext.h"
-#include "llvm/Module.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/Function.h"
+#include "llvm/IR/Instructions.h"
+#include "llvm/IR/LLVMContext.h"
+#include "llvm/IR/Module.h"
 #include "llvm/Pass.h"
 #include "llvm/Support/CallSite.h"
 #include "llvm/Support/Compiler.h"

Modified: vmkit/branches/incinerator/patches/llvm.patch
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/patches/llvm.patch?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/patches/llvm.patch (original)
+++ vmkit/branches/incinerator/patches/llvm.patch Thu Jun 20 07:38:37 2013
@@ -1,57 +1,6 @@
---- a/lib/CodeGen/AsmPrinter/AsmPrinter.cpp	2012-11-01 10:14:31.000000000 +0100
-+++ b/lib/CodeGen/AsmPrinter/AsmPrinter.cpp	2013-03-28 17:37:24.297848000 +0100
-@@ -174,22 +174,22 @@ bool AsmPrinter::doInitialization(Module
- 
-   GCModuleInfo *MI = getAnalysisIfAvailable<GCModuleInfo>();
-   assert(MI && "AsmPrinter didn't require GCModuleInfo?");
-   for (GCModuleInfo::iterator I = MI->begin(), E = MI->end(); I != E; ++I)
-     if (GCMetadataPrinter *MP = GetOrCreateGCPrinter(*I))
-       MP->beginAssembly(*this);
--
-+/*
-   // Emit module-level inline asm if it exists.
-   if (!M.getModuleInlineAsm().empty()) {
-     OutStreamer.AddComment("Start of file scope inline assembly");
-     OutStreamer.AddBlankLine();
-     EmitInlineAsm(M.getModuleInlineAsm()+"\n");
-     OutStreamer.AddComment("End of file scope inline assembly");
-     OutStreamer.AddBlankLine();
-   }
--
-+*/
-   if (MAI->doesSupportDebugInformation())
-     DD = new DwarfDebug(this, &M);
- 
-   switch (MAI->getExceptionHandlingType()) {
-   case ExceptionHandling::None:
-     return false;
-@@ -925,12 +925,21 @@ bool AsmPrinter::doFinalization(Module &
-   GCModuleInfo *MI = getAnalysisIfAvailable<GCModuleInfo>();
-   assert(MI && "AsmPrinter didn't require GCModuleInfo?");
-   for (GCModuleInfo::iterator I = MI->end(), E = MI->begin(); I != E; )
-     if (GCMetadataPrinter *MP = GetOrCreateGCPrinter(*--I))
-       MP->finishAssembly(*this);
- 
-+  // Emit module-level inline asm if it exists.
-+  if (!M.getModuleInlineAsm().empty()) {
-+    OutStreamer.AddComment("Start of file scope inline assembly");
-+    OutStreamer.AddBlankLine();
-+    EmitInlineAsm(M.getModuleInlineAsm()+"\n");
-+    OutStreamer.AddComment("End of file scope inline assembly");
-+    OutStreamer.AddBlankLine();
-+  }
-+
-   // If we don't have any trampolines, then we don't require stack memory
-   // to be executable. Some targets have a directive to declare this.
-   Function *InitTrampolineIntrinsic = M.getFunction("llvm.init.trampoline");
-   if (!InitTrampolineIntrinsic || InitTrampolineIntrinsic->use_empty())
-     if (const MCSection *S = MAI->getNonexecutableStackSection(OutContext))
-       OutStreamer.SwitchSection(S);
---- a/lib/Target/CppBackend/CPPBackend.cpp	2012-11-23 20:56:57.000000000 +0100
-+++ b/lib/Target/CppBackend/CPPBackend.cpp	2013-03-28 17:37:24.302140000 +0100
-@@ -372,12 +372,13 @@ std::string CppWriter::getCppName(Type*
-     }
-     case Type::X86_FP80TyID: return "Type::getX86_FP80Ty(mod->getContext())";
+--- a/lib/Target/CppBackend/CPPBackend.cpp	2013-03-25 18:42:20.000000000 +0100
++++ a/lib/Target/CppBackend/CPPBackend.cpp	2013-06-20 10:57:56.348917453 +0200
+@@ -374,8 +374,9 @@ std::string CppWriter::getCppName(Type*
      case Type::FloatTyID:    return "Type::getFloatTy(mod->getContext())";
      case Type::DoubleTyID:   return "Type::getDoubleTy(mod->getContext())";
      case Type::LabelTyID:    return "Type::getLabelTy(mod->getContext())";
@@ -61,98 +10,28 @@
        error("Invalid primitive type");
        break;
      }
-     // shouldn't be returned, but make it sensible
-     return "Type::getVoidTy(mod->getContext())";
-@@ -442,12 +443,14 @@ std::string CppWriter::getCppName(const
-         name += std::string("_") + utostr(uniqueNum++);
-       UsedNames.insert(name);
+@@ -444,8 +445,10 @@ std::string CppWriter::getCppName(const
        return ValueNames[val] = name;
      } else {
        name = getTypePrefix(val->getType());
      }
-+  } else if (dyn_cast<MDNode>(val)) {
-+	  name = std::string("metadata_");
++  } else if (isa<MDNode>(val)) {
++    name = std::string("metadata_");
    } else {
      name = getTypePrefix(val->getType());
    }
    if (val->hasName())
-     name += val->getName();
-   else
-@@ -1408,12 +1411,16 @@ void CppWriter::printInstruction(const I
-           << getCppName(ila->getFunctionType()) << ", \""
-           << ila->getAsmString() << "\", \""
+@@ -1420,8 +1423,13 @@ void CppWriter::printInstruction(const I
            << ila->getConstraintString() << "\","
            << (ila->hasSideEffects() ? "true" : "false") << ");";
        nl(Out);
      }
 +    if (const Function* F = dyn_cast<Function>(call->getCalledValue())) {
-+    	if ((F->getName().compare("llvm.dbg.value") == 0) || (F->getName().compare("llvm.dbg.declare") == 0))
-+    		break;	//Generate nothing
++      // Do not generate anything for debugging symbols intrinsics
++      if (F->getName().compare("llvm.dbg.value"  ) == 0) break;
++      if (F->getName().compare("llvm.dbg.declare") == 0) break;
 +    }
      if (call->getNumArgOperands() > 1) {
        Out << "std::vector<Value*> " << iName << "_params;";
        nl(Out);
        for (unsigned i = 0; i < call->getNumArgOperands(); ++i) {
-         Out << iName << "_params.push_back(" << opNames[i] << ");";
-         nl(Out);
---- a/lib/CodeGen/AsmPrinter/DwarfDebug.cpp	2012-11-07 06:19:04.000000000 +0100
-+++ b/lib/CodeGen/AsmPrinter/DwarfDebug.cpp	2013-03-30 01:20:19.820477000 +0100
-@@ -1149,21 +1149,22 @@ const MCSymbol *DwarfDebug::getLabelAfte
- /// beginInstruction - Process beginning of an instruction.
- void DwarfDebug::beginInstruction(const MachineInstr *MI) {
-   // Check if source location changes, but ignore DBG_VALUE locations.
-   if (!MI->isDebugValue()) {
-     DebugLoc DL = MI->getDebugLoc();
-     if (DL != PrevInstLoc && (!DL.isUnknown() || UnknownLocations)) {
--      unsigned Flags = 0;
-+      unsigned Flags = DWARF2_FLAG_IS_STMT;
-       PrevInstLoc = DL;
-       if (DL == PrologEndLoc) {
-         Flags |= DWARF2_FLAG_PROLOGUE_END;
-         PrologEndLoc = DebugLoc();
-       }
-+/*
-       if (PrologEndLoc.isUnknown())
-         Flags |= DWARF2_FLAG_IS_STMT;
--
-+*/
-       if (!DL.isUnknown()) {
-         const MDNode *Scope = DL.getScope(Asm->MF->getFunction()->getContext());
-         recordSourceLine(DL.getLine(), DL.getCol(), Scope, Flags);
-       } else
-         recordSourceLine(0, 0, 0, 0);
-     }
-@@ -1439,13 +1440,13 @@ void DwarfDebug::beginFunction(const Mac
-   // Record beginning of function.
-   if (!PrologEndLoc.isUnknown()) {
-     DebugLoc FnStartDL = getFnDebugLoc(PrologEndLoc,
-                                        MF->getFunction()->getContext());
-     recordSourceLine(FnStartDL.getLine(), FnStartDL.getCol(),
-                      FnStartDL.getScope(MF->getFunction()->getContext()),
--                     0);
-+                     DWARF2_FLAG_IS_STMT);
-   }
- }
- 
- void DwarfDebug::addScopeVariable(LexicalScope *LS, DbgVariable *Var) {
- //  SmallVector<DbgVariable *, 8> &Vars = ScopeVariables.lookup(LS);
-   ScopeVariables[LS].push_back(Var);
---- a/test/DebugInfo/X86/ending-run.ll	2012-04-05 22:39:05.000000000 +0200
-+++ b/test/DebugInfo/X86/ending-run.ll	2013-03-30 01:25:51.458268000 +0100
-@@ -1,14 +1,12 @@
- ; RUN: llc -mtriple=x86_64-apple-darwin %s -o %t -filetype=obj
- ; RUN: llvm-dwarfdump %t | FileCheck %s
- 
--; Check that the line table starts at 7, not 4, but that the first
--; statement isn't until line 8.
-+; Check that the line table starts at 7, not 4.
- 
--; CHECK-NOT: 0x0000000000000000      7      0      1   0  is_stmt
--; CHECK: 0x0000000000000000      7      0      1   0
-+; CHECK: 0x0000000000000000      7      0      1   0  is_stmt
- ; CHECK: 0x0000000000000004      8     18      1   0  is_stmt prologue_end
- 
- define i32 @callee(i32 %x) nounwind uwtable ssp {
- entry:
-   %x.addr = alloca i32, align 4
-   %y = alloca i32, align 4

Modified: vmkit/branches/incinerator/tools/vmjc/vmjc.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/branches/incinerator/tools/vmjc/vmjc.cpp?rev=184414&r1=184413&r2=184414&view=diff
==============================================================================
--- vmkit/branches/incinerator/tools/vmjc/vmjc.cpp (original)
+++ vmkit/branches/incinerator/tools/vmjc/vmjc.cpp Thu Jun 20 07:38:37 2013
@@ -17,15 +17,15 @@
 
 #include <llvm/Linker.h>
 #include "llvm/LinkAllPasses.h"
-#include "llvm/LinkAllVMCore.h"
-#include "llvm/Module.h"
+#include "llvm/LinkAllIR.h"
+#include "llvm/IR/Module.h"
 #include "llvm/PassManager.h"
 #include "llvm/Assembly/PrintModulePass.h"
 #include "llvm/CodeGen/LinkAllCodegenComponents.h"
 #include "llvm/Bitcode/ReaderWriter.h"
 #include "llvm/ExecutionEngine/ExecutionEngine.h"
 #include "llvm/Support/CommandLine.h"
-#include "llvm/Support/IRReader.h"
+#include "llvm/IRReader/IRReader.h"
 #include "llvm/Support/ManagedStatic.h"
 #include "llvm/Support/MemoryBuffer.h"
 #include "llvm/Support/PassNameParser.h"
@@ -34,7 +34,7 @@
 #include "llvm/Support/SystemUtils.h"
 #include "llvm/Support/raw_ostream.h"
 #include "llvm/Support/Signals.h"
-#include "llvm/DataLayout.h"
+#include "llvm/IR/DataLayout.h"
 #include "llvm/Target/TargetMachine.h"
 
 





More information about the vmkit-commits mailing list