~ubuntu-branches/debian/sid/gcc-4.8/sid

« back to all changes in this revision

Viewing changes to .svn/pristine/b9/b92cdde70846bc979d674709859cd6f64ad4c20d.svn-base

  • Committer: Package Import Robot
  • Author(s): Matthias Klose
  • Date: 2014-12-19 19:48:34 UTC
  • Revision ID: package-import@ubuntu.com-20141219194834-4dz1q7rrn5pad823
Tags: 4.8.4-1
* GCC 4.8.4 release.
  - Fix PR target/61407 (darwin), PR middle-end/58624 (ice),
    PR sanitizer/64265 (wrong code).
* Require recent binutils to pass go test failures.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# DP: Reliably prune GCC notes in C++ compat suite
 
2
 
 
3
in testing the rs6000 ABI patches I noted a weird effect: usually, the
 
4
-Wpsabi warning notes are ignored in the compat test suites, so we get
 
5
a clean test run anyway.
 
6
 
 
7
However, when running the C++ version of the struct-layout-1.exp case
 
8
*alone* (using RUNTESTFLAGS=struct-layout-1.exp), suddenly tests are
 
9
failing because of those extra notes.  This does *not* happen with
 
10
the C version of that suite ...
 
11
 
 
12
It turns out that that pruning those notes is supposed to happen
 
13
from within gcc-defs.exp:${tool}_check_compile:
 
14
    if { [info proc ${tool}-dg-prune] != "" } {
 
15
        global target_triplet
 
16
        set gcc_output [${tool}-dg-prune $target_triplet $gcc_output]
 
17
    }
 
18
 
 
19
However, the g++-dg-prune routine is defined in g++-dg.exp, which
 
20
is never included from g++.dg/compat/struct-layout-1.exp (directly
 
21
or indirectly).  Now, when running the full suite, that file would
 
22
have been loaded by some earlier g++.dg .exp file, so everything
 
23
works out.  But when running struct-layout-1.exp stand-alone, the
 
24
g++-dg-prune routine is never defined and thus silently no pruning
 
25
takes place.
 
26
 
 
27
To fix this, the following patch simply loads g++-dg.exp directly
 
28
from g++.dg/compat/struct-layout-1.exp.
 
29
 
 
30
Tested on powerpc64-linux and powerpc64le-linux.
 
31
 
 
32
OK for mainline (and 4.8/4.9 once the rs6000 ABI patches are
 
33
backported there)?
 
34
 
 
35
Bye,
 
36
Ulrich
 
37
 
 
38
 
 
39
gcc/testsuite/ChangeLog:
 
40
 
 
41
        * g++.dg/compat/struct-layout-1.exp: Load g++-dg.exp
 
42
 
 
43
 
 
44
--- a/src/gcc/testsuite/g++.dg/compat/struct-layout-1.exp
 
45
+++ b/src/gcc/testsuite/g++.dg/compat/struct-layout-1.exp
 
46
@@ -89,6 +89,9 @@ proc compat-use-tst-compiler { } {
 
47
 # This must be done after the compat-use-*-compiler definitions.
 
48
 load_lib compat.exp
 
49
 
 
50
+# Provide the g++-dg-prune routine (gcc-dp.exp is loaded by compat.exp)
 
51
+load_lib g++-dg.exp
 
52
+
 
53
 g++_init
 
54
 
 
55
 # Save variables for the C++ compiler under test, which each test will
 
56