OSDN Git Service

Backport from 2012-04-24 mainline r186768.
authorgjl <gjl@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 24 Apr 2012 15:23:46 +0000 (15:23 +0000)
committergjl <gjl@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 24 Apr 2012 15:23:46 +0000 (15:23 +0000)
PR target/53065
* config/avr/avr.h (HARD_REGNO_CALL_PART_CLOBBERED): New hook define.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-4_7-branch@186770 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/config/avr/avr.h

index b55fc7c..0c230a3 100644 (file)
@@ -1,3 +1,10 @@
+2012-04-24  Georg-Johann Lay  <avr@gjlay.de>
+
+       Backport from 2012-04-24 mainline r186768.
+
+       PR target/53065
+       * config/avr/avr.h (HARD_REGNO_CALL_PART_CLOBBERED): New hook define.
+
 2012-04-24  Richard Guenther  <rguenther@suse.de>
 
        PR tree-optimization/53085
index bd5241c..591e21d 100644 (file)
@@ -394,6 +394,11 @@ enum reg_class {
 
 #define REGNO_OK_FOR_INDEX_P(NUM) 0
 
+#define HARD_REGNO_CALL_PART_CLOBBERED(REGNO, MODE)                    \
+  (((REGNO) < 18 && (REGNO) + GET_MODE_SIZE (MODE) > 18)               \
+   || ((REGNO) < REG_Y && (REGNO) + GET_MODE_SIZE (MODE) > REG_Y)      \
+   || ((REGNO) < REG_Z && (REGNO) + GET_MODE_SIZE (MODE) > REG_Z))
+
 #define TARGET_SMALL_REGISTER_CLASSES_FOR_MODE_P hook_bool_mode_true
 
 #define STACK_PUSH_CODE POST_DEC