| ... | @@ -2100,6 +2100,10 @@ static void construct_linker_job_wasm(LinkJob *lj) { | ... | @@ -2100,6 +2100,10 @@ static void construct_linker_job_wasm(LinkJob *lj) { |
| 2100 | CodeGen *g = lj->codegen; | 2100 | CodeGen *g = lj->codegen; |
| 2101 | | 2101 | |
| 2102 | lj->args.append("-error-limit=0"); | 2102 | lj->args.append("-error-limit=0"); |
| | 2103 | // Increase the default stack size to a more reasonable value of 1MB instead of |
| | 2104 | // the default of 1 Wasm page being 64KB. |
| | 2105 | lj->args.append("-z"); |
| | 2106 | lj->args.append("stack-size=1048576"); |
| 2103 | | 2107 | |
| 2104 | if (g->out_type != OutTypeExe) { | 2108 | if (g->out_type != OutTypeExe) { |
| 2105 | lj->args.append("--no-entry"); // So lld doesn't look for _start. | 2109 | lj->args.append("--no-entry"); // So lld doesn't look for _start. |