Skip to content

Commit

Permalink
Codegen C - Turn down gcc optimisation level to work around #347
Browse files Browse the repository at this point in the history
  • Loading branch information
thepowersgang committed Dec 16, 2024
1 parent bb8b59f commit 994ddf8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/trans/codegen_c.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1282,7 +1282,8 @@ namespace {
args.push_back("-O1");
break;
case 2:
args.push_back("-O2");
//args.push_back("-O2");
args.push_back("-O1"); // HACK: Work around mrustc #347 by reducing the optimisation level
break;
}
// HACK: Work around [https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117423] by disabling an optimisation stage
Expand Down

0 comments on commit 994ddf8

Please sign in to comment.