Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
27df8a62
Commit
27df8a62
authored
Sep 21, 2010
by
Ian Lynagh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add an if_compiler_profiled helper
and use it to skip the th, ghci and debugger tests when GHC is profiled.
parent
82aa866a
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
34 additions
and
7 deletions
+34
-7
testsuite/config/ghc
testsuite/config/ghc
+14
-4
testsuite/driver/testlib.py
testsuite/driver/testlib.py
+6
-0
testsuite/tests/ghc-regress/ghci.debugger/scripts/all.T
testsuite/tests/ghc-regress/ghci.debugger/scripts/all.T
+3
-1
testsuite/tests/ghc-regress/ghci.debugger/scripts/break022/all.T
...te/tests/ghc-regress/ghci.debugger/scripts/break022/all.T
+1
-1
testsuite/tests/ghc-regress/ghci.debugger/scripts/break023/all.T
...te/tests/ghc-regress/ghci.debugger/scripts/break023/all.T
+1
-1
testsuite/tests/ghc-regress/ghci/scripts/all.T
testsuite/tests/ghc-regress/ghci/scripts/all.T
+3
-0
testsuite/tests/ghc-regress/th/2014/all.T
testsuite/tests/ghc-regress/th/2014/all.T
+2
-0
testsuite/tests/ghc-regress/th/TH_import_loop/TH_import_loop.T
...uite/tests/ghc-regress/th/TH_import_loop/TH_import_loop.T
+2
-0
testsuite/tests/ghc-regress/th/TH_recompile/all.T
testsuite/tests/ghc-regress/th/TH_recompile/all.T
+1
-0
testsuite/tests/ghc-regress/th/all.T
testsuite/tests/ghc-regress/th/all.T
+1
-0
No files found.
testsuite/config/ghc
View file @
27df8a62
...
...
@@ -120,12 +120,22 @@ threaded_ways = filter(lambda x: x in config.run_ways,
def get_compiler_info():
# This should really not go through the shell
h = os.popen('"' + config.compiler + '" --
numeric-version
', 'r')
v
= h.read()
h = os.popen('"' + config.compiler + '" --
info
', 'r')
s
= h.read()
h.close()
v = re.sub('[\r\n]', '', v)
v = v.split('-')
compilerInfoDict = dict(eval(s))
h = os.popen('"' + config.compiler + '" +RTS --info', 'r')
s = h.read()
h.close()
rtsInfoDict = dict(eval(s))
v = compilerInfoDict["Project version"].split('-')
config.compiler_version = v[0]
config.compiler_maj_version = re.sub('^([0-9]+\.[0-9]+).*',r'\1', v[0])
config.compiler_tags = v[1:]
if re.match(".*_p(_.*|$)", rtsInfoDict["RTS way"]):
config.compiler_profiled = True
else:
config.compiler_profiled = False
testsuite/driver/testlib.py
View file @
27df8a62
...
...
@@ -292,6 +292,12 @@ def if_compiler_type( compiler, f ):
else
:
return
normal
def
if_compiler_profiled
(
f
):
if
config
.
compiler_profiled
:
return
f
else
:
return
normal
def
if_compiler_lt
(
compiler
,
version
,
f
):
if
config
.
compiler_type
==
compiler
and
\
version_lt
(
config
.
compiler_version
,
version
):
...
...
testsuite/tests/ghc-regress/ghci.debugger/scripts/all.T
View file @
27df8a62
setTestOpts
(
composes
([
extra_run_opts
('
-ignore-dot-ghci
'),
normalise_slashes
]))
setTestOpts
(
composes
([
extra_run_opts
('
-ignore-dot-ghci
'),
if_compiler_profiled
(
skip
),
normalise_slashes
]))
test
('
print001
',
normal
,
ghci_script
,
['
print001.script
'])
test
('
print002
',
normal
,
ghci_script
,
['
print002.script
'])
...
...
testsuite/tests/ghc-regress/ghci.debugger/scripts/break022/all.T
View file @
27df8a62
setTestOpts
(
extra_run_opts
('
-ignore-dot-ghci
'))
setTestOpts
(
extra_run_opts
('
-ignore-dot-ghci
')
,
if_compiler_profiled
(
skip
)
)
test
('
break022
',
normal
,
ghci_script
,
['
break022.script
'])
testsuite/tests/ghc-regress/ghci.debugger/scripts/break023/all.T
View file @
27df8a62
setTestOpts
(
extra_run_opts
('
-ignore-dot-ghci
'))
setTestOpts
(
extra_run_opts
('
-ignore-dot-ghci
')
,
if_compiler_profiled
(
skip
)
)
test
('
break023
',
normal
,
ghci_script
,
['
break023.script
'])
testsuite/tests/ghc-regress/ghci/scripts/all.T
View file @
27df8a62
setTestOpts
(
if_compiler_profiled
(
skip
))
test
('
ghci001
',
normal
,
ghci_script
,
['
ghci001.script
'])
test
('
ghci002
',
normal
,
ghci_script
,
['
ghci002.script
'])
test
('
ghci003
',
normal
,
ghci_script
,
['
ghci003.script
'])
...
...
testsuite/tests/ghc-regress/th/2014/all.T
View file @
27df8a62
setTestOpts
(
if_compiler_profiled
(
skip
))
test
('
2014
',
extra_clean
(['
A.hi-boot
','
A.hi
','
A.o
','
A.o-boot
',
'
B.hi
',
'
B.o
',
'
C.hi
',
'
C.o
']),
...
...
testsuite/tests/ghc-regress/th/TH_import_loop/TH_import_loop.T
View file @
27df8a62
setTestOpts
(
if_compiler_profiled
(
skip
))
test
('
TH_import_loop
',
expect_broken
(
1012
),
multimod_compile_and_run
,
['
Main
',
'
-v0
'])
testsuite/tests/ghc-regress/th/TH_recompile/all.T
View file @
27df8a62
...
...
@@ -6,6 +6,7 @@ def f(opts):
setTestOpts
(
f
)
setTestOpts
(
only_compiler_types
(['
ghc
']))
setTestOpts
(
only_ways
(['
normal
']));
setTestOpts
(
if_compiler_profiled
(
skip
))
test
('
TH_recompile
',
[
expect_broken
(
481
),
...
...
testsuite/tests/ghc-regress/th/all.T
View file @
27df8a62
...
...
@@ -6,6 +6,7 @@ def f(opts):
setTestOpts
(
f
)
setTestOpts
(
only_compiler_types
(['
ghc
']))
setTestOpts
(
only_ways
(['
normal
','
ghci
']))
setTestOpts
(
if_compiler_profiled
(
skip
))
test
('
TH_mkName
',
normal
,
compile
,
['
-v0
'])
test
('
TH_1tuple
',
normal
,
compile_fail
,
['
-v0
'])
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment