Skip to content

Commit 6cf9c5d

Browse files
committed
[CIR] Disable -fclangir-call-conv-lowering from default in the LLVM pipeline
This is causing lots of churn. `-fclangir-call-conv-lowering` is not mature enough, assumptions are leading to crashes we cannot track with special messages, leading to not great user experience. Turn this off until we have someone dedicated to roll this out.
1 parent 078965e commit 6cf9c5d

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

clang/include/clang/Driver/Options.td

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3070,7 +3070,7 @@ defm clangir_analysis_only : BoolFOption<"clangir-analysis-only",
30703070
// FIXME(cir): Remove this option once all pre-existing tests are compatible with
30713071
// the calling convention lowering pass.
30723072
defm clangir_call_conv_lowering : BoolFOption<"clangir-call-conv-lowering",
3073-
FrontendOpts<"ClangIRCallConvLowering">, DefaultTrue,
3073+
FrontendOpts<"ClangIRCallConvLowering">, DefaultFalse,
30743074
PosFlag<SetTrue, [], [ClangOption, CC1Option], "Transform CIR to abide to calling convetions during lowering">,
30753075
NegFlag<SetFalse, [], [ClangOption, CC1Option], "Ignore calling convetion during lowering">,
30763076
BothFlags<[], [ClangOption, CC1Option], "">>;

clang/lib/Driver/ToolChains/Clang.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5152,6 +5152,8 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA,
51525152

51535153
Args.addOptOutFlag(CmdArgs, options::OPT_fclangir_call_conv_lowering,
51545154
options::OPT_fno_clangir_call_conv_lowering);
5155+
Args.addOptInFlag(CmdArgs, options::OPT_fclangir_call_conv_lowering,
5156+
options::OPT_fno_clangir_call_conv_lowering);
51555157
if (Args.hasArg(options::OPT_fclangir_mem2reg))
51565158
CmdArgs.push_back("-fclangir-mem2reg");
51575159

clang/test/CIR/Driver/callconv.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
// RUN: %clang %s -fno-clangir-call-conv-lowering -### -c %s 2>&1 | FileCheck --check-prefix=DISABLE %s
22
// DISABLE: "-fno-clangir-call-conv-lowering"
33
// RUN: %clang %s -fclangir-call-conv-lowering -### -c %s 2>&1 | FileCheck --check-prefix=ENABLE %s
4-
// ENABLE-NOT: "-fclangir-call-conv-lowering"
4+
// ENABLE: "-fclangir-call-conv-lowering"

0 commit comments

Comments
 (0)