[llvm-dev] Instruction selection for 'load' based on static vs. dynamic data
Dr. ERDI Gergo via llvm-dev
llvm-dev at lists.llvm.org
Tue May 9 06:16:51 PDT 2017
On Tue, 9 May 2017, Krzysztof Parzyszek wrote:
> def: Pat<(ld (add (WRAPPER RC:$addr), (sign_extend RC:$offset))),
> (load_instruction_rr RC:$addr, RC:$offset)>;
>
> Where "load_instruction" is a machine load instruction with base address and
> an offset, both in registers, and RC is the corresponding register class.
Can I also use something more complex than a single machine load
instruction here? I.e. can I write something like
def: Pat<(ld (add (WRAPPER RC:$addr), (sign_extend RC:$offset))),
(load_instruction_rr (special_add RC:$addr, RC:$offset))>;
? Or do I have to go via some pseudo-instruction for that?
More information about the llvm-dev
mailing list