dwarf2.exp: Replace -gdwarf-2 with -gdwarf.

* gcc.dg/debug/dwarf2/dwarf2.exp: Replace -gdwarf-2 with -gdwarf.
        * gcc.dg/debug/dwarf2/dwarf-die7.c: Likewise.
        * gcc.dg/debug/dwarf2/static1.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-dfp.c: Likewise.
        * gcc.dg/debug/dwarf2/fesd-any.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-uninit.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-die1.c: Likewise.
        * gcc.dg/debug/dwarf2/var1.c: Likewise.
        * gcc.dg/debug/dwarf2/pr29609-2.c: Likewise.
        * gcc.dg/debug/dwarf2/aranges-fnsec-1.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-die3.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-merge.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-char1.c: Likewise.
        * gcc.dg/debug/dwarf2/discriminator.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-char2.c: Likewise.
        * gcc.dg/debug/dwarf2/fesd-baseonly.c: Likewise.
        * gcc.dg/debug/dwarf2/pr36690-3.c: Likewise.
        * gcc.dg/debug/dwarf2/const-2.c: Likewise.
        * gcc.dg/debug/dwarf2/ipa-cp1.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-char3.c: Likewise.
        * gcc.dg/debug/dwarf2/var2.c: Likewise.
        * gcc.dg/debug/dwarf2/pr36690-2.c: Likewise.
        * gcc.dg/debug/dwarf2/pr31230.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-float.c: Likewise.
        * gcc.dg/debug/dwarf2/short-circuit.c: Likewise.
        * gcc.dg/debug/dwarf2/pr36690-1.c: Likewise.
        * gcc.dg/debug/dwarf2/fesd-reduced.c: Likewise.
        * gcc.dg/debug/dwarf2/pr37616.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-die2.c: Likewise.
        * gcc.dg/debug/dwarf2/inline1.c: Likewise.
        * gcc.dg/debug/dwarf2/fesd-sys.c: Likewise.
        * gcc.dg/debug/dwarf2/pr29609-1.c: Likewise.
        * gcc.dg/debug/dwarf2/asm-line1.c: Likewise.
        * gcc.dg/debug/dwarf2/c99-typedef1.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf2-macro.c: Likewise.
        * gcc.dg/debug/dwarf2/fesd-none.c: Likewise.
        * gcc.dg/debug/dwarf2/pr51410.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-file1.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-die6.c: Likewise.
        * gcc.dg/debug/dwarf2/const-2b.c: Likewise.
        * gcc.dg/debug/dwarf2/dwarf-die5.c: Likewise.

From-SVN: r201734
This commit is contained in:
Joern Rennecke 2013-08-14 18:08:22 +00:00 committed by Joern Rennecke
parent 3ad20bd448
commit 071e3c4f2b
42 changed files with 86 additions and 42 deletions

View File

@ -1,3 +1,47 @@
2013-08-14 Joern Rennecke <joern.rennecke@embecosm.com>
* gcc.dg/debug/dwarf2/dwarf2.exp: Replace -gdwarf-2 with -gdwarf.
* gcc.dg/debug/dwarf2/dwarf-die7.c: Likewise.
* gcc.dg/debug/dwarf2/static1.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-dfp.c: Likewise.
* gcc.dg/debug/dwarf2/fesd-any.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-uninit.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-die1.c: Likewise.
* gcc.dg/debug/dwarf2/var1.c: Likewise.
* gcc.dg/debug/dwarf2/pr29609-2.c: Likewise.
* gcc.dg/debug/dwarf2/aranges-fnsec-1.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-die3.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-merge.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-char1.c: Likewise.
* gcc.dg/debug/dwarf2/discriminator.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-char2.c: Likewise.
* gcc.dg/debug/dwarf2/fesd-baseonly.c: Likewise.
* gcc.dg/debug/dwarf2/pr36690-3.c: Likewise.
* gcc.dg/debug/dwarf2/const-2.c: Likewise.
* gcc.dg/debug/dwarf2/ipa-cp1.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-char3.c: Likewise.
* gcc.dg/debug/dwarf2/var2.c: Likewise.
* gcc.dg/debug/dwarf2/pr36690-2.c: Likewise.
* gcc.dg/debug/dwarf2/pr31230.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-float.c: Likewise.
* gcc.dg/debug/dwarf2/short-circuit.c: Likewise.
* gcc.dg/debug/dwarf2/pr36690-1.c: Likewise.
* gcc.dg/debug/dwarf2/fesd-reduced.c: Likewise.
* gcc.dg/debug/dwarf2/pr37616.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-die2.c: Likewise.
* gcc.dg/debug/dwarf2/inline1.c: Likewise.
* gcc.dg/debug/dwarf2/fesd-sys.c: Likewise.
* gcc.dg/debug/dwarf2/pr29609-1.c: Likewise.
* gcc.dg/debug/dwarf2/asm-line1.c: Likewise.
* gcc.dg/debug/dwarf2/c99-typedef1.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf2-macro.c: Likewise.
* gcc.dg/debug/dwarf2/fesd-none.c: Likewise.
* gcc.dg/debug/dwarf2/pr51410.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-file1.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-die6.c: Likewise.
* gcc.dg/debug/dwarf2/const-2b.c: Likewise.
* gcc.dg/debug/dwarf2/dwarf-die5.c: Likewise.
2013-08-14 Janis Johnson <janisjo@codesourcery.com>
* gcc.target/arm/pr19599.c: Skip for -mthumb.

View File

@ -3,7 +3,7 @@
/* Origin: Joseph Myers <joseph@codesourcery.com> */
/* { dg-do compile } */
/* { dg-require-effective-target function_sections } */
/* { dg-options "-gdwarf-2 -ffunction-sections -w -dA" } */
/* { dg-options "-gdwarf -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" } } */

View File

@ -1,6 +1,6 @@
/* PR debug/50983 */
/* { dg-do compile { target *-*-gnu* } } */
/* { dg-options "-O0 -gdwarf-2" } */
/* { dg-options "-O0 -gdwarf" } */
/* { dg-final { scan-assembler "is_stmt 1" } } */
int i;

View File

@ -1,4 +1,4 @@
// { dg-options "-std=iso9899:1999 -gdwarf-2" }
// { dg-options "-std=iso9899:1999 -gdwarf" }
void f() {
int n = 3;

View File

@ -1,5 +1,5 @@
/* { dg-do compile { target powerpc_altivec_ok } } */
/* { dg-options "-O -gdwarf-2 -dA -maltivec" } */
/* { dg-options "-O -gdwarf -dA -maltivec" } */
/* { dg-final { scan-assembler "DW_AT_const_value" } } */
typedef float FloatVect __attribute__((__vector_size__(16)));

View File

@ -1,5 +1,5 @@
/* { dg-do compile { target i386*-*-* } } */
/* { dg-options "-O -gdwarf-2 -dA -msse" } */
/* { dg-options "-O -gdwarf -dA -msse" } */
/* { dg-require-effective-target sse } */
/* { dg-final { scan-assembler "DW_AT_const_value" } } */

View File

@ -1,7 +1,7 @@
/* HAVE_AS_DWARF2_DEBUG_LINE macro needs to be defined to pass the unittest.
However, dg cannot access it, so we restrict to GNU targets. */
/* { dg-do compile { target *-*-gnu* } } */
/* { dg-options "-O0 -gdwarf-2" } */
/* { dg-options "-O0 -gdwarf" } */
/* { dg-final { scan-assembler "loc \[0-9] 11 \[0-9]( is_stmt \[0-9])?\n" } } */
/* { dg-final { scan-assembler "loc \[0-9] 11 \[0-9]( is_stmt \[0-9])? discriminator 2\n" } } */
/* { dg-final { scan-assembler "loc \[0-9] 11 \[0-9]( is_stmt \[0-9])? discriminator 1\n" } } */

View File

@ -1,6 +1,6 @@
/* PR debug/7241 */
/* { dg-do compile } */
/* { dg-options "-O2 -gdwarf-2 -dA" } */
/* { dg-options "-O2 -gdwarf -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" } } */

View File

@ -1,6 +1,6 @@
/* PR debug/7241 */
/* { dg-do compile } */
/* { dg-options "-O2 -gdwarf-2 -dA" } */
/* { dg-options "-O2 -gdwarf -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" } } */

View File

@ -1,6 +1,6 @@
/* PR debug/7241 */
/* { dg-do compile } */
/* { dg-options "-O2 -gdwarf-2 -dA" } */
/* { dg-options "-O2 -gdwarf -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" } } */

View File

@ -2,7 +2,7 @@
/* { dg-do compile */
/* { dg-require-effective-target dfp } */
/* { dg-options "-O0 -gdwarf-2 -dA" } */
/* { dg-options "-O0 -gdwarf -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" } } */

View File

@ -1,6 +1,6 @@
/* Verify that inline function never actually inlined has no abstract DIE. */
/* { dg-do compile } */
/* { dg-options "-O2 -gdwarf-2 -dA" } */
/* { dg-options "-O2 -gdwarf -dA" } */
/* { dg-final { scan-assembler-not "DW_AT_inline" } } */
inline int t()
{

View File

@ -1,6 +1,6 @@
/* Verify that inline function never actually emit has no DIE. */
/* { dg-do compile } */
/* { dg-options "-O0 -gdwarf-2 -dA" } */
/* { dg-options "-O0 -gdwarf -dA" } */
/* { dg-final { scan-assembler-not "CIE Version" } } */
static inline int t()
{

View File

@ -1,6 +1,6 @@
/* Verify that extern inline function never actually inlined has no abstract DIE. */
/* { dg-do compile } */
/* { dg-options "-O0 -gdwarf-2 -dA" } */
/* { dg-options "-O0 -gdwarf -dA" } */
/* { dg-final { scan-assembler-not "DW_AT_inline" } } */
extern inline int t()
{

View File

@ -1,6 +1,6 @@
/* Inlined inline function must have abstract DIE */
/* { dg-do compile } */
/* { dg-options "-O2 -gdwarf-2 -dA -fpreprocessed" } */
/* { dg-options "-O2 -gdwarf -dA -fpreprocessed" } */
/* { dg-final { scan-assembler "3.*DW_AT_inline" } } */
#1 "test.h"
inline int t()

View File

@ -1,6 +1,6 @@
/* not inline inline function must not have abstract DIE */
/* { dg-do compile } */
/* { dg-options "-O2 -fno-inline -gdwarf-2 -dA -fpreprocessed" } */
/* { dg-options "-O2 -fno-inline -gdwarf -dA -fpreprocessed" } */
/* { dg-final { scan-assembler-not "DW_AT_inline" } } */
#1 "test.h"
inline int t()

View File

@ -1,6 +1,6 @@
/* Inlined non-inline function must have abstract DIE */
/* { dg-do compile } */
/* { dg-options "-O2 -gdwarf-2 -dA -fpreprocessed" } */
/* { dg-options "-O2 -gdwarf -dA -fpreprocessed" } */
/* { dg-final { scan-assembler "1.*DW_AT_inline" } } */
#1 "test.h"
void f(void);

View File

@ -1,5 +1,5 @@
/* { dg-do compile } */
/* { dg-options "-O2 -gdwarf-2 -dA" } */
/* { dg-options "-O2 -gdwarf -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:",

View File

@ -1,7 +1,7 @@
/* Verify the DWARF encoding of C99 floating point types. */
/* { dg-do compile */
/* { dg-options "-O0 -gdwarf-2 -dA" } */
/* { dg-options "-O0 -gdwarf -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" } } */

View File

@ -1,7 +1,7 @@
/* 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-options "-O2 -gdwarf -dA" } */
/* { dg-final { scan-assembler "DW_AT_producer: \"GNU C" } } */
/* { dg-final { scan-assembler-not "GNU C\[^\\n\\r\]*DW_AT_producer" } } */

View File

@ -1,5 +1,5 @@
/* { dg-do compile } */
/* { dg-options "-O2 -gdwarf-2 -dA" } */
/* { dg-options "-O2 -gdwarf -dA" } */
/* { dg-final { scan-assembler "DW_TAG_variable" } } */
/* PR debug/21828 */

View File

@ -1,6 +1,6 @@
/* 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-options "-g3 -gdwarf -dA -fverbose-asm" } */
/* { dg-final { scan-assembler "Start new file" } } */
#define ADD(x) (M + x)

View File

@ -22,7 +22,7 @@ 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"
set DEFAULT_CFLAGS " -ansi -pedantic-errors -gdwarf"
}
# Initialize `dg'.
@ -31,7 +31,7 @@ dg-init
# Main loop.
set comp_output [gcc_target_compile \
"$srcdir/$subdir/../trivial.c" "trivial.S" assembly \
"additional_flags=-gdwarf-2"]
"additional_flags=-gdwarf"]
if { ! [string match "*: target system does not support the * debug format*" \
$comp_output] } {
remove-build-file "trivial.S"

View File

@ -1,5 +1,5 @@
// { dg-do compile }
// { dg-options "-gdwarf-2 -dA -femit-struct-debug-detailed=any" }
// { dg-options "-gdwarf -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" } }

View File

@ -1,5 +1,5 @@
// { dg-do compile }
// { dg-options "-gdwarf-2 -dA -femit-struct-debug-baseonly" }
// { dg-options "-gdwarf -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" } }

View File

@ -1,5 +1,5 @@
// { dg-do compile }
// { dg-options "-gdwarf-2 -dA -femit-struct-debug-detailed=none" }
// { dg-options "-gdwarf -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" } }

View File

@ -1,5 +1,5 @@
// { dg-do compile }
// { dg-options "-gdwarf-2 -dA -femit-struct-debug-reduced" }
// { dg-options "-gdwarf -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" } }

View File

@ -1,5 +1,5 @@
// { dg-do compile }
// { dg-options "-gdwarf-2 -dA -femit-struct-debug-detailed=sys" }
// { dg-options "-gdwarf -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" } }

View File

@ -1,5 +1,5 @@
/* { dg-do compile } */
/* { dg-options "-O0 -gdwarf-2 -dA" } */
/* { dg-options "-O0 -gdwarf -dA" } */
void e(int);
__attribute__ ((always_inline)) inline int
t(int function_parameter)

View File

@ -1,5 +1,5 @@
/* { dg-do compile } */
/* { dg-options "-O2 -gdwarf-2 -dA" } */
/* { dg-options "-O2 -gdwarf -dA" } */
void q(int p);
static void
t(int constant_propagated_par)

View File

@ -1,7 +1,7 @@
/* PR debug/29609 */
/* Verify that breakpoint on the break is hit. */
/* { dg-do compile } */
/* { dg-options "-O0 -gdwarf-2 -dA" } */
/* { dg-options "-O0 -gdwarf -dA" } */
void abort (void);

View File

@ -1,7 +1,7 @@
/* PR debug/29609 */
/* Verify that breakpoint on both goto failure; stmts is hit. */
/* { dg-do compile } */
/* { dg-options "-O0 -gdwarf-2 -dA" } */
/* { dg-options "-O0 -gdwarf -dA" } */
extern void abort (void);
int x;

View File

@ -1,5 +1,5 @@
/* { dg-do compile } */
/* { dg-options "-gdwarf-2 -dA --param ggc-min-expand=0 --param ggc-min-heapsize=0" } */
/* { dg-options "-gdwarf -dA --param ggc-min-expand=0 --param ggc-min-heapsize=0" } */
/* { dg-final { scan-assembler-times "DIE.*DW_TAG_array_type" 1 } } */
/* { dg-final { scan-assembler-times "DIE.*DW_TAG_subrange_type" 1 } } */

View File

@ -1,7 +1,7 @@
/* PR debug/36690 */
/* Verify that break func is hit. */
/* { dg-do compile } */
/* { dg-options "-O0 -gdwarf-2 -dA" } */
/* { dg-options "-O0 -gdwarf -dA" } */
int i;

View File

@ -3,7 +3,7 @@
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" } */
/* { dg-options "-O0 -gdwarf -dA" } */
int cnt;

View File

@ -1,6 +1,6 @@
/* PR debug/36690 */
/* { dg-do compile } */
/* { dg-options "-O0 -gdwarf-2 -dA" } */
/* { dg-options "-O0 -gdwarf -dA" } */
int cnt;

View File

@ -2,7 +2,7 @@
/* 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" } */
/* { dg-options "-O0 -gdwarf -dA" } */
extern void abort (void);

View File

@ -1,6 +1,6 @@
/* PR debug/51410 */
/* { dg-do compile } */
/* { dg-options "-O0 -gdwarf-2 -dA -fno-merge-debug-strings" } */
/* { dg-options "-O0 -gdwarf -dA -fno-merge-debug-strings" } */
int x;

View File

@ -1,5 +1,5 @@
/* { dg-do compile } */
/* { dg-options "-O0 -gdwarf-2 -dA" } */
/* { dg-options "-O0 -gdwarf -dA" } */
#define True 1
#define False 0

View File

@ -1,5 +1,5 @@
/* { dg-do compile } */
/* { dg-options "-O2 -gdwarf-2" } */
/* { dg-options "-O2 -gdwarf" } */
void
main(void)
{

View File

@ -1,6 +1,6 @@
/* PR 23190 */
/* { dg-do compile }
/* { dg-options "-gdwarf-2 -dA -fno-merge-debug-strings" } */
/* { dg-options "-gdwarf -dA -fno-merge-debug-strings" } */
/* { dg-final { scan-assembler "xyzzy\[^\\n\\r\]+DW_AT_name" } } */
void f(void)

View File

@ -1,6 +1,6 @@
/* PR 23190 */
/* { dg-do compile }
/* { dg-options "-O2 -gdwarf-2 -dA" } */
/* { dg-options "-O2 -gdwarf -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" } } */