Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //Multiply Long (MULL / MLAL)
- //UMULL S=0
- case 0x00C00000:
- var value = (this.registers[this.instruction & 0x00000F00] >>> 0) * (this.registers[this.instruction & 0x0000000F] >>> 0);
- this.registers[this.instruction & 0x0000F000] = value & 0xFFFFFFFF;
- this.registers[this.instruction & 0x000F0000] = (value / 0x100000000) | 0;
- break;
- //UMULL S=1
- case 0x00D00000:
- var value = (this.registers[this.instruction & 0x00000F00] >>> 0) * (this.registers[this.instruction & 0x0000000F] >>> 0);
- this.registers[this.instruction & 0x0000F000] = value & 0xFFFFFFFF;
- this.CPSRZero = (value == 0);
- value = (value / 0x100000000) | 0;
- this.CPSRNegative = (value < 0);
- this.registers[this.instruction & 0x000F0000] = value;
- break;
- //UMLAL S=0
- case 0x00E00000:
- var value = (this.registers[this.instruction & 0x00000F00] >>> 0) * (this.registers[this.instruction & 0x0000000F] >>> 0);
- value += ((this.registers[this.instruction & 0x000F0000] >>> 0) * 0x100000000) + (this.registers[this.instruction & 0x0000F000] >>> 0);
- this.registers[this.instruction & 0x0000F000] = value & 0xFFFFFFFF;
- this.registers[this.instruction & 0x000F0000] = (value / 0x100000000) | 0;
- break;
- //UMLAL S=1
- case 0x00F00000:
- var value = (this.registers[this.instruction & 0x00000F00] >>> 0) * (this.registers[this.instruction & 0x0000000F] >>> 0);
- value += ((this.registers[this.instruction & 0x000F0000] >>> 0) * 0x100000000) + (this.registers[this.instruction & 0x0000F000] >>> 0);
- this.registers[this.instruction & 0x0000F000] = value & 0xFFFFFFFF;
- this.CPSRZero = (value == 0);
- value = (value / 0x100000000) | 0;
- this.CPSRNegative = (value < 0);
- this.registers[this.instruction & 0x000F0000] = value;
- break;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement