Skip to content
Commit a9cefc3d authored by Christian Iversen's avatar Christian Iversen Committed by Fangrui Song
Browse files

[ELF] Fix broken bitstream linking with lld when e_machine > 255

In ELF/InputFiles.cpp, getBitcodeMachineKind() is limited to uint8_t return
type. This works as long as EM_xxx is < 256, which is true for common
architectures, but not for some newly assigned or unofficial EM_* values.

The corresponding ELF field (e_machine) can hold uint16_t.

Reviewed By: MaskRay

Differential Revision: https://reviews.llvm.org/D89185
parent 8178e41d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment