Skip to content

project12 mathtest script need more steps to finish #668

Description

@chentao551

Tool

None

Interface

Website (https://nand2tetris.github.io/web-ide)

Contact Details

chentao551@gmail.com

What happened?

Not really a bug, but i wanted to suggest two small clarifications/improvements that may help future students.

  1. In project11(compiler), the discussion of compiling do subroutineCall; can be a bit misleading that it suggests the compiler should pop the return value when the called subroutine is void return type. In the VM model, every call leaves a return value on the stack. Since a Jack do statement discards the return value, the compiler should always emit something like pop temp 0 after compiling the call, regardless of whether the subroutine's return type.
  2. In Project 12(OS), MathTest.tst may need a larger VM step limit. In my experiments, even using the provided OS .vm files, the test needed around 1.3 million VM steps. It may be better to increase the script limit to 2,000,000 steps to avoid making students think their Math.jack implementation is inefficient or incorrect when the issue is only the test step limit.

Additional Comments

Hi,
I recently completed nand2tetris, completing the full system from NAND to the OS was a great experience and this book is absolutely one of the best in computer system, if not in human history, please have my knees.
Again, all my respect to Nisan and Schocken, you are my Gods, pls live forever!

Do you want to try to fix this bug?

  • I want to try to add this feature!

Code of Conduct

  • I agree to follow this project's Code of Conduct

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions