This is the mail archive of the
mailing list for the GCC project.
Re: [Patch, avr] Add device name to cpp_builtins
- From: Denis Chertykov <chertykov at gmail dot com>
- To: Senthil Kumar Selvaraj <senthil_kumar dot selvaraj at atmel dot com>
- Cc: gcc-patches <gcc-patches at gcc dot gnu dot org>, gjl at gcc dot gnu dot org
- Date: Thu, 24 Jul 2014 22:41:35 +0400
- Subject: Re: [Patch, avr] Add device name to cpp_builtins
- Authentication-results: sourceware.org; auth=none
- References: <20140723080440 dot GA28575 at atmel dot com>
2014-07-23 12:04 GMT+04:00 Senthil Kumar Selvaraj
> The below patch adds a new preprocessor define for the device name
> (__AVR_DEVICE_NAME__) that was passed to the compiler.
> While the device name macro (say __AVR_ATmega128__) can be used to
> check for a specific device, there is no way right now for code
> to get the device name it is being compiled against (without checking
> for every possible device).
> This patch is groundwork for embedding device information in a note
> section (see binutils ml discussion
> https://www.sourceware.org/ml/binutils/2014-07/msg00146.html), so that
> utilities that operate on the ELF file do not have to hardcode
> device information themselves.
> If ok, could someone apply please? I don't have commit access.
> 2014-07-23 Senthil Kumar Selvaraj <firstname.lastname@example.org>
> * config/avr/avr-c.c (avr_cpu_cpp_builtins): Add __AVR_DEVICE_NAME__.