diff options
author | Koakuma <koachan@protonmail.com> | 2024-07-03 19:14:39 +0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-07-03 19:14:39 +0700 |
commit | fb7f65ba468f462103599e762c86f49b420cd984 (patch) | |
tree | bc4f6da68eb9163a99a7dc5c2bb1deb0af4a49c1 /lldb/source/Plugins/ScriptInterpreter/Python/SWIGPythonBridge.h | |
parent | 52cc7c003a2851e66586dc15c6dc813355e147c6 (diff) | |
download | llvm-fb7f65ba468f462103599e762c86f49b420cd984.zip llvm-fb7f65ba468f462103599e762c86f49b420cd984.tar.gz llvm-fb7f65ba468f462103599e762c86f49b420cd984.tar.bz2 |
[SPARC][IAS] Emit the correct ELF machine type (#96583)
Emit the correct machine type when writing out ELF objects.
This patch is modeled on GCC's behavior:
- `-m32` emits an object of type EM_SPARC;
- `-m32 -mcpu=v9` emits EM_SPARC32PLUS (however, see below); and
- `-m64` emits EM_SPARCV9.
Note that GCC does not guarantee emission of EM_SPARC32PLUS objects,
since GNU as doesn't support user control of emitted machine type.
It will always autodetect the type based on the instruction mix:
- If there's a V9 instruction inside, then emit EM_SPARC32PLUS; and
- Emit EM_SPARC otherwise.
For LLVM we choose deterministic behavior instead for simplicity.
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/SWIGPythonBridge.h')
0 files changed, 0 insertions, 0 deletions