Permalink
Switch branches/tags
Nothing to show
Commits on Dec 31, 2017
  1. Add script to get instruction traces from GDB

    user
    user committed Dec 31, 2017
    This is how I found the stupid bug in my emulator.
  2. Change build script to build 386 emulator too

    user
    user committed Dec 31, 2017
  3. Fix backwards ZF in 386 simulator

    user
    user committed Dec 31, 2017
    The implementation was setting ZF to the opposite of the correct value,
    reversing the sense of every conditional branch in the program.  This is
    the bug that was causing tinyboot1 to crash; comparing a simulated
    execution trace with a trace run under GDB found this pretty quickly.
    Fixing it actually makes it crash sooner, after only some 11700
    instructions instead of almost 16000.
  4. Change 386 tracing to go to stderr

    user
    user committed Dec 31, 2017
    I wanted to be able to find the emulated program output, if any.
  5. Add %eip tracing to broken 386 emulator

    user
    user committed Dec 31, 2017
    It runs tinyboot1 for about 15000 instructions before crashing due to
    what appears to be running off the end of an infinite loop and trying to
    return on the operand stack.  My current objective is to diff the
    execution trace with an execution trace generated using
    scripts I haven't written yet for GDB.
Commits on Dec 24, 2017
  1. Merge pull request #4 from jaens/patch-1

    kragen committed Dec 24, 2017
    Add links in related work section
  2. Improve emulator debug output

    user
    user committed Dec 24, 2017
  3. Add debug output to broken 386 emulator

    user
    user committed Dec 24, 2017
    My 386 emulator still crashes when I try to run tinyboot1 under it but
    now it emits 8000 line of incomprehensible debugging output first.
Commits on Dec 21, 2017
  1. Fix two bugs in 386 emulator; it almost works!

    user
    user committed Dec 21, 2017
    Now it is able to run tinyboot1 to the point of accepting input.  The
    two bugs were:
    
    - sub %eax, (%esp) needed to leave its output on the stack, not in
      %eax.  Otherwise the immediately following pop %eax discards it.
    - Since dec %al is two bytes long, not one, it should increment the
      instruction pointer by 2.  Otherwise you get an instruction decoding
      error on the second byte.
    
    Now the program seems to be returning to a NULL address for some reason,
    maybe related to inequality comparisons still being broken.
  2. Add half-assed 386 “bytecode” emulator

    user
    user committed Dec 21, 2017
    This 386 emulator emulates a few instructions with sufficient
    correctness to get some distance into running StoneKnifeForth, but not
    enough to actually run it successfully.
  3. Change origin of hello42 too

    user
    user committed Dec 21, 2017
    This makes it run on (default configurations of) modern Linux kernels.
Commits on Dec 16, 2017
  1. Fix StoneKnifeForth to work on modern i386 Linux

    user
    user committed Dec 16, 2017
    StoneKnifeForth broke after a kernel upgrade many years ago.  Max
    Bernstein found and fixed the problem in his fork at
    <tekknolagi/stoneknifecpp@905105b>;
    Linux added a prohibition by default on mapping virtual memory below
    0x10000, for security reasons.  So simply changing the origin address
    was enough to get it working.
    
    (I'm actually testing this on an amd64 Linux, but it's still an i386
    binary.)
Commits on Sep 17, 2017
  1. Add eForth PDF link & UrScheme

    jaens committed Sep 17, 2017
Commits on Jul 21, 2017
  1. Merge pull request #1 from larsbrinkhoff/master

    kragen committed Jul 21, 2017
    Make GitHub detect *.tbf1 as Forth.
Commits on Feb 13, 2015
Commits on Nov 16, 2008
  1. Factored out duplication between subtraction and less-than.

    kragen committed Nov 16, 2008
    This reduced the number of machine code "magic bytes" in the code.  Also
    reformatted the code a bit, shortening it by a line.
Commits on Nov 1, 2008
  1. A bunch of cleanup to improve readability, and extra documentation.

    kragen committed Nov 1, 2008
    Updated README.md to reflect the current state of the code, and more
    experience.
    
    Put more ideas (for putting the operand stack on %edi) into tinyboot.s.
    
    Documented the language some, in comments.  Documented charset issues.
    Probably some of this needs reorganizing.
    
    Lots of readability improvements, many following Darius Bacon's feedback.
Commits on Oct 30, 2008
  1. Added tinyboot1 to .gitignore.

    kragen committed Oct 30, 2008
  2. Some README updates.

    kragen committed Oct 30, 2008
  3. Translated compiler using multi-character tokens.

    kragen committed Oct 30, 2008
    The tinyboot1.tbf1 in this  commit has been verified to compile to a
    byte-for-byte identical executable as in the previous commit.
Commits on Oct 29, 2008
Commits on Oct 19, 2008
  1. More info on related work.

    kragen committed Oct 19, 2008
  2. More documentation updates.

    kragen committed Oct 19, 2008