Understanding Delphi MAP File

后端 未结 3 1617
囚心锁ツ
囚心锁ツ 2021-02-07 23:19

Here is the sample of MAP file from my test project...

.......
 .......
 .......
 0001:001EFC14 00000020 C=CODE     S=.text    G=(none)   M=Vcl.CategoryButtons A         


        
相关标签:
3条回答
  • 2021-02-07 23:28

    The format is:
    SegmentId:StartAddress Length C=SegmentClass S=SegmentName G=SegmentGroup M=ModuleName

    The ACBP has something to do with alignment but I can't tell you what the hex numbers mean.

    C=CODE: Code-Segment
    C=ICODE: Initialization Code-Segment
    C=DATA: (initialized) Data-Segment
    C=BSS: (uninitialized) Data-Segment
    C=TLS: Thread Local Storage

    G=(none): No Segment-Group

    0 讨论(0)
  • 2021-02-07 23:28

    It mean that your asm code of your unit MainU start at $00232C28 address and the length of compiled unit is $00006998 bytes.

    The segment class (C=) is CODE, defined at beginning of map file.

    The segment name (S=) is .text

    The segment group (G=) is none.

    The segment module (M=) is MainU

    The ACBP attribute = A9 mean:

    • Unnamed absolute portion of memory address space
    • A public combining
    • The segment may be larger than 64K

    Check also: http://files.mpoli.fi/unpacked/software/programm/general/ss0288.zip/ss0288_4.txt

    0 讨论(0)
  • 2021-02-07 23:36

    According to this Embarcadero docwiki page the A, C and B are for Alignment, Combination and "Big". It seems the page does not explain what the P means. The hex value is a mask, although as far as I can see it doesn't list all values. (The listed values don't allow for an odd value for instance)

    Alignment

    • 00 - An absolute segment
    • 20 - A byte-aligned segment
    • 40 - A word-aligned segment
    • 60 - A paragraph-aligned segment
    • 80 - A page-aligned segment
    • A0 - An unnamed absolute portion of storage

    Combination

    • 00 - Cannot be combined
    • 08 - A public combining segment

    Big (for 16 bit)

    • 00 - Segment less than 64 K
    • 02 - Segment exactly 64K
    0 讨论(0)
提交回复
热议问题