Skip to content

Commit beda737

Browse files
authored
Remove --print-symbol-map / --symbolmap (#7862)
This is no longer needed by emscripten. See emscripten-core/emscripten#25053.
1 parent a09b9ee commit beda737

15 files changed

+8
-244
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ Current Trunk
1818
- The --mod-asyncify-never-unwind and --mod-asyncify-always-and-only-unwind
1919
passed were deleted. They only existed to support the lazy code loading
2020
support in emscripten that was removed. (#7893)
21+
- The --print-symbol-map/--symbolmap flags we removed. They only existed to
22+
support an emscripten feature which was re-implemented downstream. (#7862)
2123

2224
v124
2325
----

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
@@ -391,17 +391,6 @@ void PassRegistry::registerPasses() {
391391
registerPass(
392392
"print-call-graph", "print call graph", createPrintCallGraphPass);
393393

394-
// Register PrintFunctionMap using its normal name.
395-
registerPass("print-function-map",
396-
"print a map of function indexes to names",
397-
createPrintFunctionMapPass);
398-
// Also register it as "symbolmap" so that wasm-opt --symbolmap=foo is the
399-
// same as wasm-as --symbolmap=foo even though the latter is not a pass
400-
// (wasm-as cannot run arbitrary passes).
401-
// TODO: switch emscripten to this name, then remove the old one
402-
registerPass(
403-
"symbolmap", "(alias for print-function-map)", createPrintFunctionMapPass);
404-
405394
registerPass("propagate-globals-globally",
406395
"propagate global values to other globals (useful for tests)",
407396
createPropagateGlobalsGloballyPass);

src/passes/passes.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,6 @@ Pass* createPrecomputePropagatePass();
129129
Pass* createPrinterPass();
130130
Pass* createPrintCallGraphPass();
131131
Pass* createPrintFeaturesPass();
132-
Pass* createPrintFunctionMapPass();
133132
Pass* createPropagateGlobalsGloballyPass();
134133
Pass* createRandomizeBranchHintsPass();
135134
Pass* createRemoveNonJSOpsPass();

src/tools/wasm-opt.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -436,12 +436,12 @@ For more on how to optimize effectively, see
436436

437437
if (options.extra.count("output") == 0) {
438438
if (!options.quiet) {
439-
bool printsToStdout = std::any_of(
440-
options.passes.begin(),
441-
options.passes.end(),
442-
[](const OptimizationOptions::PassInfo& info) {
443-
return info.name == "print" || info.name == "print-function-map";
444-
});
439+
bool printsToStdout =
440+
std::any_of(options.passes.begin(),
441+
options.passes.end(),
442+
[](const OptimizationOptions::PassInfo& info) {
443+
return info.name == "print";
444+
});
445445
if (!printsToStdout) {
446446
std::cerr << "warning: no output file specified, not emitting output\n";
447447
}

test/lit/help/wasm-metadce.test

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -367,9 +367,6 @@
367367
;; CHECK-NEXT: --print-full print in full s-expression
368368
;; CHECK-NEXT: format
369369
;; CHECK-NEXT:
370-
;; CHECK-NEXT: --print-function-map print a map of function indexes
371-
;; CHECK-NEXT: to names
372-
;; CHECK-NEXT:
373370
;; CHECK-NEXT: --print-minified print in minified s-expression
374371
;; CHECK-NEXT: format
375372
;; CHECK-NEXT:
@@ -522,8 +519,6 @@
522519
;; CHECK-NEXT: --stub-unsupported-js stub out unsupported JS
523520
;; CHECK-NEXT: operations
524521
;; CHECK-NEXT:
525-
;; CHECK-NEXT: --symbolmap (alias for print-function-map)
526-
;; CHECK-NEXT:
527522
;; CHECK-NEXT: --table64-lowering alias for memory64-lowering
528523
;; CHECK-NEXT:
529524
;; 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
@@ -391,9 +391,6 @@
391391
;; CHECK-NEXT: --print-full print in full s-expression
392392
;; CHECK-NEXT: format
393393
;; CHECK-NEXT:
394-
;; CHECK-NEXT: --print-function-map print a map of function indexes
395-
;; CHECK-NEXT: to names
396-
;; CHECK-NEXT:
397394
;; CHECK-NEXT: --print-minified print in minified s-expression
398395
;; CHECK-NEXT: format
399396
;; CHECK-NEXT:
@@ -546,8 +543,6 @@
546543
;; CHECK-NEXT: --stub-unsupported-js stub out unsupported JS
547544
;; CHECK-NEXT: operations
548545
;; CHECK-NEXT:
549-
;; CHECK-NEXT: --symbolmap (alias for print-function-map)
550-
;; CHECK-NEXT:
551546
;; CHECK-NEXT: --table64-lowering alias for memory64-lowering
552547
;; CHECK-NEXT:
553548
;; 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
@@ -331,9 +331,6 @@
331331
;; CHECK-NEXT: --print-full print in full s-expression
332332
;; CHECK-NEXT: format
333333
;; CHECK-NEXT:
334-
;; CHECK-NEXT: --print-function-map print a map of function indexes
335-
;; CHECK-NEXT: to names
336-
;; CHECK-NEXT:
337334
;; CHECK-NEXT: --print-minified print in minified s-expression
338335
;; CHECK-NEXT: format
339336
;; CHECK-NEXT:
@@ -486,8 +483,6 @@
486483
;; CHECK-NEXT: --stub-unsupported-js stub out unsupported JS
487484
;; CHECK-NEXT: operations
488485
;; CHECK-NEXT:
489-
;; CHECK-NEXT: --symbolmap (alias for print-function-map)
490-
;; CHECK-NEXT:
491486
;; CHECK-NEXT: --table64-lowering alias for memory64-lowering
492487
;; CHECK-NEXT:
493488
;; CHECK-NEXT: --trace-calls instrument the build with code

test/lit/wasm-split/symbolmap-multi-split.wast

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

0 commit comments

Comments
 (0)