flat assembler
Message board for the users of flat assembler.
Index
> Windows > Compiler bug? |
Author |
|
JohnFound 02 Jan 2005, 23:06
No, it is not a bug. It is normal behaviour. The uninitialized data (i.e. declared with rb, rw, rd, rq or "db ?", etc. and when it is declared at the end of the data section (after all initialized data) will not be included in the executable file, but will be created directly in memory during loading of PE executable (remember this data memory is only reserved, it doesn't contains defined data).
So, in order to get minimal file size, you MUST place your uninitialized data at the end of the sections. Regards. |
|||
02 Jan 2005, 23:06 |
|
snifit 02 Jan 2005, 23:10
Ah that explains it, thanks.
|
|||
02 Jan 2005, 23:10 |
|
Madis731 04 Jan 2005, 22:12
As you can see you have written code AFTER data, but you still have minimal size exe. In PE file code is right after the header and data is always at the back end, nice optimization concerning size.
|
|||
04 Jan 2005, 22:12 |
|
Vasilev Vjacheslav 05 Jan 2005, 08:48
often uninitialized data placed in special section
Code: section '.idata' data readable szTest db "test",0 section '.udata' readable writeable szBuffer rb 1024 |
|||
05 Jan 2005, 08:48 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.