[lld] [lld] Add target support for SystemZ (s390x) (PR #75643)

Ulrich Weigand via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 8 06:02:01 PST 2024


uweigand wrote:

I see, that appears to be an endian bug in the kernel makefiles:
```
+	# Change e_type to ET_REL so that it can be used to link final vmlinux.
+	# Unlike GNU ld, lld does not allow an ET_EXEC input.
+	printf '\1' | dd of=${2} conv=notrunc bs=1 seek=16 status=none
```
introduced here: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=90ceddcb495008ac8ba7a3dce297841efcd7d584

On a big-endian platform, instead of changing `e_type` from 0x03 to 0x01, this command changes it to 0x0103.


https://github.com/llvm/llvm-project/pull/75643


More information about the llvm-commits mailing list