[llvm] [X86][GISel] lower GOT-relative G_GLOBAL_VALUEs (PR #181983)
Evgenii Kudriashov via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 7 05:57:55 PDT 2026
e-kud wrote:
> Please could you clarify the differences? I'm not very familiar with SelectionDAG
@rosefromthedead IIUC, Matt means that SelectionDAG selects an address based on `selectAddr` in `llvm/lib/Target/X86/X86ISelDAGToDAG.cpp` using patterns. That is invoked for `addr` operands as
```
def addr : ComplexPattern<iPTR, 5, "selectAddr">;
```
So the expectation is that GlobalISel should work in the same way, in other words, we should build an address using `X86InstructionSelector::selectAddr` and existing patterns instead of emitting MIR using c++ code when we failed pattern matching.
I've updated #170038, there we don't do any manual (a.k.a. using C++ code), we just reuse existing patterns.
https://github.com/llvm/llvm-project/pull/181983
More information about the llvm-commits
mailing list