| Register | FAQ | Calendar | Search | Today's Posts | Mark Forums Read |
|
#11
| |||
| |||
| On Mar 3, 3:15 pm, Robert Riebisch <Robert.Riebi...@arcor.de> wrote: > Jim Leonard wrote: > > So, does anyone know of a nice .map analyzer utility out there, to > > prevent me from re-inventing the wheel? :-) > > Erm... What do you need this tool for? All info is already in the .map > file. Yes, but I am not going to visually inspect a ~200KB .MAP file looking for the largest chunks of the DATA segment. I will probably write a small utility to analyze the .MAP file, determine the sizes of every element, and then print out the 10 largest ones or something. |
|
#12
| |||
| |||
| Jim Leonard wrote : > > I will probably write a small utility to analyze the .MAP file, > determine the sizes of every element, and then print out the 10 > largest ones or something. Import the map file into an Excel sheet with the hex offsets in column A and the symbol names in column B. Then use the formula "=HEX2BIN(A2)-HEX2BIN(A1)" in column C - that is, depending on which row is on top. Copy column C to column D with values only - then sort on column D. -- /klaus |
|
#13
| |||
| |||
| On Mar 4, 1:05 am, Klaus Jorgensen <k...@no.spam> wrote: > Import the map file into an Excel sheet with the hex offsets in column > A and the symbol names in column B. > Then use the formula "=HEX2BIN(A2)-HEX2BIN(A1)" in column C - that is, > depending on which row is on top. > Copy column C to column D with values only - then sort on column D. I'll try that tonight, thanks very much! Always learning, even after 20 years of working with TP... This exercise has clued me into a few things: - foo:string is the same as foo:string[255] (knew this already but it's a good reminder never to use empty strings again) - PChar arrays (aka defined as const foo:PChar='testing') take up space in the data segment :-/ - The compiler takes advantage of the fact that PChar arrays are pointers to null-terminated strings and is smart enough to optimize 100% identical contents by only having one copy and the others reference it via pointers. I was not expecting that at all; that is very cool. |
|
#14
| |||
| |||
| On Mar 4, 1:05 am, Klaus Jorgensen <k...@no.spam> wrote: > Then use the formula "=HEX2BIN(A2)-HEX2BIN(A1)" in column C - that is, Hm... Excel 2003's HEX2BIN claims in the helpfile that it doesn't support numbers over 1FF. I'll write my utility anyway :-) |
|
#15
| |||
| |||
| Jim Leonard wrote : > On Mar 4, 1:05 am, Klaus Jorgensen <k...@no.spam> wrote: >> Then use the formula "=HEX2BIN(A2)-HEX2BIN(A1)" in column C - that is, > > Hm... Excel 2003's HEX2BIN claims in the helpfile that it doesn't > support numbers over 1FF. > > I'll write my utility anyway :-) Sorry - my fingers or keyboard must have had an off day.... Should have been HEX2DEC and not HEX2BIN. -- /klaus |
![]() |
| Thread Tools | |
| Display Modes | |
In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.