Adds patterns to match integer loads/stores bitcasted to fp values
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
You mention unimplemented hooks in D60394 and on the github issue, so why did you go for this approach instead? Solving this in a generic manner seems like the 'good' thing to do, no?
I didn't get an answer there and when I tried to prototype the hooks solution, I've noticed that atomic_load_N (and store) apparently is integer-only, so just to match fp AtomicLoads for correct lowering more stuff had to be introduced and it wouldn't really reduce the td boilerplate (just simplify it a bit). Maybe there is a better approach (actually, I wonder why "LD + MOV/MOV+ ST are not folded by some generic MIR pass), but I've decided to submit this targeted patch first.
Okay, fair enough. I understand there's a chance of producing some illegal IR with float types for aarch64 so it's probably safer, and easier, to perform the folding here.