This utility allows more efficient start of pattern match.
Often MachineInstr(MI) is available and instead of using
mi_match(MI.getOperand(0).getReg(), MRI, ...) followed by
MRI.getVRegDef(Reg) that gives back MI we now use
mi_match(MI, MRI, ...).
Details
Details
Diff Detail
Diff Detail
Event Timeline
llvm/include/llvm/CodeGen/GlobalISel/MIPatternMatch.h | ||
---|---|---|
192 | Maybe simpler? |
Comment Actions
Can we have testcases which check what happens with
- An instruction with 0 defs
- An instruction with > 1 def
?
clang-tidy: warning: invalid case style for function 'mi_match' [readability-identifier-naming]
not useful