+2017-02-01  Markus Metzger  <markus.t.metzger@intel.com>
+
+       * gdb.btrace/buffer-size.exp: Add unsupported/untested message if
+       the test is skipped.
+       * gdb.btrace/data.exp: Likewise.
+       * gdb.btrace/delta.exp: Likewise.
+       * gdb.btrace/dlopen.exp: Likewise.
+       * gdb.btrace/enable-running.exp: Likewise.
+       * gdb.btrace/enable.exp: Likewise.
+       * gdb.btrace/exception.exp: Likewise.
+       * gdb.btrace/function_call_history.exp: Likewise.
+       * gdb.btrace/gcore.exp: Likewise.
+       * gdb.btrace/instruction_history.exp: Likewise.
+       * gdb.btrace/multi-thread-step.exp: Likewise.
+       * gdb.btrace/nohist.exp: Likewise.
+       * gdb.btrace/non-stop.exp: Likewise.
+       * gdb.btrace/reconnect.exp: Likewise.
+       * gdb.btrace/record_goto-step.exp: Likewise.
+       * gdb.btrace/record_goto.exp: Likewise.
+       * gdb.btrace/rn-dl-bind.exp: Likewise.
+       * gdb.btrace/segv.exp: Likewise.
+       * gdb.btrace/step.exp: Likewise.
+       * gdb.btrace/stepi.exp: Likewise.
+       * gdb.btrace/tailcall-only.exp: Likewise.
+       * gdb.btrace/tailcall.exp: Likewise.
+       * gdb.btrace/tsx.exp: Likewise.
+       * gdb.btrace/unknown_functions.exp: Likewise.
+       * gdb.btrace/vdso.exp: Likewise.
+
 2017-02-01  Markus Metzger  <markus.t.metzger@intel.com>
 
        * gdb.btrace/enable-running.c: New.
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile record_goto.c
 if [prepare_for_testing "failed to prepare" $testfile $srcfile] {
     return -1
 }
 
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile
 if [prepare_for_testing "failed to prepare" $testfile $srcfile] {
     return -1
 }
+
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile record_goto.c
 if [prepare_for_testing "failed to prepare" $testfile $srcfile] {
     return -1
 }
+
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-if { [skip_btrace_tests] } { return -1 }
-if { [skip_shlib_tests]  } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
+
+if { [skip_shlib_tests]  } {
+    unsupported "target does not support shared library tests"
+    return -1
+}
 
 standard_testfile
 
 
 if { [gdb_compile_shlib $srcfile_lib $binfile_lib \
          [list additional_flags=-fPIC]] != "" } {
-    untested "failed to compile shared library"
+    untested "failed to prepare shlib"
     return -1
 }
 
 }
 
 if ![runto_main] {
-    return 0
+    untested "failed to run to main"
+    return -1
 }
 
 # Trace the test function
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
 standard_testfile
 if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" "$binfile" executable {debug}] != "" } {
+    untested "failed to prepare"
     return -1
 }
 
 }
 
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
 # start fresh - without an executable
 gdb_exit
 gdb_test "record instruction-history" "No record target is currently active\\..*" "record instruction-history without target"
 gdb_test "info record" "No record target is currently active\\." "info record without target"
 
-# start inferior
 standard_testfile
 if [prepare_for_testing "failed to prepare" $testfile {} {debug}] {
     return -1
 }
+
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 # otherwise rerun twice, target should be automatically disabled
 load_lib gdbserver-support.exp
 if [skip_gdbserver_tests] {
+    unsupported "target does not support gdbserver"
     return 0
 }
 clean_restart $testfile
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 # make sure record-btrace can be enabled after re-run
 clean_restart $testfile
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 gdb_test_no_output "record btrace"
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 gdb_test_no_output "record btrace" "enable after re-run"
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile exception.cc
 if [prepare_for_testing "failed to prepare" $testfile $srcfile {c++ debug}] {
     return -1
 }
+
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile
 if [prepare_for_testing "failed to prepare" $testfile {} {debug}] {
     return -1
 }
+
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # make sure we can handle incomplete trace with respect to indentation
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 # navigate to the fib in line 24 above
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile record_goto.c
 if [prepare_for_testing "failed to prepare" $testfile $srcfile] {
     return -1
 }
 
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# compile and run to main
 standard_testfile .c .S
 if [prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" {debug}] {
     return -1
 }
+
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile
 if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" "$binfile" executable {debug}] != "" } {
+    untested "failed to prepare"
     return -1
 }
 clean_restart $testfile
 
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile record_goto.c
 if [prepare_for_testing "failed to prepare" $testfile $srcfile] {
     return -1
 }
 
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
-
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile
 if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" "$binfile" executable {debug}] != "" } {
+    untested "failed to prepare"
     return -1
 }
 clean_restart $testfile
 gdb_test_no_output "set non-stop on"
 
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 
 load_lib gdbserver-support.exp
 
-if { [skip_btrace_tests] } { return -1 }
-if { [skip_gdbserver_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
+if { [skip_gdbserver_tests] } {
+    unsupported "target does not support gdbserver"
+    return -1
+}
 
 standard_testfile
 if [prepare_for_testing "failed to prepare" $testfile $srcfile] {
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
 standard_testfile record_goto.c
-
-# start inferior
 if [prepare_for_testing "failed to prepare" $testfile $srcfile] {
     return -1
 }
 
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
 # The "record goto" command jumps to a specific instruction in the execution
 # trace.  To guarantee that we always get the same execution trace, we use
                standard_testfile i686-record_goto.S
        }
 } else {
-    verbose "Skipping ${testfile}."
+    unsupported "target architecture not supported"
     return -1
 }
 
 if [prepare_for_testing "failed to prepare" $testfile $srcfile $opts] {
     return -1
 }
+
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # Test that we can reverse-next over the dynamic linker's symbol
 # lookup code.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile
 if [prepare_for_testing "failed to prepare" $testfile $srcfile {c++ debug}] {
     return -1
 }
+
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile
 if [prepare_for_testing "failed to prepare" $testfile $srcfile] {
     return -1
 }
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
 standard_testfile record_goto.c
-
-# start inferior
 if [prepare_for_testing "failed to prepare" $testfile $srcfile] {
     return -1
 }
 
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
 # This test is stepping on instruction level.  To guarantee that we always
 # get the same execution trace, we use an assembly source file.
                standard_testfile i686-record_goto.S
        }
 } else {
-    verbose "Skipping ${testfile}."
+    unsupported "target architecture not supported"
     return -1
 }
 
-# start inferior
 if [prepare_for_testing "failed to prepare" $testfile $srcfile] {
     return -1
 }
 
-global gdb_prompt
-
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
+global gdb_prompt
+
 proc check_replay_at { insn } {
   gdb_test "info record" [multi_line \
     "Active record target: record-btrace" \
 
 # calls.  This used to cause a crash in get_frame_type.
 #
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
 # This test requires the compiler to generate a tail call.  To guarantee that
 # we always get one, we use an assembly source file.
                standard_testfile i686-tailcall-only.S
        }
 } else {
-    verbose "Skipping ${testfile}."
+    unsupported "target architecture not supported"
     return -1
 }
 
 if [prepare_for_testing "failed to prepare" $testfile $srcfile $opts] {
     return -1
 }
+
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
 # This test requires the compiler to generate a tail call.  To guarantee that
 # we always get one, we use an assembly source file.
                standard_testfile i686-tailcall.S
        }
 } else {
-    verbose "Skipping ${testfile}."
+    unsupported "target architecture not supported"
     return -1
 }
 
     return -1
 }
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-if { [skip_btrace_pt_tests] } { return -1 }
-if { [skip_tsx_tests] } { return -1 }
+if { [skip_btrace_pt_tests] } {
+    unsupported "target does not support PT"
+    return -1
+}
+
+if { [skip_tsx_tests] } {
+    unsupported "target does not support TSX"
+    return -1
+}
 
-# compile and run to main
 standard_testfile .c x86-tsx.S
 if [prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" {debug}] {
     return -1
 }
+
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }
 
 
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile
 
 # discard local symbols
 if [prepare_for_testing "failed to prepare" $testfile $srcfile $ldflags] {
     return -1
 }
+
 if ![runto test] {
+    untested "failed to run to main"
     return -1
 }
 
 
 #
 # Test that we can access the vdso memory during replay for stepping.
 
-# check for btrace support
-if { [skip_btrace_tests] } { return -1 }
+if { [skip_btrace_tests] } {
+    unsupported "target does not support record-btrace"
+    return -1
+}
 
-# start inferior
 standard_testfile
 if [prepare_for_testing "failed to prepare" $testfile $srcfile] {
     return -1
 }
+
 if ![runto_main] {
+    untested "failed to run to main"
     return -1
 }