We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 14a2869 commit bdfdbfbCopy full SHA for bdfdbfb
1 file changed
src/passes/pass.cpp
@@ -17,6 +17,10 @@
17
#include <chrono>
18
#include <sstream>
19
20
+#ifdef __linux__
21
+#include <unistd.h>
22
+#endif
23
+
24
#include "ir/hashed.h"
25
#include "ir/module-utils.h"
26
#include "pass.h"
@@ -415,7 +419,12 @@ static void dumpWast(Name name, Module* wasm) {
415
419
while (numstr.size() < 3) {
416
420
numstr = '0' + numstr;
417
421
}
418
- auto fullName = std::string("byn-") + numstr + "-" + name.str + ".wasm";
422
+ auto fullName = std::string("byn-");
423
424
+ // TODO: use _getpid() on windows, elsewhere?
425
+ fullName += std::to_string(getpid()) + '-';
426
427
+ fullName += numstr + "-" + name.str + ".wasm";
428
Colors::disable();
429
ModuleWriter writer;
430
writer.setBinary(false); // TODO: add an option for binary
0 commit comments