From e93f30a65fdca10d8881fe1a462eca347b5f58b2 Mon Sep 17 00:00:00 2001
From: Vladimir Makarov <vmakarov@redhat.com>
Date: Thu, 10 Nov 2016 17:04:31 +0000
Subject: target.def (additional_allocno_class_p): New.

2016-11-10  Vladimir Makarov  <vmakarov@redhat.com>

	* target.def (additional_allocno_class_p): New.
	* hooks.h (hook_bool_reg_class_t_false): New prototype.
	* hooks.c (hook_bool_reg_class_t_false): New.
	* ira.c (setup_allocno_and_important_classes): Use the new hook.
	* doc/tm.texi.in (TARGET_ADDITIONAL_ALLOCNO_CLASS_P): Add it.
	* doc/tm.texi: Update.

From-SVN: r242043
---
 gcc/target.def | 12 ++++++++++++
 1 file changed, 12 insertions(+)

(limited to 'gcc/target.def')

diff --git a/gcc/target.def b/gcc/target.def
index bcdbc0e..caeeff9 100644
--- a/gcc/target.def
+++ b/gcc/target.def
@@ -5029,6 +5029,18 @@ DEFHOOK
  reg_class_t, (reg_class_t, machine_mode),
  NULL)
 
+/* Determine an additional allocno class.  */
+DEFHOOK
+(additional_allocno_class_p,
+ "This hook should return @code{true} if given class of registers should\
+  be an allocno class in any way.  Usually RA uses only one register\
+  class from all classes containing the same register set.  In some\
+  complicated cases, you need to have two or more such classes as\
+  allocno ones for RA correct work.  Not defining this hook is\
+  equivalent to returning @code{false} for all inputs.",
+ bool, (reg_class_t),
+ hook_bool_reg_class_t_false)
+
 DEFHOOK
 (cstore_mode,
  "This hook defines the machine mode to use for the boolean result of\
-- 
cgit v1.1

