Mirror of CollapseOS
25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

12345678910111213141516
  1. BIN( is the addr at which the compiled binary will live. It is
  2. often 0.
  3. ORG is H@ offset at which we begin spitting binary. Used to
  4. compute PC. To have a proper PC, call "H@ ORG !" at the
  5. beginning of your assembly process. PC is H@ - ORG + BIN(.
  6. Labels are a convenient way of managing relative jump
  7. calculations. Backward labels are easy. It is only a matter or
  8. recording "HERE" and do subtractions. Forward labels record the
  9. place where we should write the offset, and then when we get to
  10. that point later on, the label records the offset there.
  11. To avoid using dict memory in compilation targets, we
  12. pre-declare label variables here, which means we have a limited
  13. number of it. For now, 4 ought to be enough. (cont.)