feat: implement QADD/QSUB

This commit is contained in:
2023-09-07 03:36:17 -05:00
parent 177f9b55a9
commit 819eace2a7
4 changed files with 32 additions and 21 deletions

View File

@@ -20,7 +20,6 @@ pub const arm = struct {
const multiply = @import("cpu/arm/multiply.zig").multiply;
const cop = @import("cpu/arm/coprocessor.zig");
const clz = @import("cpu/arm/misc_instructions.zig").clz;
/// Determine index into ARM InstrFn LUT
pub fn idx(opcode: u32) u12 {
@@ -43,8 +42,6 @@ pub const arm = struct {
handler.* = switch (@as(u2, i >> 10)) {
0b00 => if (i == 0x121) blk: { // 12 bits
break :blk branchExchange(InstrFn);
} else if (i == 0x161) blk: { // 12 bits
break :blk clz(InstrFn);
} else if (i & 0xFBF == 0x109) blk: { // 11 bits
const B = i >> 6 & 1 == 1;
break :blk swap(InstrFn, B);