+2014-12-04 Maciej W. Rozycki <macro@codesourcery.com>
+
+ * gdb.cp/expand-psymtabs-cxx.exp: Accept any address of
+ `method(long)', not just 0x0.
+ * gdb.cp/nsalias.exp: Align code labels to 4.
+ * gdb.dwarf2/dw2-canonicalize-type.S (main): Expand to 4-bytes.
+ * gdb.dwarf2/dw2-empty-pc-range.S (main): Likewise.
+ * gdb.dwarf2/pr11465.S (_ZN1N1cE): Likewise.
+ * gdb.dwarf2/dw2-case-insensitive.c (START_INSNS): New macro.
+ (cu_text_start, FUNC_lang_start): Use `START_INSNS'.
+ * gdb.dwarf2/dw2-stack-boundary.exp: Accept noise in complaints.
+
2014-12-02 Doug Evans <dje@google.com>
PR symtab/17602
# FAIL was:
# $1 = {<text variable, no debug info>} 0
-gdb_test "p 'method(long)'" { = {void \(long\)} 0x0 <method.long.>} \
+gdb_test "p 'method(long)'" " = {void \\(long\\)} $hex <method.long.>" \
"before expand"
-gdb_test "p method" { = {void \(long\)} 0x0 <method.long.>} \
+gdb_test "p method" " = {void \\(long\\)} $hex <method.long.>" \
"force expand"
-gdb_test "p 'method(long)'" { = {void \(long\)} 0x0 <method.long.>} \
+gdb_test "p 'method(long)'" " = {void \\(long\\)} $hex <method.long.>" \
"after expand"
subprogram {
{specification :$im_foo_label}
- {low_pc 0x1 DW_FORM_addr}
- {high_pc 0x2 DW_FORM_addr}
+ {low_pc 0x4 DW_FORM_addr}
+ {high_pc 0x7 DW_FORM_addr}
}
subprogram {
{specification :$i_foo_label}
- {low_pc 0x3 DW_FORM_addr}
- {high_pc 0x4 DW_FORM_addr}
+ {low_pc 0x8 DW_FORM_addr}
+ {high_pc 0xb DW_FORM_addr}
}
subprogram {
{specification :$o_foo_label}
- {low_pc 0x5 DW_FORM_addr}
- {high_pc 0x6 DW_FORM_addr}
+ {low_pc 0xc DW_FORM_addr}
+ {high_pc 0xf DW_FORM_addr}
}
}
}
.text
.globl main
-main: .byte 0
+main:
+ .4byte 0
.Lmain_end:
.section .debug_info
debug_start:
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+/* Target-specific way of forcing an instruction label. */
+#ifdef __mips__
+#define START_INSNS asm (".insn");
+#else
+#define START_INSNS
+#endif
+
/* Use DW_LANG_Fortran90 for case insensitive DWARF. */
asm (".globl cu_text_start");
asm ("cu_text_start:");
+START_INSNS
asm (".globl FUNC_lang_start");
asm (".p2align 4");
asm ("FUNC_lang_start:");
+START_INSNS
void
FUNC_lang (void)
.text
pc_start:
- .byte 0
+ .4byte 0
pc_end:
.section .debug_info
}
}
gdb_test_no_output "set complaints 100"
-gdb_test "file $binfile" {Reading symbols from .*\.\.\.location description stack underflow\.\.\.location description stack overflow\.\.\.done\.} "check partial symtab errors"
+gdb_test "file $binfile" {Reading symbols from .*\.\.\.location description stack underflow\.\.\.location description stack overflow\.\.\..*done\.} "check partial symtab errors"
gdb_test "p underflow" {Asked for position 0 of stack, stack only has 0 elements on it\.}
gdb_test "p overflow" " = 2"
text_start:
_ZN1N1cE:
/* Valid function must have non-empty PC range. */
- .byte 0
+ .4byte 0
text_end:
.section .debug_info
dieb4: .uleb128 0xf /* DW_TAG_subprogram */
.4byte die95-d /* DW_AT_abstract_origin */
.4byte _ZN1N1cE /* DW_AT_low_pc */
- .4byte _ZN1N1cE + 1 /* DW_AT_high_pc */
+ .4byte _ZN1N1cE + (text_end - text_start)
+ /* DW_AT_high_pc */
diec9: .uleb128 0x10 /* DW_TAG_subprogram */
.4byte die9f-d /* DW_AT_abstract_origin */
.byte 2f-1f /* DW_AT_location */
.4byte .LASF8 /* DW_AT_name */
.4byte dief2-d /* DW_AT_type */
.4byte _ZN1N1cE /* DW_AT_low_pc */
- .4byte _ZN1N1cE + 1 /* DW_AT_high_pc */
+ .4byte _ZN1N1cE + (text_end - text_start)
+ /* DW_AT_high_pc */
dief2: .uleb128 0x12 /* DW_TAG_base_type */
.byte 0x4 /* DW_AT_byte_size */
.byte 0x5 /* DW_AT_encoding */