]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - gdb/testsuite/gdb.trace/change-loc.exp
Update years in copyright notice for the GDB files.
[thirdparty/binutils-gdb.git] / gdb / testsuite / gdb.trace / change-loc.exp
index a5a982f77b00a2b2d3f073d693d3c2c265787222..6e05da1d22671341ce81ee49f48b237da045a3c0 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2011-2012 Free Software Foundation, Inc.
+# Copyright 2011-2013 Free Software Foundation, Inc.
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
 # the Free Software Foundation; either version 3 of the License, or
@@ -18,20 +18,18 @@ if {[skip_shlib_tests]} {
     return 0
 }
 
-set testfile "change-loc"
+standard_testfile
 set libfile1 "change-loc-1"
 set libfile2 "change-loc-2"
-set srcfile $testfile.c
 set executable $testfile
 set libsrc1 $srcdir/$subdir/$libfile1.c
 set libsrc2 $srcdir/$subdir/$libfile2.c
-set binfile $objdir/$subdir/$testfile
-set lib_sl1 $objdir/$subdir/$libfile1.sl
-set lib_sl2 $objdir/$subdir/$libfile2.sl
+set lib_sl1 [standard_output_file $libfile1.sl]
+set lib_sl2 [standard_output_file $libfile2.sl]
 
 set lib_opts debug
 
-if [get_compiler_info ${binfile}] {
+if [get_compiler_info] {
     return -1
 }
 
@@ -156,7 +154,8 @@ proc tracepoint_change_loc_1 { trace_type } { with_test_prefix "1 $trace_type" {
     # shlib is unloaded, there are still three locations, but one is pending.
     gdb_test "info trace" \
         "Num     Type\[ \]+Disp Enb Address\[ \]+What.*
-\[0-9\]+\[\t \]+\(|fast \)tracepoint\[ \]+keep y.*\<MULTIPLE\>.*4\.1.* in func4.*4\.2.* in func4.*4\.3.* \<PENDING\>\[\t \]+set_tracepoint.*" \
+\[0-9\]+\[\t \]+\(|fast \)tracepoint\[ \]+keep y.*\<MULTIPLE\>.*
+4\.1.* in func4.*\tinstalled on target\r\n(4\.2.* in func4.*\tinstalled on target\r\n4\.3.* \<PENDING\>\[\t \]+set_tracepoint|4\.2.* \<PENDING\>\[\t \]+set_tracepoint.*4\.3.* in func4.*\tinstalled on target).*" \
         "tracepoint with two locations (unload)"
 
     gdb_test_no_output "tstop"
@@ -188,10 +187,11 @@ proc tracepoint_change_loc_2 { trace_type } { with_test_prefix "2 $trace_type" {
     gdb_trace_setactions "set action for tracepoint" "" \
        "collect \$$pcreg" "^$"
 
-    # tracepoint has no location information now.
+    # tracepoint has no location information now.  Make sure nothing
+    # else is displayed.
     gdb_test "info trace" \
        "Num     Type\[ \]+Disp Enb Address\[ \]+What.*
-\[0-9\]+\[\t \]+\(|fast \)tracepoint\[ \]+keep y.*PENDING.*set_tracepoint.*" \
+\[0-9\]+\[\t \]+\(|fast \)tracepoint\[ \]+keep y.*PENDING.*set_tracepoint\r\n\[\t \]+collect \\$$pcreg\r" \
        "single pending tracepoint info (without symbols)"
 
     gdb_load ${binfile}
@@ -260,7 +260,8 @@ proc tracepoint_change_loc_2 { trace_type } { with_test_prefix "2 $trace_type" {
     # shlib is unloaded, there are still three locations, but one is pending.
     gdb_test "info trace" \
        "Num     Type\[ \]+Disp Enb Address\[ \]+What.*
-\[0-9\]+\[\t \]+\(|fast \)tracepoint\[ \]+keep y.*\<MULTIPLE\>.*1\.1.* in func4.*1\.2.* in func4.*1\.3.* \<PENDING\>\[\t \]+set_tracepoint.*" \
+\[0-9\]+\[\t \]+\(|fast \)tracepoint\[ \]+keep y.*\<MULTIPLE\>.*
+1\.1.* in func4.*\tinstalled on target\r\n(1\.2.* in func4.*\tinstalled on target\r\n1\.3.* \<PENDING\>\[\t \]+set_tracepoint|1\.2.* \<PENDING\>\[\t \]+set_tracepoint\r\n1\.3.* in func4.*\tinstalled on target).*" \
        "tracepoint with two locations (unload)"
 
     gdb_test_no_output "tstop"
@@ -275,7 +276,7 @@ tracepoint_change_loc_1 "trace"
 tracepoint_change_loc_2 "trace"
 
 # Re-compile test case with IPA.
-set libipa $objdir/../gdbserver/libinproctrace.so
+set libipa [get_in_proc_agent]
 gdb_load_shlibs $libipa
 
 if { [gdb_compile "$srcdir/$subdir/$srcfile" $binfile executable \