(indirect_operand): Verify mode of OP is correct.

From-SVN: r6222
This commit is contained in:
Richard Kenner 1993-12-12 08:01:09 -05:00
parent cc79451b14
commit b0e0a0f9a8
1 changed files with 3 additions and 0 deletions

View File

@ -1088,6 +1088,9 @@ indirect_operand (op, mode)
- MIN (UNITS_PER_WORD, GET_MODE_SIZE (GET_MODE (inner))));
#endif
if (mode != VOIDmode && GET_MODE (op) != mode)
return 0;
/* The only way that we can have a general_operand as the resulting
address is if OFFSET is zero and the address already is an operand
or if the address is (plus Y (const_int -OFFSET)) and Y is an