Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

How to find theprogram size in keil

Status
Not open for further replies.

thannara123

Advanced Member level 4
Joined
Jan 7, 2010
Messages
1,455
Helped
120
Reputation
240
Reaction score
111
Trophy points
1,353
Location
God's Own country India, India
Activity points
9,455
Hi experts , I want to know the size of the my program written Keil (8051 Compact able ) ,How can i find it,any simple way to understand it ?
 

nandhu015

Advanced Member level 5
Joined
Feb 11, 2006
Messages
1,965
Helped
300
Reputation
600
Reaction score
224
Trophy points
1,353
Location
India
Activity points
9,845
while compiling the code, Keil will display, code size & data size in output window
 

thannara123

Advanced Member level 4
Joined
Jan 7, 2010
Messages
1,455
Helped
120
Reputation
240
Reaction score
111
Trophy points
1,353
Location
God's Own country India, India
Activity points
9,455
thanks for reply ,
Build target 'Target 1'
compiling g.c...
linking...
Program Size: data=9.0 xdata=0 code=53
"k" - 0 Error(s), 0 Warning(s).

how to ,or how to understand in Kilobyte or bite ?
 

js

Full Member level 5
Joined
Oct 9, 2005
Messages
265
Helped
38
Reputation
76
Reaction score
36
Trophy points
1,308
Activity points
2,662
I only work with small programs and allways get only bytes (without "k")
:)
...but I think this is k=K=kilo (1024x) bytes..

p.s.
add some array:
unsigned char data arrayOfBytes[1000];
and you will see change in code size...
:)
 

ckshivaram

Advanced Member level 5
Joined
Apr 21, 2008
Messages
5,070
Helped
2,149
Reputation
4,304
Reaction score
2,089
Trophy points
1,393
Location
villingen (Germany) / Bangalore
Activity points
30,094
all the files generated by compiler like object , hex, and other files can be seen in the directory where it creates hex file... you can check the properties of it to find the size...
 

alexan_e

Administrator
Joined
Mar 16, 2008
Messages
11,895
Helped
2,021
Reputation
4,158
Reaction score
2,031
Trophy points
1,393
Location
Greece
Activity points
64,377
all the files generated by compiler like object , hex, and other files can be seen in the directory where it creates hex file... you can check the properties of it to find the size...

The filesize is not at all same as the code size, for example this is a 228 byte code which is written is a hex file of 664 bytes.
The hex file includes address info too and not just the code bytes.

Code:
:0400000012C0FECF5D
:10000400FDCFFCCFFBCFFACFF9CFF8CFF7CFF6CFA8
:10001400F5CFF4CFF3CFF2CF21C0F0CFEFCFEECFB7
:10002400EDCFF894EE27ECBBF1E0FBBFEBBFE5BFEF
:10003400F8E1F1BDE1BD8DE0A2E0BB27ED938A9527
:10004400E9F780E094E0A0E6ED930197E9F7EFE5A6
:10005400EDBFE4E0EEBFC0E6D1E01AC08A93AA93F4
:10006400EA93EFB7EA93E5B1E8BBA0E09099A1E089
:10007400E1E0EA2711F4909801C0909A8BE18A9507
:10008400F1F7369AE991EFBFE991A9918991189511
:10009400E0E0E8BBEFEFE7BBE0E0E5BBE4BBE2BBDD
:1000A400EFEFE1BBE0E0E3BFE2BFEFBDEEBDEDBDCE
:1000B400ECBDE7BDE6BDEBBDEABDE9BDE8BDE2BD13
:1000C400E5BDE4BDE3BDE5BFE9BFE0E8E8B9E0E0D4
:1000D400E0BFE0E6E7B9EEECE6B97894FFCFFFCFF6
:00000001FF

The correct sizes can only be viewed in the compiler report screen or maybe a compiler log file

Alex
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top