TEMPLATE static u32 FASTCALL OP_LSL_0(const u32 i) { cpu->R[REG_NUM(i, 0)] = cpu->R[REG_NUM(i, 3)]; cpu->CPSR.bits.N = BIT31(cpu->R[REG_NUM(i, 0)]); cpu->CPSR.bits.Z = cpu->R[REG_NUM(i, 0)] == 0; return 1; }
TEMPLATE static uint32_t FASTCALL OP_LSL_0(uint32_t i) { cpu->R[REG_NUM(i, 0)] = cpu->R[REG_NUM(i, 3)]; cpu->CPSR.bits.N = BIT31(cpu->R[REG_NUM(i, 0)]); cpu->CPSR.bits.Z = !cpu->R[REG_NUM(i, 0)]; return 1; }
TEMPLATE static u32 FASTCALL OP_LSL_0(const u32 i) { cpu->R[REG_NUM(i, 0)] = cpu->R[REG_NUM(i, 3)]; cpu->CPSR.bits.N = BIT31(cpu->R[REG_NUM(i, 0)]); cpu->CPSR.bits.Z = cpu->R[REG_NUM(i, 0)] == 0; return 1; } TEMPLATE static u32 FASTCALL OP_LSL(const u32 i) { u32 v = (i>>6) & 0x1F; cpu->CPSR.bits.C = BIT_N(cpu->R[REG_NUM(i, 3)], 32-v); cpu->R[REG_NUM(i, 0)] = (cpu->R[REG_NUM(i, 3)] << v); cpu->CPSR.bits.N = BIT31(cpu->R[REG_NUM(i, 0)]); cpu->CPSR.bits.Z = cpu->R[REG_NUM(i, 0)] == 0; return 1; } TEMPLATE static u32 FASTCALL OP_LSL_REG(const u32 i) { u32 v = cpu->R[REG_NUM(i, 3)] & 0xFF; if(v == 0) { cpu->CPSR.bits.N = BIT31(cpu->R[REG_NUM(i, 0)]); cpu->CPSR.bits.Z = cpu->R[REG_NUM(i, 0)] == 0; return 2; }