1
0
mirror of https://github.com/hsoft/collapseos.git synced 2024-11-10 02:28:06 +11:00
collapseos/blk/203

17 lines
651 B
Plaintext
Raw Normal View History

Flow
There are 2 label types: backward and forward. For each type,
there are two actions: set and write. Setting a label is
declaring where it is. It has to be performed at the label's
destination. Writing a label is writing its offset difference
to the binary result. It has to be done right after a relative
jump operation. Yes, labels are only for relative jumps.
For backward labels, set happens before write. For forward
labels, write happen before set. The write operation writes a
dummy placeholder, and then the set operation writes the offset
at that placeholder's address.
(cont.)