From 9a9a996b7b83ac05a2ff8715051a86a3abf59f39 Mon Sep 17 00:00:00 2001 From: Stan Cox Date: Thu, 6 Oct 1994 15:13:26 +0000 Subject: [PATCH] If operand1 is an invalid PIC address, then legitimize it before doing anything else. From-SVN: r8228 --- gcc/config/m88k/m88k.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gcc/config/m88k/m88k.c b/gcc/config/m88k/m88k.c index 28ac763695c7..b8ec1bd21c88 100644 --- a/gcc/config/m88k/m88k.c +++ b/gcc/config/m88k/m88k.c @@ -224,6 +224,10 @@ emit_move_sequence (operands, mode, scratch) register rtx operand0 = operands[0]; register rtx operand1 = operands[1]; + if (CONSTANT_P (operand1) && flag_pic + && pic_address_needs_scratch (operand1)) + operands[1] = operand1 = legitimize_address (1, operand1, 0, 0); + /* Handle most common case first: storing into a register. */ if (register_operand (operand0, mode)) { -- 2.43.5