[PATCH] D152248: [AVR] Fix incorrect expanded pseudo instruction ROLBRd

Patryk Wychowaniec via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 6 02:36:13 PDT 2023


Patryk27 added inline comments.


================
Comment at: llvm/lib/Target/AVR/AVRExpandPseudoInsts.cpp:1488
+  // due to aykevl's comment in https://reviews.llvm.org/D152063 .
+  buildMI(MBB, MBBI, AVR::EORRdRr)
+      .addReg(TmpReg, RegState::Define)
----------------
benshi001 wrote:
> Patryk27 wrote:
> > Hmm, this feels kinda excessive - wouldn't adding `let Uses = [R1]` to `ROLBRd` be sufficient?
> > 
> > ```
> > let Uses = [R1] in
> > def ROLBRd : Pseudo<(outs GPR8
> >                      : $rd),
> >                     (ins GPR8
> >                      : $src),
> >                     "rolb\t$rd",
> >                     [(set i8
> >                       : $rd, (AVRrol i8
> >                               : $src)),
> >                      (implicit SREG)]>;
> > ```
> Because it maybe `R17` on AVRTINY.
ah, true, true 


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D152248/new/

https://reviews.llvm.org/D152248



More information about the llvm-commits mailing list