diff options
-rw-r--r-- | testsuite/config/ghc | 10 | ||||
-rw-r--r-- | testsuite/driver/testlib.py | 8 |
2 files changed, 9 insertions, 9 deletions
diff --git a/testsuite/config/ghc b/testsuite/config/ghc index 73ff7d3fd6..da7cc3a2af 100644 --- a/testsuite/config/ghc +++ b/testsuite/config/ghc @@ -80,7 +80,7 @@ if (ghc_with_llvm == 1): config.in_tree_compiler = in_tree_compiler config.clean_only = clean_only -config.way_flags = { +config.way_flags = lambda name : { 'normal' : [], 'g1' : [], 'optasm' : ['-O', '-fasm'], @@ -97,7 +97,7 @@ config.way_flags = { 'threaded1_ls' : ['-threaded', '-debug'], 'threaded2' : ['-O', '-threaded', '-eventlog'], 'threaded2_hT' : ['-O', '-threaded'], - 'hpc' : ['-O', '-fhpc' ], + 'hpc' : ['-O', '-fhpc', '-hpcdir', '.hpc.' + name ], 'prof_hc_hb' : ['-O', '-prof', '-static', '-auto-all'], 'prof_hb' : ['-O', '-prof', '-static', '-auto-all'], 'prof_hd' : ['-O', '-prof', '-static', '-auto-all'], @@ -153,15 +153,15 @@ config.way_rts_flags = { prof_ways = map (lambda x: x[0], \ filter(lambda x: '-prof' in x[1], \ - config.way_flags.items())) + config.way_flags('dummy_name').items())) threaded_ways = map (lambda x: x[0], \ filter(lambda x: '-threaded' in x[1] or 'ghci' == x[0], \ - config.way_flags.items())) + config.way_flags('dummy_name').items())) opt_ways = map (lambda x: x[0], \ filter(lambda x: '-O' in x[1], \ - config.way_flags.items())) + config.way_flags('dummy_name').items())) def get_compiler_info(): # This should really not go through the shell diff --git a/testsuite/driver/testlib.py b/testsuite/driver/testlib.py index 4868e6d788..f21b380bcb 100644 --- a/testsuite/driver/testlib.py +++ b/testsuite/driver/testlib.py @@ -1229,7 +1229,7 @@ def simple_build( name, way, extra_hc_opts, should_fail, top_mod, link, addsuf, + config.compiler + "' " \ + join(comp_flags,' ') + ' ' \ + to_do + ' ' + srcname + ' ' \ - + join(config.way_flags[way],' ') + ' ' \ + + join(config.way_flags(name)[way],' ') + ' ' \ + extra_hc_opts + ' ' \ + opts.extra_hc_opts + ' ' \ + '>' + errname + ' 2>&1' @@ -1415,7 +1415,7 @@ def interpreter_run( name, way, extra_hc_opts, compile_only, top_mod ): cmd = "'" + config.compiler + "' " \ + join(flags,' ') + ' ' \ + srcname + ' ' \ - + join(config.way_flags[way],' ') + ' ' \ + + join(config.way_flags(name)[way],' ') + ' ' \ + extra_hc_opts + ' ' \ + getTestOpts().extra_hc_opts + ' ' \ + '<' + scriptname + ' 1>' + outname + ' 2>' + errname @@ -1511,7 +1511,7 @@ def extcore_run( name, way, extra_hc_opts, compile_only, top_mod ): cmd = 'cd ' + getTestOpts().testdir + " && '" \ + config.compiler + "' " \ + join(flags,' ') + ' ' \ - + join(config.way_flags[way],' ') + ' ' \ + + join(config.way_flags(name)[way],' ') + ' ' \ + extra_hc_opts + ' ' \ + getTestOpts().extra_hc_opts \ + to_do \ @@ -1536,7 +1536,7 @@ def extcore_run( name, way, extra_hc_opts, compile_only, top_mod ): deplist2 = string.replace(deplist,'.lhs,', '.hcr'); to_compile = string.replace(deplist2,'.hs,', '.hcr'); - flags = join(filter(lambda f: f != '-fext-core',config.way_flags[way]),' ') + flags = join(filter(lambda f: f != '-fext-core',config.way_flags(name)[way]),' ') if getTestOpts().outputdir != None: flags.extend(["-outputdir", getTestOpts().outputdir]) |