diff options
Diffstat (limited to 'testsuite/lib')
-rw-r--r-- | testsuite/lib/libffi.exp | 29 |
1 files changed, 26 insertions, 3 deletions
diff --git a/testsuite/lib/libffi.exp b/testsuite/lib/libffi.exp index 014e520..28d6036 100644 --- a/testsuite/lib/libffi.exp +++ b/testsuite/lib/libffi.exp @@ -284,10 +284,33 @@ proc run-many-tests { testcases extra_flags } { set optimizations { "" } } + set targetabis { "" } + if [string match $using_gcc "yes"] { + if [istarget "i?86-*-*"] { + set targetabis { + "" + "-DABI_NUM=FFI_STDCALL -DABI_ATTR=__STDCALL__" + "-DABI_NUM=FFI_THISCALL -DABI_ATTR=__THISCALL__" + "-DABI_NUM=FFI_FASTCALL -DABI_ATTR=__FASTCALL__" + } + } + } + set common [ concat $common $extra_flags ] - foreach opt $optimizations { - set options [ concat $common $opt ] - dg-runtest $testcases $options "" + foreach test $testcases { + set testname [file tail $test] + if [search_for $test "ABI_NUM"] { + set abis $targetabis + } else { + set abis { "" } + } + foreach opt $optimizations { + foreach abi $abis { + set options [concat $common $opt $abi] + verbose "Testing $testname, $options" 1 + dg-test $test $options "" + } + } } } |