Skip to content

Commit

Permalink
fix llvm-kompile being passed more options conventionally (#4514)
Browse files Browse the repository at this point in the history
This changes the order of flags passed to llvm-kompile in order to
ensure that llvm-kompile-codegen will run with the correct optimization
flags.

Co-authored-by: rv-jenkins <[email protected]>
  • Loading branch information
Dwight Guth and rv-jenkins authored Jul 11, 2024
1 parent f807c22 commit d90b8b1
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -143,9 +143,6 @@ private void llvmKompile(String type, String executable) {
args.add("--mutable-bytes");
}

// Arguments after this point are passed on to Clang.
args.add("--");

if (options.debug) {
args.add("-g");
args.add("-O1");
Expand All @@ -171,6 +168,9 @@ private void llvmKompile(String type, String executable) {
args.add("-O2"); // clang -O3 does not make the llvm backend any faster
}

// Arguments after this point are passed on to Clang.
args.add("--");

args.addAll(options.ccopts);

if (globalOptions.verbose) {
Expand Down

0 comments on commit d90b8b1

Please sign in to comment.