OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /openrisc/trunk/gnu-stable/gcc-4.5.1/gcc/testsuite/gcc.dg/debug
    from Rev 816 to Rev 826
    Reverse comparison

Rev 816 → Rev 826

/dwarf2/inline2.c
0,0 → 1,70
/* Contributed by Dodji Seketeli <dodji@redhat.com>
Origin: PR debug/37801
 
Abstract instances (DW_TAG_subroutines having the DW_AT_inline attribute)
of second and first were having a DW_TAG_lexical_block DIE wrongly
representing the inlined calls to third (in second) and to
second (in first). At the same time, main didn't have children
DW_TAG_inlined_subroutine DIEs representing the inlined calls to
first, second and third.
 
The ideal goal here is to test that we have no superfluous
DW_TAG_lexical_block DIE anymore, that abstract instances DIEs have
no descendant DIE with a DW_AT_abstract_origin attribute, and that main has
properly nested DW_TAG_inlined_subroutine DIEs for third, second and first.
*/
 
/* { dg-options "-O -g3 -gdwarf-2 -dA" } */
/* { dg-do compile } */
 
/* There are 6 inlined subroutines:
- One for each subroutine inlined into main, that's 3.
- One for earch subroutine inline into the out of line instances
of third, second and first. */
/* { dg-final { scan-assembler-times "\\(DIE \\(.*?\\) DW_TAG_inlined_subroutine" 6 } } */
 
/* Likewise we should have 6 DW_TAG_lexical_block DIEs:
- One for each subroutine inlined into main, so that's 3.
- One for each subroutine inlined in the out of line instances
of third, second and first, that's 3.
*/
/* { dg-final { scan-assembler-times "\\(DIE \\(.*?\\) DW_TAG_lexical_block" 6 } } */
 
 
/* There are 3 DW_AT_inline attributes: one per abstract inline instance.
The value of the attribute must be 0x3, meaning the function was
actually inlined. */
/* { dg-final { scan-assembler-times "(?:byte|data1)\[^\n\]*0x3\[^\n\]* DW_AT_inline" 3 } } */
 
volatile int *a;
 
inline void
third (int arg3)
{
int var3 = arg3;
a[0] = var3;
}
 
inline void
second (int arg2)
{
int var2 = arg2;
third (var2+1);
}
 
inline void
first (int arg1)
{
int var1 = arg1;
second (var1+1);
}
 
int
main ()
{
int some_int = 1;
first (some_int);
return 0;
}
 
 
dwarf2/inline2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/inline3.c =================================================================== --- dwarf2/inline3.c (nonexistent) +++ dwarf2/inline3.c (revision 826) @@ -0,0 +1,22 @@ +/* Verify that only one DW_AT_const_value is emitted for baz, + not for baz abstract DIE and again inside of + DW_TAG_inlined_subroutine. */ +/* { dg-options "-O2 -gdwarf-2 -dA" } */ +/* { dg-do compile } */ +/* { dg-final { scan-assembler-times " DW_AT_const_value" 1 } } */ + +struct A { const long i; const long j; }; + +static inline long +foo (void) +{ + const struct A baz = { .i = 2, .j = 21 }; + asm volatile ("" : : : "memory"); + return baz.i * baz.j; +} + +int +main () +{ + return foo () - 42; +}
dwarf2/inline3.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/struct-loc1.c =================================================================== --- dwarf2/struct-loc1.c (nonexistent) +++ dwarf2/struct-loc1.c (revision 826) @@ -0,0 +1,17 @@ +/* { dg-do compile } */ +/* { dg-options "-gdwarf-2 -O0 -dA -fno-merge-debug-strings" } */ + +struct foo; +struct foo *obj; +struct foo +{ + int x; +}; + +int +main () +{ + return 0; +} + +/* { dg-final { scan-assembler "DW_TAG_structure_type\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"foo\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0x)?6\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */
dwarf2/struct-loc1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr41445-1.c =================================================================== --- dwarf2/pr41445-1.c (nonexistent) +++ dwarf2/pr41445-1.c (revision 826) @@ -0,0 +1,18 @@ +/* PR preprocessor/41445 */ +/* Test that token after multi-line function-like macro use + gets correct locus even when preprocessing separately. */ +/* { dg-do compile } */ +/* { dg-options "-save-temps -gdwarf-2 -O0 -dA -fno-merge-debug-strings" } */ + +#define A(a,b) +int varh;A(1, + + + + 2)int vari; +int varj; + +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"varh\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0x)?8\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"vari\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0xc|12)\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"varj\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0xd|13)\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { cleanup-saved-temps } } */
dwarf2/pr41445-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr41445-2.c =================================================================== --- dwarf2/pr41445-2.c (nonexistent) +++ dwarf2/pr41445-2.c (revision 826) @@ -0,0 +1,9 @@ +/* PR preprocessor/41445 */ +/* { dg-do compile } */ +/* { dg-options "-gdwarf-2 -O0 -dA -fno-merge-debug-strings" } */ + +#include "pr41445-1.c" + +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"varh\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0x)?8\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"vari\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0xc|12)\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"varj\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0xd|13)\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */
dwarf2/pr41445-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr41445-3.c =================================================================== --- dwarf2/pr41445-3.c (nonexistent) +++ dwarf2/pr41445-3.c (revision 826) @@ -0,0 +1,18 @@ +/* PR preprocessor/41445 */ +/* Test that token after multi-line function-like macro use + gets correct locus even when preprocessing separately. */ +/* { dg-do compile } */ +/* { dg-options "-save-temps -gdwarf-2 -O0 -dA -fno-merge-debug-strings" } */ + +#define A(a,b) +int varh;/* + +Some multi-line comment. + + */int vari; +int varj; + +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"varh\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0x)?8\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"vari\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0xc|12)\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"varj\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0xd|13)\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { cleanup-saved-temps } } */
dwarf2/pr41445-3.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr41445-4.c =================================================================== --- dwarf2/pr41445-4.c (nonexistent) +++ dwarf2/pr41445-4.c (revision 826) @@ -0,0 +1,9 @@ +/* PR preprocessor/41445 */ +/* { dg-do compile } */ +/* { dg-options "-gdwarf-2 -O0 -dA -fno-merge-debug-strings" } */ + +#include "pr41445-3.c" + +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"varh\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0x)?8\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"vari\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0xc|12)\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"varj\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0xd|13)\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */
dwarf2/pr41445-4.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr41445-5.c =================================================================== --- dwarf2/pr41445-5.c (nonexistent) +++ dwarf2/pr41445-5.c (revision 826) @@ -0,0 +1,14 @@ +/* PR preprocessor/41445 */ +/* Test that token after multi-line function-like macro use + gets correct locus even when preprocessing separately. */ +/* { dg-do compile } */ +/* { dg-options "-save-temps -gdwarf-2 -O0 -dA -fno-merge-debug-strings" } */ + +#define A(x) vari x +#define vari(x) +#define B , varj +int A(B) ; + +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"vari\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0x)?7\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"varj\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0xa|10)\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { cleanup-saved-temps } } */
dwarf2/pr41445-5.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr41445-6.c =================================================================== --- dwarf2/pr41445-6.c (nonexistent) +++ dwarf2/pr41445-6.c (revision 826) @@ -0,0 +1,8 @@ +/* PR preprocessor/41445 */ +/* { dg-do compile } */ +/* { dg-options "-gdwarf-2 -O0 -dA -fno-merge-debug-strings" } */ + +#include "pr41445-5.c" + +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"vari\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0x)?7\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */ +/* { dg-final { scan-assembler "DW_TAG_variable\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\"varj\[^\\r\\n\]*DW_AT_name(\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*DW_AT_)*\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*\[^0-9a-fA-FxX](0xa|10)\[^0-9a-fA-FxX]\[^\\r\\n\]*DW_AT_decl_line" } } */
dwarf2/pr41445-6.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr37726.c =================================================================== --- dwarf2/pr37726.c (nonexistent) +++ dwarf2/pr37726.c (revision 826) @@ -0,0 +1,25 @@ +/* PR debug/37726 */ +/* { dg-do compile } */ +/* { dg-options "-gdwarf-2 -O0 -dA -fno-merge-debug-strings" } */ + +int foo (int parm) +{ + int var = 0; + int bar (void) + { + return parm + var; + } + parm++; + var++; + return bar (); +} + +int +main (void) +{ + return foo (4) - 6; +} + +/* Both parm and var variables should be in debug info for both foo and bar. */ +/* { dg-final { scan-assembler-times "\"parm\[^\n\]*\"\[^\n\]*DW_AT_name" 2 } } */ +/* { dg-final { scan-assembler-times "\"var\[^\n\]*\"\[^\n\]*DW_AT_name" 2 } } */
dwarf2/pr37726.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/global-used-types.c =================================================================== --- dwarf2/global-used-types.c (nonexistent) +++ dwarf2/global-used-types.c (revision 826) @@ -0,0 +1,14 @@ +/* + Contributed by Dodji Seketeli + { dg-options "-gdwarf-2 -dA -fno-merge-debug-strings" } + { dg-do compile } + { dg-final { scan-assembler-times "DIE \\(0x.*?\\) DW_TAG_enumeration_type" 1 } } + { dg-final { scan-assembler-times "DIE \\(0x.*?\\) DW_TAG_enumerator" 2 } } + { dg-final { scan-assembler-times "ascii \"a.0\"\[\t \]+.*?DW_AT_name" 1 } } + { dg-final { scan-assembler-times "ascii \"b.0\"\[\t \]+.*?DW_AT_name" 1 } } + */ + +enum { a, b }; + +int v = a; +char s[b];
dwarf2/global-used-types.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/inline1.c =================================================================== --- dwarf2/inline1.c (nonexistent) +++ dwarf2/inline1.c (revision 826) @@ -0,0 +1,18 @@ +/* { dg-do compile } */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ +void e(int); +__attribute__ ((always_inline)) inline int +t(int function_parameter) +{ + e(function_parameter); +} + +void test (int function_parameter2) +{ + t(function_parameter2); +} + +/* Verify that we get both function_parameter and function_parameter2 declared + in test. Overall we should have 3 variables with location defined (also + function_parameter in offline copy of t. */ +/* { dg-final { scan-assembler-times " DW_AT_location" 3 } } */
dwarf2/inline1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-float.c =================================================================== --- dwarf2/dwarf-float.c (nonexistent) +++ dwarf2/dwarf-float.c (revision 826) @@ -0,0 +1,15 @@ +/* Verify the DWARF encoding of C99 floating point types. */ + +/* { dg-do compile */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ +/* { dg-final { scan-assembler "0x4.*DW_AT_encoding" } } */ +/* { dg-final { scan-assembler "0x4.*DW_AT_byte_size" } } */ +/* { dg-final { scan-assembler "0x8.*DW_AT_byte_size" } } */ +/* { dg-final { scan-assembler "0x10.*DW_AT_byte_size" } } */ + +void foo () +{ + float f = 1.5f; + double d = 1.5; + long double l = 1.5l; +}
dwarf2/dwarf-float.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/var1.c =================================================================== --- dwarf2/var1.c (nonexistent) +++ dwarf2/var1.c (revision 826) @@ -0,0 +1,10 @@ +/* PR 23190 */ +/* { dg-do compile } +/* { dg-options "-gdwarf-2 -dA -fno-merge-debug-strings" } */ +/* { dg-final { scan-assembler "xyzzy\[^\\n\\r\]+DW_AT_name" } } */ + +void f(void) +{ + static int xyzzy; + xyzzy += 3; +}
dwarf2/var1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/aranges-fnsec-1.c =================================================================== --- dwarf2/aranges-fnsec-1.c (nonexistent) +++ dwarf2/aranges-fnsec-1.c (revision 826) @@ -0,0 +1,14 @@ +/* Test that .debug_aranges and .debug_ranges do not have an entry for the + text section if nothing went in there. */ +/* Origin: Joseph Myers */ +/* { dg-do compile } */ +/* { dg-options "-gdwarf-2 -ffunction-sections -w -dA" } */ +/* { dg-final { scan-assembler-not "\\.Letext0-\\.Ltext0" } } */ +/* { dg-final { scan-assembler-not "\\.Ltext0\[^\n\r\]*Offset 0x0" } } */ +/* { dg-final { scan-assembler "DW_AT_ranges" } } */ + +int +f (void) +{ + return 1; +}
dwarf2/aranges-fnsec-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-dfp.c =================================================================== --- dwarf2/dwarf-dfp.c (nonexistent) +++ dwarf2/dwarf-dfp.c (revision 826) @@ -0,0 +1,16 @@ +/* Verify the DWARF encoding of C99 decimal floating point types. */ + +/* { dg-do compile */ +/* { dg-require-effective-target dfp } */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ +/* { dg-final { scan-assembler "0x10.*DW_AT_encoding" } } */ +/* { dg-final { scan-assembler "0x4.*DW_AT_byte_size" } } */ +/* { dg-final { scan-assembler "0x8.*DW_AT_byte_size" } } */ +/* { dg-final { scan-assembler "0x10.*DW_AT_byte_size" } } */ + +void foo () +{ + _Decimal32 f = 1.5df; + _Decimal64 d = 1.5dd; + _Decimal128 l = 1.5dl; +}
dwarf2/dwarf-dfp.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/var2.c =================================================================== --- dwarf2/var2.c (nonexistent) +++ dwarf2/var2.c (revision 826) @@ -0,0 +1,14 @@ +/* PR 23190 */ +/* { dg-do compile } +/* { dg-options "-O2 -gdwarf-2 -dA" } */ +/* { dg-final { scan-assembler "DW_OP_addr\[\\n\\r\]+\[^\\n\\r\]+foo" } } */ +/* { dg-final { scan-assembler "DW_OP_addr\[\\n\\r\]+\[^\\n\\r\]+bar" } } */ + +static int foo; +int bar; +int main(void) +{ + foo += 3; + bar *= 5; + return 0; +}
dwarf2/var2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr41543.c =================================================================== --- dwarf2/pr41543.c (nonexistent) +++ dwarf2/pr41543.c (revision 826) @@ -0,0 +1,14 @@ +/* PR preprocessor/41543 */ +/* { dg-do compile } */ +/* { dg-options "-save-temps -g -O0 -dA -fno-merge-debug-strings" } */ + +#include + +int +foo (va_list ap) +{ + return va_arg (ap, int); +} + +/* { dg-final { scan-assembler-not "DW_AT_decl_file\[^\\r\\n\]*\(pr41543\.i\)" } } */ +/* { dg-final { cleanup-saved-temps } } */
dwarf2/pr41543.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/fesd.h =================================================================== --- dwarf2/fesd.h (nonexistent) +++ dwarf2/fesd.h (revision 826) @@ -0,0 +1,36 @@ +/* +where from: base = matching base; head = other header +what kind: ordy = ordinary struct; tmpl = template struct +definition: decl = incomplete declaration; defn = full definition +how used: not = not used; ref = by ref; ptr = through pointer; + fld = as field; var = as variable +from where: base = from base; head = other header +*/ + +struct gstruct_head_ordy_decl_not; +struct gstruct_head_ordy_defn_not { int field_head_ordy_defn_not; }; + +struct gstruct_head_ordy_decl_ref_head; +struct gstruct_head_ordy_defn_ref_head { int field_head_ordy_defn_ref_head; }; +struct gstruct_head_ordy_defn_ptr_head { int field_head_ordy_defn_ptr_head; }; +struct gstruct_head_ordy_defn_fld_head { int field_head_ordy_defn_fld_head; }; +struct gstruct_head_ordy_defn_var_head { + struct gstruct_head_ordy_decl_ref_head *field_head_ordy_defn_var_head_inc; + struct gstruct_head_ordy_defn_ref_head *field_head_ordy_defn_var_head_ref; + struct gstruct_head_ordy_defn_ptr_head *field_head_ordy_defn_var_head_ptr; + struct gstruct_head_ordy_defn_fld_head field_head_ordy_defn_var_head_fld; +}; +extern struct gstruct_head_ordy_defn_var_head head_var1; + +struct gstruct_head_ordy_decl_ref_base; +struct gstruct_head_ordy_defn_ref_base { int field_head_ordy_defn_ref_base; }; +struct gstruct_head_ordy_defn_ptr_base { int field_head_ordy_defn_ptr_base; }; +struct gstruct_head_ordy_defn_fld_base { int field_head_ordy_defn_fld_base; }; +struct gstruct_head_ordy_defn_var_base { int field_head_ordy_defn_var_base; }; + +inline int head_function() { + return 0 ++ head_var1.field_head_ordy_defn_var_head_ptr->field_head_ordy_defn_ptr_head ++ head_var1.field_head_ordy_defn_var_head_fld.field_head_ordy_defn_fld_head +; +}
dwarf2/fesd.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr36690-1.c =================================================================== --- dwarf2/pr36690-1.c (nonexistent) +++ dwarf2/pr36690-1.c (revision 826) @@ -0,0 +1,22 @@ +/* PR debug/36690 */ +/* Verify that break func is hit. */ +/* { dg-do compile } */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ + +int i; + +void +func (void) +{ + while (i == 1) + i = 0; +} + +int +main (void) +{ + func (); + return 0; +} + +/* { dg-final { scan-assembler "pr36690-1.c:11" } } */
dwarf2/pr36690-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/const-2b.c =================================================================== --- dwarf2/const-2b.c (nonexistent) +++ dwarf2/const-2b.c (revision 826) @@ -0,0 +1,7 @@ +/* { dg-do compile { target i386*-*-* } } */ +/* { dg-options "-O -gdwarf-2 -dA -msse" } */ +/* { dg-require-effective-target sse } */ +/* { dg-final { scan-assembler "DW_AT_const_value" } } */ + +typedef float FloatVect __attribute__((__vector_size__(16))); +static FloatVect Foo = { 250000000.0, 0.0, 0.0, 0.0 };
dwarf2/const-2b.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr36690-2.c =================================================================== --- dwarf2/pr36690-2.c (nonexistent) +++ dwarf2/pr36690-2.c (revision 826) @@ -0,0 +1,39 @@ +/* PR debug/36690 */ +/* Verify that breakpoint can be put on goto f1, it is hit and + varz at that spot is defined and contains 5. Nowhere else + in the function should be varz in the scope. */ +/* { dg-do compile } */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ + +int cnt; + +void +bar (int i) +{ + cnt += i; +} + +void +foo (int i) +{ + if (!i) + bar (0); + else + { + static int varz = 5; + goto f1; + } + bar (1); +f1: + bar (2); +} + +int +main (void) +{ + foo (0); + foo (1); + return 0; +} + +/* { dg-final { scan-assembler "pr36690-2.c:24" } } */
dwarf2/pr36690-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr36690-3.c =================================================================== --- dwarf2/pr36690-3.c (nonexistent) +++ dwarf2/pr36690-3.c (revision 826) @@ -0,0 +1,53 @@ +/* PR debug/36690 */ +/* { dg-do compile } */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ + +int cnt; + +void +bar (int i) +{ + cnt += i; +} + +void +foo (int i, int j) +{ + if (j) + { + bar (i + 1); + goto f1; + } + bar (i + 2); + goto f2; +f1: + if (i > 10) + goto f3; +f2: + if (i > 40) + goto f4; + else + goto f5; +f3: + bar (i); +f4: + bar (i); +f5: + bar (i); +} + +int +main (void) +{ + foo (0, 1); + foo (11, 1); + foo (21, 0); + foo (41, 0); + return 0; +} + +/* { dg-final { scan-assembler "pr36690-3.c:19" } } */ +/* { dg-final { scan-assembler "pr36690-3.c:22" } } */ +/* { dg-final { scan-assembler "pr36690-3.c:25" } } */ +/* { dg-final { scan-assembler "pr36690-3.c:28" } } */ +/* { dg-final { scan-assembler "pr36690-3.c:30" } } */
dwarf2/pr36690-3.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr29609-1.c =================================================================== --- dwarf2/pr29609-1.c (nonexistent) +++ dwarf2/pr29609-1.c (revision 826) @@ -0,0 +1,32 @@ +/* PR debug/29609 */ +/* Verify that breakpoint on the break is hit. */ +/* { dg-do compile } */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ + +void abort (void); + +int +foo (void) +{ + int a, i; + + for (i = 1; i <= 10; i++) + { + if (i < 3) + a = 1; + else + break; + a = 5; + } + return a; +} + +int +main (void) +{ + if (foo () != 5) + abort (); + return 0; +} + +/* { dg-final { scan-assembler "pr29609-1.c:18" } } */
dwarf2/pr29609-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr29609-2.c =================================================================== --- dwarf2/pr29609-2.c (nonexistent) +++ dwarf2/pr29609-2.c (revision 826) @@ -0,0 +1,53 @@ +/* PR debug/29609 */ +/* Verify that breakpoint on both goto failure; stmts is hit. */ +/* { dg-do compile } */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ + +extern void abort (void); +int x; + +int +foo (void) +{ + return 0 ^ x; +} + +int +bar (void) +{ + return 1 ^ x; +} + +int +baz (void) +{ + int c; + + if (!foo ()) + goto failure; + + if (!bar ()) + goto failure; + + return 0; + +failure: + return 1; +} + +int +main (void) +{ + if (baz () != 1) + abort (); + x = 1; + if (baz () != 1) + abort (); + x = 2; + if (baz () != 0) + abort (); + return 0; +} + +/* { dg-final { scan-assembler "pr29609-2.c:27" } } */ +/* { dg-final { scan-assembler "pr29609-2.c:30" } } */
dwarf2/pr29609-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/ipa-cp1.c =================================================================== --- dwarf2/ipa-cp1.c (nonexistent) +++ dwarf2/ipa-cp1.c (revision 826) @@ -0,0 +1,30 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -gdwarf-2 -dA" } */ +void q(int p); +static void +t(int constant_propagated_par) +{ + int local_var = constant_propagated_par + 1; + q(local_var); + q(local_var); + q(local_var); + q(local_var); + q(local_var); + q(local_var); + q(local_var); + q(local_var); + q(local_var); + q(local_var); + q(local_var); +} +main() +{ + t(5); + t(5); + t(5); + t(5); + t(5); + t(5); + t(5); +} +/* { dg-final { scan-assembler "local_var" } } */
dwarf2/ipa-cp1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/fesd-reduced.c =================================================================== --- dwarf2/fesd-reduced.c (nonexistent) +++ dwarf2/fesd-reduced.c (revision 826) @@ -0,0 +1,83 @@ +// { dg-do compile } +// { dg-options "-gdwarf-2 -dA -femit-struct-debug-reduced" } +// { dg-final { scan-assembler "timespec.*DW_AT_name" } } +// { dg-final { scan-assembler "tv_sec.*DW_AT_name" } } +// { dg-final { scan-assembler "tv_nsec.*DW_AT_name" } } +// { dg-final { scan-assembler "itimerspec.*DW_AT_name" } } +// { dg-final { scan-assembler "it_interval.*DW_AT_name" } } +// { dg-final { scan-assembler "it_value.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_ptr_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ptr_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_fld_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_fld_head.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_var_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_inc.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_ref.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_fld.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_decl_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_inc.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_ref.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_fld.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_inc.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_ref.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_fld.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_decl_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_decl_ref_base.*DW_AT_name" } } +# 1 "fesd-reduced.c" +# 1 "" +# 1 "" +# 1 "fesd-reduced.c" + +//#include "time.h" +# 1 "time.h" 1 3 4 +struct timespec + { + long int tv_sec; + long int tv_nsec; + }; + +struct itimerspec + { + struct timespec it_interval; + struct timespec it_value; + }; + +# 6 "fesd-reduced.c" 2 + +struct timespec base_var8; +struct itimerspec *base_var9; + +#include "fesd-reduced.h" + +struct gstruct_head_ordy_defn_var_base base_var1; +struct gstruct_base_ordy_defn_var_base base_var2; + +int base_function() { + return 0 ++ base_var1.field_head_ordy_defn_var_base ++ base_var2.field1_base_ordy_defn_var_base_ptr->field_head_ordy_defn_ptr_base ++ base_var2.field1_base_ordy_defn_var_base_fld.field_head_ordy_defn_fld_base ++ base_var2.field2_base_ordy_defn_var_base_ptr->field_base_ordy_defn_ptr_base ++ base_var2.field2_base_ordy_defn_var_base_fld.field_base_ordy_defn_fld_base +; +}
dwarf2/fesd-reduced.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/fesd-baseonly.c =================================================================== --- dwarf2/fesd-baseonly.c (nonexistent) +++ dwarf2/fesd-baseonly.c (revision 826) @@ -0,0 +1,83 @@ +// { dg-do compile } +// { dg-options "-gdwarf-2 -dA -femit-struct-debug-baseonly" } +// { dg-final { scan-assembler "timespec.*DW_AT_name" } } +// { dg-final { scan-assembler-not "tv_sec.*DW_AT_name" } } +// { dg-final { scan-assembler-not "tv_nsec.*DW_AT_name" } } +// { dg-final { scan-assembler "itimerspec.*DW_AT_name" } } +// { dg-final { scan-assembler-not "it_interval.*DW_AT_name" } } +// { dg-final { scan-assembler-not "it_value.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_ptr_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ptr_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_fld_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_fld_head.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_var_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_inc.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_ref.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_fld.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_decl_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_inc.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_ref.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_fld.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_inc.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_ref.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_fld.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_decl_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_decl_ref_base.*DW_AT_name" } } +# 1 "fesd-baseonly.c" +# 1 "" +# 1 "" +# 1 "fesd-baseonly.c" + +//#include "time.h" +# 1 "time.h" 1 3 4 +struct timespec + { + long int tv_sec; + long int tv_nsec; + }; + +struct itimerspec + { + struct timespec it_interval; + struct timespec it_value; + }; + +# 6 "fesd-baseonly.c" 2 + +struct timespec base_var8; +struct itimerspec *base_var9; + +#include "fesd-baseonly.h" + +struct gstruct_head_ordy_defn_var_base base_var1; +struct gstruct_base_ordy_defn_var_base base_var2; + +int base_function() { + return 0 ++ base_var1.field_head_ordy_defn_var_base ++ base_var2.field1_base_ordy_defn_var_base_ptr->field_head_ordy_defn_ptr_base ++ base_var2.field1_base_ordy_defn_var_base_fld.field_head_ordy_defn_fld_base ++ base_var2.field2_base_ordy_defn_var_base_ptr->field_base_ordy_defn_ptr_base ++ base_var2.field2_base_ordy_defn_var_base_fld.field_base_ordy_defn_fld_base +; +}
dwarf2/fesd-baseonly.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/fesd-sys.c =================================================================== --- dwarf2/fesd-sys.c (nonexistent) +++ dwarf2/fesd-sys.c (revision 826) @@ -0,0 +1,83 @@ +// { dg-do compile } +// { dg-options "-gdwarf-2 -dA -femit-struct-debug-detailed=sys" } +// { dg-final { scan-assembler "timespec.*DW_AT_name" } } +// { dg-final { scan-assembler "tv_sec.*DW_AT_name" } } +// { dg-final { scan-assembler "tv_nsec.*DW_AT_name" } } +// { dg-final { scan-assembler "itimerspec.*DW_AT_name" } } +// { dg-final { scan-assembler "it_interval.*DW_AT_name" } } +// { dg-final { scan-assembler "it_value.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_ptr_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ptr_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_fld_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_fld_head.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_var_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_inc.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_ref.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_fld.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_decl_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_inc.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_ref.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_fld.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_inc.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_ref.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_fld.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_decl_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_decl_ref_base.*DW_AT_name" } } +# 1 "fesd-sys.c" +# 1 "" +# 1 "" +# 1 "fesd-sys.c" + +//#include "time.h" +# 1 "time.h" 1 3 4 +struct timespec + { + long int tv_sec; + long int tv_nsec; + }; + +struct itimerspec + { + struct timespec it_interval; + struct timespec it_value; + }; + +# 6 "fesd-sys.c" 2 + +struct timespec base_var8; +struct itimerspec *base_var9; + +#include "fesd-sys.h" + +struct gstruct_head_ordy_defn_var_base base_var1; +struct gstruct_base_ordy_defn_var_base base_var2; + +int base_function() { + return 0 ++ base_var1.field_head_ordy_defn_var_base ++ base_var2.field1_base_ordy_defn_var_base_ptr->field_head_ordy_defn_ptr_base ++ base_var2.field1_base_ordy_defn_var_base_fld.field_head_ordy_defn_fld_base ++ base_var2.field2_base_ordy_defn_var_base_ptr->field_base_ordy_defn_ptr_base ++ base_var2.field2_base_ordy_defn_var_base_fld.field_base_ordy_defn_fld_base +; +}
dwarf2/fesd-sys.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/short-circuit.c =================================================================== --- dwarf2/short-circuit.c (nonexistent) +++ dwarf2/short-circuit.c (revision 826) @@ -0,0 +1,108 @@ +/* { dg-do compile } */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ + +#define True 1 +#define False 0 + +_Bool F1 (_Bool B1, _Bool B2) +{ + _Bool R; + + if (B1 + && B2) + R = True; + else + R = False; + return R; +} + +_Bool F2 (_Bool B1, _Bool B2) +{ + _Bool R; + + R = B1 + && B2; + return R; +} + +_Bool F3 (_Bool B1, _Bool B2) +{ + _Bool R = False; + + if (B1 + && B2) + R = True; + return R; +} + +_Bool F4 (_Bool B1, _Bool B2) +{ + _Bool R = False; + + if (B1 + || B2) + ; + else + R = True; + return R; +} + +_Bool F5 (_Bool B1, _Bool B2) +{ + _Bool R = False; + + if (!(B1 + && B2)) + R = True; + return R; +} + +_Bool F8 (_Bool B1, _Bool B2, _Bool B3, _Bool B4, _Bool B5, _Bool B6, + _Bool B7, _Bool B8) +{ + _Bool R; + + if ((B1 + || B2) + && B3 + && !(B4 + || B5) + && (B6 + || (B7 + && B8))) + R = True; + else + R = False; + return R; +} + +/* { dg-final { scan-assembler "short-circuit.c:11" } } */ +/* { dg-final { scan-assembler "short-circuit.c:12" } } */ +/* { dg-final { scan-assembler "short-circuit.c:13" } } */ +/* { dg-final { scan-assembler "short-circuit.c:15" } } */ + +/* { dg-final { scan-assembler "short-circuit.c:23" } } */ +/* { dg-final { scan-assembler "short-circuit.c:24" } } */ + +/* { dg-final { scan-assembler "short-circuit.c:32" } } */ +/* { dg-final { scan-assembler "short-circuit.c:33" } } */ +/* { dg-final { scan-assembler "short-circuit.c:34" } } */ + +/* { dg-final { scan-assembler "short-circuit.c:42" } } */ +/* { dg-final { scan-assembler "short-circuit.c:43" } } */ +/* { dg-final { scan-assembler "short-circuit.c:46" } } */ + +/* { dg-final { scan-assembler "short-circuit.c:54" } } */ +/* { dg-final { scan-assembler "short-circuit.c:55" } } */ +/* { dg-final { scan-assembler "short-circuit.c:56" } } */ + +/* { dg-final { scan-assembler "short-circuit.c:65" } } */ +/* { dg-final { scan-assembler "short-circuit.c:66" } } */ +/* { dg-final { scan-assembler "short-circuit.c:67" } } */ +/* { dg-final { scan-assembler "short-circuit.c:68" } } */ +/* { dg-final { scan-assembler "short-circuit.c:69" } } */ +/* { dg-final { scan-assembler "short-circuit.c:70" } } */ +/* { dg-final { scan-assembler "short-circuit.c:71" } } */ +/* { dg-final { scan-assembler "short-circuit.c:72" } } */ +/* { dg-final { scan-assembler "short-circuit.c:73" } } */ +/* { dg-final { scan-assembler "short-circuit.c:75" } } */
dwarf2/short-circuit.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-char1.c =================================================================== --- dwarf2/dwarf-char1.c (nonexistent) +++ dwarf2/dwarf-char1.c (revision 826) @@ -0,0 +1,13 @@ +/* PR debug/7241 */ +/* { dg-do compile } */ +/* { dg-options "-O2 -gdwarf-2 -dA" } */ +/* { dg-skip-if "Unmatchable assembly" { mmix-*-* } { "*" } { "" } } */ +/* { dg-final { scan-assembler "0x\[68\]\[ \t\]+\[#@;!/|\]+\[ \t\]+DW_AT_encoding" } } */ +/* { dg-final { scan-assembler-not "0x\[57\]\[ \t\]+\[#@;!/|\]+\[ \t\]+DW_AT_encoding" } } */ + +char a; +const char b; +signed char c; +volatile signed char d; +unsigned char e; +volatile const unsigned char f;
dwarf2/dwarf-char1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf2.exp =================================================================== --- dwarf2/dwarf2.exp (nonexistent) +++ dwarf2/dwarf2.exp (revision 826) @@ -0,0 +1,43 @@ +# Copyright (C) 2002, 2007 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 +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GCC; see the file COPYING3. If not see +# . + +# GCC testsuite that uses the `dg.exp' driver. + +# Load support procs. +load_lib gcc-dg.exp + +# If a testcase doesn't have special options, use these. +global DEFAULT_CFLAGS +if ![info exists DEFAULT_CFLAGS] then { + set DEFAULT_CFLAGS " -ansi -pedantic-errors -gdwarf-2" +} + +# Initialize `dg'. +dg-init + +# Main loop. +set comp_output [gcc_target_compile \ + "$srcdir/$subdir/../trivial.c" "trivial.S" assembly \ + "additional_flags=-gdwarf-2"] +if { ! [string match "*: target system does not support the * debug format*" \ + $comp_output] } { + remove-build-file "trivial.S" + dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/*.\[cS\] $srcdir/c-c++-common/dwarf2/*.c]] \ + "" $DEFAULT_CFLAGS +} + +# All done. +dg-finish Index: dwarf2/fesd-reduced.h =================================================================== --- dwarf2/fesd-reduced.h (nonexistent) +++ dwarf2/fesd-reduced.h (revision 826) @@ -0,0 +1,19 @@ +#include "fesd.h" + +struct gstruct_base_ordy_decl_not; +struct gstruct_base_ordy_defn_not { int field_base_ordy_defn_not; }; + +struct gstruct_base_ordy_decl_ref_base; +struct gstruct_base_ordy_defn_ref_base { int field_base_ordy_defn_ref_base; }; +struct gstruct_base_ordy_defn_ptr_base { int field_base_ordy_defn_ptr_base; }; +struct gstruct_base_ordy_defn_fld_base { int field_base_ordy_defn_fld_base; }; +struct gstruct_base_ordy_defn_var_base { + struct gstruct_head_ordy_decl_ref_base *field1_base_ordy_defn_var_base_inc; + struct gstruct_head_ordy_defn_ref_base *field1_base_ordy_defn_var_base_ref; + struct gstruct_head_ordy_defn_ptr_base *field1_base_ordy_defn_var_base_ptr; + struct gstruct_head_ordy_defn_fld_base field1_base_ordy_defn_var_base_fld; + struct gstruct_base_ordy_decl_ref_base *field2_base_ordy_defn_var_base_inc; + struct gstruct_base_ordy_defn_ref_base *field2_base_ordy_defn_var_base_ref; + struct gstruct_base_ordy_defn_ptr_base *field2_base_ordy_defn_var_base_ptr; + struct gstruct_base_ordy_defn_fld_base field2_base_ordy_defn_var_base_fld; +};
dwarf2/fesd-reduced.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/fesd-baseonly.h =================================================================== --- dwarf2/fesd-baseonly.h (nonexistent) +++ dwarf2/fesd-baseonly.h (revision 826) @@ -0,0 +1,19 @@ +#include "fesd.h" + +struct gstruct_base_ordy_decl_not; +struct gstruct_base_ordy_defn_not { int field_base_ordy_defn_not; }; + +struct gstruct_base_ordy_decl_ref_base; +struct gstruct_base_ordy_defn_ref_base { int field_base_ordy_defn_ref_base; }; +struct gstruct_base_ordy_defn_ptr_base { int field_base_ordy_defn_ptr_base; }; +struct gstruct_base_ordy_defn_fld_base { int field_base_ordy_defn_fld_base; }; +struct gstruct_base_ordy_defn_var_base { + struct gstruct_head_ordy_decl_ref_base *field1_base_ordy_defn_var_base_inc; + struct gstruct_head_ordy_defn_ref_base *field1_base_ordy_defn_var_base_ref; + struct gstruct_head_ordy_defn_ptr_base *field1_base_ordy_defn_var_base_ptr; + struct gstruct_head_ordy_defn_fld_base field1_base_ordy_defn_var_base_fld; + struct gstruct_base_ordy_decl_ref_base *field2_base_ordy_defn_var_base_inc; + struct gstruct_base_ordy_defn_ref_base *field2_base_ordy_defn_var_base_ref; + struct gstruct_base_ordy_defn_ptr_base *field2_base_ordy_defn_var_base_ptr; + struct gstruct_base_ordy_defn_fld_base field2_base_ordy_defn_var_base_fld; +};
dwarf2/fesd-baseonly.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-merge.c =================================================================== --- dwarf2/dwarf-merge.c (nonexistent) +++ dwarf2/dwarf-merge.c (revision 826) @@ -0,0 +1,10 @@ +/* Verify that mergeable strings are used in the CU DIE. */ +/* { dg-do compile } */ +/* { dg-require-effective-target string_merging } */ +/* { dg-options "-O2 -gdwarf-2 -dA" } */ +/* { dg-final { scan-assembler "DW_AT_producer: \"GNU C" } } */ +/* { dg-final { scan-assembler-not "GNU C\[^\\n\\r\]*DW_AT_producer" } } */ + +void func (void) +{ +}
dwarf2/dwarf-merge.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-char2.c =================================================================== --- dwarf2/dwarf-char2.c (nonexistent) +++ dwarf2/dwarf-char2.c (revision 826) @@ -0,0 +1,13 @@ +/* PR debug/7241 */ +/* { dg-do compile } */ +/* { dg-options "-O2 -gdwarf-2 -dA" } */ +/* { dg-skip-if "Unmatchable assembly" { mmix-*-* } { "*" } { "" } } */ +/* { dg-final { scan-assembler "0x\[68\]\[ \t\]+\[#@;!/|\]+\[ \t\]+DW_AT_encoding" } } */ +/* { dg-final { scan-assembler-not "0x\[57\]\[ \t\]+\[#@;!/|\]+\[ \t\]+DW_AT_encoding" } } */ + +const char a; +char b; +volatile signed char c; +signed char d; +const volatile unsigned char e; +unsigned char f;
dwarf2/dwarf-char2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-char3.c =================================================================== --- dwarf2/dwarf-char3.c (nonexistent) +++ dwarf2/dwarf-char3.c (revision 826) @@ -0,0 +1,8 @@ +/* PR debug/7241 */ +/* { dg-do compile } */ +/* { dg-options "-O2 -gdwarf-2 -dA" } */ +/* { dg-skip-if "Unmatchable assembly" { mmix-*-* } { "*" } { "" } } */ +/* { dg-final { scan-assembler "0x\[68\]\[ \t\]+\[#@;!/|\]+\[ \t\]+DW_AT_encoding" } } */ +/* { dg-final { scan-assembler-not "0x\[57\]\[ \t\]+\[#@;!/|\]+\[ \t\]+DW_AT_encoding" } } */ + +const char *p = "abc";
dwarf2/dwarf-char3.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-file1.c =================================================================== --- dwarf2/dwarf-file1.c (nonexistent) +++ dwarf2/dwarf-file1.c (revision 826) @@ -0,0 +1,9 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -gdwarf-2 -dA" } */ +/* { dg-final { scan-assembler "File Entry:|.file" } } */ +/* Verify that a file entry is output for this file. Only systems that + do not define HAVE_AS_DWARF2_DEBUG_LINE will put out "File Entry:", + but systems that do define HAVE_AS_DWARF2_DEBUG_LINE will put out a + ".file" so we check for either. */ + +int bar = 3;
dwarf2/dwarf-file1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/fesd-sys.h =================================================================== --- dwarf2/fesd-sys.h (nonexistent) +++ dwarf2/fesd-sys.h (revision 826) @@ -0,0 +1,19 @@ +#include "fesd.h" + +struct gstruct_base_ordy_decl_not; +struct gstruct_base_ordy_defn_not { int field_base_ordy_defn_not; }; + +struct gstruct_base_ordy_decl_ref_base; +struct gstruct_base_ordy_defn_ref_base { int field_base_ordy_defn_ref_base; }; +struct gstruct_base_ordy_defn_ptr_base { int field_base_ordy_defn_ptr_base; }; +struct gstruct_base_ordy_defn_fld_base { int field_base_ordy_defn_fld_base; }; +struct gstruct_base_ordy_defn_var_base { + struct gstruct_head_ordy_decl_ref_base *field1_base_ordy_defn_var_base_inc; + struct gstruct_head_ordy_defn_ref_base *field1_base_ordy_defn_var_base_ref; + struct gstruct_head_ordy_defn_ptr_base *field1_base_ordy_defn_var_base_ptr; + struct gstruct_head_ordy_defn_fld_base field1_base_ordy_defn_var_base_fld; + struct gstruct_base_ordy_decl_ref_base *field2_base_ordy_defn_var_base_inc; + struct gstruct_base_ordy_defn_ref_base *field2_base_ordy_defn_var_base_ref; + struct gstruct_base_ordy_defn_ptr_base *field2_base_ordy_defn_var_base_ptr; + struct gstruct_base_ordy_defn_fld_base field2_base_ordy_defn_var_base_fld; +};
dwarf2/fesd-sys.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/fesd-any.c =================================================================== --- dwarf2/fesd-any.c (nonexistent) +++ dwarf2/fesd-any.c (revision 826) @@ -0,0 +1,84 @@ +// { dg-do compile } +// { dg-options "-gdwarf-2 -dA -femit-struct-debug-detailed=any" } +// { dg-final { scan-assembler "timespec.*DW_AT_name" } } +// { dg-final { scan-assembler "tv_sec.*DW_AT_name" } } +// { dg-final { scan-assembler "tv_nsec.*DW_AT_name" } } +// { dg-final { scan-assembler "itimerspec.*DW_AT_name" } } +// { dg-final { scan-assembler "it_interval.*DW_AT_name" } } +// { dg-final { scan-assembler "it_value.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler "field_head_ordy_defn_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_ptr_head.*DW_AT_name" } } +// { dg-final { scan-assembler "field_head_ordy_defn_ptr_head.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_fld_head.*DW_AT_name" } } +// { dg-final { scan-assembler "field_head_ordy_defn_fld_head.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_var_head.*DW_AT_name" } } +// { dg-final { scan-assembler "field_head_ordy_defn_var_head_inc.*DW_AT_name" } } +// { dg-final { scan-assembler "field_head_ordy_defn_var_head_ref.*DW_AT_name" } } +// { dg-final { scan-assembler "field_head_ordy_defn_var_head_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler "field_head_ordy_defn_var_head_fld.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_decl_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_head_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_head_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_head_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_head_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field_base_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_inc.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_ref.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler "field1_base_ordy_defn_var_base_fld.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_inc.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_ref.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler "field2_base_ordy_defn_var_base_fld.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_decl_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_decl_ref_base.*DW_AT_name" } } +# 1 "fesd-any.c" +# 1 "" +# 1 "" +# 1 "fesd-any.c" + +//#include "time.h" +# 1 "time.h" 1 3 4 +struct timespec + { + long int tv_sec; + long int tv_nsec; + }; + +struct itimerspec + { + struct timespec it_interval; + struct timespec it_value; + }; + +# 6 "fesd-any.c" 2 + +struct timespec base_var8; +struct itimerspec *base_var9; + +#include "fesd-any.h" + +struct gstruct_head_ordy_defn_var_base base_var1; +struct gstruct_base_ordy_defn_var_base base_var2; + +int base_function() { + return 0 ++ base_var1.field_head_ordy_defn_var_base ++ base_var2.field1_base_ordy_defn_var_base_ptr->field_head_ordy_defn_ptr_base ++ base_var2.field1_base_ordy_defn_var_base_fld.field_head_ordy_defn_fld_base ++ base_var2.field2_base_ordy_defn_var_base_ptr->field_base_ordy_defn_ptr_base ++ base_var2.field2_base_ordy_defn_var_base_fld.field_base_ordy_defn_fld_base +; +} +
dwarf2/fesd-any.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-uninit.c =================================================================== --- dwarf2/dwarf-uninit.c (nonexistent) +++ dwarf2/dwarf-uninit.c (revision 826) @@ -0,0 +1,10 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -gdwarf-2 -dA" } */ +/* { dg-final { scan-assembler "DW_TAG_variable" } } */ +/* PR debug/21828 */ + +static int i; +int main() { + i += 3; + return 0; +}
dwarf2/dwarf-uninit.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/static1.c =================================================================== --- dwarf2/static1.c (nonexistent) +++ dwarf2/static1.c (revision 826) @@ -0,0 +1,8 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -gdwarf-2" } */ +void +main(void) +{ + static int unused_local_var; +} +/* { dg-final { scan-assembler "unused_local_var" } } */
dwarf2/static1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/fesd-any.h =================================================================== --- dwarf2/fesd-any.h (nonexistent) +++ dwarf2/fesd-any.h (revision 826) @@ -0,0 +1,19 @@ +#include "fesd.h" + +struct gstruct_base_ordy_decl_not; +struct gstruct_base_ordy_defn_not { int field_base_ordy_defn_not; }; + +struct gstruct_base_ordy_decl_ref_base; +struct gstruct_base_ordy_defn_ref_base { int field_base_ordy_defn_ref_base; }; +struct gstruct_base_ordy_defn_ptr_base { int field_base_ordy_defn_ptr_base; }; +struct gstruct_base_ordy_defn_fld_base { int field_base_ordy_defn_fld_base; }; +struct gstruct_base_ordy_defn_var_base { + struct gstruct_head_ordy_decl_ref_base *field1_base_ordy_defn_var_base_inc; + struct gstruct_head_ordy_defn_ref_base *field1_base_ordy_defn_var_base_ref; + struct gstruct_head_ordy_defn_ptr_base *field1_base_ordy_defn_var_base_ptr; + struct gstruct_head_ordy_defn_fld_base field1_base_ordy_defn_var_base_fld; + struct gstruct_base_ordy_decl_ref_base *field2_base_ordy_defn_var_base_inc; + struct gstruct_base_ordy_defn_ref_base *field2_base_ordy_defn_var_base_ref; + struct gstruct_base_ordy_defn_ptr_base *field2_base_ordy_defn_var_base_ptr; + struct gstruct_base_ordy_defn_fld_base field2_base_ordy_defn_var_base_fld; +};
dwarf2/fesd-any.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/fesd-none.c =================================================================== --- dwarf2/fesd-none.c (nonexistent) +++ dwarf2/fesd-none.c (revision 826) @@ -0,0 +1,84 @@ +// { dg-do compile } +// { dg-options "-gdwarf-2 -dA -femit-struct-debug-detailed=none" } +// { dg-final { scan-assembler "timespec.*DW_AT_name" } } +// { dg-final { scan-assembler-not "tv_sec.*DW_AT_name" } } +// { dg-final { scan-assembler-not "tv_nsec.*DW_AT_name" } } +// { dg-final { scan-assembler "itimerspec.*DW_AT_name" } } +// { dg-final { scan-assembler-not "it_interval.*DW_AT_name" } } +// { dg-final { scan-assembler-not "it_value.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_ptr_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ptr_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_fld_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_fld_head.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_var_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_inc.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_ref.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_head_fld.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_decl_ref_head.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_head_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_head_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_base_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_base_ordy_defn_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_base_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_base_ordy_defn_ptr_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_base_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field_base_ordy_defn_fld_base.*DW_AT_name" } } +// { dg-final { scan-assembler "gstruct_base_ordy_defn_var_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field1_base_ordy_defn_var_base_inc.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field1_base_ordy_defn_var_base_ref.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field1_base_ordy_defn_var_base_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field1_base_ordy_defn_var_base_fld.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field2_base_ordy_defn_var_base_inc.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field2_base_ordy_defn_var_base_ref.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field2_base_ordy_defn_var_base_ptr.*DW_AT_name" } } +// { dg-final { scan-assembler-not "field2_base_ordy_defn_var_base_fld.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_head_ordy_decl_ref_base.*DW_AT_name" } } +// { dg-final { scan-assembler-not "gstruct_base_ordy_decl_ref_base.*DW_AT_name" } } +# 1 "fesd-none.c" +# 1 "" +# 1 "" +# 1 "fesd-none.c" + +//#include "time.h" +# 1 "time.h" 1 3 4 +struct timespec + { + long int tv_sec; + long int tv_nsec; + }; + +struct itimerspec + { + struct timespec it_interval; + struct timespec it_value; + }; + +# 6 "fesd-none.c" 2 + +struct timespec base_var8; +struct itimerspec *base_var9; + +#include "fesd-none.h" + +struct gstruct_head_ordy_defn_var_base base_var1; +struct gstruct_base_ordy_defn_var_base base_var2; + +int base_function() { + return 0 ++ base_var1.field_head_ordy_defn_var_base ++ base_var2.field1_base_ordy_defn_var_base_ptr->field_head_ordy_defn_ptr_base ++ base_var2.field1_base_ordy_defn_var_base_fld.field_head_ordy_defn_fld_base ++ base_var2.field2_base_ordy_defn_var_base_ptr->field_base_ordy_defn_ptr_base ++ base_var2.field2_base_ordy_defn_var_base_fld.field_base_ordy_defn_fld_base +; +} +
dwarf2/fesd-none.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/fesd-none.h =================================================================== --- dwarf2/fesd-none.h (nonexistent) +++ dwarf2/fesd-none.h (revision 826) @@ -0,0 +1,19 @@ +#include "fesd.h" + +struct gstruct_base_ordy_decl_not; +struct gstruct_base_ordy_defn_not { int field_base_ordy_defn_not; }; + +struct gstruct_base_ordy_decl_ref_base; +struct gstruct_base_ordy_defn_ref_base { int field_base_ordy_defn_ref_base; }; +struct gstruct_base_ordy_defn_ptr_base { int field_base_ordy_defn_ptr_base; }; +struct gstruct_base_ordy_defn_fld_base { int field_base_ordy_defn_fld_base; }; +struct gstruct_base_ordy_defn_var_base { + struct gstruct_head_ordy_decl_ref_base *field1_base_ordy_defn_var_base_inc; + struct gstruct_head_ordy_defn_ref_base *field1_base_ordy_defn_var_base_ref; + struct gstruct_head_ordy_defn_ptr_base *field1_base_ordy_defn_var_base_ptr; + struct gstruct_head_ordy_defn_fld_base field1_base_ordy_defn_var_base_fld; + struct gstruct_base_ordy_decl_ref_base *field2_base_ordy_defn_var_base_inc; + struct gstruct_base_ordy_defn_ref_base *field2_base_ordy_defn_var_base_ref; + struct gstruct_base_ordy_defn_ptr_base *field2_base_ordy_defn_var_base_ptr; + struct gstruct_base_ordy_defn_fld_base field2_base_ordy_defn_var_base_fld; +};
dwarf2/fesd-none.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/c99-typedef1.c =================================================================== --- dwarf2/c99-typedef1.c (nonexistent) +++ dwarf2/c99-typedef1.c (revision 826) @@ -0,0 +1,9 @@ +// { dg-options "-std=iso9899:1999 -gdwarf-2" } + +void f() { + int n = 3; + typedef int T[n++]; + + T t; + t[0] = 7; +}
dwarf2/c99-typedef1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-die1.c =================================================================== --- dwarf2/dwarf-die1.c (nonexistent) +++ dwarf2/dwarf-die1.c (revision 826) @@ -0,0 +1,8 @@ +/* Verify that inline function never actually inlined has no abstract DIE. */ +/* { dg-do compile } */ +/* { dg-options "-O2 -gdwarf-2 -dA" } */ +/* { dg-final { scan-assembler-not "DW_AT_inline" } } */ +inline int t() +{ +} +int (*q)()=t;
dwarf2/dwarf-die1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf2-macro.c =================================================================== --- dwarf2/dwarf2-macro.c (nonexistent) +++ dwarf2/dwarf2-macro.c (revision 826) @@ -0,0 +1,13 @@ +/* Test to make sure the mcaro info includes a start file command for the main source */ +/* { dg-do compile } */ +/* { dg-options "-g3 -gdwarf-2 -dA -fverbose-asm" } */ +/* { dg-final { scan-assembler "Start new file" } } */ + +#define ADD(x) (M + x) + +int main (void) +{ +#define N 28 +#define M 42 + return ADD(N); +}
dwarf2/dwarf2-macro.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/const-1.c =================================================================== --- dwarf2/const-1.c (nonexistent) +++ dwarf2/const-1.c (revision 826) @@ -0,0 +1,7 @@ +/* { dg-do compile } */ +/* { dg-options "-O -gdwarf-2 -dA -gno-strict-dwarf -fno-merge-debug-strings" } */ +/* { dg-require-visibility "" } */ +/* { dg-final { scan-assembler "DW_AT_location\[^\\r\\n\]*\[\\r\\n\]*\[^\\r\\n\]*DW_OP_addr\[^\\r\\n\]*\[\\r\\n\]*\[^\\r\\n\]*fnx\[^\\r\\n\]*\[\\r\\n\]*\[^\\r\\n\]*DW_OP_stack_value" } } */ + +extern void fnx() __attribute__((visibility("hidden"))); +static void (*f)() = fnx;
dwarf2/const-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-die2.c =================================================================== --- dwarf2/dwarf-die2.c (nonexistent) +++ dwarf2/dwarf-die2.c (revision 826) @@ -0,0 +1,7 @@ +/* Verify that inline function never actually emit has no DIE. */ +/* { dg-do compile } */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ +/* { dg-final { scan-assembler-not "CIE Version" } } */ +static inline int t() +{ +}
dwarf2/dwarf-die2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr43237.c =================================================================== --- dwarf2/pr43237.c (nonexistent) +++ dwarf2/pr43237.c (revision 826) @@ -0,0 +1,31 @@ +/* PR debug/43237 */ +/* { dg-do compile } */ +/* { dg-options "-g -O2 -dA -fno-merge-debug-strings" } */ + +struct S +{ + int *a; + int b; + int **c; + int d; +}; + +void foo (struct S *); +void bar (struct S *); + +int +baz (void) +{ + struct S s; + foo (&s); + { + int a[s.b]; + int *c[s.d]; + s.a = a; + s.c = c; + bar (&s); + } + return 0; +} + +/* { dg-final { scan-assembler-not "LLST\[^\\r\\n\]*DW_AT_upper_bound" } } */
dwarf2/pr43237.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/const-2.c =================================================================== --- dwarf2/const-2.c (nonexistent) +++ dwarf2/const-2.c (revision 826) @@ -0,0 +1,6 @@ +/* { dg-do compile { target powerpc_altivec_ok } } */ +/* { dg-options "-O -gdwarf-2 -dA -maltivec" } */ +/* { dg-final { scan-assembler "DW_AT_const_value" } } */ + +typedef float FloatVect __attribute__((__vector_size__(16))); +static FloatVect Foo = { 250000000.0, 0.0, 0.0, 0.0 };
dwarf2/const-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-die3.c =================================================================== --- dwarf2/dwarf-die3.c (nonexistent) +++ dwarf2/dwarf-die3.c (revision 826) @@ -0,0 +1,11 @@ +/* Verify that extern inline function never actually inlined has no abstract DIE. */ +/* { dg-do compile } */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ +/* { dg-final { scan-assembler-not "DW_AT_inline" } } */ +extern inline int t() +{ +} +int (*q)()=t; +int t() +{ +}
dwarf2/dwarf-die3.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-die5.c =================================================================== --- dwarf2/dwarf-die5.c (nonexistent) +++ dwarf2/dwarf-die5.c (revision 826) @@ -0,0 +1,12 @@ +/* Inlined inline function must have abstract DIE */ +/* { dg-do compile } */ +/* { dg-options "-O2 -gdwarf-2 -dA -fpreprocessed" } */ +/* { dg-final { scan-assembler "3.*DW_AT_inline" } } */ +#1 "test.h" +inline int t() +{ +} +int q() +{ + t(); +}
dwarf2/dwarf-die5.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-die6.c =================================================================== --- dwarf2/dwarf-die6.c (nonexistent) +++ dwarf2/dwarf-die6.c (revision 826) @@ -0,0 +1,12 @@ +/* not inline inline function must not have abstract DIE */ +/* { dg-do compile } */ +/* { dg-options "-O2 -fno-inline -gdwarf-2 -dA -fpreprocessed" } */ +/* { dg-final { scan-assembler-not "DW_AT_inline" } } */ +#1 "test.h" +inline int t() +{ +} +int q() +{ + t(); +}
dwarf2/dwarf-die6.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr37616.c =================================================================== --- dwarf2/pr37616.c (nonexistent) +++ dwarf2/pr37616.c (revision 826) @@ -0,0 +1,41 @@ +/* PR debug/37616 */ +/* Test that one can put breakpoints onto continue, exitlab and break + and actually see program reaching those breakpoints. */ +/* { dg-do compile } */ +/* { dg-options "-O0 -gdwarf-2 -dA" } */ + +extern void abort (void); + +int +foo (int parm) +{ + int varj, varm; + + for (varj = 0; varj < 10; varj++) + { + if (varj == 5) + continue; + if (varj == 7 && !parm) + goto exitlab; + if (varj == 9) + break; + varm = varj; + } + +exitlab: + return varm; +} + +int +main (void) +{ + if (foo (0) != 6) + abort (); + if (foo (1) != 8) + abort (); + return 0; +} + +/* { dg-final { scan-assembler "pr37616.c:17" } } */ +/* { dg-final { scan-assembler "pr37616.c:19" } } */ +/* { dg-final { scan-assembler "pr37616.c:21" } } */
dwarf2/pr37616.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/dwarf-die7.c =================================================================== --- dwarf2/dwarf-die7.c (nonexistent) +++ dwarf2/dwarf-die7.c (revision 826) @@ -0,0 +1,14 @@ +/* Inlined non-inline function must have abstract DIE */ +/* { dg-do compile } */ +/* { dg-options "-O2 -gdwarf-2 -dA -fpreprocessed" } */ +/* { dg-final { scan-assembler "1.*DW_AT_inline" } } */ +#1 "test.h" +void f(void); +static int t() +{ + f(); +} +int q() +{ + t(); +}
dwarf2/dwarf-die7.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2/pr41695.c =================================================================== --- dwarf2/pr41695.c (nonexistent) +++ dwarf2/pr41695.c (revision 826) @@ -0,0 +1,18 @@ +/* PR debug/41695 */ +/* { dg-do compile } */ +/* { dg-options "-g -O2 -dA -fno-merge-debug-strings" } */ + +int bar (int); + +void +foo (void) +{ + int b = 0; + b = bar (b); + b = bar (b); + b = bar (b); + b = bar (b); + bar (b); +} + +/* { dg-final { scan-assembler-not "LVL(\[0-9\]+)-\[^1\]\[^\\r\\n\]*Location list begin address\[^\\r\\n\]*\[\\r\\n\]+\[^\\r\\n\]*LVL\\1-1-" } } */
dwarf2/pr41695.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr29558.c =================================================================== --- pr29558.c (nonexistent) +++ pr29558.c (revision 826) @@ -0,0 +1,30 @@ +/* { dg-do compile } */ + +void stpi_unpack_16_1(int length, unsigned char *out, unsigned char bit) +{ + unsigned char tempin; + unsigned char temp[16]; + for (bit = 128; length > 0; length--) { + if (tempin & 128) + temp[0] |= bit; + else + { + *out++ = temp[1]; + *out++ = temp[2]; + *out++ = temp[3]; + *out++ = temp[4]; + *out++ = temp[5]; + *out++ = temp[6]; + *out++ = temp[7]; + *out++ = temp[9]; + *out++ = temp[10]; + *out++ = temp[11]; + *out++ = temp[12]; + *out++ = temp[13]; + *out++ = temp[14]; + *out++ = temp[15]; + __builtin_memset (temp, 0, 16); + } + } +} +
pr29558.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: debug.exp =================================================================== --- debug.exp (nonexistent) +++ debug.exp (revision 826) @@ -0,0 +1,31 @@ +# Copyright (C) 2002, 2007 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 +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GCC; see the file COPYING3. If not see +# . + +# GCC testsuite that uses the `dg.exp' driver. + +# Load support procs. +load_lib gcc-dg.exp + +# Initialize `dg'. +dg-init + +# Main loop. + +gcc-dg-debug-runtest gcc_target_compile trivial.c [list -O -O3] \ + [lsort [glob -nocomplain $srcdir/$subdir/*.\[cS\]]] + +# All done. +dg-finish Index: enum-1.c =================================================================== --- enum-1.c (nonexistent) +++ enum-1.c (revision 826) @@ -0,0 +1,16 @@ +/* Verify that used enums are output. */ +/* { dg-do compile } */ +/* { dg-final { scan-assembler "JTI_MAX" } } */ + +int var; + +enum java_tree_index +{ + JTI_MAX +}; + +void function (void) +{ + var = JTI_MAX; +} +
enum-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr32610.c =================================================================== --- pr32610.c (nonexistent) +++ pr32610.c (revision 826) @@ -0,0 +1,14 @@ +/* PR debug/32610 */ +/* { dg-do compile } */ + +inline void +foo (int x) +{ + double (*arr)[x]; +} + +void +bar (void) +{ + foo (1); +}
pr32610.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr41343-1.c =================================================================== --- pr41343-1.c (nonexistent) +++ pr41343-1.c (revision 826) @@ -0,0 +1,20 @@ +/* { dg-do compile } */ + +#define X(new,old) int i ## new = i ## old + i ## old; +#define Y(pfx) X(pfx ## 1, pfx) \ + X(pfx ## 2, pfx ## 1) \ + X(pfx ## 3, pfx ## 2) \ + X(pfx ## 4, pfx ## 3) \ + X(pfx ## 5, pfx ## 4) \ + X(pfx ## 6, pfx ## 5) \ + X(pfx ## 7, pfx ## 6) \ + X(pfx ## 8, pfx ## 7) \ + X(pfx ## 9, pfx ## 8) + +void foo (int i1) +{ + Y(1) + Y(11) + Y(111) + asm ("" : : "X" (i1)); +}
pr41343-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr41264-1.c =================================================================== --- pr41264-1.c (nonexistent) +++ pr41264-1.c (revision 826) @@ -0,0 +1,40 @@ +/* { dg-do compile } */ + +#if (__SIZEOF_INT__ <= 2) +typedef unsigned long hashval_t; +#else +typedef unsigned int hashval_t; +#endif +static hashval_t __attribute__((always_inline)) +iterative_hash_host_wide_int (long val, hashval_t val2) +{ + hashval_t a = (hashval_t) val; + int zero = 0; + hashval_t b = (hashval_t) (val >> (sizeof (hashval_t) * 8 + zero)); + + a -= b; a -= val2; a ^= (val2>>13); + b -= val2; b -= a; b ^= (a<< 8); + val2 -= a; val2 -= b; val2 ^= ((b&0xffffffff)>>13); + a -= b; a -= val2; a ^= ((val2&0xffffffff)>>12); + b -= val2; b -= a; b = (b ^ (a<<16)) & 0xffffffff; + val2 -= a; val2 -= b; val2 = (val2 ^ (b>> 5)) & 0xffffffff; + a -= b; a -= val2; a = (a ^ (val2>> 3)) & 0xffffffff; + b -= val2; b -= a; b = (b ^ (a<<10)) & 0xffffffff; + val2 -= a; val2 -= b; val2 = (val2 ^ (b>>15)) & 0xffffffff; + return val2; +} + +hashval_t +bla (int nunits, int mode) +{ + hashval_t hashcode = 0; + + + hashcode = iterative_hash_host_wide_int (14, hashcode); + hashcode = iterative_hash_host_wide_int (nunits, hashcode); + hashcode = iterative_hash_host_wide_int (mode, hashcode); + if (nunits) + return 0; + else + return hashcode; +}
pr41264-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: crash1.c =================================================================== --- crash1.c (nonexistent) +++ crash1.c (revision 826) @@ -0,0 +1,8 @@ +/* PR c/14492 */ +/* { dg-options "" } */ + +int main() { + double d = 1.0; + char x[(int) d]; + return 0; +}
crash1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: debug-1.c =================================================================== --- debug-1.c (nonexistent) +++ debug-1.c (revision 826) @@ -0,0 +1,34 @@ +/* Verify that the scheduler does not discard the lexical block. */ +/* { dg-do compile } */ +/* { dg-options "-dA" } */ +/* On MIPS targets that support conditional moves, the optimal + implementation of this function is: + + l[wd] tmp,p + li $2,2 + jr $31 + movz $2,$0,tmp + + After if-conversion, we have a conditional move into a pseudo P + followed a copy of P into the return register ($2). P is associated + with xyzzy, so if-conversion is behaving as expected, and has not lost + the variable association. The destination of the second instruction + is associated with the function return value. Combine then combines + these two instructions, removing the last use of P and xyzzy. + + Everything is behaving as expected in this scenario, so we avoid + using conditional moves for this test. */ +/* { dg-options "-dA -fno-if-conversion" { target mips*-*-* } } */ +/* { dg-final { scan-assembler "xyzzy" } } */ + +long p; + +long foo(void) +{ + { + long xyzzy = 0; + if (p) + xyzzy = 2; + return xyzzy; + } +}
debug-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: debug-2.c =================================================================== --- debug-2.c (nonexistent) +++ debug-2.c (revision 826) @@ -0,0 +1,24 @@ +/* Verify that the scheduler does not discard the lexical block. */ +/* { dg-do compile } */ +/* { dg-options "-dA" } */ +/* See the comment in debug-1.c. */ +/* { dg-options "-dA -fno-if-conversion" { target mips*-*-* } } */ +/* { dg-final { scan-assembler "xyzzy" } } */ + +long p; + +long foo(void) +{ + if (1) + { + long xyzzy = 0; + if (p) + xyzzy = 2; + return xyzzy; + } + else + { + int x = 0; + return x; + } +}
debug-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20020220-1.c =================================================================== --- 20020220-1.c (nonexistent) +++ 20020220-1.c (revision 826) @@ -0,0 +1,31 @@ +/* PR debug/4461 + This testcase failed to link in Dwarf-2 because + constant -4.0 in constant pool was never referenced by anything + but Dwarf-2 location descriptor. */ +/* { dg-do run } */ + +void __attribute__((noinline)) +foo (const char *x __attribute__((unused)), + __complex__ long double y __attribute__((unused)), + __complex__ long double z __attribute__((unused))) +{ +} + +void +bar (void) +{ + foo ("", + __builtin_conjl (({ __complex__ long double r; + __real__ r = 3.0; + __imag__ r = -4.0; + r; })), + ({ __complex__ long double s; + __real__ s = 3.0; + __imag__ s = 4.0; + s; })); +} + +int main (void) +{ + return 0; +}
20020220-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: debug-3.c =================================================================== --- debug-3.c (nonexistent) +++ debug-3.c (revision 826) @@ -0,0 +1,35 @@ +/* This testcase failed, because scope containing baz was deleted + (spanned 0 basic blocks) and DWARF-2 couldn't find baz origin. */ +/* { dg-do compile } */ +/* { dg-require-effective-target trampolines } */ + +struct A { char *a, *b, *c, *d; }; + +static int +bar (struct A *x) +{ + return x->c - x->b; +} + +void fnptr (void (*fn) (void)); + +void +foo (void) +{ + struct A e; + + { + void baz (void) + { + bar (&e); + } + fnptr (baz); + } + { + struct A *f; + + f = &e; + if (f->c - f->a > f->d - f->a) + f->c = f->d; + } +}
debug-3.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: debug-4.c =================================================================== --- debug-4.c (nonexistent) +++ debug-4.c (revision 826) @@ -0,0 +1,26 @@ +/* This testcase failed, because scope containing baz was not emitted + (doesn't contain any instructions) and DWARF-2 couldn't find baz origin. */ +/* { dg-do compile } */ + +struct A { char *a, *b, *c, *d; }; + +static int +bar (struct A *x) +{ + return x->c - x->b; +} + +void +foo (void) +{ + struct A e; + + { + int baz (void) + { + return bar (&e); + } + } + if (e.c - e.a > e.d - e.a) + e.c = e.d; +}
debug-4.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20000503-1.c =================================================================== --- 20000503-1.c (nonexistent) +++ 20000503-1.c (revision 826) @@ -0,0 +1,16 @@ +/* { dg-do compile } */ + +/* Distilled from GCC's stmt.c. Caused abort in dwarf-1 code. */ + +static void +expand_nl_goto_receiver () +{ +{ +static struct elims {int from, to;} elim_regs[] = {{ 16, 7}, { 16, 6}, { 20, 7},{ 20, 6}}; + int i; + + for (i = 0; i < sizeof elim_regs / sizeof elim_regs[0]; i++) + if (elim_regs[i].from == 16 && elim_regs[i].to == 6) + break; + } +}
20000503-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20020104-2.c =================================================================== --- 20020104-2.c (nonexistent) +++ 20020104-2.c (revision 826) @@ -0,0 +1,9 @@ +/* This testcase used to fail because outlining_inline_function was called + too early, before rtl was generated. */ +/* { dg-do compile } */ + +int foo (const int *x) +{ + char a[*x]; + return 0; +}
20020104-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr36690-1.c =================================================================== --- pr36690-1.c (nonexistent) +++ pr36690-1.c (revision 826) @@ -0,0 +1,23 @@ +/* PR debug/36690 */ +/* Verify that break func is hit. + This version of the test just checks that it can be compiled, linked + and executed, further testing is done in corresponding gcc.dg/dwarf2/ + test and hopefully in gdb testsuite. */ +/* { dg-do run } */ +/* { dg-options "-O0 -g -dA" } */ + +int i; + +void +func (void) +{ + while (i == 1) + i = 0; +} + +int +main (void) +{ + func (); + return 0; +}
pr36690-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: vta-1.c =================================================================== --- vta-1.c (nonexistent) +++ vta-1.c (revision 826) @@ -0,0 +1,34 @@ +/* https://bugzilla.redhat.com/show_bug.cgi?id=521991#c5 + + Distilled from Linux XFS source code. foo, inlined into bar, ends + up with debug stmts referencing the addressable variable b. + Optimization made it non-addressable, and then completely optimized + away, before we got a chance to rename (and discard) the occurrence + in the debug stmt. When we did, we crashed, attempting to rename + an unreference variable. */ + +/* { dg-do compile } */ + +static inline int +foo (void *x, unsigned y) +{ + unsigned z = *(unsigned long *) x % y; + *(unsigned long *) x = *(unsigned long *) x / y; + return z; +} + +struct S +{ + unsigned t; +}; + +void +bar (struct S *x, int *y) +{ + int a = 0; + unsigned long b = x->t; + foo (&b, x->t); + for (;; a++) + if (b) + *y = 1; +}
vta-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr36690-2.c =================================================================== --- pr36690-2.c (nonexistent) +++ pr36690-2.c (revision 826) @@ -0,0 +1,40 @@ +/* PR debug/36690 */ +/* Verify that breakpoint can be put on goto f1, it is hit and + varz at that spot is defined and contains 5. Nowhere else + in the function should be varz in the scope. + This version of the test just checks that it can be compiled, linked + and executed, further testing is done in corresponding gcc.dg/dwarf2/ + test and hopefully in gdb testsuite. */ +/* { dg-do run } */ +/* { dg-options "-O0 -g -dA" } */ + +int cnt; + +void +bar (int i) +{ + cnt += i; +} + +void +foo (int i) +{ + if (!i) + bar (0); + else + { + static int varz = 5; + goto f1; + } + bar (1); +f1: + bar (2); +} + +int +main (void) +{ + foo (0); + foo (1); + return 0; +}
pr36690-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: debug-5.c =================================================================== --- debug-5.c (nonexistent) +++ debug-5.c (revision 826) @@ -0,0 +1,47 @@ +/* This testcase failed, because scope containing baz was deleted + (spanned 0 basic blocks) and DWARF-2 couldn't find baz origin. */ +/* { dg-do compile } */ +/* { dg-require-effective-target trampolines } */ + +extern void abort (void); + +struct A { char *a, *b, *c, *d; }; + +static int +bar (struct A *x) +{ + return x->c - x->b; +} + +static int +bar2 (struct A *x) +{ + int a = x->c - x->b; + x->c += 26; + return a; +} + +void fnptr (void (*fn) (void)); + +void +foo (void) +{ + struct A e; + + if (bar2 (&e) < 0) + abort (); + { + void baz (void) + { + bar (&e); + } + fnptr (baz); + } + { + struct A *f; + + f = &e; + if (f->c - f->a > f->d - f->a) + f->c = f->d; + } +}
debug-5.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: vta-2.c =================================================================== --- vta-2.c (nonexistent) +++ vta-2.c (revision 826) @@ -0,0 +1,21 @@ +/* { dg-do compile } */ + +static int +bar (void *a, unsigned int b, int n) +{ + int c = *(unsigned long *) a % b; + *(unsigned long *) a = (int) (*(unsigned long *) a) / b; + return c; +} + +int +foo (unsigned long x, int *y, int z) +{ + int level; + for (level = 0; level < *y; level++) + { + bar (&x, z, sizeof (x)); + if (x) + return *y - 1; + } +}
vta-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr36690-3.c =================================================================== --- pr36690-3.c (nonexistent) +++ pr36690-3.c (revision 826) @@ -0,0 +1,47 @@ +/* PR debug/36690 */ +/* { dg-do run } */ +/* { dg-options "-O0 -g -dA" } */ + +int cnt; + +void +bar (int i) +{ + cnt += i; +} + +void +foo (int i, int j) +{ + if (j) + { + bar (i + 1); + goto f1; + } + bar (i + 2); + goto f2; +f1: + if (i > 10) + goto f3; +f2: + if (i > 40) + goto f4; + else + goto f5; +f3: + bar (i); +f4: + bar (i); +f5: + bar (i); +} + +int +main (void) +{ + foo (0, 1); + foo (11, 1); + foo (21, 0); + foo (41, 0); + return 0; +}
pr36690-3.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr29609-1.c =================================================================== --- pr29609-1.c (nonexistent) +++ pr29609-1.c (revision 826) @@ -0,0 +1,33 @@ +/* PR debug/29609 */ +/* Verify that breakpoint on the break is hit. + This version of the test just checks that it can be compiled, linked + and executed, further testing is done in corresponding gcc.dg/dwarf2/ + test and hopefully in gdb testsuite. */ +/* { dg-do run } */ +/* { dg-options "-O0 -g -dA" } */ + +extern void abort (void); + +int +foo (void) +{ + int a, i; + + for (i = 1; i <= 10; i++) + { + if (i < 3) + a = 1; + else + break; + a = 5; + } + return a; +} + +int +main (void) +{ + if (foo () != 5) + abort (); + return 0; +}
pr29609-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20031231-1.c =================================================================== --- 20031231-1.c (nonexistent) +++ 20031231-1.c (revision 826) @@ -0,0 +1,21 @@ +/* { dg-do compile } */ + +/* We used to fail because GCC didn't expect always inline to be inlined at + -O0. */ +typedef union tree_node *tree; +typedef struct c_pretty_print_info c_pretty_printer; + + +void pp_c_string_literal (c_pretty_printer *, tree); + + +static __inline__ __attribute__((always_inline)) void +pp_c_shift_expression (c_pretty_printer *pp, tree e) +{ +} + +static void +pp_c_relational_expression (c_pretty_printer *pp, tree e) +{ + pp_c_shift_expression (pp, e); +}
20031231-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20020224-1.c =================================================================== --- 20020224-1.c (nonexistent) +++ 20020224-1.c (revision 826) @@ -0,0 +1,71 @@ +/* { dg-options "-g3 -O" } */ +/* { dg-do compile } */ + +/* Here's the deal: f4 is inlined into main, f3 is inlined into f4, f2 is + inlined into f1. The DIE of main should contain DW_TAG_inlined_subroutines + children for f4, f3, f2 and f1. Also, there should be a DIE representing + and out of line instance of f4, aside the DIE representing its abstract + instance. + We used to fail to emit debugging info for t1, because it was moved + inside the (inlined) block of f1, marked as abstract, then we'd crash. */ + +#define UNUSED __attribute__((unused)) +#define EXT __extension__ + +int undef(void); + +inline static void +f1 (int i UNUSED) +{ +} + +inline static void +f2 (void) +{ + f1 (EXT ({ int t1 UNUSED; undef (); })); +} + +inline static void +f3 (void) +{ + int v1 UNUSED; + int v2 UNUSED; + + EXT ({ int t2 UNUSED; if (0) undef (); 0; }) + && EXT ({ int t3 UNUSED; if (0) undef (); 0; }); + + if (1) + { + undef (); + if (1) + f2 (); + } + + { + undef (); + } +} + +inline static void +f4 (void) +{ + EXT ({ undef (); 1; }) && EXT ({ int t4 UNUSED = ({ 1; }); 1; }); + + { } + + EXT ({ int t5 UNUSED; if (0) undef (); 0; }); + + f4 (); + + undef (); + f3 (); + + return; +} + +int +main () +{ + int foo = 1; + f4 (); +}
20020224-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20010207-1.c =================================================================== --- 20010207-1.c (nonexistent) +++ 20010207-1.c (revision 826) @@ -0,0 +1,4 @@ +/* { dg-do compile } */ +extern inline int f1 (void) {return f2();} +int f3 (void) {return f1();} +int f1 (void) {return 0;}
20010207-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: debug-6.c =================================================================== --- debug-6.c (nonexistent) +++ debug-6.c (revision 826) @@ -0,0 +1,38 @@ +/* Verify that bb-reorder re-inserts nested scopes properly. */ +/* { dg-do compile } */ +/* { dg-options "-dA" } */ +/* { dg-final { scan-assembler "xyzzy" } } */ + +extern void abort (void); + +struct A { char *a, *b, *c, *d; }; + +static int +bar2 (struct A *x) +{ + int a = x->c - x->b; + x->c += 26; + return a; +} + +void fnptr (int *); + +void +foo (void) +{ + struct A e; + + if (bar2 (&e) < 0) + abort (); + { + int xyzzy; + fnptr (&xyzzy); + } + { + struct A *f; + + f = &e; + if (f->c - f->a > f->d - f->a) + f->c = f->d; + } +}
debug-6.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: vta-3.c =================================================================== --- vta-3.c (nonexistent) +++ vta-3.c (revision 826) @@ -0,0 +1,17 @@ +/* { dg-do compile } */ + +int +foo (void) +{ + union { char e[8]; int i; } a, b; + char *c, *d; + unsigned int i; + c = a.e; + d = &b.e[sizeof (int) - 1]; + for (i = 0; i < sizeof (int); i++) + { + *d = *c++; + --d; + } + return b.i; +}
vta-3.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr29609-2.c =================================================================== --- pr29609-2.c (nonexistent) +++ pr29609-2.c (revision 826) @@ -0,0 +1,53 @@ +/* PR debug/29609 */ +/* Verify that breakpoint on both goto failure; stmts is hit. + This version of the test just checks that it can be compiled, linked + and executed, further testing is done in corresponding gcc.dg/dwarf2/ + test and hopefully in gdb testsuite. */ +/* { dg-do run } */ +/* { dg-options "-O0 -g -dA" } */ + +extern void abort (void); +int x; + +int +foo (void) +{ + return 0 ^ x; +} + +int +bar (void) +{ + return 1 ^ x; +} + +int +baz (void) +{ + int c; + + if (!foo ()) + goto failure; + + if (!bar ()) + goto failure; + + return 0; + +failure: + return 1; +} + +int +main (void) +{ + if (baz () != 1) + abort (); + x = 1; + if (baz () != 1) + abort (); + x = 2; + if (baz () != 0) + abort (); + return 0; +}
pr29609-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: debug-7.c =================================================================== --- debug-7.c (nonexistent) +++ debug-7.c (revision 826) @@ -0,0 +1,16 @@ +/* { dg-do compile } */ +/* { dg-options "-dA" } */ +/* PR debug/12934. */ + +static inline int foo () +{ + return 42; +} + +void bar (int *); + +void baz () +{ + int a[foo ()]; + bar (a); +}
debug-7.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr16676.c =================================================================== --- pr16676.c (nonexistent) +++ pr16676.c (revision 826) @@ -0,0 +1,5 @@ +/* { dg-do compile } */ + +void foo (void) { + void nested () {} +}
pr16676.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: redecl-1.c =================================================================== --- redecl-1.c (nonexistent) +++ redecl-1.c (revision 826) @@ -0,0 +1,352 @@ +/* Test for multiple declarations and composite types. As in bug + 13801. Test no problems in debug information generation. */ +/* Origin: Joseph Myers */ +/* { dg-do compile } */ +/* { dg-options "" } */ + +typedef int IA[]; +typedef int A10[10]; + +/* Test all combinations of: a variable declared at file scope (no + type specifiers, or extern, or static), or just inside a function + (with extern), redeclared in an inner scope (with extern), and + redeclared in an inner scope when the previous declaration is + hidden (with extern, and not if the original declaration was + static). Test three times: incomplete variable types; pointers to + incomplete types; functions returning such pointers. + + This test only includes the valid code cases, to test debug info + generation. (Incomplete static at file scope is not permitted by + ISO C, but is accepted by GCC as an extension without + -pedantic.) */ + +A10 a5; +void +f5 (void) +{ + sizeof(a5); + { + extern IA a5; + sizeof(a5); + { + int a5; + { + extern A10 a5; + sizeof(a5); + } + } + sizeof(a5); + } + sizeof(a5); +} +extern A10 a5; + +A10 a7; +void +f7 (void) +{ + sizeof(a7); + { + extern A10 a7; + sizeof(a7); + { + int a7; + { + extern A10 a7; + sizeof(a7); + } + } + sizeof(a7); + } + sizeof(a7); +} +extern A10 a7; + +extern A10 a13; +void +f13 (void) +{ + sizeof(a13); + { + extern IA a13; + sizeof(a13); + { + int a13; + { + extern A10 a13; + sizeof(a13); + } + } + sizeof(a13); + } + sizeof(a13); +} +extern A10 a13; + +extern A10 a15; +void +f15 (void) +{ + sizeof(a15); + { + extern A10 a15; + sizeof(a15); + { + int a15; + { + extern A10 a15; + sizeof(a15); + } + } + sizeof(a15); + } + sizeof(a15); +} +extern A10 a15; + + +static A10 a18; +void +f18 (void) +{ + sizeof(a18); + { + extern IA a18; + sizeof(a18); + } + sizeof(a18); +} +extern A10 a18; + +static A10 a19; +void +f19 (void) +{ + sizeof(a19); + { + extern A10 a19; + sizeof(a19); + } + sizeof(a19); +} +extern A10 a19; + +A10 *b5; +void +g5 (void) +{ + sizeof(*b5); + { + extern IA *b5; + sizeof(*b5); + { + int b5; + { + extern A10 *b5; + sizeof(*b5); + } + } + sizeof(*b5); + } + sizeof(*b5); +} +extern A10 *b5; + +A10 *b7; +void +g7 (void) +{ + sizeof(*b7); + { + extern A10 *b7; + sizeof(*b7); + { + int b7; + { + extern A10 *b7; + sizeof(*b7); + } + } + sizeof(*b7); + } + sizeof(*b7); +} +extern A10 *b7; + +extern A10 *b13; +void +g13 (void) +{ + sizeof(*b13); + { + extern IA *b13; + sizeof(*b13); + { + int b13; + { + extern A10 *b13; + sizeof(*b13); + } + } + sizeof(*b13); + } + sizeof(*b13); +} +extern A10 *b13; + +extern A10 *b15; +void +g15 (void) +{ + sizeof(*b15); + { + extern A10 *b15; + sizeof(*b15); + { + int b15; + { + extern A10 *b15; + sizeof(*b15); + } + } + sizeof(*b15); + } + sizeof(*b15); +} +extern A10 *b15; + +static A10 *b18; +void +g18 (void) +{ + sizeof(*b18); + { + extern IA *b18; + sizeof(*b18); + } + sizeof(*b18); +} +extern A10 *b18; + +static A10 *b19; +void +g19 (void) +{ + sizeof(*b19); + { + extern A10 *b19; + sizeof(*b19); + } + sizeof(*b19); +} +extern A10 *b19; + +A10 *c5 (void); +void +h5 (void) +{ + sizeof(*c5()); + { + extern IA *c5 (void); + sizeof(*c5()); + { + int c5; + { + extern A10 *c5 (void); + sizeof(*c5()); + } + } + sizeof(*c5()); + } + sizeof(*c5()); +} +A10 *c5 (void) { return 0; } + +A10 *c7 (void); +void +h7 (void) +{ + sizeof(*c7()); + { + extern A10 *c7 (void); + sizeof(*c7()); + { + int c7; + { + extern A10 *c7 (void); + sizeof(*c7()); + } + } + sizeof(*c7()); + } + sizeof(*c7()); +} +A10 *c7 (void) { return 0; } + +extern A10 *c13 (void); +void +h13 (void) +{ + sizeof(*c13()); + { + extern IA *c13 (void); + sizeof(*c13()); + { + int c13; + { + extern A10 *c13 (void); + sizeof(*c13()); + } + } + sizeof(*c13()); + } + sizeof(*c13()); +} +extern A10 *c13 (void) { return 0; } + +extern A10 *c15 (void); +void +h15 (void) +{ + sizeof(*c15()); + { + extern A10 *c15 (void); + sizeof(*c15()); + { + int c15; + { + extern A10 *c15 (void); + sizeof(*c15()); + } + } + sizeof(*c15()); + } + sizeof(*c15()); +} +extern A10 *c15 (void) { return 0; } + +static A10 *c18 (void); +void +h18 (void) +{ + sizeof(*c18()); + { + extern IA *c18 (void); + sizeof(*c18()); + } + sizeof(*c18()); +} +static A10 *c18 (void) { return 0; } + +static A10 *c19 (void); +void +h19 (void) +{ + sizeof(*c19()); + { + extern A10 *c19 (void); + sizeof(*c19()); + } + sizeof(*c19()); +} +static A10 *c19 (void) { return 0; }
redecl-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20030605-1.c =================================================================== --- 20030605-1.c (nonexistent) +++ 20030605-1.c (revision 826) @@ -0,0 +1,7 @@ +/* Verify we don't ICE on statement-expressions. */ +/* { dg-do compile } */ + +void foo(void) +{ + char buf[({ 4; })]; +}
20030605-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20020327-1.c =================================================================== --- 20020327-1.c (nonexistent) +++ 20020327-1.c (revision 826) @@ -0,0 +1,12 @@ +/* { dg-do link } */ + +#ifndef __powerpc64__ +/* Fails on powerpc64-linux due to the function Letext using a global + .Letext symbol that conflicts with .Letext emitted by gcc with + -gstabs. Some day the linker will be fixed to not require global + "dot" syms, but for now disable this test entirely for powerpc64. + Using xfail doesn't work, nor does dg-excess-errors because some + combinations of command line options won't cause this test to fail. */ +void Letext (void) { } +#endif +int main() { return 0; }
20020327-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: redecl-2.c =================================================================== --- redecl-2.c (nonexistent) +++ redecl-2.c (revision 826) @@ -0,0 +1,24 @@ +/* Test for multiple declarations and composite types. As in bug + 13801. Illustrates how bug causes correct code to be wrongly + diagnosed. Debug test: avoid ICE. */ +/* Origin: Joseph Myers */ +/* { dg-do compile } */ +/* { dg-options "" } */ + +typedef int IA[]; +typedef int A5[5]; +typedef int A10[10]; + +A10 array10; + +A5 *ap; +void +f (void) +{ + int ap; + { + extern IA *ap; + /* This assignment is valid. */ + ap = &array10; + } +}
redecl-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: redecl-3.c =================================================================== --- redecl-3.c (nonexistent) +++ redecl-3.c (revision 826) @@ -0,0 +1,12 @@ +/* Test for multiple declarations and composite types. */ + +/* Origin: Joseph Myers */ +/* { dg-do compile } */ +/* { dg-options "" } */ + +int y[]; +void +g (void) +{ + extern int y[1]; +}
redecl-3.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: redecl-4.c =================================================================== --- redecl-4.c (nonexistent) +++ redecl-4.c (revision 826) @@ -0,0 +1,12 @@ +/* Test for multiple declarations and composite types. */ + +/* Origin: Joseph Myers */ +/* { dg-do compile } */ +/* { dg-options "" } */ + +static int y[]; +void +g (void) +{ + extern int y[1]; +}
redecl-4.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20041219-1.c =================================================================== --- 20041219-1.c (nonexistent) +++ 20041219-1.c (revision 826) @@ -0,0 +1,8 @@ +/* PR 18067 */ +/* { dg-do compile } */ + +void foo(int i) +{ + const int j=i+1; + int a[1][j*j]; +}
20041219-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: redecl-5.c =================================================================== --- redecl-5.c (nonexistent) +++ redecl-5.c (revision 826) @@ -0,0 +1,31 @@ +/* Test for multiple declarations and composite types, as in bug + 13801. Test types saved from outer scopes are up to date. Debug + test. */ +/* Origin: Joseph Myers */ +/* { dg-do compile } */ +/* { dg-options "" } */ + +int x[]; + +void +f (void) +{ + extern int x[]; +} + +int x[10]; + +void +g (void) +{ + int x; + { + extern int x[10]; + } +} + +void +h (void) +{ + sizeof (x); +}
redecl-5.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: tls-1.c =================================================================== --- tls-1.c (nonexistent) +++ tls-1.c (revision 826) @@ -0,0 +1,19 @@ +/* Test that optimized out __thread var doesn't have its location + referenced in debug info. */ +/* { dg-do link } */ +/* { dg-options "-O2" } */ +/* { dg-require-effective-target tls } */ + +static __thread int vara; + +int +foo (int b) +{ + return vara + b; +} + +int +main (void) +{ + return foo (0); +}
tls-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20050907-1.c =================================================================== --- 20050907-1.c (nonexistent) +++ 20050907-1.c (revision 826) @@ -0,0 +1,24 @@ +/* PR 23190 */ +/* Well, collateral damage from a proposed patch fixing 23190. We'd emit + debug info for multilib_exclusions_raw without emitting the variable + itself, leading to link errors. This reduced form is filed as PR 23777, + for not eliminating things soon enough. */ +/* { dg-do link } */ + +static const char *const multilib_exclusions_raw[] = { 0 }; + +void __attribute__((noinline)) f(char *const *p) +{ + __asm__ ("" : : "g"(p) : "memory"); +} + +void g (char **o) +{ + const char *const *q = multilib_exclusions_raw; + + f (o); + while (*q++) + f (o); +} + +int main() { return 0; }
20050907-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: trivial.c =================================================================== --- trivial.c (nonexistent) +++ trivial.c (revision 826) @@ -0,0 +1,6 @@ +/* { dg-do run } */ + +int main(void) +{ + return 0; +}
trivial.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr33316.c =================================================================== --- pr33316.c (nonexistent) +++ pr33316.c (revision 826) @@ -0,0 +1,15 @@ +/* PR debug/33316 */ + +int +foo (void *x, int y) +{ + const struct { int d[y]; } *a = x; + return a[0].d[0]; +} + +int +bar (void *x, int y) +{ + const struct S { int d[y]; } *a = x; + return a[0].d[0]; +}
pr33316.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr42244.c =================================================================== --- pr42244.c (nonexistent) +++ pr42244.c (revision 826) @@ -0,0 +1,13 @@ +/* PR debug/42444 */ +/* { dg-do compile } */ +/* { dg-options "-O2 -g -fmodulo-sched -ffloat-store" } */ + +extern int a, b; + +double +foo (double x) +{ + for (; a > b; a--) + x *= (double) a; + return x; +}
pr42244.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2-1.c =================================================================== --- dwarf2-1.c (nonexistent) +++ dwarf2-1.c (revision 826) @@ -0,0 +1,11 @@ +/* { dg-do compile } */ + +/* Copyright (C) 2000 Free Software Foundation */ +/* Contributed by Alexandre Oliva */ + +static int foo () { return 0; } + +void bar () { + int foo (); + int foo (); +}
dwarf2-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr35154.c =================================================================== --- pr35154.c (nonexistent) +++ pr35154.c (revision 826) @@ -0,0 +1,34 @@ +/* Test to make sure that stabs for C symbols that go into .comm have the + proper structure. These should be lettered G for the struct that gives + the name to the .comm, and should be V or S for .lcomm symbols. */ + +static char i_outer; +struct { + char f1; + char f2; +} opta; +struct { + char f1; + char f2; +} optb; + +int +main() +{ + static char i_inner[2]; + i_inner[0] = 'a'; i_inner[1] = 'b'; + opta.f1 = 'c'; + opta.f2 = 'd'; + optb.f1 = 'C'; + optb.f2 = 'D'; + i_outer = 'e'; +/* { dg-do compile } */ +/* { dg-skip-if "No stabs" { mmix-*-* *-*-netware* alpha*-*-* hppa*64*-*-* ia64-*-* *-*-vxworks* } { "*" } { "" } } */ +/* { dg-skip-if "stabs only" { *-*-* } { "*" } { "-gstabs" } } */ + return 0; +} + +/* { dg-final { scan-assembler ".stabs.*i_inner:V" } } */ +/* { dg-final { scan-assembler ".stabs.*i_outer:S" } } */ +/* { dg-final { scan-assembler ".stabs.*opta:G" } } */ +/* { dg-final { scan-assembler ".stabs.*optb:G" } } */
pr35154.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2-2.c =================================================================== --- dwarf2-2.c (nonexistent) +++ dwarf2-2.c (revision 826) @@ -0,0 +1,17 @@ +/* { dg-do compile } */ + +/* Copyright (C) 2000 Free Software Foundation */ +/* Contributed by Alexandre Oliva */ + +inline double fx (double x) +{ + return 3 * x; +} + +main () +{ + double a = 0, fx (double), foo (); + fx (a); + if (a != 3) + foo (); +}
dwarf2-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: const-1.c =================================================================== --- const-1.c (nonexistent) +++ const-1.c (revision 826) @@ -0,0 +1,3 @@ +/* { dg-do compile } */ +typedef float FloatVect __attribute__((__vector_size__(16))); +static FloatVect Foo = { 250000000.0, 0.0, 0.0, 0.0 };
const-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr39412.c =================================================================== --- pr39412.c (nonexistent) +++ pr39412.c (revision 826) @@ -0,0 +1,16 @@ +/* PR debug/39412 */ +/* { dg-do compile } */ + +struct S { int i; }; + +inline void +bar (const void *x, unsigned long y) +{ + const union { struct S a[y]; } *u = x; +} + +void +foo (const void *x, unsigned long y) +{ + bar (x, y); +}
pr39412.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2-3.c =================================================================== --- dwarf2-3.c (nonexistent) +++ dwarf2-3.c (revision 826) @@ -0,0 +1,13 @@ +/* Test -feliminate-dwarf2-dups */ +/* Contributed by Devang Patel */ +/* { dg-do compile } */ +/* { dg-options "-feliminate-dwarf2-dups" } */ + +#include "dwarf2-3.h" + +int main() +{ + struct point p; + p.x = 0; + p.y = 0; +}
dwarf2-3.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: const-2.c =================================================================== --- const-2.c (nonexistent) +++ const-2.c (revision 826) @@ -0,0 +1,2 @@ +/* { dg-do compile } */ +static __complex__ int x = 3.0;
const-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr41717.c =================================================================== --- pr41717.c (nonexistent) +++ pr41717.c (revision 826) @@ -0,0 +1,10 @@ +/* PR debug/41717 */ +/* { dg-do compile } */ + +void +foo (void) +{ + _Complex float v[1], w; + v[1] = 0.0f + 0.8fi; + w = __builtin_conjf (v[1] * v[1]); +}
pr41717.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: const-3.c =================================================================== --- const-3.c (nonexistent) +++ const-3.c (revision 826) @@ -0,0 +1,7 @@ +/* Make sure we don't emit strings just because of debug information + for string initializers. */ +/* { dg-do compile } */ +/* { dg-options "-O2 -g" } */ +/* { dg-final { scan-assembler-not "dontgenerate" } } */ +static const char *p = "dontgenerate1"; +static const char *q[2] = { 0, "dontgenerate2" };
const-3.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20011223-1.c =================================================================== --- 20011223-1.c (nonexistent) +++ 20011223-1.c (revision 826) @@ -0,0 +1,11 @@ +/* Origin: PR c/5163 from aj@suse.de. */ +/* { dg-do compile } */ + +extern int bar (int); + +int +foo (void) +{ + extern int bar (int); + return bar (5); +}
20011223-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr37616.c =================================================================== --- pr37616.c (nonexistent) +++ pr37616.c (revision 826) @@ -0,0 +1,40 @@ +/* PR debug/37616 */ +/* Test that one can put breakpoints onto continue, exitlab and break + and actually see program reaching those breakpoints. + This version of the test just checks that it can be compiled, linked + and executed, further testing is done in corresponding gcc.dg/dwarf2/ + test and hopefully in gdb testsuite. */ +/* { dg-do run } */ +/* { dg-options "-O0 -g -dA" } */ + +extern void abort (void); + +int +foo (int parm) +{ + int varj, varm; + + for (varj = 0; varj < 10; varj++) + { + if (varj == 5) + continue; + if (varj == 7 && !parm) + goto exitlab; + if (varj == 9) + break; + varm = varj; + } + +exitlab: + return varm; +} + +int +main (void) +{ + if (foo (0) != 6) + abort (); + if (foo (1) != 8) + abort (); + return 0; +}
pr37616.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr41893-1.c =================================================================== --- pr41893-1.c (nonexistent) +++ pr41893-1.c (revision 826) @@ -0,0 +1,13 @@ +/* PR debug/41893 */ +/* { dg-do compile } */ +/* { dg-options "-combine -fwhole-program -O" } */ +/* { dg-additional-sources "pr41893-2.c" } */ + +struct S { int v; }; +struct S s; + +void __attribute__((externally_visible)) +func1 (void) +{ + struct S *p = &s; +}
pr41893-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: 20041023-1.c =================================================================== --- 20041023-1.c (nonexistent) +++ 20041023-1.c (revision 826) @@ -0,0 +1,13 @@ +/* { dg-do compile } */ + +static void +foo (unsigned char x) +{ + unsigned char a[5 + x]; +} + +void +bar (void) +{ + foo (80); +}
20041023-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr41893-2.c =================================================================== --- pr41893-2.c (nonexistent) +++ pr41893-2.c (revision 826) @@ -0,0 +1,10 @@ +/* PR debug/41893 */ +/* { dg-do compile } */ + +extern struct S s; + +void +func2 (void) +{ + &s; +}
pr41893-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr26881.c =================================================================== --- pr26881.c (nonexistent) +++ pr26881.c (revision 826) @@ -0,0 +1,16 @@ +/* { dg-do compile } */ +/* { dg-options "-g -O0" } */ +int +main (int argc, char **argv) +{ + if (0) + { + static union + { + } + u; + typedef char tt; + static tt c[8]; + return c[0] == 0x01 && c[1] == 0x02; + } +}
pr26881.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: dwarf2-3.h =================================================================== --- dwarf2-3.h (nonexistent) +++ dwarf2-3.h (revision 826) @@ -0,0 +1,9 @@ +/* Test -feliminate-dwarf2-dups */ +/* Contributed by Devang Patel */ + +struct point +{ + int x; + int y; +}; +
dwarf2-3.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr43972.c =================================================================== --- pr43972.c (nonexistent) +++ pr43972.c (revision 826) @@ -0,0 +1,29 @@ +/* PR debug/43972 */ +/* { dg-do compile } */ +/* { dg-options "-g -w" } */ +/* { dg-options "-g -fpic -w" { target fpic } } */ + +struct { int *b1; } *f1 (); +short v1[1]; +struct S { int b2; }; +void +foo (struct S *a1, union { char *b3; unsigned *b4; int *b5; } *a2) +{ + int d; + switch (d) + { + case 0: + { + int c = a1->b2, i; + if (f1 () == 0) + *a2->b3++ = 2; + else if (((long) (f1 () - f1 ())) ^ ((long) f1 ()->b1 - ((long) f1 () & 8))) + *a2->b3++ = (long) f1 - ((long) f1 () & 0xff); + else + *a2->b4++ = (long) f1; + for (i = 0; i < c; i++) + *a2->b5++ = (long) v1; + foo (a1, a2); + } + } +}
pr43972.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: pr42767.c =================================================================== --- pr42767.c (nonexistent) +++ pr42767.c (revision 826) @@ -0,0 +1,18 @@ +/* PR debug/42767 */ +/* { dg-do compile } */ +/* { dg-options "-O1 -g" } */ + +struct lineno_cache_entry +{ + unsigned long size; +}; +_bfd_link_section_stabs (struct lineno_cache_entry * stabsec) +{ + unsigned long count; + unsigned char *sym; + unsigned char *symend; + unsigned long skip; + count = stabsec->size / 12; + for (; sym < symend; sym += 1); + stabsec->size = (count - skip) * 12; +}
pr42767.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.