$CODEALIGN PROC not work (x86)
Original Reporter info from Mantis: barlone @barloneD
-
Reporter name:
Original Reporter info from Mantis: barlone @barloneD
- Reporter name:
Description:
By studying the compiled code in internal disassembler I saw that procedures entry point always aligned to 0x10 (16). Any combination of directive $CODEALIGN PROC (or compiler option -OaPROC) does not affect to result.
This greatly affects the size of EXE.
Small test in attach. Below his translation to asm:
00401400 55 push %ebp
^^^^^^^^
00401401 89e5 mov %esp,%ebp
test1.lpr:10
00401403 ff05a0b04000 incl 0x40b0a0
test1.lpr:11
00401409 c9 leave
0040140A c3 ret
0040140B 0000 add %al,(%eax)
0040140D 0000 add %al,(%eax)
0040140F 00 add %dl,-0x77(%ebp)
test1.lpr:14
00401410 55 push %ebp
^^^^^^^^
00401411 89e5 mov %esp,%ebp
test1.lpr:15
00401413 ff0da0b04000 decl 0x40b0a0
test1.lpr:16
00401419 c9 leave
0040141A c3 ret
0040141B 0000 add %al,(%eax)
0040141D 0000 add %al,(%eax)
0040141F 00 add %dl,-0x77(%ebp)
Steps to reproduce:
View any program with subroutines in internal Disassembler.
Mantis conversion info:
- Mantis ID: 19463
- OS Build: XP SP3
- Build: 2011/05/12
- Platform: Windows
- Version: 2.5.1
- Fixed in version: 2.6.0
- Fixed in revision: 17659 (#93e53e19)
- Monitored by: » crossbuilder (Burkhard Carstens)