[llvm-dev] New register class and patterns

Matt Arsenault via llvm-dev llvm-dev at lists.llvm.org
Fri Feb 5 11:21:01 PST 2016


On 02/04/2016 11:41 AM, Rail Shafigulin wrote:
> Does LLVM make an assumption that there is an implicit register output 
> if there are no outputs given to the pattern? I'm also curious about 
> how did LLVM know that an output of this instruction was setting a 
> flag in a special purpose register rather than a GPR? When I look at 
> the DAG pattern for the instruction, (Escalasetflag (i32 GPR:$rA), 
> immSExt16:$imm, Cond), I can't find anything saying that it sets a 
> flag in the special purpose register. 
No, this would have to be a void side effecting instruction which is a 
bit different. The flag register is an implicit register added to the 
selected MachineInstr's operands.

-Matt


More information about the llvm-dev mailing list