[llvm] [X86] Added support for 16bit LEA instruction (PR #122102)
Phoebe Wang via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 8 19:22:02 PST 2025
================
@@ -25,6 +25,12 @@ let SchedRW = [WriteLEA] in {
[(set GR32:$dst, lea32addr:$src)]>,
OpSize32, Requires<[Not64BitMode]>;
+ def LEA64_16r : I<0x8D, MRMSrcMem, (outs GR16:$dst), (ins lea64_16mem:$src),
+ "lea{w}\t{$src|$dst}, {$dst|$src}",
+ [(set GR16:$dst, lea64_16addr:$src)]>,
+ OpSize16,
+ Requires<[In64BitMode]>;
----------------
phoebewang wrote:
Is it possible not to define a new LEA64_16r, but add a pattern for 16-bit with LEA64_32r? This should address the encoding size concern.
https://github.com/llvm/llvm-project/pull/122102
More information about the llvm-commits
mailing list