]> git.ipfire.org Git - thirdparty/gcc.git/commit
libiberty, Darwin : Fix simple-object LTO table for cross-endian case.
authorIain Sandoe <iain@sandoe.co.uk>
Fri, 9 Apr 2021 12:40:11 +0000 (13:40 +0100)
committerIain Sandoe <iain@sandoe.co.uk>
Wed, 18 Aug 2021 18:33:49 +0000 (19:33 +0100)
commit220c410162ebece4fffa2912ed79e348d3731d77
tree8198223ef5e41232252406ab2828b088a4ff1aa8
parent15bdae016654f63a36e49a37c9d26282bebb1da9
libiberty, Darwin : Fix simple-object LTO table for cross-endian case.

We encapsulate streamed IR in three special sections with a table
that describes their entries.  The table is expected to be written
with native endianness for the target, but for cross-endian cross-
compilation the swapping was omitted.  Fixed thus.

Signed-off-by: Iain Sandoe <iain@sandoe.co.uk>
libiberty/ChangeLog:

* simple-object-mach-o.c (simple_object_mach_o_write_segment):
Arrange to swap the LTO index tables where needed.
libiberty/simple-object-mach-o.c