re PR bootstrap/64612 (profiledbootstrap failures)
authorJakub Jelinek <jakub@redhat.com>
Wed, 28 Jan 2015 07:45:56 +0000 (08:45 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Wed, 28 Jan 2015 07:45:56 +0000 (08:45 +0100)
PR bootstrap/64612
* lib/target-supports.exp (check_effective_target_comdat_group): New.
* g++.dg/ipa/pr64612.C: Guard scan-assembler test with
{ target comdat_group }.

* doc/sourcebuild.texi (comdat_group): Document.

From-SVN: r220198

gcc/ChangeLog
gcc/doc/sourcebuild.texi
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/ipa/pr64612.C
gcc/testsuite/lib/target-supports.exp

index 32dbae4f6e841558945cce3f1fae3270da199b67..168d255b54d131bb4a0b1a13a7c2f5c939b9d13a 100644 (file)
@@ -1,3 +1,8 @@
+2015-01-28  Jakub Jelinek  <jakub@redhat.com>
+
+       PR bootstrap/64612
+       * doc/sourcebuild.texi (comdat_group): Document.
+
 2015-01-28  Terry Guo  <terry.guo@arm.com>
 
        * config/arm/thumb1.md (*thumb1_movpc_insn): New insn pattern.
index 738e55832ae113073ee8149115ba5a866d273c10..eef5081b998c17b0294da6d564474464460da63d 100644 (file)
@@ -1930,6 +1930,9 @@ Target supports @code{wchar_t} that is compatible with @code{char16_t}.
 
 @item wchar_t_char32_t_compatible
 Target supports @code{wchar_t} that is compatible with @code{char32_t}.
+
+@item comdat_group
+Target uses comdat groups.
 @end table
 
 @subsubsection Local to tests in @code{gcc.target/i386}
index 6c0f0e19f5a496d5ad783dc434e69aeabe8c2cdb..12c1c57d65d4ca7219941d75b50aeed80a04112d 100644 (file)
@@ -1,3 +1,10 @@
+2015-01-28  Jakub Jelinek  <jakub@redhat.com>
+
+       PR bootstrap/64612
+       * lib/target-supports.exp (check_effective_target_comdat_group): New.
+       * g++.dg/ipa/pr64612.C: Guard scan-assembler test with
+       { target comdat_group }.
+
 2015-01-27  Tobias Burnus  <burnus@net-b.de>
 
        PR fortran/63861
index f1cd96ad139b6474fb47d311205ca9d7336f8384..b6fe39a37411f947e98a48f8ce728dd6c01c965a 100644 (file)
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -std=c++11" } */
-/* { dg-final { scan-assembler "_ZN5QListI7QStringED1Ev" } } */
+/* { dg-final { scan-assembler "_ZN5QListI7QStringED1Ev" { target comdat_group } } } */
 
 class A
 {
index b673560df377c68a93ab445b872043ed775d4221..2cc8c219dc642b7bf6e662b630b45a8c5fe4f912 100644 (file)
@@ -6199,3 +6199,13 @@ proc check_effective_target_pie_copyreloc { } {
 
     return $pie_copyreloc_available_saved
 }
+
+# Return 1 if the target uses comdat groups.
+
+proc check_effective_target_comdat_group {} {
+    return [check_no_messages_and_pattern comdat_group "\.section\[^\n\r]*,comdat" assembly {
+       // C++
+       inline int foo () { return 1; }
+       int (*fn) () = foo;
+    }]
+}