[vmkit-commits] [vmkit] r67198 - in /vmkit/trunk/lib/JnJVM: Compiler/JITInfo.cpp Compiler/JnjvmModuleAOT.cpp Compiler/LowerConstantCalls.cpp VMCore/JavaClass.cpp VMCore/JavaConstantPool.cpp VMCore/JavaTypes.cpp VMCore/Jnjvm.cpp VMCore/JnjvmClassLoader.cpp VMCore/JnjvmClassLoader.h

Nicolas Geoffray nicolas.geoffray at lip6.fr
Wed Mar 18 04:14:12 PDT 2009


Author: geoffray
Date: Wed Mar 18 06:14:00 2009
New Revision: 67198

URL: http://llvm.org/viewvc/llvm-project?rev=67198&view=rev
Log:
Change naming to be consistent.


Modified:
    vmkit/trunk/lib/JnJVM/Compiler/JITInfo.cpp
    vmkit/trunk/lib/JnJVM/Compiler/JnjvmModuleAOT.cpp
    vmkit/trunk/lib/JnJVM/Compiler/LowerConstantCalls.cpp
    vmkit/trunk/lib/JnJVM/VMCore/JavaClass.cpp
    vmkit/trunk/lib/JnJVM/VMCore/JavaConstantPool.cpp
    vmkit/trunk/lib/JnJVM/VMCore/JavaTypes.cpp
    vmkit/trunk/lib/JnJVM/VMCore/Jnjvm.cpp
    vmkit/trunk/lib/JnJVM/VMCore/JnjvmClassLoader.cpp
    vmkit/trunk/lib/JnJVM/VMCore/JnjvmClassLoader.h

Modified: vmkit/trunk/lib/JnJVM/Compiler/JITInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/lib/JnJVM/Compiler/JITInfo.cpp?rev=67198&r1=67197&r2=67198&view=diff

==============================================================================
--- vmkit/trunk/lib/JnJVM/Compiler/JITInfo.cpp (original)
+++ vmkit/trunk/lib/JnJVM/Compiler/JITInfo.cpp Wed Mar 18 06:14:00 2009
@@ -58,7 +58,7 @@
     
     
     JavaLLVMCompiler* Mod = 
-      (JavaLLVMCompiler*)classDef->classLoader->getModule();
+      (JavaLLVMCompiler*)classDef->classLoader->getCompiler();
     StructType* structType = StructType::get(fields, false);
     virtualType = PointerType::getUnqual(structType);
     const TargetData* targetData = JnjvmModule::TheTargetData;
@@ -113,7 +113,7 @@
     }
   
     JavaLLVMCompiler* Mod = 
-      (JavaLLVMCompiler*)cl->classLoader->getModule();
+      (JavaLLVMCompiler*)cl->classLoader->getCompiler();
     StructType* structType = StructType::get(fields, false);
     staticType = PointerType::getUnqual(structType);
     const TargetData* targetData = JnjvmModule::TheTargetData;
@@ -166,7 +166,7 @@
 Function* LLVMMethodInfo::getMethod() {
   if (!methodFunction) {
     JnjvmClassLoader* JCL = methodDef->classDef->classLoader;
-    JavaLLVMCompiler* Mod = (JavaLLVMCompiler*)JCL->getModule();
+    JavaLLVMCompiler* Mod = (JavaLLVMCompiler*)JCL->getCompiler();
     if (Mod->isStaticCompiling()) {
 
       const UTF8* jniConsClName = methodDef->classDef->name;
@@ -223,7 +223,7 @@
 ConstantInt* LLVMMethodInfo::getOffset() {
   if (!offsetConstant) {
     JnjvmClassLoader* JCL = methodDef->classDef->classLoader;
-    JavaCompiler* Mod = JCL->getModule();
+    JavaCompiler* Mod = JCL->getCompiler();
     Mod->resolveVirtualClass(methodDef->classDef);
     offsetConstant = ConstantInt::get(Type::Int32Ty, methodDef->offset);
   }
@@ -233,7 +233,7 @@
 ConstantInt* LLVMFieldInfo::getOffset() {
   if (!offsetConstant) {
     JnjvmClassLoader* JCL = fieldDef->classDef->classLoader;
-    JavaCompiler* Mod = JCL->getModule();
+    JavaCompiler* Mod = JCL->getCompiler();
     if (isStatic(fieldDef->access)) {
       Mod->resolveStaticClass(fieldDef->classDef); 
     } else {
@@ -334,7 +334,7 @@
   std::vector<Value*> Args;
 
   JavaLLVMCompiler* Mod = 
-    (JavaLLVMCompiler*)signature->initialLoader->getModule();
+    (JavaLLVMCompiler*)signature->initialLoader->getCompiler();
   const char* name = 0;
   if (Mod->isStaticCompiling()) {
     name = virt ? signature->printString("virtual_buf") :
@@ -394,7 +394,7 @@
   std::vector<Value*> Args;
   
   JavaLLVMCompiler* Mod = 
-    (JavaLLVMCompiler*)signature->initialLoader->getModule();
+    (JavaLLVMCompiler*)signature->initialLoader->getCompiler();
   const char* name = 0;
   if (Mod->isStaticCompiling()) {
     name = virt ? signature->printString("virtual_ap") :
@@ -504,7 +504,7 @@
     // Lock here because we are called by arbitrary code
     mvm::MvmModule::protectIR();
     virtualBufFunction = createFunctionCallBuf(true);
-    if (!signature->initialLoader->getModule()->isStaticCompiling()) {
+    if (!signature->initialLoader->getCompiler()->isStaticCompiling()) {
       signature->setVirtualCallBuf((intptr_t)
         mvm::MvmModule::executionEngine->getPointerToGlobal(virtualBufFunction));
       // Now that it's compiled, we don't need the IR anymore
@@ -520,7 +520,7 @@
     // Lock here because we are called by arbitrary code
     mvm::MvmModule::protectIR();
     virtualAPFunction = createFunctionCallAP(true);
-    if (!signature->initialLoader->getModule()->isStaticCompiling()) {
+    if (!signature->initialLoader->getCompiler()->isStaticCompiling()) {
       signature->setVirtualCallAP((intptr_t)
         mvm::MvmModule::executionEngine->getPointerToGlobal(virtualAPFunction));
       // Now that it's compiled, we don't need the IR anymore
@@ -536,7 +536,7 @@
     // Lock here because we are called by arbitrary code
     mvm::MvmModule::protectIR();
     staticBufFunction = createFunctionCallBuf(false);
-    if (!signature->initialLoader->getModule()->isStaticCompiling()) {
+    if (!signature->initialLoader->getCompiler()->isStaticCompiling()) {
       signature->setStaticCallBuf((intptr_t)
         mvm::MvmModule::executionEngine->getPointerToGlobal(staticBufFunction));
       // Now that it's compiled, we don't need the IR anymore
@@ -552,7 +552,7 @@
     // Lock here because we are called by arbitrary code
     mvm::MvmModule::protectIR();
     staticAPFunction = createFunctionCallAP(false);
-    if (!signature->initialLoader->getModule()->isStaticCompiling()) {
+    if (!signature->initialLoader->getCompiler()->isStaticCompiling()) {
       signature->setStaticCallAP((intptr_t)
         mvm::MvmModule::executionEngine->getPointerToGlobal(staticAPFunction));
       // Now that it's compiled, we don't need the IR anymore

Modified: vmkit/trunk/lib/JnJVM/Compiler/JnjvmModuleAOT.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/lib/JnJVM/Compiler/JnjvmModuleAOT.cpp?rev=67198&r1=67197&r2=67198&view=diff

==============================================================================
--- vmkit/trunk/lib/JnJVM/Compiler/JnjvmModuleAOT.cpp (original)
+++ vmkit/trunk/lib/JnJVM/Compiler/JnjvmModuleAOT.cpp Wed Mar 18 06:14:00 2009
@@ -1492,7 +1492,7 @@
   
   Jnjvm* vm = th->getJVM();
   JnjvmBootstrapLoader* bootstrapLoader = vm->bootstrapLoader;
-  JavaAOTCompiler* M = (JavaAOTCompiler*)bootstrapLoader->getModule();
+  JavaAOTCompiler* M = (JavaAOTCompiler*)bootstrapLoader->getCompiler();
   try {
 
     bootstrapLoader->analyseClasspathEnv(vm->classpath);

Modified: vmkit/trunk/lib/JnJVM/Compiler/LowerConstantCalls.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/lib/JnJVM/Compiler/LowerConstantCalls.cpp?rev=67198&r1=67197&r2=67198&view=diff

==============================================================================
--- vmkit/trunk/lib/JnJVM/Compiler/LowerConstantCalls.cpp (original)
+++ vmkit/trunk/lib/JnJVM/Compiler/LowerConstantCalls.cpp Wed Mar 18 06:14:00 2009
@@ -117,7 +117,7 @@
 bool LowerConstantCalls::runOnFunction(Function& F) {
   JavaMethod* meth = LLVMMethodInfo::get(&F);
   JavaLLVMCompiler* TheCompiler = 
-    (JavaLLVMCompiler*)meth->classDef->classLoader->getModule();
+    (JavaLLVMCompiler*)meth->classDef->classLoader->getCompiler();
   JnjvmModule* module = TheCompiler->getIntrinsics();
   bool Changed = false;
   for (Function::iterator BI = F.begin(), BE = F.end(); BI != BE; BI++) { 

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

==============================================================================
--- vmkit/trunk/lib/JnJVM/VMCore/JavaClass.cpp (original)
+++ vmkit/trunk/lib/JnJVM/VMCore/JavaClass.cpp Wed Mar 18 06:14:00 2009
@@ -365,7 +365,7 @@
 #endif
     classDef->acquire();
     if (code == 0) {
-      code = classDef->classLoader->getModule()->materializeFunction(this);
+      code = classDef->classLoader->getCompiler()->materializeFunction(this);
       Jnjvm* vm = JavaThread::get()->getJVM();
       vm->addMethodInFunctionMap(this, code);
     }
@@ -380,7 +380,7 @@
     code = ptr;
     Jnjvm* vm = JavaThread::get()->getJVM();
     vm->addMethodInFunctionMap(this, code);
-    classDef->classLoader->getModule()->setMethod(this, ptr, name);
+    classDef->classLoader->getCompiler()->setMethod(this, ptr, name);
   }
   access |= ACC_NATIVE;
   classDef->release();
@@ -533,7 +533,7 @@
 JavaObject* UserClass::doNew(Jnjvm* vm) {
   assert(this && "No class when allocating.");
   assert((this->isInitializing() || 
-          classLoader->getModule()->isStaticCompiling())
+          classLoader->getCompiler()->isStaticCompiling())
          && "Uninitialized class when allocating.");
   JavaObject* res = 
     (JavaObject*)vm->gcAllocator.allocateManagedObject(getVirtualSize(),
@@ -932,7 +932,7 @@
       loadParents();
       loadExceptions();
       acquire();
-      JavaCompiler *Comp = classLoader->getModule();
+      JavaCompiler *Comp = classLoader->getCompiler();
       Comp->resolveVirtualClass(this);
       Comp->resolveStaticClass(this);
       setResolved();

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

==============================================================================
--- vmkit/trunk/lib/JnJVM/VMCore/JavaConstantPool.cpp (original)
+++ vmkit/trunk/lib/JnJVM/VMCore/JavaConstantPool.cpp Wed Mar 18 06:14:00 2009
@@ -307,7 +307,7 @@
   }
 #endif
 
-  if (!temp && classDef->classLoader->getModule()->isStaticCompiling()) {
+  if (!temp && classDef->classLoader->getCompiler()->isStaticCompiling()) {
     temp = loadClass(index);
   }
   return temp;

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

==============================================================================
--- vmkit/trunk/lib/JnJVM/VMCore/JavaTypes.cpp (original)
+++ vmkit/trunk/lib/JnJVM/VMCore/JavaTypes.cpp Wed Mar 18 06:14:00 2009
@@ -105,28 +105,28 @@
 
 intptr_t Signdef::staticCallBuf() {
   if (!_staticCallBuf) {
-    initialLoader->getModule()->staticCallBuf(this);
+    initialLoader->getCompiler()->staticCallBuf(this);
   }
   return _staticCallBuf;
 }
 
 intptr_t Signdef::virtualCallBuf() {
   if (!_virtualCallBuf) {
-    initialLoader->getModule()->virtualCallBuf(this);
+    initialLoader->getCompiler()->virtualCallBuf(this);
   }
   return _virtualCallBuf;
 }
 
 intptr_t Signdef::staticCallAP() {
   if (!_staticCallAP) {
-    initialLoader->getModule()->staticCallAP(this);
+    initialLoader->getCompiler()->staticCallAP(this);
   }
   return _staticCallAP;
 }
 
 intptr_t Signdef::virtualCallAP() {
   if (!_virtualCallAP) {
-    initialLoader->getModule()->virtualCallAP(this);
+    initialLoader->getCompiler()->virtualCallAP(this);
   }
   return _virtualCallAP;
 }

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

==============================================================================
--- vmkit/trunk/lib/JnJVM/VMCore/Jnjvm.cpp (original)
+++ vmkit/trunk/lib/JnJVM/VMCore/Jnjvm.cpp Wed Mar 18 06:14:00 2009
@@ -267,7 +267,7 @@
   vsnprintf(tmp, 4096, fmt, ap);
   va_end(ap);
   
-  if (cl && !bootstrapLoader->getModule()->isStaticCompiling()) {
+  if (cl && !bootstrapLoader->getCompiler()->isStaticCompiling()) {
     JavaObject* obj = CreateError(cl, init, tmp);
     JavaThread::get()->throwException(obj);
   } else {

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

==============================================================================
--- vmkit/trunk/lib/JnJVM/VMCore/JnjvmClassLoader.cpp (original)
+++ vmkit/trunk/lib/JnJVM/VMCore/JnjvmClassLoader.cpp Wed Mar 18 06:14:00 2009
@@ -273,7 +273,7 @@
 JnjvmClassLoader::JnjvmClassLoader(JnjvmClassLoader& JCL, JavaObject* loader,
                                    Jnjvm* I) {
   bootstrapLoader = JCL.bootstrapLoader;
-  TheCompiler = bootstrapLoader->getModule()->Create("Applicative loader");
+  TheCompiler = bootstrapLoader->getCompiler()->Create("Applicative loader");
   
   hashUTF8 = new(allocator) UTF8Map(allocator,
                                     bootstrapLoader->upcalls->ArrayOfChar);
@@ -954,7 +954,7 @@
 }
 
 void JnjvmClassLoader::insertAllMethodsInVM(Jnjvm* vm) {
-  JavaCompiler* M = getModule();
+  JavaCompiler* M = getCompiler();
   for (ClassMap::iterator i = classes->map.begin(), e = classes->map.end();
        i != e; ++i) {
     CommonClass* cl = i->second;

Modified: vmkit/trunk/lib/JnJVM/VMCore/JnjvmClassLoader.h
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/lib/JnJVM/VMCore/JnjvmClassLoader.h?rev=67198&r1=67197&r2=67198&view=diff

==============================================================================
--- vmkit/trunk/lib/JnJVM/VMCore/JnjvmClassLoader.h (original)
+++ vmkit/trunk/lib/JnJVM/VMCore/JnjvmClassLoader.h Wed Mar 18 06:14:00 2009
@@ -116,9 +116,9 @@
   ///
   UTF8Map* hashUTF8;
   
-  /// getModule - Get the Java compiler of this class loader.
+  /// getCompiler - Get the Java compiler of this class loader.
   ///
-  JavaCompiler* getModule() { return TheCompiler; }
+  JavaCompiler* getCompiler() { return TheCompiler; }
 
   /// setCompiler - Set the compiler of classes loaded by this class loader.
   ///





More information about the vmkit-commits mailing list