flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
shism2
Whats the difference between reserve data and normal data?
Ex : rd 1 = reserve data Ex : dw ? normal data |
|||
![]() |
|
okasvi
Quote: The data reservation directive should be followed by only one numerical from fasm.pdf _________________ When We Ride On Our Enemies support reverse smileys |: Last edited by okasvi on 06 Mar 2006, 12:56; edited 1 time in total |
|||
![]() |
|
Madis731
...but there will be a difference if you put:
Code:
rb 1048576
or Code:
times 1048576 db ?
at the end of the file. In the first case your resulting file will be small, but with the latter code you can easily add 1MB to your resulting binary. |
|||
![]() |
|
Tomasz Grysztar
The "rb 1048576" and "times 1048576 db ?", and "db 1048576 dup ?" have all exactly the same result. The only difference is that assembler processes the "rb" faster.
|
|||
![]() |
|
vid
isn't "times XXX db <something>" optimized exception?
|
|||
![]() |
|
Madis731
Maybe I got it wrong then but should they be different as DB defines each byte, but RB can reserve only that byte without explicitly doing any memory-store operations on it. RB only points to the memory, while DB *ALSO* defines each byte in that region. Correct me if I'm wrong!
|
|||
![]() |
|
vid
Madis: but defining byte with value "?" is same as reserving it
|
|||
![]() |
|
Tomasz Grysztar
"RB 1" == "DB ?"
They do exactly the same - reserve one byte as uninitialized data. |
|||
![]() |
|
vid
Tomasz: isn't "times XXX db <something>" optimized exception?
|
|||
![]() |
|
Tomasz Grysztar
No, why did you think so?
|
|||
![]() |
|
vid
some times it was only way to define long initialized arrays, so it kind-of needed that. And i have some (probably false) flashbacks about you mentioning something like this optimization.
|
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.
Website powered by rwasa.