Fix more cases of improper test names
[deliverable/binutils-gdb.git] / gdb / testsuite / gdb.dwarf2 / atomic-type.exp
index e2a3447322dc62adb38db2fa3334d01196ef4a46..319f76faef605c9000a6a48e3b34f32d733df6eb 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2014, 2015 Free Software Foundation, Inc.
+# Copyright 2014-2016 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
@@ -25,6 +25,12 @@ standard_testfile atomic.c atomic-type-dw.S
 
 set asm_file [standard_output_file $srcfile2]
 Dwarf::assemble $asm_file {
+    global srcdir subdir srcfile
+
+    set f_result [function_range f ${srcdir}/${subdir}/${srcfile}]
+    set f_start [lindex $f_result 0]
+    set f_length [lindex $f_result 1]
+
     cu {} {
        DW_TAG_compile_unit {
                 {DW_AT_language @DW_LANG_C11}
@@ -68,8 +74,8 @@ Dwarf::assemble $asm_file {
 
             DW_TAG_subprogram {
                 {name f}
-                {low_pc [gdb_target_symbol f] addr}
-                {high_pc f_end_lbl addr}
+                {low_pc $f_start addr}
+                {high_pc "$f_start + $f_length" addr}
                 {type :$i_l}
             } {
                 DW_TAG_formal_parameter {
@@ -81,7 +87,7 @@ Dwarf::assemble $asm_file {
     }
 }
 
-if { [prepare_for_testing ${testfile}.exp ${testfile} \
+if { [prepare_for_testing "failed to prepare" ${testfile} \
          [list $srcfile $asm_file] {nodebug}] } {
     return -1
 }
This page took 0.025944 seconds and 4 git commands to generate.