-
Notifications
You must be signed in to change notification settings - Fork 15
Small Data
Claudiu Zissulescu edited this page Apr 18, 2017
·
9 revisions
Data Type | Range | #Elements | Size |
---|---|---|---|
char | [-256,255] | 512 | 512 bytes |
short | [-256,510] | 383 | 766 bytes |
int | [-256,1020] | 319 | 1276 bytes |
The lower limit depends on the possibility to access byte-aligned datum, hence, it is hard connected to the range of s9 short immediate (i.e., -256). Any other access can be done using address-scaling feature of the load/store instructions.
The number of elements which we can fit in sdata section highly depends on the data alignment properties. For example if we use only 4 byte datum, 1 byte aligned, we can fit up to 128 elements in the section.