From 8536c657ffc11014c02aa7811eda04ce8b05dd6b Mon Sep 17 00:00:00 2001 From: Nick Clifton Date: Fri, 10 Feb 2006 12:05:12 +0000 Subject: Fix %hi() operator for 64-bit hosts. --- cpu/ChangeLog | 4 ++++ cpu/iq2000.opc | 2 ++ 2 files changed, 6 insertions(+) (limited to 'cpu') diff --git a/cpu/ChangeLog b/cpu/ChangeLog index 358e366..baefa5c 100644 --- a/cpu/ChangeLog +++ b/cpu/ChangeLog @@ -1,3 +1,7 @@ +2006-02-10 Nick Clifton + + * iq2000.opc (parse_hi16): Truncate shifted values to 16 bits. + 2006-01-06 DJ Delorie * m32c.cpu (mov.w:q): Fix mode. diff --git a/cpu/iq2000.opc b/cpu/iq2000.opc index 63ef076..5287506 100644 --- a/cpu/iq2000.opc +++ b/cpu/iq2000.opc @@ -218,6 +218,7 @@ parse_hi16 (CGEN_CPU_DESC cd, if (value & 0x8000) value += 0x10000; value >>= 16; + value &= 0xffff; } *valuep = value; @@ -243,6 +244,7 @@ parse_hi16 (CGEN_CPU_DESC cd, && result_type == CGEN_PARSE_OPERAND_RESULT_NUMBER) value >>= 16; + value &= 0xffff; *valuep = value; return errmsg; -- cgit v1.1