From a0737a0fea7aad6beb7b79cc037021c306d65d6b Mon Sep 17 00:00:00 2001 From: Matt Witherspoon <32485495+spoonincode@users.noreply.github.com> Date: Thu, 11 Jan 2018 16:51:43 -0500 Subject: [PATCH] Make tabination of our hacks in WAVM match what the rest of it is written in --- libraries/wasm-jit/Include/Runtime/Runtime.h | 4 ++-- libraries/wasm-jit/Source/Runtime/ModuleInstance.cpp | 12 ++++++------ libraries/wasm-jit/Source/Runtime/RuntimePrivate.h | 2 +- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/libraries/wasm-jit/Include/Runtime/Runtime.h b/libraries/wasm-jit/Include/Runtime/Runtime.h index 79a7f57ce..b58232a65 100644 --- a/libraries/wasm-jit/Include/Runtime/Runtime.h +++ b/libraries/wasm-jit/Include/Runtime/Runtime.h @@ -212,10 +212,10 @@ namespace Runtime // Gets the default table/memory for a ModuleInstance. RUNTIME_API MemoryInstance* getDefaultMemory(ModuleInstance* moduleInstance); - RUNTIME_API uint64_t getDefaultMemorySize(ModuleInstance* moduleInstance); + RUNTIME_API uint64_t getDefaultMemorySize(ModuleInstance* moduleInstance); RUNTIME_API TableInstance* getDefaultTable(ModuleInstance* moduleInstance); - RUNTIME_API void runInstanceStartFunc(ModuleInstance* moduleInstance); + RUNTIME_API void runInstanceStartFunc(ModuleInstance* moduleInstance); // Gets an object exported by a ModuleInstance by name. RUNTIME_API ObjectInstance* getInstanceExport(ModuleInstance* moduleInstance,const std::string& name); diff --git a/libraries/wasm-jit/Source/Runtime/ModuleInstance.cpp b/libraries/wasm-jit/Source/Runtime/ModuleInstance.cpp index ba72725cb..a10011bbc 100644 --- a/libraries/wasm-jit/Source/Runtime/ModuleInstance.cpp +++ b/libraries/wasm-jit/Source/Runtime/ModuleInstance.cpp @@ -184,7 +184,7 @@ namespace Runtime if(module.startFunctionIndex != UINTPTR_MAX) { assert(moduleInstance->functions[module.startFunctionIndex]->type == IR::FunctionType::get()); - moduleInstance->startFunctionIndex = module.startFunctionIndex; + moduleInstance->startFunctionIndex = module.startFunctionIndex; } moduleInstances.push_back(moduleInstance); @@ -200,14 +200,14 @@ namespace Runtime uint64_t getDefaultMemorySize(ModuleInstance* moduleInstance) { return moduleInstance->defaultMemory->numPages << IR::numBytesPerPageLog2; } TableInstance* getDefaultTable(ModuleInstance* moduleInstance) { return moduleInstance->defaultTable; } - void runInstanceStartFunc(ModuleInstance* moduleInstance) { - if(moduleInstance->startFunctionIndex != UINTPTR_MAX) - invokeFunction(moduleInstance->functions[moduleInstance->startFunctionIndex],{}); - } + void runInstanceStartFunc(ModuleInstance* moduleInstance) { + if(moduleInstance->startFunctionIndex != UINTPTR_MAX) + invokeFunction(moduleInstance->functions[moduleInstance->startFunctionIndex],{}); + } ObjectInstance* getInstanceExport(ModuleInstance* moduleInstance,const std::string& name) { auto mapIt = moduleInstance->exportMap.find(name); return mapIt == moduleInstance->exportMap.end() ? nullptr : mapIt->second; } -} \ No newline at end of file +} diff --git a/libraries/wasm-jit/Source/Runtime/RuntimePrivate.h b/libraries/wasm-jit/Source/Runtime/RuntimePrivate.h index f4d0853d3..23ea3e885 100644 --- a/libraries/wasm-jit/Source/Runtime/RuntimePrivate.h +++ b/libraries/wasm-jit/Source/Runtime/RuntimePrivate.h @@ -118,7 +118,7 @@ namespace Runtime LLVMJIT::JITModuleBase* jitModule; - Uptr startFunctionIndex = UINTPTR_MAX; + Uptr startFunctionIndex = UINTPTR_MAX; ModuleInstance( std::vector&& inFunctionImports, -- GitLab