[AVR][Clang] Implement __AVR_HAVE_*__ macros
These macros are defined in avr-gcc and are useful when working with assembly. For example, startup code needs to copy the contents of .data from flash to RAM, but should use elpm (instead of lpm) on devices with more than 64kB flash. Without __AVR_HAVE_ELPM__, there is no way to know whether the elpm instruction is supported. This partially fixes https://github.com/llvm/llvm-project/issues/56157. Differential Revision: https://reviews.llvm.org/D137572
Loading
Please sign in to comment