Skip to content
Snippets Groups Projects
Commit d3ff08a3 authored by Andrew Pinski's avatar Andrew Pinski
Browse files

aarch64: Fix __builtin_apply with -mgeneral-regs-only [PR113486]


The problem here is the builtin apply mechanism thinks the FP registers
are to be used due to get_raw_arg_mode not returning VOIDmode. This
fixes that oversight and the backend now returns VOIDmode for non-general-regs
if TARGET_GENERAL_REGS_ONLY is true.

Built and tested for aarch64-linux-gnu with no regressions.

	PR target/113486

gcc/ChangeLog:

	* config/aarch64/aarch64.cc (aarch64_get_reg_raw_mode): For
	TARGET_GENERAL_REGS_ONLY, return VOIDmode for non-GP_REGNUM_P regno.

gcc/testsuite/ChangeLog:

	* gcc.target/aarch64/builtin_apply-1.c: New test.

Signed-off-by: default avatarAndrew Pinski <quic_apinski@quicinc.com>
parent fb54b977
No related branches found
No related tags found
No related merge requests found
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