diff options
author | Andrew Waterman <waterman@s141.Millennium.Berkeley.EDU> | 2010-09-07 16:04:57 -0700 |
---|---|---|
committer | Andrew Waterman <waterman@s141.Millennium.Berkeley.EDU> | 2010-09-07 16:04:57 -0700 |
commit | c82197c5930d4bf103fe80a7ac877e22b22c4842 (patch) | |
tree | 847392bcd03619bd557fedbb80924ebb4d899c07 /riscv | |
parent | 0771c7b0175154df9205c40c37c375693e8a0c7b (diff) | |
download | spike-c82197c5930d4bf103fe80a7ac877e22b22c4842.zip spike-c82197c5930d4bf103fe80a7ac877e22b22c4842.tar.gz spike-c82197c5930d4bf103fe80a7ac877e22b22c4842.tar.bz2 |
[xcc, sim] added slei/sleui in lieu of slti/sltiu
Rationale was that since we have the datapath for rc = (ra < rb),
it's straightforward to also add rc = !(imm < rb) = (rb <= imm).
Diffstat (limited to 'riscv')
-rw-r--r-- | riscv/execute.h | 4 | ||||
-rw-r--r-- | riscv/insns/slei.h | 1 | ||||
-rw-r--r-- | riscv/insns/sleiu.h | 1 | ||||
-rw-r--r-- | riscv/insns/slti.h | 1 | ||||
-rw-r--r-- | riscv/insns/sltiu.h | 1 |
5 files changed, 4 insertions, 4 deletions
diff --git a/riscv/execute.h b/riscv/execute.h index 15f90ef..69bdeb0 100644 --- a/riscv/execute.h +++ b/riscv/execute.h @@ -480,12 +480,12 @@ switch((insn.bits >> 0x19) & 0x7f) } case 0x2: { - #include "insns/slti.h" + #include "insns/slei.h" break; } case 0x3: { - #include "insns/sltiu.h" + #include "insns/sleiu.h" break; } case 0x4: diff --git a/riscv/insns/slei.h b/riscv/insns/slei.h new file mode 100644 index 0000000..2f4fe29 --- /dev/null +++ b/riscv/insns/slei.h @@ -0,0 +1 @@ +RA = !(sreg_t(cmp_trunc(SIMM)) < sreg_t(cmp_trunc(RB))); diff --git a/riscv/insns/sleiu.h b/riscv/insns/sleiu.h new file mode 100644 index 0000000..2519eb4 --- /dev/null +++ b/riscv/insns/sleiu.h @@ -0,0 +1 @@ +RA = !(cmp_trunc(SIMM) < cmp_trunc(RB)); diff --git a/riscv/insns/slti.h b/riscv/insns/slti.h deleted file mode 100644 index a5ef31e..0000000 --- a/riscv/insns/slti.h +++ /dev/null @@ -1 +0,0 @@ -RA = sreg_t(cmp_trunc(RB)) < sreg_t(cmp_trunc(SIMM)); diff --git a/riscv/insns/sltiu.h b/riscv/insns/sltiu.h deleted file mode 100644 index a09f3ec..0000000 --- a/riscv/insns/sltiu.h +++ /dev/null @@ -1 +0,0 @@ -RA = cmp_trunc(RB) < cmp_trunc(SIMM); |