diff options
Diffstat (limited to '')
| -rw-r--r-- | isa/decode.cpp | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/isa/decode.cpp b/isa/decode.cpp index d709cf8..4af9a0d 100644 --- a/isa/decode.cpp +++ b/isa/decode.cpp | |||
| @@ -1,4 +1,5 @@ | |||
| 1 | #include <cassert> | 1 | #include <cassert> |
| 2 | #include <iostream> | ||
| 2 | 3 | ||
| 3 | #include "isa/isa.h" | 4 | #include "isa/isa.h" |
| 4 | 5 | ||
| @@ -112,31 +113,31 @@ instruction_context decode(unsigned int dfifb, unsigned int pc, unsigned int bit | |||
| 112 | case 4: | 113 | case 4: |
| 113 | // GTF get flags | 114 | // GTF get flags |
| 114 | inst.ef = [](auto &ctx) { | 115 | inst.ef = [](auto &ctx) { |
| 116 | std::cerr << "unimplemented GTF\n"; | ||
| 115 | assert(false); | 117 | assert(false); |
| 116 | }; | 118 | }; |
| 117 | break; | 119 | break; |
| 118 | case 5: | 120 | case 5: |
| 119 | // RTF restore flags | 121 | // RTF restore flags |
| 120 | inst.ef = [](auto &ctx) { | 122 | inst.ef = [](auto &ctx) { |
| 123 | std::cerr << "unimplemented RTF\n"; | ||
| 121 | assert(false); | 124 | assert(false); |
| 122 | }; | 125 | }; |
| 123 | break; | 126 | break; |
| 124 | case 6: | 127 | case 6: |
| 125 | // SGT skip if greater than | 128 | // SGT skip if greater than |
| 126 | inst.ef = [](auto &ctx) { | 129 | inst.ef = [](auto &ctx) { |
| 130 | std::cerr << "unimplemented SGT\n"; | ||
| 127 | assert(false); | 131 | assert(false); |
| 128 | }; | 132 | }; |
| 129 | break; | 133 | break; |
| 130 | case 7: | 134 | case 7: |
| 131 | // CAF clear all flags | 135 | // CAF clear all flags |
| 132 | inst.ef = [](auto &ctx) { | 136 | inst.ef = [](auto &ctx) { |
| 137 | std::cerr << "unimplemented CAF\n"; | ||
| 133 | assert(false); | 138 | assert(false); |
| 134 | }; | 139 | }; |
| 135 | break; | 140 | break; |
| 136 | default: | ||
| 137 | inst.ef = [](auto &ctx) { | ||
| 138 | assert(false); | ||
| 139 | }; | ||
| 140 | } | 141 | } |
| 141 | break; | 142 | break; |
| 142 | case 004: | 143 | case 004: |
| @@ -203,13 +204,15 @@ instruction_context decode(unsigned int dfifb, unsigned int pc, unsigned int bit | |||
| 203 | }; | 204 | }; |
| 204 | break; | 205 | break; |
| 205 | default: | 206 | default: |
| 206 | inst.ef = [](auto &ctx) { | 207 | inst.ef = [bits](auto &ctx) { |
| 208 | std::cerr << "unimplemented IOT TT suboperation " << (bits & 07) << "\n"; | ||
| 207 | assert(false); | 209 | assert(false); |
| 208 | }; | 210 | }; |
| 209 | } | 211 | } |
| 210 | break; | 212 | break; |
| 211 | default: | 213 | default: |
| 212 | inst.ef = [](auto &ctx) { | 214 | inst.ef = [bits](auto &ctx) { |
| 215 | std::cerr << "unimplemented IOT device " << ((bits >> 6) & 07) << ((bits >> 3) & 07) << " suboperation " << (bits & 07) << "\n"; | ||
| 213 | assert(false); | 216 | assert(false); |
| 214 | }; | 217 | }; |
| 215 | } | 218 | } |
| @@ -323,7 +326,10 @@ instruction_context decode(unsigned int dfifb, unsigned int pc, unsigned int bit | |||
| 323 | ctx.mq = new_mq; | 326 | ctx.mq = new_mq; |
| 324 | }; | 327 | }; |
| 325 | } else { | 328 | } else { |
| 326 | assert(false); | 329 | inst.ef = [bits](auto &ctx) { |
| 330 | std::cerr << "unimplemented OPR " << ((bits >> 6) & 07) << ((bits >> 3) & 07) << (bits & 07) << "\n"; | ||
| 331 | assert(false); | ||
| 332 | }; | ||
| 327 | } | 333 | } |
| 328 | break; | 334 | break; |
| 329 | } | 335 | } |
