diff options
author | Quentin Carbonneaux <quentin@c9x.me> | 2023-01-09 14:05:06 +0100 |
---|---|---|
committer | Quentin Carbonneaux <quentin@c9x.me> | 2023-01-09 14:05:06 +0100 |
commit | f1b21d145ba03c6052b4b722dc457f8e944e6fca (patch) | |
tree | b7dacee406a295b57e88f7b9f5766026cc84709a | |
parent | 0956b11331a8c0d5880fff1eb35e8f3ffdc452b8 (diff) | |
download | roux-f1b21d145ba03c6052b4b722dc457f8e944e6fca.tar.gz |
reorder some sections in doc v1.1
-rw-r--r-- | doc/il.txt | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/doc/il.txt b/doc/il.txt index 857050f..cc3e021 100644 --- a/doc/il.txt +++ b/doc/il.txt @@ -712,24 +712,6 @@ towards zero. `loadsw` to make explicit that the extension mechanism used is irrelevant. - * Stack allocation. - - * `alloc4` -- `m(l)` - * `alloc8` -- `m(l)` - * `alloc16` -- `m(l)` - - These instructions allocate a chunk of memory on the - stack. The number ending the instruction name is the - alignment required for the allocated slot. QBE will - make sure that the returned address is a multiple of - that alignment value. - - Stack allocation instructions are used, for example, - when compiling the C local variables, because their - address can be taken. When compiling Fortran, - temporaries can be used directly instead, because - it is illegal to take the address of a variable. - * Blits. * `blit` -- `(m,m,w)` @@ -750,6 +732,24 @@ towards zero. preferable that frontends generate calls to a supporting `memcpy` function. + * Stack allocation. + + * `alloc4` -- `m(l)` + * `alloc8` -- `m(l)` + * `alloc16` -- `m(l)` + + These instructions allocate a chunk of memory on the + stack. The number ending the instruction name is the + alignment required for the allocated slot. QBE will + make sure that the returned address is a multiple of + that alignment value. + + Stack allocation instructions are used, for example, + when compiling the C local variables, because their + address can be taken. When compiling Fortran, + temporaries can be used directly instead, because + it is illegal to take the address of a variable. + The following example makes use of some of the memory instructions. Pointers are stored in long temporaries. |