[llvm-branch-commits] [lld] [lld][LoongArch] Convert TLS IE to LE in the normal or medium code model (PR #123680)
Lu Weining via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Thu Mar 20 01:59:45 PDT 2025
================
@@ -1375,14 +1375,20 @@ unsigned RelocationScanner::handleTlsRelocation(RelExpr expr, RelType type,
return 1;
}
+ // LoongArch support IE to LE optimization in non-extreme code model.
+ bool execOptimizeInLoongArch =
+ ctx.arg.emachine == EM_LOONGARCH &&
+ (type == R_LARCH_TLS_IE_PC_HI20 || type == R_LARCH_TLS_IE_PC_LO12);
----------------
SixWeining wrote:
R_LARCH_TLS_IE_PC_HI20 and R_LARCH_TLS_IE_PC_LO12 are also used by the extreme code model. Is this condition reliable?
https://github.com/llvm/llvm-project/pull/123680
More information about the llvm-branch-commits
mailing list