diff options
author | Alon Zakai <azakai@google.com> | 2023-01-03 15:43:01 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-03 23:43:01 +0000 |
commit | 6a52a44255d57efd27b3979bd7b2ef3ad132f54a (patch) | |
tree | 37dbdbf964fe3f238c7ea99a81e950f1bbe2d055 /src/passes/pass.cpp | |
parent | 6e95580b42993207a4efe225db71efa0db391af4 (diff) | |
download | binaryen-6a52a44255d57efd27b3979bd7b2ef3ad132f54a.tar.gz binaryen-6a52a44255d57efd27b3979bd7b2ef3ad132f54a.tar.bz2 binaryen-6a52a44255d57efd27b3979bd7b2ef3ad132f54a.zip |
Write debug info in Pass-Debug mode 3 (#5384)
Without the names section debugging can be hard sometimes, on the binaries
that that mode emits for each pass.
Diffstat (limited to 'src/passes/pass.cpp')
-rw-r--r-- | src/passes/pass.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/passes/pass.cpp b/src/passes/pass.cpp index 732c2e8e2..373322a51 100644 --- a/src/passes/pass.cpp +++ b/src/passes/pass.cpp @@ -671,7 +671,6 @@ void PassRunner::addDefaultGlobalOptimizationPostPasses() { } static void dumpWasm(Name name, Module* wasm) { - // write out the wat static int counter = 0; std::string numstr = std::to_string(counter++); while (numstr.size() < 3) { @@ -685,6 +684,7 @@ static void dumpWasm(Name name, Module* wasm) { fullName += numstr + "-" + name.toString(); Colors::setEnabled(false); ModuleWriter writer; + writer.setDebugInfo(true); writer.writeBinary(*wasm, fullName + ".wasm"); } |