Skip to content

Commit ed17c39

Browse files
committed
Remove --print-symbol-map / --symbolmap=
This is no longer needed by emscripten. See emscripten-core/emscripten#25053.
1 parent 126b4f7 commit ed17c39

File tree

9 files changed

+1
-87
lines changed

9 files changed

+1
-87
lines changed

src/passes/CMakeLists.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,6 @@ set(passes_SOURCES
9191
Print.cpp
9292
PrintCallGraph.cpp
9393
PrintFeatures.cpp
94-
PrintFunctionMap.cpp
9594
RoundTrip.cpp
9695
SetGlobals.cpp
9796
SignaturePruning.cpp

src/passes/PrintFunctionMap.cpp

Lines changed: 0 additions & 54 deletions
This file was deleted.

src/passes/pass.cpp

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -398,17 +398,6 @@ void PassRegistry::registerPasses() {
398398
registerPass(
399399
"print-call-graph", "print call graph", createPrintCallGraphPass);
400400

401-
// Register PrintFunctionMap using its normal name.
402-
registerPass("print-function-map",
403-
"print a map of function indexes to names",
404-
createPrintFunctionMapPass);
405-
// Also register it as "symbolmap" so that wasm-opt --symbolmap=foo is the
406-
// same as wasm-as --symbolmap=foo even though the latter is not a pass
407-
// (wasm-as cannot run arbitrary passes).
408-
// TODO: switch emscripten to this name, then remove the old one
409-
registerPass(
410-
"symbolmap", "(alias for print-function-map)", createPrintFunctionMapPass);
411-
412401
registerPass("propagate-globals-globally",
413402
"propagate global values to other globals (useful for tests)",
414403
createPropagateGlobalsGloballyPass);

src/passes/passes.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,6 @@ Pass* createPrecomputePropagatePass();
131131
Pass* createPrinterPass();
132132
Pass* createPrintCallGraphPass();
133133
Pass* createPrintFeaturesPass();
134-
Pass* createPrintFunctionMapPass();
135134
Pass* createPropagateGlobalsGloballyPass();
136135
Pass* createRandomizeBranchHintsPass();
137136
Pass* createRemoveNonJSOpsPass();

src/tools/wasm-opt.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -440,7 +440,7 @@ For more on how to optimize effectively, see
440440
options.passes.begin(),
441441
options.passes.end(),
442442
[](const OptimizationOptions::PassInfo& info) {
443-
return info.name == "print" || info.name == "print-function-map";
443+
return info.name == "print";
444444
});
445445
if (!printsToStdout) {
446446
std::cerr << "warning: no output file specified, not emitting output\n";

test/lit/help/wasm-metadce.test

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -374,9 +374,6 @@
374374
;; CHECK-NEXT: --print-full print in full s-expression
375375
;; CHECK-NEXT: format
376376
;; CHECK-NEXT:
377-
;; CHECK-NEXT: --print-function-map print a map of function indexes
378-
;; CHECK-NEXT: to names
379-
;; CHECK-NEXT:
380377
;; CHECK-NEXT: --print-minified print in minified s-expression
381378
;; CHECK-NEXT: format
382379
;; CHECK-NEXT:
@@ -526,8 +523,6 @@
526523
;; CHECK-NEXT: --stub-unsupported-js stub out unsupported JS
527524
;; CHECK-NEXT: operations
528525
;; CHECK-NEXT:
529-
;; CHECK-NEXT: --symbolmap (alias for print-function-map)
530-
;; CHECK-NEXT:
531526
;; CHECK-NEXT: --table64-lowering alias for memory64-lowering
532527
;; CHECK-NEXT:
533528
;; CHECK-NEXT: --trace-calls instrument the build with code

test/lit/help/wasm-opt.test

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -398,9 +398,6 @@
398398
;; CHECK-NEXT: --print-full print in full s-expression
399399
;; CHECK-NEXT: format
400400
;; CHECK-NEXT:
401-
;; CHECK-NEXT: --print-function-map print a map of function indexes
402-
;; CHECK-NEXT: to names
403-
;; CHECK-NEXT:
404401
;; CHECK-NEXT: --print-minified print in minified s-expression
405402
;; CHECK-NEXT: format
406403
;; CHECK-NEXT:
@@ -550,8 +547,6 @@
550547
;; CHECK-NEXT: --stub-unsupported-js stub out unsupported JS
551548
;; CHECK-NEXT: operations
552549
;; CHECK-NEXT:
553-
;; CHECK-NEXT: --symbolmap (alias for print-function-map)
554-
;; CHECK-NEXT:
555550
;; CHECK-NEXT: --table64-lowering alias for memory64-lowering
556551
;; CHECK-NEXT:
557552
;; CHECK-NEXT: --trace-calls instrument the build with code

test/lit/help/wasm2js.test

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -338,9 +338,6 @@
338338
;; CHECK-NEXT: --print-full print in full s-expression
339339
;; CHECK-NEXT: format
340340
;; CHECK-NEXT:
341-
;; CHECK-NEXT: --print-function-map print a map of function indexes
342-
;; CHECK-NEXT: to names
343-
;; CHECK-NEXT:
344341
;; CHECK-NEXT: --print-minified print in minified s-expression
345342
;; CHECK-NEXT: format
346343
;; CHECK-NEXT:
@@ -490,8 +487,6 @@
490487
;; CHECK-NEXT: --stub-unsupported-js stub out unsupported JS
491488
;; CHECK-NEXT: operations
492489
;; CHECK-NEXT:
493-
;; CHECK-NEXT: --symbolmap (alias for print-function-map)
494-
;; CHECK-NEXT:
495490
;; CHECK-NEXT: --table64-lowering alias for memory64-lowering
496491
;; CHECK-NEXT:
497492
;; CHECK-NEXT: --trace-calls instrument the build with code

test/unit/test_warnings.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,3 @@ def test_quiet_suppresses_warnings(self):
2020
def test_no_warn_on_print(self):
2121
err = shared.run_process(shared.WASM_OPT + [self.input_path('asyncify-pure.wat'), '--print'], stderr=subprocess.PIPE).stderr
2222
self.assertNotIn('warning: no output file specified, not emitting output', err)
23-
24-
def test_no_warn_on_print_function_map(self):
25-
err = shared.run_process(shared.WASM_OPT + [self.input_path('asyncify-pure.wat'), '--print-function-map'], stderr=subprocess.PIPE).stderr
26-
self.assertNotIn('warning: no output file specified, not emitting output', err)

0 commit comments

Comments
 (0)