diff options
author | Ben Gamari <ben@well-typed.com> | 2022-06-23 12:12:52 -0400 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2022-06-28 03:24:24 -0400 |
commit | df762ae9e2d5263fb71f6df38323ac3ca400cc47 (patch) | |
tree | 417edc0c63a185422b7b8f49ddfce655abebac79 | |
parent | 57a5f88cf70ec6dd65ff4a2df0c11805ec1db018 (diff) | |
download | haskell-df762ae9e2d5263fb71f6df38323ac3ca400cc47.tar.gz |
-ddump-llvm shouldn't imply -fllvm
Previously -ddump-llvm would change the backend used, which contrasts
with all other dump flags. This is quite surprising and cost me quite
a bit of time. Dump flags should not change compiler behavior.
Fixes #21776.
-rw-r--r-- | compiler/GHC/Driver/Session.hs | 2 | ||||
-rw-r--r-- | testsuite/tests/codeGen/should_compile/all.T | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/compiler/GHC/Driver/Session.hs b/compiler/GHC/Driver/Session.hs index 99a2c10bf6..67c6ff6938 100644 --- a/compiler/GHC/Driver/Session.hs +++ b/compiler/GHC/Driver/Session.hs @@ -2469,7 +2469,7 @@ dynamic_flags_deps = [ , make_ord_flag defGhcFlag "ddump-asm-stats" (setDumpFlag Opt_D_dump_asm_stats) , make_ord_flag defGhcFlag "ddump-llvm" - (NoArg $ setObjBackend llvmBackend >> setDumpFlag' Opt_D_dump_llvm) + (NoArg $ setDumpFlag' Opt_D_dump_llvm) , make_ord_flag defGhcFlag "ddump-c-backend" (NoArg $ setDumpFlag' Opt_D_dump_c_backend) , make_ord_flag defGhcFlag "ddump-deriv" diff --git a/testsuite/tests/codeGen/should_compile/all.T b/testsuite/tests/codeGen/should_compile/all.T index a18451b98e..78d96f83ff 100644 --- a/testsuite/tests/codeGen/should_compile/all.T +++ b/testsuite/tests/codeGen/should_compile/all.T @@ -55,7 +55,8 @@ test('T15155', [ unless(have_ncg(), skip) ], makefile_test, []) -test('T15155l', [ when(unregisterised(), skip), unless(have_llvm(), skip)], +test('T15155l', + [when(unregisterised(), skip), unless(have_llvm(), skip), only_ways(llvm_ways)], makefile_test, []) test('T16449_1', normal, compile, ['']) |