[vmkit-commits] [vmkit] r57242 - in /vmkit/trunk: include/mvm/JIT.h include/mvm/Threads/Thread.h lib/JnJVM/Classpath/ClasspathVMThread.cpp.inc lib/JnJVM/VMCore/JavaInitialise.cpp lib/JnJVM/VMCore/Jnjvm.cpp lib/Mvm/CommonThread/ctthread.cpp

Nicolas Geoffray nicolas.geoffray at lip6.fr
Tue Oct 7 05:34:50 PDT 2008


Author: geoffray
Date: Tue Oct  7 07:34:48 2008
New Revision: 57242

URL: http://llvm.org/viewvc/llvm-project?rev=57242&view=rev
Log:
Compilation fix after r57238.


Modified:
    vmkit/trunk/include/mvm/JIT.h
    vmkit/trunk/include/mvm/Threads/Thread.h
    vmkit/trunk/lib/JnJVM/Classpath/ClasspathVMThread.cpp.inc
    vmkit/trunk/lib/JnJVM/VMCore/JavaInitialise.cpp
    vmkit/trunk/lib/JnJVM/VMCore/Jnjvm.cpp
    vmkit/trunk/lib/Mvm/CommonThread/ctthread.cpp

Modified: vmkit/trunk/include/mvm/JIT.h
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/include/mvm/JIT.h?rev=57242&r1=57241&r2=57242&view=diff

==============================================================================
--- vmkit/trunk/include/mvm/JIT.h (original)
+++ vmkit/trunk/include/mvm/JIT.h Tue Oct  7 07:34:48 2008
@@ -27,10 +27,11 @@
 #include "mvm/Method.h"
 #include "mvm/MvmMemoryManager.h"
 #include "mvm/Threads/Locks.h"
-#include "mvm/Threads/Thread.h"
 
 namespace mvm {
 
+class Thread;
+
 /// JITInfo - This class can be derived from to hold private JIT-specific
 /// information. Objects of type are accessed/created with
 /// <Class>::getInfo and destroyed when the <Class> object is destroyed.

Modified: vmkit/trunk/include/mvm/Threads/Thread.h
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/include/mvm/Threads/Thread.h?rev=57242&r1=57241&r2=57242&view=diff

==============================================================================
--- vmkit/trunk/include/mvm/Threads/Thread.h (original)
+++ vmkit/trunk/include/mvm/Threads/Thread.h Tue Oct  7 07:34:48 2008
@@ -13,6 +13,7 @@
 #include "types.h"
 
 #include "MvmGC.h"
+#include "mvm/JIT.h"
 #include "mvm/Threads/Key.h"
 
 
@@ -78,15 +79,22 @@
   /// get - Get the thread specific data of the current thread.
   ///
   static Thread* get() {
+#if 1//defined(__PPC__) || defined(__ppc__)
     return (Thread*)Thread::threadKey->get();
+#else
+    return (Thread*)mvm::jit::getExecutionEnvironment();
+#endif
   }
   
   /// set - Set the thread specific data of the current thread.
   ///
   static void set(Thread* th) {
-    return Thread::threadKey->set(th);
+#if 1//defined(__PPC__) || defined(__ppc__)
+    Thread::threadKey->set(th);
+#else
+    mvm::jit::setExecutionEnvironment(th);
+#endif
   }
-
 };
 
 

Modified: vmkit/trunk/lib/JnJVM/Classpath/ClasspathVMThread.cpp.inc
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/lib/JnJVM/Classpath/ClasspathVMThread.cpp.inc?rev=57242&r1=57241&r2=57242&view=diff

==============================================================================
--- vmkit/trunk/lib/JnJVM/Classpath/ClasspathVMThread.cpp.inc (original)
+++ vmkit/trunk/lib/JnJVM/Classpath/ClasspathVMThread.cpp.inc Tue Oct  7 07:34:48 2008
@@ -50,7 +50,7 @@
   JavaObject* vmThread = arg->vmThread;
   JavaThread* intern = arg->intern;
   free(arg);
-  mvm::Thread::threadKey->set(intern);
+  mvm::Thread::set(intern);
 #ifdef MULTIPLE_GC
   intern->GC->inject_my_thread(&argc);
 #else

Modified: vmkit/trunk/lib/JnJVM/VMCore/JavaInitialise.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/lib/JnJVM/VMCore/JavaInitialise.cpp?rev=57242&r1=57241&r2=57242&view=diff

==============================================================================
--- vmkit/trunk/lib/JnJVM/VMCore/JavaInitialise.cpp (original)
+++ vmkit/trunk/lib/JnJVM/VMCore/JavaInitialise.cpp Tue Oct  7 07:34:48 2008
@@ -11,6 +11,7 @@
 
 #include "mvm/VirtualMachine.h"
 #include "mvm/Threads/Locks.h"
+#include "mvm/Threads/Thread.h"
 
 #include "JavaArray.h"
 #include "JavaCache.h"
@@ -241,7 +242,7 @@
 }
 
 void Jnjvm::runApplication(int argc, char** argv) {
-  mvm::Thread::threadKey->set(this->bootstrapThread);
+  mvm::Thread::set(this->bootstrapThread);
   this->runMain(argc, argv);
 }
 

Modified: vmkit/trunk/lib/JnJVM/VMCore/Jnjvm.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/lib/JnJVM/VMCore/Jnjvm.cpp?rev=57242&r1=57241&r2=57242&view=diff

==============================================================================
--- vmkit/trunk/lib/JnJVM/VMCore/Jnjvm.cpp (original)
+++ vmkit/trunk/lib/JnJVM/VMCore/Jnjvm.cpp Tue Oct  7 07:34:48 2008
@@ -18,6 +18,7 @@
 #include "debug.h"
 
 #include "mvm/JIT.h"
+#include "mvm/Threads/Thread.h"
 
 #include "JavaArray.h"
 #include "JavaClass.h"
@@ -830,7 +831,7 @@
   isolate->bootstrapThread = allocator_new(&isolate->allocator, JavaThread)();
   isolate->bootstrapThread->initialise(0, isolate);
   void* baseSP = sp ? sp : mvm::Thread::get()->baseSP;
-  JavaThread::threadKey->set(isolate->bootstrapThread);
+  JavaThread::set(isolate->bootstrapThread);
   
 #ifdef MULTIPLE_GC
   isolate->bootstrapThread->GC = isolate->GC;

Modified: vmkit/trunk/lib/Mvm/CommonThread/ctthread.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/lib/Mvm/CommonThread/ctthread.cpp?rev=57242&r1=57241&r2=57242&view=diff

==============================================================================
--- vmkit/trunk/lib/Mvm/CommonThread/ctthread.cpp (original)
+++ vmkit/trunk/lib/Mvm/CommonThread/ctthread.cpp Tue Oct  7 07:34:48 2008
@@ -68,7 +68,7 @@
 void Thread::initialise() {
   Thread::threadKey = new mvm::Key<Thread>();
   Thread* th = new Thread();
-  mvm::Thread::threadKey->set(th);
+  mvm::Thread::set(th);
 }
 
 int Thread::start(int *tid, int (*fct)(void *), void *arg) {





More information about the vmkit-commits mailing list