- if (eattr & DEFINED)
- {
- for(j=0; j<fwindex; j++)
- {
- if (fwdjump[j] == address)
- {
- page_jump = (address & 0xFFFFFF00) - (eval & 0xFFFFFF00);
-
- if (page_jump)
- {
- if (eval % 4)
- {
- err_setup();
- sprintf(buf, "* \'jump\' at $%08X - destination address not aligned for long page jump, insert a \'nop\' before the destination address", address);
-
- if (listing > 0)
- ship_ln(buf);
-
- if (err_flag)
- write(err_fd, buf, (LONG)strlen(buf));
- else
- printf("%s\n", buf);
- }
- }
- else
- {
- if (!(eval & 0x0000000F) || ((eval - 2) % 4))
- {
- err_setup();
- sprintf(buf, "* \'jump\' at $%08X - destination address not aligned for short page jump, insert a \'nop\' before the destination address", address);
-
- if (listing > 0)
- ship_ln(buf);
-
- if (err_flag)
- write(err_fd, buf, (LONG)strlen(buf));
- else
- printf("%s\n", buf);
- }
- }
-
- // Clear this jump as it has been checked
- fwdjump[j] = 0;
- j = fwindex;
- }
- }
- }
-
- eval = ((eval >> 16) & 0x0000FFFF) | ((eval << 16) & 0xFFFF0000);
- flags = (MLONG|MMOVEI);
+ if ((w & FUMASKRISC) == FU_MOVEI)
+ {
+ // Long constant in MOVEI # is word-swapped, so fix it here
+ eval = WORDSWAP32(eval);
+ flags |= MMOVEI;