[PATCH] D42998: [x86/retpoline] Make the external thunk names exactly match the names that happened to end up in GCC.
Chandler Carruth via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 6 19:43:39 PST 2018
chandlerc marked an inline comment as done.
chandlerc added inline comments.
================
Comment at: llvm/lib/Target/X86/X86ISelLowering.cpp:26969
+ // is costly.
switch (Reg) {
case 0:
----------------
rnk wrote:
> nit, think this would be cleaner as two switches?
> if (Subtarget.useRetpolineExternalThunk()) {
> switch (Ret) {
> case X86::EAX: return "__x86_indirect_thunk_eax";
> case X86::ECX: return "__x86_indirect_thunk_ecx";
> ...
> }
> } else {
> switch (Ret) {
> case X86::EAX: return "__llvm_retpoline_eax";
> case X86::ECX: return "__llvm_retpoline_ecx";
> ...
> }
> }
Sure.
Repository:
rL LLVM
https://reviews.llvm.org/D42998
More information about the llvm-commits
mailing list