[PATCH] D129977: [LoongArch] Support load/store of dso_local PIC global values
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Jul 17 21:41:37 PDT 2022
MaskRay added a comment.
In D129977#3658602 <https://reviews.llvm.org/D129977#3658602>, @wangleiat wrote:
> Thanks!
>
>> load-store.ll has UB due to out-of-bounds load/store. Fix the UB in the variable
>> test and add an array test. Note: PIC array index is currently wrong.
>
> Spelling mistakes? Is NONPIC?
I pick NOPIC because `-fno-pic` is usually used to refer the position-dependent codegen. NOPIC should be fine.
> The wrong array index is due to constant folding with `GlobalAddress` when `isDSOLocal()`.
> The interface function of the common layer is `TargetLowering::isOffsetFoldingLegal`.
Thanks!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D129977/new/
https://reviews.llvm.org/D129977
More information about the llvm-commits
mailing list