diff options
Diffstat (limited to 'ld/testsuite')
-rw-r--r-- | ld/testsuite/ld-ctf/conflicting-cycle-1.parent.d | 4 | ||||
-rw-r--r-- | ld/testsuite/ld-ctf/cross-tu-cyclic-conflicting.d | 4 | ||||
-rw-r--r-- | ld/testsuite/ld-ctf/forward.c | 2 | ||||
-rw-r--r-- | ld/testsuite/ld-ctf/forward.d | 23 |
4 files changed, 29 insertions, 4 deletions
diff --git a/ld/testsuite/ld-ctf/conflicting-cycle-1.parent.d b/ld/testsuite/ld-ctf/conflicting-cycle-1.parent.d index 4cbe9b6..5da66fda 100644 --- a/ld/testsuite/ld-ctf/conflicting-cycle-1.parent.d +++ b/ld/testsuite/ld-ctf/conflicting-cycle-1.parent.d @@ -29,8 +29,8 @@ Contents of CTF section .ctf: #... Types: #... - 0x[0-9a-f]*: struct B \(.* - *\[0x0\] \(ID 0x[0-9a-f]*\) \(kind 9\) struct B \(.* + 0x[0-9a-f]*: struct B + *\[0x0\] \(ID 0x[0-9a-f]*\) \(kind 9\) struct B #... CTF archive member: .*: #... diff --git a/ld/testsuite/ld-ctf/cross-tu-cyclic-conflicting.d b/ld/testsuite/ld-ctf/cross-tu-cyclic-conflicting.d index 3c975eb..eff295e 100644 --- a/ld/testsuite/ld-ctf/cross-tu-cyclic-conflicting.d +++ b/ld/testsuite/ld-ctf/cross-tu-cyclic-conflicting.d @@ -23,8 +23,8 @@ Contents of CTF section \.ctf: 0x[0-9a-f]*: int \[0x0:0x[0-9a-f]*\] \(size 0x[0-9a-f]*\) *\[0x0\] \(ID 0x[0-9a-f]*\) \(kind 1\) int:[0-9]* \(aligned at 0x[0-9a-f]*, format 0x1, offset:bits 0x0:0x[0-9a-f]*\) #... - 0x[0-9a-f]*: struct A .* - *\[0x0\] \(ID 0x[0-9a-f]*\) \(kind 9\) struct A .* + 0x[0-9a-f]*: struct A + *\[0x0\] \(ID 0x[0-9a-f]*\) \(kind 9\) struct A #... 0x[0-9a-f]*: struct C .* *\[0x0\] \(ID 0x[0-9a-f]*\) \(kind 6\) struct C .* diff --git a/ld/testsuite/ld-ctf/forward.c b/ld/testsuite/ld-ctf/forward.c new file mode 100644 index 0000000..e41a7ae --- /dev/null +++ b/ld/testsuite/ld-ctf/forward.c @@ -0,0 +1,2 @@ +struct foo; +struct foo *bar __attribute__((used)); diff --git a/ld/testsuite/ld-ctf/forward.d b/ld/testsuite/ld-ctf/forward.d new file mode 100644 index 0000000..9ff0dd2 --- /dev/null +++ b/ld/testsuite/ld-ctf/forward.d @@ -0,0 +1,23 @@ +#as: +#source: forward.c +#objdump: --ctf=.ctf +#ld: -shared +#name: Forwards + +.*: +file format .* + +Contents of CTF section .ctf: + + Header: + Magic number: 0xdff2 + Version: 4 \(CTF_VERSION_3\) +#... + Type section: .* \(0x18 bytes\) +#... + Types: + + 0x[0-9a-f]: struct foo + *\[0x0\] \(ID 0x[0-9a-f]*\) \(kind 9\) struct foo + 0x[0-9a-f]: struct foo \* \(size 0x[0-9a-f]*\) -> 0x[0-9a-f]: struct foo + *\[0x0\] \(ID 0x[0-9a-f]\) \(kind 3\) struct foo \* \(aligned at 0x[0-9a-f]*\) +#... |