[_Complex test 2/4] _Complex type in varargs.exp

Pedro Alves pedro@codesourcery.com
Fri May 20 15:37:00 GMT 2011


On Friday 20 May 2011 16:22:15, Yao Qi wrote:
> OK, I opened another two PRs for armv7l-unknown-linux-gnueabi and
> x86_64-unknown-linux-gnu.  KFAIL to different PRs according to the
> target.  An internal error on x86_64-linux is not KFAIL'ed, because I
> failed to KFAIL it after some experiments for some time.

Did you try setup_kfail?  See below.  The way you have things
doesn't catch the internal error case because that is matched
within gdb_test_multiple itself.  You could also check the return
of gdb_test_multiple to see if an internal match happened, but
that's more complicated than setup_kfail.

> x86_64-unknown-linux-gnu:
> KFAIL: gdb.base/varargs.exp: print find_max_float_real(4, fc1, fc2, fc3,
> fc4) (PRMS: gdb/12790)
> KFAIL: gdb.base/varargs.exp: print find_max_double_real(4, dc1, dc2,
> dc3, dc4) (PRMS: gdb/12790)
> FAIL: gdb.base/varargs.exp: print find_max_long_double_real(4, ldc1,
> ldc2, ldc3, ldc4) (GDB internal error)
> 

    setup_kfail gdb/12776 "i?86-*-*"
    setup_kfail gdb/12790 "x86_64-*-*"
    setup_kfail gdb/12791 "arm*-*-*"
    set test "print find_max_long_double_real(4, ldc1, ldc2, ldc3, ldc4)"
    gdb_test_multiple $test $test {
	-re ".*= 4 \\+ 4 \\* I.*${gdb_prompt} $" {
	    pass $test
	}
    }

Maybe you can even convert the gdb_test_multiple's to gdb_test that way.
(You could also put the setup_kfails in a procedure to not need to 
repeat them everywhere).

-- 
Pedro Alves



More information about the Gdb-patches mailing list