New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
llvm-objcopy: "error: invalid symbol index" with mips64el-linux-gnuabi64 #52647
Comments
I think the problem is in The fix will be to pass this information to these functions, and quite possibly other functions in the code (I see a reference to Unfortunately, my MIPS knowledge is limited, so I don't know how to get the proper value for the |
I will take a look at this bug. |
The fix is in the https://reviews.llvm.org/D115635. |
MIPS64 little endian target has a "special" encoding of `r_info` relocation record field. Instead of one 64-bit little endian number, it is a little endian 32-bit number followed by a 32-bit big endian number. For correct reading and writing such fields we must provide information about target machine into the corresponding routine. This patch does this for the `llvm-objcopy` tool and fix handling of MIPS64 little endian files. The bug was reported in the issue #52647. Differential Revision: https://reviews.llvm.org/D115635
Thanks Simon! |
Initial reported and triaged at ClangBuiltLinux/linux#1534.
While building the Linux kernel with
OBJCOPY=llvm-objcopy
, the following error is observed:This appears to be related to the use of
-EL
and-mabi=64
. A very simple C reproducer:It does not happen with
mips64-linux-gnuabi64
or 32-bit MIPS targets.The text was updated successfully, but these errors were encountered: