[PATCH] D77207: [AVR] Fix I/O instructions on XMEGA

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 20 04:18:20 PDT 2020


RKSimon added inline comments.


================
Comment at: llvm/lib/Target/AVR/AVRInstrInfo.td:145
+  uint64_t val = N->getZExtValue() - offset;
+  return val >= 0x0 && val < 0x3f;
 }], ioaddr_XFORM>;
----------------
@vlastik the "val >= 0x0" is redundant as these are unsigned values and gcc warns with:
```
lib/Target/AVR/AVRGenDAGISel.inc:1676:14: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
   return val >= 0x0 && val < 0x3f;
```
which causes problems with Werror builds - can these be removed please?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D77207





More information about the llvm-commits mailing list