summaryrefslogtreecommitdiff
path: root/gcc/config/s390/s390.h
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/config/s390/s390.h')
-rw-r--r--gcc/config/s390/s390.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/gcc/config/s390/s390.h b/gcc/config/s390/s390.h
index 1623666cb65..3cc731c84f2 100644
--- a/gcc/config/s390/s390.h
+++ b/gcc/config/s390/s390.h
@@ -374,8 +374,9 @@ do \
/* If a 4-byte value is loaded into a FPR, it is placed into the
*upper* half of the register, not the lower. Therefore, we
cannot use SUBREGs to switch between modes in FP registers. */
-#define CANNOT_CHANGE_MODE_CLASS(FROM, TO) \
- (GET_MODE_SIZE (FROM) != GET_MODE_SIZE (TO) ? FP_REGS : NO_REGS)
+#define CANNOT_CHANGE_MODE_CLASS(FROM, TO, CLASS) \
+ (GET_MODE_SIZE (FROM) != GET_MODE_SIZE (TO) \
+ ? reg_classes_intersect_p (FP_REGS, CLASS) : 0)
/* Register classes. */