[all-commits] [llvm/llvm-project] a8efcb: [AVR][Clang] Implement __AVR_HAVE_*__ macros
Ayke via All-commits
all-commits at lists.llvm.org
Tue Nov 22 16:22:44 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: a8efcb96e6db91d1bcc5e56e08814330dbdbfccb
https://github.com/llvm/llvm-project/commit/a8efcb96e6db91d1bcc5e56e08814330dbdbfccb
Author: Ayke van Laethem <aykevanlaethem at gmail.com>
Date: 2022-11-23 (Wed, 23 Nov 2022)
Changed paths:
M clang/lib/Basic/Targets/AVR.cpp
M clang/test/Preprocessor/avr-atmega328p.c
M clang/test/Preprocessor/avr-attiny104.c
Log Message:
-----------
[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
More information about the All-commits
mailing list