Skip to content
Snippets Groups Projects
Commit cde452e2 authored by Georg-Johann Lay's avatar Georg-Johann Lay
Browse files

AVR: Only provide a built-in when it is available.

Some built-ins are not available for C++ since they are using
named address-spaces or fixed-point types.

gcc/
	* config/avr/builtins.def (AVR_FIRST_C_ONLY_BUILTIN_ID): New macro.
	* config/avr/avr-protos.h (avr_builtin_supported_p): New.
	* config/avr/avr.cc (avr_builtin_supported_p): New function.
	(avr_init_builtins): Only provide a built-in when it is supported.
	* config/avr/avr-c.cc (avr_cpu_cpp_builtins): Only define the
	__BUILTIN_AVR_<NAME> build-in defines when the associated built-in
	function is supported.
	* doc/extend.texi (AVR Built-in Functions): Add a note that
	following built-ins are supported for only for GNU-C.
parent 4e6fd85b
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment