Releases: kobby-pentangeli/lc3box
Releases · kobby-pentangeli/lc3box
Release list
Auditable programs
lc3box-v0.7.1
lc3box run now works when its input is not an interactive terminal, and the toolbox grows a set of small, self-contained example programs that each print their result to the console.
Added
- A collection of short example programs under
examples/, each self-contained and printing its result: reversing a string, counting the set bits of a word, computing the XOR of two registers, folding a vector with bitwise AND, counting a character's occurrences in a string, multiplying by ten, and three signed-comparison variants. Numeric results are shown by a small in-program decimal or hexadecimal print routine, since the LC-3 has no numeric-output trap.
Changed
- The bundled example programs are now provided as readable, re-assemblable
.asmsource---disassembled from the pre-assembled objects where only an object existed---so every example can be read, edited, and re-assembled.
Fixed
lc3box runno longer aborts when standard input is not a terminal. Placing the terminal in raw mode is now best-effort, so a program run from a pipe, a redirect, or a non-interactive environment executes and prints its output instead of failing with a device error; an interactive terminal still gets raw-mode keyboard input as before.
New LC3 Debugger
What's new
Adds lc3debug, an interactive debugger for the toolbox: load a program and drive it one instruction at a time---single-step, set breakpoints, inspect and edit registers and memory, and disassemble the code around the program counter---so what a program does between assembly and output is no longer a black box.
Added
lc3debug, a new interactive debugger that drives thelc3vmvirtual machine one instruction at a time. It single-steps (step [n]), runs to a breakpoint orHALT(continue), sets and clears breakpoints (break/delete) and lists them (breaks), shows and edits the register file (registers/set) and memory (write), disassembles a window around the program counter (disassemble), and reloads the program to its entry point (reset). The engine is a pure state machine with no terminal of its own, so it embeds cleanly in other programs.- An
lc3box dbgsubcommand that opens a debugging session on a program:lc3box dbg program.asmassembles it in memory first,lc3box dbg program.objloads the object directly, then reads commands from a prompt. An executing program drives the terminal in raw mode for the span of the run, while the prompt stays line-edited. lc3box::dbgin the umbrella library, re-exportinglc3debugalongside the existingkernel/vm/asm/dsmmodules, each behind a like-named feature---fullnow enables all five.- The library primitives the debugger is built on: a public single-step entry point on the virtual machine (
lc3vm) and single-instruction rendering in the disassembler (lc3dsm).
lc3box-v0.6.0-stable
First stable release
Features
-
lc3core, a shared library crate that defines the LC-3 instruction set: the opcode set, the register and condition-code model, the trap vectors, the memory-map constants, the big-endian.objobject-file format, and the assembler pseudo-ops. -
lc3as, a two-pass assembler that translates LC-3 assembly source (.asm) into the big-endian.objobject fileslc3vmruns. -
lc3dsm, a disassembler that decodes a big-endian.objobject file back into a readable, re-assemblable LC-3 assembly listing. -
lc3vm, LC-3 virtual machine that loads and executes a pre-assembled object file (.obj), interpreting it against a full 16-bit address space. -
lc3box, a unified command-line driver with one subcommand per tool:runexecutes a program,asmassembles source into object files, anddisasmdisassembles an object back into a re-assemblable listing.