diff options
author | Nick Alcock <nick.alcock@oracle.com> | 2021-10-25 11:17:02 +0100 |
---|---|---|
committer | Nick Alcock <nick.alcock@oracle.com> | 2021-10-25 11:17:03 +0100 |
commit | 10909ea819417549886daf2fea983cc42cd6c734 (patch) | |
tree | 5e3efa946bd95255e7b22f852f2122e23cf5dabc /ld | |
parent | 80b56fad5c99a8c93004b0432dd2b363125de35a (diff) | |
download | binutils-10909ea819417549886daf2fea983cc42cd6c734.zip binutils-10909ea819417549886daf2fea983cc42cd6c734.tar.gz binutils-10909ea819417549886daf2fea983cc42cd6c734.tar.bz2 |
binutils, ld: make objdump --ctf's parameter optional
ld by default (and always, unless adjusted with a hand-rolled linker
script) emits deduplicated CTF into the .ctf section. But viewing
it needs you to explicitly tell objdump this: it doesn't default
its argument, even though what you always end up typing is
--ctf=.ctf.
This is annoying, so make the argument optional.
binutils/ChangeLog
2021-10-25 Nick Alcock <nick.alcock@oracle.com>
* objdump.c (usage): --ctf now has an optional argument.
(main): Adjust accordingly.
(dump_ctf): Default it.
* doc/ctf.options.texi: Adjust.
ld/ChangeLog
2021-10-25 Nick Alcock <nick.alcock@oracle.com>
* testsuite/ld-ctf/array.d: Change --ctf=.ctf to --ctf.
* testsuite/ld-ctf/conflicting-cycle-1.B-1.d: Likewise.
* testsuite/ld-ctf/conflicting-cycle-1.B-2.d: Likewise.
* testsuite/ld-ctf/conflicting-cycle-1.parent.d: Likewise.
* testsuite/ld-ctf/conflicting-cycle-2.A-1.d: Likewise.
* testsuite/ld-ctf/conflicting-cycle-2.A-2.d: Likewise.
* testsuite/ld-ctf/conflicting-cycle-2.parent.d: Likewise.
* testsuite/ld-ctf/conflicting-cycle-3.C-1.d: Likewise.
* testsuite/ld-ctf/conflicting-cycle-3.C-2.d: Likewise.
* testsuite/ld-ctf/conflicting-cycle-3.parent.d: Likewise.
* testsuite/ld-ctf/conflicting-enums.d: Likewise.
* testsuite/ld-ctf/conflicting-typedefs.d: Likewise.
* testsuite/ld-ctf/cross-tu-cyclic-conflicting.d: Likewise.
* testsuite/ld-ctf/cross-tu-cyclic-nonconflicting.d: Likewise.
* testsuite/ld-ctf/cross-tu-into-cycle.d: Likewise.
* testsuite/ld-ctf/cross-tu-noncyclic.d: Likewise.
* testsuite/ld-ctf/cycle-1.d: Likewise.
* testsuite/ld-ctf/cycle-2.A.d: Likewise.
* testsuite/ld-ctf/cycle-2.B.d: Likewise.
* testsuite/ld-ctf/cycle-2.C.d: Likewise.
* testsuite/ld-ctf/data-func-conflicted.d: Likewise.
* testsuite/ld-ctf/diag-cttname-null.d: Likewise.
* testsuite/ld-ctf/diag-cuname.d: Likewise.
* testsuite/ld-ctf/diag-parlabel.d: Likewise.
* testsuite/ld-ctf/enum-forward.d: Likewise.
* testsuite/ld-ctf/enums.d: Likewise.
* testsuite/ld-ctf/forward.d: Likewise.
* testsuite/ld-ctf/function.d: Likewise.
* testsuite/ld-ctf/nonrepresentable.d: Likewise.
* testsuite/ld-ctf/slice.d: Likewise.
* testsuite/ld-ctf/super-sub-cycles.d: Likewise.
Diffstat (limited to 'ld')
32 files changed, 65 insertions, 31 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog index 808191b..470e446 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,37 @@ +2021-10-25 Nick Alcock <nick.alcock@oracle.com> + + * testsuite/ld-ctf/array.d: Change --ctf=.ctf to --ctf. + * testsuite/ld-ctf/conflicting-cycle-1.B-1.d: Likewise. + * testsuite/ld-ctf/conflicting-cycle-1.B-2.d: Likewise. + * testsuite/ld-ctf/conflicting-cycle-1.parent.d: Likewise. + * testsuite/ld-ctf/conflicting-cycle-2.A-1.d: Likewise. + * testsuite/ld-ctf/conflicting-cycle-2.A-2.d: Likewise. + * testsuite/ld-ctf/conflicting-cycle-2.parent.d: Likewise. + * testsuite/ld-ctf/conflicting-cycle-3.C-1.d: Likewise. + * testsuite/ld-ctf/conflicting-cycle-3.C-2.d: Likewise. + * testsuite/ld-ctf/conflicting-cycle-3.parent.d: Likewise. + * testsuite/ld-ctf/conflicting-enums.d: Likewise. + * testsuite/ld-ctf/conflicting-typedefs.d: Likewise. + * testsuite/ld-ctf/cross-tu-cyclic-conflicting.d: Likewise. + * testsuite/ld-ctf/cross-tu-cyclic-nonconflicting.d: Likewise. + * testsuite/ld-ctf/cross-tu-into-cycle.d: Likewise. + * testsuite/ld-ctf/cross-tu-noncyclic.d: Likewise. + * testsuite/ld-ctf/cycle-1.d: Likewise. + * testsuite/ld-ctf/cycle-2.A.d: Likewise. + * testsuite/ld-ctf/cycle-2.B.d: Likewise. + * testsuite/ld-ctf/cycle-2.C.d: Likewise. + * testsuite/ld-ctf/data-func-conflicted.d: Likewise. + * testsuite/ld-ctf/diag-cttname-null.d: Likewise. + * testsuite/ld-ctf/diag-cuname.d: Likewise. + * testsuite/ld-ctf/diag-parlabel.d: Likewise. + * testsuite/ld-ctf/enum-forward.d: Likewise. + * testsuite/ld-ctf/enums.d: Likewise. + * testsuite/ld-ctf/forward.d: Likewise. + * testsuite/ld-ctf/function.d: Likewise. + * testsuite/ld-ctf/nonrepresentable.d: Likewise. + * testsuite/ld-ctf/slice.d: Likewise. + * testsuite/ld-ctf/super-sub-cycles.d: Likewise. + 2021-09-30 Dimitar Dimitrov <dimitar@dinux.eu> * scripttempl/pru.sc (.resource_table): Align the output diff --git a/ld/testsuite/ld-ctf/array.d b/ld/testsuite/ld-ctf/array.d index 142f9e9..0fe675e 100644 --- a/ld/testsuite/ld-ctf/array.d +++ b/ld/testsuite/ld-ctf/array.d @@ -1,7 +1,7 @@ #as: #source: array-char.c #source: array-int.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables --hash-style=sysv #name: Arrays diff --git a/ld/testsuite/ld-ctf/conflicting-cycle-1.B-1.d b/ld/testsuite/ld-ctf/conflicting-cycle-1.B-1.d index 27273c5..2ed3ce1 100644 --- a/ld/testsuite/ld-ctf/conflicting-cycle-1.B-1.d +++ b/ld/testsuite/ld-ctf/conflicting-cycle-1.B-1.d @@ -4,7 +4,7 @@ #source: B.c #source: B-2.c #source: C.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Conflicting cycle 1.B-1 diff --git a/ld/testsuite/ld-ctf/conflicting-cycle-1.B-2.d b/ld/testsuite/ld-ctf/conflicting-cycle-1.B-2.d index 28a92f4..3b9b7f6 100644 --- a/ld/testsuite/ld-ctf/conflicting-cycle-1.B-2.d +++ b/ld/testsuite/ld-ctf/conflicting-cycle-1.B-2.d @@ -4,7 +4,7 @@ #source: B.c #source: B-2.c #source: C.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Conflicting cycle 1.B-2 diff --git a/ld/testsuite/ld-ctf/conflicting-cycle-1.parent.d b/ld/testsuite/ld-ctf/conflicting-cycle-1.parent.d index a9755e8..83c56fe 100644 --- a/ld/testsuite/ld-ctf/conflicting-cycle-1.parent.d +++ b/ld/testsuite/ld-ctf/conflicting-cycle-1.parent.d @@ -4,7 +4,7 @@ #source: B.c #source: B-2.c #source: C.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Conflicting cycle 1.parent diff --git a/ld/testsuite/ld-ctf/conflicting-cycle-2.A-1.d b/ld/testsuite/ld-ctf/conflicting-cycle-2.A-1.d index 33ed6e8..6a07d36 100644 --- a/ld/testsuite/ld-ctf/conflicting-cycle-2.A-1.d +++ b/ld/testsuite/ld-ctf/conflicting-cycle-2.A-1.d @@ -6,7 +6,7 @@ #source: B-2.c #source: C.c #source: C-2.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Conflicting cycle 2.A-1 diff --git a/ld/testsuite/ld-ctf/conflicting-cycle-2.A-2.d b/ld/testsuite/ld-ctf/conflicting-cycle-2.A-2.d index a98b66c..6775421 100644 --- a/ld/testsuite/ld-ctf/conflicting-cycle-2.A-2.d +++ b/ld/testsuite/ld-ctf/conflicting-cycle-2.A-2.d @@ -6,7 +6,7 @@ #source: B-2.c #source: C.c #source: C-2.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Conflicting cycle 2.A-2 diff --git a/ld/testsuite/ld-ctf/conflicting-cycle-2.parent.d b/ld/testsuite/ld-ctf/conflicting-cycle-2.parent.d index 87ec41d..30be9b0 100644 --- a/ld/testsuite/ld-ctf/conflicting-cycle-2.parent.d +++ b/ld/testsuite/ld-ctf/conflicting-cycle-2.parent.d @@ -6,7 +6,7 @@ #source: B-2.c #source: C.c #source: C-2.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Conflicting cycle 2.parent diff --git a/ld/testsuite/ld-ctf/conflicting-cycle-3.C-1.d b/ld/testsuite/ld-ctf/conflicting-cycle-3.C-1.d index ac750a7..b60768f 100644 --- a/ld/testsuite/ld-ctf/conflicting-cycle-3.C-1.d +++ b/ld/testsuite/ld-ctf/conflicting-cycle-3.C-1.d @@ -5,7 +5,7 @@ #source: B-2.c #source: C.c #source: C-2.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Conflicting cycle 3.C-1 diff --git a/ld/testsuite/ld-ctf/conflicting-cycle-3.C-2.d b/ld/testsuite/ld-ctf/conflicting-cycle-3.C-2.d index 603432f..590d373 100644 --- a/ld/testsuite/ld-ctf/conflicting-cycle-3.C-2.d +++ b/ld/testsuite/ld-ctf/conflicting-cycle-3.C-2.d @@ -5,7 +5,7 @@ #source: B-2.c #source: C.c #source: C-2.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Conflicting cycle 3.C-2 diff --git a/ld/testsuite/ld-ctf/conflicting-cycle-3.parent.d b/ld/testsuite/ld-ctf/conflicting-cycle-3.parent.d index 24f0800..dbe2e46 100644 --- a/ld/testsuite/ld-ctf/conflicting-cycle-3.parent.d +++ b/ld/testsuite/ld-ctf/conflicting-cycle-3.parent.d @@ -5,7 +5,7 @@ #source: B-2.c #source: C.c #source: C-2.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared #name: Conflicting cycle 3 diff --git a/ld/testsuite/ld-ctf/conflicting-enums.d b/ld/testsuite/ld-ctf/conflicting-enums.d index 5eeae7a..4f8cf81 100644 --- a/ld/testsuite/ld-ctf/conflicting-enums.d +++ b/ld/testsuite/ld-ctf/conflicting-enums.d @@ -1,7 +1,7 @@ #as: #source: enum.c #source: enum-2.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared #name: Conflicting Enums diff --git a/ld/testsuite/ld-ctf/conflicting-typedefs.d b/ld/testsuite/ld-ctf/conflicting-typedefs.d index 72082ba..4ae8de4 100644 --- a/ld/testsuite/ld-ctf/conflicting-typedefs.d +++ b/ld/testsuite/ld-ctf/conflicting-typedefs.d @@ -1,7 +1,7 @@ #as: #source: typedef-int.c #source: typedef-long.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared #name: Conflicting Typedefs diff --git a/ld/testsuite/ld-ctf/cross-tu-cyclic-conflicting.d b/ld/testsuite/ld-ctf/cross-tu-cyclic-conflicting.d index 6d5e869..0fba1b4 100644 --- a/ld/testsuite/ld-ctf/cross-tu-cyclic-conflicting.d +++ b/ld/testsuite/ld-ctf/cross-tu-cyclic-conflicting.d @@ -3,7 +3,7 @@ #as: #source: cross-tu-cyclic-1.c #source: cross-tu-cyclic-2.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared #name: cross-TU-cyclic-conflicting diff --git a/ld/testsuite/ld-ctf/cross-tu-cyclic-nonconflicting.d b/ld/testsuite/ld-ctf/cross-tu-cyclic-nonconflicting.d index 1a71484..c83789a 100644 --- a/ld/testsuite/ld-ctf/cross-tu-cyclic-nonconflicting.d +++ b/ld/testsuite/ld-ctf/cross-tu-cyclic-nonconflicting.d @@ -5,7 +5,7 @@ #as: #source: cross-tu-2.c #source: cross-tu-cyclic-1.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: cross-TU-cyclic-nonconflicting diff --git a/ld/testsuite/ld-ctf/cross-tu-into-cycle.d b/ld/testsuite/ld-ctf/cross-tu-into-cycle.d index 7f3aebc..903dedb 100644 --- a/ld/testsuite/ld-ctf/cross-tu-into-cycle.d +++ b/ld/testsuite/ld-ctf/cross-tu-into-cycle.d @@ -7,7 +7,7 @@ #as: #source: cross-tu-cyclic-3.c #source: cross-tu-cyclic-4.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: cross-TU-into-cycle diff --git a/ld/testsuite/ld-ctf/cross-tu-noncyclic.d b/ld/testsuite/ld-ctf/cross-tu-noncyclic.d index 3ebc52d..28c2eb4 100644 --- a/ld/testsuite/ld-ctf/cross-tu-noncyclic.d +++ b/ld/testsuite/ld-ctf/cross-tu-noncyclic.d @@ -3,7 +3,7 @@ #as: #source: cross-tu-1.c #source: cross-tu-2.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: cross-TU-noncyclic diff --git a/ld/testsuite/ld-ctf/cycle-1.d b/ld/testsuite/ld-ctf/cycle-1.d index e64608e..379f12f 100644 --- a/ld/testsuite/ld-ctf/cycle-1.d +++ b/ld/testsuite/ld-ctf/cycle-1.d @@ -3,7 +3,7 @@ #source: A.c #source: B.c #source: C.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Cycle 1 diff --git a/ld/testsuite/ld-ctf/cycle-2.A.d b/ld/testsuite/ld-ctf/cycle-2.A.d index 39d48c1..ab3876c 100644 --- a/ld/testsuite/ld-ctf/cycle-2.A.d +++ b/ld/testsuite/ld-ctf/cycle-2.A.d @@ -2,7 +2,7 @@ #source: A.c #source: B.c #source: C.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Cycle 2.A diff --git a/ld/testsuite/ld-ctf/cycle-2.B.d b/ld/testsuite/ld-ctf/cycle-2.B.d index 4babd97..65d702e 100644 --- a/ld/testsuite/ld-ctf/cycle-2.B.d +++ b/ld/testsuite/ld-ctf/cycle-2.B.d @@ -2,7 +2,7 @@ #source: A.c #source: B.c #source: C.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Cycle 2.B diff --git a/ld/testsuite/ld-ctf/cycle-2.C.d b/ld/testsuite/ld-ctf/cycle-2.C.d index 757483c..81aa6dd 100644 --- a/ld/testsuite/ld-ctf/cycle-2.C.d +++ b/ld/testsuite/ld-ctf/cycle-2.C.d @@ -2,7 +2,7 @@ #source: A.c #source: B.c #source: C.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Cycle 2.C diff --git a/ld/testsuite/ld-ctf/data-func-conflicted.d b/ld/testsuite/ld-ctf/data-func-conflicted.d index f4f4fdd..7a1b2d7 100644 --- a/ld/testsuite/ld-ctf/data-func-conflicted.d +++ b/ld/testsuite/ld-ctf/data-func-conflicted.d @@ -1,7 +1,7 @@ #as: #source: data-func-1.c #source: data-func-2.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared -s #name: Conflicted data syms, partially indexed, stripped diff --git a/ld/testsuite/ld-ctf/diag-cttname-null.d b/ld/testsuite/ld-ctf/diag-cttname-null.d index d1ca0b1..511908e 100644 --- a/ld/testsuite/ld-ctf/diag-cttname-null.d +++ b/ld/testsuite/ld-ctf/diag-cttname-null.d @@ -1,6 +1,6 @@ #as: #source: diag-cttname-null.s -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Diagnostics - Null type name diff --git a/ld/testsuite/ld-ctf/diag-cuname.d b/ld/testsuite/ld-ctf/diag-cuname.d index e4d4926..d858b5f 100644 --- a/ld/testsuite/ld-ctf/diag-cuname.d +++ b/ld/testsuite/ld-ctf/diag-cuname.d @@ -1,6 +1,6 @@ #as: #source: diag-cuname.s -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Diagnostics - Invalid CU name offset diff --git a/ld/testsuite/ld-ctf/diag-parlabel.d b/ld/testsuite/ld-ctf/diag-parlabel.d index 9d2c086..892970b 100644 --- a/ld/testsuite/ld-ctf/diag-parlabel.d +++ b/ld/testsuite/ld-ctf/diag-parlabel.d @@ -1,6 +1,6 @@ #as: #source: diag-parlabel.s -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Diagnostics - Non-zero parlabel in parent diff --git a/ld/testsuite/ld-ctf/enum-forward.d b/ld/testsuite/ld-ctf/enum-forward.d index a83651e..c53364e 100644 --- a/ld/testsuite/ld-ctf/enum-forward.d +++ b/ld/testsuite/ld-ctf/enum-forward.d @@ -1,6 +1,6 @@ #as: #source: enum-forward.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared #name: Forwards to enums diff --git a/ld/testsuite/ld-ctf/enums.d b/ld/testsuite/ld-ctf/enums.d index d36c7e1..501c18f 100644 --- a/ld/testsuite/ld-ctf/enums.d +++ b/ld/testsuite/ld-ctf/enums.d @@ -1,6 +1,6 @@ #as: #source: enums.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared #name: Enumerated types diff --git a/ld/testsuite/ld-ctf/forward.d b/ld/testsuite/ld-ctf/forward.d index bb92961..5998ecb 100644 --- a/ld/testsuite/ld-ctf/forward.d +++ b/ld/testsuite/ld-ctf/forward.d @@ -1,6 +1,6 @@ #as: #source: forward.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared #name: Forwards diff --git a/ld/testsuite/ld-ctf/function.d b/ld/testsuite/ld-ctf/function.d index e6cb209..66c67eb 100644 --- a/ld/testsuite/ld-ctf/function.d +++ b/ld/testsuite/ld-ctf/function.d @@ -1,6 +1,6 @@ #as: #source: function.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared #name: Function diff --git a/ld/testsuite/ld-ctf/nonrepresentable.d b/ld/testsuite/ld-ctf/nonrepresentable.d index 8461b54..610558f 100644 --- a/ld/testsuite/ld-ctf/nonrepresentable.d +++ b/ld/testsuite/ld-ctf/nonrepresentable.d @@ -1,7 +1,7 @@ #as: #source: nonrepresentable-1.c #source: nonrepresentable-2.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared #name: Nonrepresentable types diff --git a/ld/testsuite/ld-ctf/slice.d b/ld/testsuite/ld-ctf/slice.d index 8973dcf..838607f 100644 --- a/ld/testsuite/ld-ctf/slice.d +++ b/ld/testsuite/ld-ctf/slice.d @@ -1,6 +1,6 @@ #as: #source: slice.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared --ctf-variables #name: Slice diff --git a/ld/testsuite/ld-ctf/super-sub-cycles.d b/ld/testsuite/ld-ctf/super-sub-cycles.d index 67fa358..4eb009d 100644 --- a/ld/testsuite/ld-ctf/super-sub-cycles.d +++ b/ld/testsuite/ld-ctf/super-sub-cycles.d @@ -1,6 +1,6 @@ #as: #source: super-sub-cycles.c -#objdump: --ctf=.ctf +#objdump: --ctf #ld: -shared #name: Super- and sub-cycles |