On our server, a word is a 16-bit data type. So 32-bit quatities are double words and 64-bit quantities are quad words.
C declaration | Intel data type | Assemby-code suffix | Size (bytes) |
char | byte | b | 1 |
short | word | w | 2 |
int | double word | l | 4 |
long, char* | quad word | q | 8 |
float | single precision | s | 4 |
double | double precision | l | 8 |
Most assembly-code instructions generated by gcc have a single character suffix denoting the size of the operand.
For example the data movement instruction has four variants
- movb (move byte)
- movw (move word)
- movl (move double word)
- movq (move quad word)
There is no ambiguity between int and double using the same assembly suffix, since the instructions are different.
© 2017 – 2018, Eric. All rights reserved.