PR21166: Validate rdrand/rdseed support separately in gdb.reverse/insn-reverse-x86.c
authorLuis Machado <lgustavo@codesourcery.com>
Thu, 23 Feb 2017 20:36:58 +0000 (14:36 -0600)
committerLuis Machado <lgustavo@codesourcery.com>
Thu, 23 Feb 2017 20:39:16 +0000 (14:39 -0600)
commit17cd494709a60750234c7dbe4f1db2932f8a71c4
tree4eaf73161d75025746e59409b47088aba3405a56
parent359ca075e7fe20a5106d5c068193dad0c53af480
PR21166: Validate rdrand/rdseed support separately in gdb.reverse/insn-reverse-x86.c

As reported in PR21166, there are Intel processors out there that support
rdrand but not rdseed. The fix is to verify both features separately and only
run rdrand/rdseed tests if supported.

gdb/testsuite/ChangeLog:
2017-02-23  Luis Machado  <lgustavo@codesourcery.com>

* gdb.reverse/insn-reverse.x86.c (check_rdrand_support): Renamed to ...
(check_supported_features): ... this. Changed return type to void.
(supports_rdseed): New static global.
(rdseed): Check supports_rdseed.
(initialize): Call check_supported_features.
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.reverse/insn-reverse-x86.c