[PATCH] D153865: [LoongArch] Add back SDNPSideEffect properties to CSR and IOCSR read ops
WÁNG Xuěruì via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 27 05:52:47 PDT 2023
xen0n created this revision.
xen0n added reviewers: SixWeining, wangleiat, hev, MaskRay, xry111.
Herald added a subscriber: hiraditya.
Herald added a project: All.
xen0n requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
In general, CSR and IOCSR reads cannot be reordered, merged or otherwise
optimized, because:
- there may well be intervening writes between seemingly common expressions;
- the stateful entity behind a given (IO)CSR may well be volatile.
Confirmed to fix broken Clang Linux/LoongArch builds (dying when a
userspace process tries to use FPU, panicking when that process is init)
with this patch.
Fixes: https://github.com/llvm/llvm-project/issues/63549
Fixes: 2efdacf74c54 <https://reviews.llvm.org/rG2efdacf74c54a14ff72e9ab4b2e0707e5b3b86a8> ("[LoongArch] Add missing chains and remove unnecessary `SDNPSideEffect` property for some intrinsic nodes")
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D153865
Files:
llvm/lib/Target/LoongArch/LoongArchInstrInfo.td
llvm/test/CodeGen/LoongArch/intrinsic-csr-side-effects.ll
llvm/test/CodeGen/LoongArch/intrinsic-iocsr-side-effects.ll
llvm/test/CodeGen/LoongArch/intrinsic-la64.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D153865.534938.patch
Type: text/x-patch
Size: 11043 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230627/9931fa9b/attachment-0001.bin>
More information about the llvm-commits
mailing list