From 0d479b8e8de85a87979fff1b17cf8a478c8ff988 Mon Sep 17 00:00:00 2001 From: law Date: Tue, 12 Jul 1994 20:23:58 +0000 Subject: [PATCH] * pa.h (GO_IF_LEGITIMATE_ADDRESS): Only allow immediate addressing using 5 bits to avoid losing with FP loads and stores on page zero. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@7752 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/config/pa/pa.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/gcc/config/pa/pa.h b/gcc/config/pa/pa.h index 2991f4f..ed20c28 100644 --- a/gcc/config/pa/pa.h +++ b/gcc/config/pa/pa.h @@ -1268,7 +1268,11 @@ extern union tree_node *current_function_decl; REG+REG, REG+(REG*SCALE) or REG+SMALLINT. But we can treat a SYMBOL_REF as legitimate if it is part of this function's constant-pool, because such addresses can actually - be output as REG+SMALLINT. */ + be output as REG+SMALLINT. + + Note we only allow 5 bit immediates for access to a constant address; + doing so avoids losing for loading/storing a FP register at an address + which will not fit in 5 bits. */ #define VAL_5_BITS_P(X) ((unsigned)(X) + 0x10 < 0x20) #define INT_5_BITS(X) VAL_5_BITS_P (INTVAL (X)) @@ -1333,7 +1337,7 @@ extern union tree_node *current_function_decl; goto ADDR; \ else if (GET_CODE (X) == LABEL_REF \ || (GET_CODE (X) == CONST_INT \ - && INT_14_BITS (X))) \ + && INT_5_BITS (X))) \ goto ADDR; \ } -- 2.7.4