diff options
author | Cary Coutant <ccoutant@google.com> | 2012-09-07 20:14:10 +0000 |
---|---|---|
committer | Cary Coutant <ccoutant@google.com> | 2012-09-07 20:14:10 +0000 |
commit | d2d60eefc4034426d1ec42476e518422299658cf (patch) | |
tree | a0b26a09fc31273c235d0d694235adf599b07399 /gold/testsuite | |
parent | aae628c13199b40d2e5f18a597e5b8cb38d91849 (diff) | |
download | gdb-d2d60eefc4034426d1ec42476e518422299658cf.zip gdb-d2d60eefc4034426d1ec42476e518422299658cf.tar.gz gdb-d2d60eefc4034426d1ec42476e518422299658cf.tar.bz2 |
2012-09-06 Cary Coutant <ccoutant@google.com>
gold/
* dwarf_reader.cc (Dwarf_die::read_attributes): Add
DW_FORM_GNU_addr_index and DW_FORM_GNU_str_index.
(Dwarf_die::skip_attributes): Likewise.
* object.cc (Read_symbols_data::~Read_symbols_data): Update comment.
* testsuite/gdb_index_test.cc (inline_func_1): New function.
(main): Call it.
* testsuite/gdb_index_test_comm.sh: Check index for inline function.
Diffstat (limited to 'gold/testsuite')
-rw-r--r-- | gold/testsuite/gdb_index_test.cc | 11 | ||||
-rwxr-xr-x | gold/testsuite/gdb_index_test_comm.sh | 1 |
2 files changed, 12 insertions, 0 deletions
diff --git a/gold/testsuite/gdb_index_test.cc b/gold/testsuite/gdb_index_test.cc index 342d47c..d5ac2f1 100644 --- a/gold/testsuite/gdb_index_test.cc +++ b/gold/testsuite/gdb_index_test.cc @@ -123,6 +123,16 @@ struct anonymous_union_container { anonymous_union_container anonymous_union_var; +#ifdef __GNUC__ +#define ALWAYS_INLINE __attribute__((always_inline)) +#else +#define ALWAYS_INLINE +#endif + +static inline ALWAYS_INLINE int +inline_func_1(int i) +{ return i * 17; } + int main() { @@ -134,5 +144,6 @@ main() check(&two::c2v1); check(&two::c2v2); check(&two::c2v3); + anonymous_union_var.u.b = inline_func_1(3) - 51; return anonymous_union_var.u.b; } diff --git a/gold/testsuite/gdb_index_test_comm.sh b/gold/testsuite/gdb_index_test_comm.sh index 7100329..4ab07b3 100755 --- a/gold/testsuite/gdb_index_test_comm.sh +++ b/gold/testsuite/gdb_index_test_comm.sh @@ -80,5 +80,6 @@ check $STDOUT "^\[ *[0-9]*\] two::c2<int>:" check $STDOUT "^\[ *[0-9]*\] two::c2v1:" check $STDOUT "^\[ *[0-9]*\] two::c2v2:" check $STDOUT "^\[ *[0-9]*\] anonymous_union_var:" +check $STDOUT "^\[ *[0-9]*\] inline_func_1:" exit 0 |