#15046 - cosmic4z - Fri Jan 16, 2004 4:21 pm
I have 8, u32 (long) values in my c, source file, thus:
long CAM_p1_x; // top left (x)
long CAM_p1_y; // top left (y)
long CAM_p2_x; // top right (x)
long CAM_p2_y; // top right (y)
long CAM_p3_x; // bottom left (x)
long CAM_p3_y; // bottom left (y)
long CAM_p4_x; // bottom right (x)
long CAM_p4_y; // bottom right (y)
When I complie my project (using devkitadv), I look in the generated mapfile and they do not appear in the same order in memory as specified in my source file.
The relevant part of the map file, looks like this:
COMMON 0x03000888 0x40 camera.o
0x0 (size before relaxing)
0x03000888 CAM_p3_y
0x0300088c CAM_p1_y
0x03000890 CAM_right_y
0x03000894 CAM_left_x
0x03000898 CAM_p4_y
0x0300089c CAM_p2_x
0x030008a0 CAM_p4_x
0x030008a4 CAM_right_x
0x030008a8 CAM_p3_x
0x030008ac CAM_p1_x
0x030008b0 CAM_top_x
0x030008b4 CAM_bottom_y
0x030008b8 CAM_p2_y
0x030008bc CAM_left_y
0x030008c0 CAM_bottom_x
0x030008c4 CAM_top_y
As you can see, the order has been mixed up.
Why is this, and is there anything I can do to force the same order as per my source file?
Many thanks,
Jamie
_________________
Qwak - www.qwak.co.uk | Forum - www.qwak.co.uk/forum/
long CAM_p1_x; // top left (x)
long CAM_p1_y; // top left (y)
long CAM_p2_x; // top right (x)
long CAM_p2_y; // top right (y)
long CAM_p3_x; // bottom left (x)
long CAM_p3_y; // bottom left (y)
long CAM_p4_x; // bottom right (x)
long CAM_p4_y; // bottom right (y)
When I complie my project (using devkitadv), I look in the generated mapfile and they do not appear in the same order in memory as specified in my source file.
The relevant part of the map file, looks like this:
COMMON 0x03000888 0x40 camera.o
0x0 (size before relaxing)
0x03000888 CAM_p3_y
0x0300088c CAM_p1_y
0x03000890 CAM_right_y
0x03000894 CAM_left_x
0x03000898 CAM_p4_y
0x0300089c CAM_p2_x
0x030008a0 CAM_p4_x
0x030008a4 CAM_right_x
0x030008a8 CAM_p3_x
0x030008ac CAM_p1_x
0x030008b0 CAM_top_x
0x030008b4 CAM_bottom_y
0x030008b8 CAM_p2_y
0x030008bc CAM_left_y
0x030008c0 CAM_bottom_x
0x030008c4 CAM_top_y
As you can see, the order has been mixed up.
Why is this, and is there anything I can do to force the same order as per my source file?
Many thanks,
Jamie
_________________
Qwak - www.qwak.co.uk | Forum - www.qwak.co.uk/forum/