From 46282a482ec81e8d379b4e9b3ee50f66dd0ac5e5 Mon Sep 17 00:00:00 2001 From: Sam Clegg Date: Tue, 31 May 2022 07:04:51 -0700 Subject: Remove renameMainArgcArgv from wasm-emscripten-finalize (#4700) This part to finalize is currently not used and was added in preparation for https://reviews.llvm.org/D75277. However, the better solution to dealing with this alternative name for main is on the emscripten side. The main reason for this is that doing the rename here in binaryen would require finalize to always re-write the binary, which is expensive. --- src/tools/wasm-emscripten-finalize.cpp | 6 ------ 1 file changed, 6 deletions(-) (limited to 'src/tools/wasm-emscripten-finalize.cpp') diff --git a/src/tools/wasm-emscripten-finalize.cpp b/src/tools/wasm-emscripten-finalize.cpp index 8fdc203a9..b4e27ca5c 100644 --- a/src/tools/wasm-emscripten-finalize.cpp +++ b/src/tools/wasm-emscripten-finalize.cpp @@ -266,12 +266,6 @@ int main(int argc, const char* argv[]) { generator.onlyI64DynCalls = onlyI64DynCalls; generator.noDynCalls = noDynCalls; - if (!standaloneWasm) { - // This is also not needed in standalone mode since standalone mode uses - // crt1.c to invoke the main and is aware of __main_argc_argv mangling. - generator.renameMainArgcArgv(); - } - PassRunner passRunner(&wasm, options.passOptions); passRunner.setDebug(options.debug); passRunner.setDebugInfo(debugInfo); -- cgit v1.2.3