diff mbox series

[committed] arc: Don't allow millicode thunks with reduced register set CPUs.

Message ID 20210604071603.568387-1-claziss@synopsys.com
State New
Headers show
Series [committed] arc: Don't allow millicode thunks with reduced register set CPUs. | expand

Commit Message

Claudiu Zissulescu Ianculescu June 4, 2021, 7:16 a.m. UTC
The millicode thunks are not reduced register set safe.  Disable them
for CPUs having this option on.

gcc/
2021-06-04  Claudiu Zissulescu  <claziss@synopsys.com>

	* config/arc/arc.c (arc_override_options): Disable millicode
	thunks when RF16 is on.

Signed-off-by: Claudiu Zissulescu <claziss@synopsys.com>
---
 gcc/config/arc/arc.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/gcc/config/arc/arc.c b/gcc/config/arc/arc.c
index b77d0566386..0d34c964963 100644
--- a/gcc/config/arc/arc.c
+++ b/gcc/config/arc/arc.c
@@ -1451,8 +1451,10 @@  arc_override_options (void)
   if (TARGET_ARC700 && (arc_tune != ARC_TUNE_ARC7XX))
     flag_delayed_branch = 0;
 
-  /* Millicode thunks doesn't work with long calls.  */
-  if (TARGET_LONG_CALLS_SET)
+  /* Millicode thunks doesn't work for long calls.  */
+  if (TARGET_LONG_CALLS_SET
+      /* neither for RF16.  */
+      || TARGET_RF16)
     target_flags &= ~MASK_MILLICODE_THUNK_SET;
 
   /* Set unaligned to all HS cpus.  */