]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
commit 4dc5b0e7836af7594fdb47061122a5655e5d4a82
authorJan Kratochvil <jan.kratochvil@redhat.com>
Sat, 2 Jul 2011 20:18:26 +0000 (20:18 +0000)
committerJan Kratochvil <jan.kratochvil@redhat.com>
Sat, 2 Jul 2011 20:18:26 +0000 (20:18 +0000)
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Sat Jul 2 12:08:44 2011 +0000
+
commit c0cfd78e8522c5ef61f77d5c613a0a0d7d6635fd
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Sat Jul 2 15:13:12 2011 +0000

gdb/testsuite/
* gdb.cp/m-static.exp: Call get_compiler_info.
(static const int initialized nowhere): Call setup_xfail for gcc <= 4.4.
* gdb.cp/pr9167.exp (p b): Likewise.
* gdb.cp/temargs.exp: Do not set have_pr_45024_fixed for gcc 4.6.
(test value of P in inner_m, test type of Z in inner_m): Call
setup_xfail for gcc <= 4.5.

gdb/testsuite/ChangeLog
gdb/testsuite/gdb.cp/m-static.exp
gdb/testsuite/gdb.cp/pr9167.exp
gdb/testsuite/gdb.cp/temargs.exp

index 9f523e8586bfdeb185a30fb62360104abd190be6..12efd0c3bee6c39384d110bc04bd4dedd01317a7 100644 (file)
@@ -1,3 +1,12 @@
+2011-07-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+       * gdb.cp/m-static.exp: Call get_compiler_info.
+       (static const int initialized nowhere): Call setup_xfail for gcc <= 4.4.
+       * gdb.cp/pr9167.exp (p b): Likewise.
+       * gdb.cp/temargs.exp: Do not set have_pr_45024_fixed for gcc 4.6.
+       (test value of P in inner_m, test type of Z in inner_m): Call
+       setup_xfail for gcc <= 4.5.
+
 2011-07-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
 
        * gdb.cp/paren-type.cc: New files.
index 9f060aca6f8784603dd3240446f460021cab823a..2743f591272c283dd5b92f99124a6335229aa1f0 100644 (file)
@@ -52,6 +52,10 @@ if { [gdb_compile "$objdir/$subdir/$objfile $objdir/$subdir/$objfile1" "${binfil
      return -1
 }
 
+if [get_compiler_info $binfile] {
+    return -1
+}
+
 gdb_exit
 gdb_start
 gdb_reinitialize_dir $srcdir/$subdir
@@ -126,6 +130,13 @@ gdb_test "print test3.data.value_derived" "\\$\[0-9\].* = etruscan" "template ob
 gdb_test "print test4.elsewhere" "\\$\[0-9\].* = 221" "static const int initialized elsewhere"
 
 # static const int that nobody initializes.  From PR gdb/635.
+if {[test_compiler_info {gcc-[0-3]-*}]
+    || [test_compiler_info {gcc-4-[0-4]-*}]} {
+    # There was an extra CU-level DW_TAG_variable as DW_AT_declaration
+    # with DW_AT_name = nowhere
+    # and DW_AT_MIPS_linkage_name = _ZN9gnu_obj_47nowhereE .
+    setup_xfail *-*-*
+}
 gdb_test "print test4.nowhere" "field nowhere is nonexistent or has been optimized out" "static const int initialized nowhere"
 
 # static const initialized in the class definition, PR gdb/11702.
index 4487929ede003630f451312ebfb741ed01502237..fc8476ca623125093f5527b828757c6cbdc19e7d 100644 (file)
@@ -32,5 +32,12 @@ if ![runto_main] then {
 gdb_breakpoint [gdb_get_line_number "marker"]
 gdb_continue_to_breakpoint "marker"
 
+if {[test_compiler_info {gcc-[0-3]-*}]
+    || [test_compiler_info {gcc-4-[0-4]-*}]} {
+    # There was an extra CU-level DW_TAG_variable for DEFAULT_INSTANCE
+    # as DW_AT_declaration with DW_AT_name = nowhere
+    # and DW_AT_MIPS_linkage_name = _ZN9gnu_obj_47nowhereE .
+    setup_xfail *-*-*
+}
 gdb_test "p b" "{<A<int, B>> = {<ATB<int>> = {data = 0}, static DEFAULT_INSTANCE = <optimized out>}, <No data fields>}"
 
index cd1eb53134daafc1ab78f7c6e49a8d5f534554af..ba9e85b9063a175ccec6c83a3fbe2e342348438a 100644 (file)
@@ -96,13 +96,23 @@ gdb_test "ptype T" "long" "test type of T in inner_m"
 setup_kfail "gcc/45024" *-*-*
 gdb_test "print I" " = 47" "test value of I in inner_m"
 
-if $have_older_template_gcc { setup_xfail "*-*-*" }
+if $have_older_template_gcc { setup_xfail "*-*-*"
+} elseif {[test_compiler_info {gcc-[0-3]-*}]
+        || [test_compiler_info {gcc-4-[0-5]-*}]} {
+  # gcc-4.5.x still does not emit inner DW_TAG_structure_type.
+  setup_xfail "*-*-*"
+}
 gdb_test "print P == &a_global" " = true" "test value of P in inner_m"
 
 setup_kfail "gcc/41736" *-*-*
 gdb_test "print MP" "&S::f" "test value of MP in inner_m"
 
-if $have_older_template_gcc { setup_xfail "*-*-*" }
+if $have_older_template_gcc { setup_xfail "*-*-*"
+} elseif {[test_compiler_info {gcc-[0-3]-*}]
+        || [test_compiler_info {gcc-4-[0-5]-*}]} {
+  # gcc-4.5.x still does not emit outer DW_TAG_structure_type.
+  setup_xfail "*-*-*"
+}
 gdb_test "whatis Z" "float" "test type of Z in inner_m"
 
 #