On 10/07/2015 01:04 AM, Christian Bruel wrote:
The ARM target can switch different alignment requirements between the
thumb or arm, thanks to the attribute ((target)). Using
FUNCTION_BOUNDARY that now depends on the switchable target_flag.

The previous attempt to fix this was to use the set_current_function
hook to reset DECL_ALIGN. On a second thought I found this not
satisfactory because this hook is called multiple time between passes,
whereas the setting only needs to be done once.

Instead, this patch resets the function's DECL_ALIGN in
allocate_struct_function, when not enforced by the user or the language,
after the attributes are processed.

Tested for arm-none-eabi (with the 1/2 part
https://gcc.gnu.org/ml/gcc-patches/2015-09/msg02198.html)

Bootstraped for x86_64-unknown-linux-gnu and tested (c+,c++,fortran)

Comments ? OK for trunk ?
Bernd seems pretty engaged at this point. I'll just add I like this much more than the prior approaches.

jeff

Reply via email to