diff options
author | Simon Marlow <marlowsd@gmail.com> | 2015-11-07 09:39:05 +0000 |
---|---|---|
committer | Simon Marlow <marlowsd@gmail.com> | 2015-11-07 09:39:05 +0000 |
commit | ce1f1607ed7f8fedd2f63c8610cafefd59baaf32 (patch) | |
tree | 718641160c3d93a2ca974deec1e228cb09e1a97e /testsuite/tests/quasiquotation | |
parent | a58eeb7febd67c93dab82de7049ef1dcdecd34e9 (diff) | |
download | haskell-ce1f1607ed7f8fedd2f63c8610cafefd59baaf32.tar.gz |
Make GHCi & TH work when the compiler is built with -prof
Summary:
Amazingly, there were zero changes to the byte code generator and very
few changes to the interpreter - mainly because we've used good
abstractions that hide the differences between profiling and
non-profiling. So that bit was pleasantly straightforward, but there
were a pile of other wibbles to get the whole test suite through.
Note that a compiler built with -prof is now like one built with
-dynamic, in that to use TH you have to build the code the same way.
For dynamic, we automatically enable -dynamic-too when TH is required,
but we don't have anything equivalent for profiling, so you have to
explicitly use -prof when building code that uses TH with a profiled
compiler. For this reason Cabal won't work with TH. We don't expect
to ship a profiled compiler, so I think that's OK.
Test Plan: validate with GhcProfiled=YES in validate.mk
Reviewers: goldfire, bgamari, rwbarton, austin, hvr, erikd, ezyang
Reviewed By: ezyang
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D1407
GHC Trac Issues: #4837, #545
Diffstat (limited to 'testsuite/tests/quasiquotation')
-rw-r--r-- | testsuite/tests/quasiquotation/qq007/Makefile | 2 | ||||
-rw-r--r-- | testsuite/tests/quasiquotation/qq007/test.T | 2 | ||||
-rw-r--r-- | testsuite/tests/quasiquotation/qq008/Makefile | 2 | ||||
-rw-r--r-- | testsuite/tests/quasiquotation/qq008/test.T | 2 | ||||
-rw-r--r-- | testsuite/tests/quasiquotation/qq009/Makefile | 2 | ||||
-rw-r--r-- | testsuite/tests/quasiquotation/qq009/test.T | 2 |
6 files changed, 6 insertions, 6 deletions
diff --git a/testsuite/tests/quasiquotation/qq007/Makefile b/testsuite/tests/quasiquotation/qq007/Makefile index e31a732a26..79eb3b9085 100644 --- a/testsuite/tests/quasiquotation/qq007/Makefile +++ b/testsuite/tests/quasiquotation/qq007/Makefile @@ -7,6 +7,6 @@ TH_QQ: ifeq "$(GhcDynamic)" "YES" '$(TEST_HC)' $(TEST_HC_OPTS) -c QQ.hs -dynamic -osuf dyn_o -hisuf dyn_hi else - '$(TEST_HC)' $(TEST_HC_OPTS) -c QQ.hs + '$(TEST_HC)' $(TEST_HC_OPTS) $(ghcThWayFlags) -c QQ.hs endif diff --git a/testsuite/tests/quasiquotation/qq007/test.T b/testsuite/tests/quasiquotation/qq007/test.T index 0b4448cdc0..4d6767d3f8 100644 --- a/testsuite/tests/quasiquotation/qq007/test.T +++ b/testsuite/tests/quasiquotation/qq007/test.T @@ -4,4 +4,4 @@ test('qq007', pre_cmd('$MAKE -s --no-print-directory TH_QQ'), ], multimod_compile, - ['Test', '-v0']) + ['Test', '-v0 ' + config.ghc_th_way_flags]) diff --git a/testsuite/tests/quasiquotation/qq008/Makefile b/testsuite/tests/quasiquotation/qq008/Makefile index e31a732a26..79eb3b9085 100644 --- a/testsuite/tests/quasiquotation/qq008/Makefile +++ b/testsuite/tests/quasiquotation/qq008/Makefile @@ -7,6 +7,6 @@ TH_QQ: ifeq "$(GhcDynamic)" "YES" '$(TEST_HC)' $(TEST_HC_OPTS) -c QQ.hs -dynamic -osuf dyn_o -hisuf dyn_hi else - '$(TEST_HC)' $(TEST_HC_OPTS) -c QQ.hs + '$(TEST_HC)' $(TEST_HC_OPTS) $(ghcThWayFlags) -c QQ.hs endif diff --git a/testsuite/tests/quasiquotation/qq008/test.T b/testsuite/tests/quasiquotation/qq008/test.T index 8cac1a9f0a..cb1feae7da 100644 --- a/testsuite/tests/quasiquotation/qq008/test.T +++ b/testsuite/tests/quasiquotation/qq008/test.T @@ -4,4 +4,4 @@ test('qq008', pre_cmd('$MAKE -s --no-print-directory TH_QQ'), ], multimod_compile, - ['Test', '-v0']) + ['Test', '-v0 ' + config.ghc_th_way_flags]) diff --git a/testsuite/tests/quasiquotation/qq009/Makefile b/testsuite/tests/quasiquotation/qq009/Makefile index 0fa91dbf9a..f3fb673593 100644 --- a/testsuite/tests/quasiquotation/qq009/Makefile +++ b/testsuite/tests/quasiquotation/qq009/Makefile @@ -7,5 +7,5 @@ TH_QQ: ifeq "$(GhcDynamic)" "YES" '$(TEST_HC)' $(TEST_HC_OPTS) -c QQ.hs -dynamic -osuf dyn_o -hisuf dyn_hi else - '$(TEST_HC)' $(TEST_HC_OPTS) -c QQ.hs + '$(TEST_HC)' $(TEST_HC_OPTS) $(ghcThWayFlags) -c QQ.hs endif diff --git a/testsuite/tests/quasiquotation/qq009/test.T b/testsuite/tests/quasiquotation/qq009/test.T index 10b939a3bd..7ad1ebef49 100644 --- a/testsuite/tests/quasiquotation/qq009/test.T +++ b/testsuite/tests/quasiquotation/qq009/test.T @@ -4,4 +4,4 @@ test('qq009', pre_cmd('$MAKE -s --no-print-directory TH_QQ'), ], multimod_compile, - ['Test', '-v0']) + ['Test', '-v0 ' + config.ghc_th_way_flags]) |