Mail Archives: djgpp/1996/12/12/16:20:20
Erik Max Francis (max AT alcyone DOT com) wrote:
: luca wrote:
: > Hi,
: > what is faster ?
: > int or short int ?
: In general, for any compiler, the native word size that is used by the
^^^^^^^^^^^^
: processor is going to be faster than any other combination; generally this
: is called an int in a C compiler for that architecture. For DJGPP the int
: is 32 bits.
Not true... Here are some examples:
Microsoft FORTRAN 5.x has default INTEGER as INTEGER*4 and it is a 16-bit
compiler! (INTEGER*2 is faster).
All compilers I have seen for the 8-bit computers have sizeof(int)==2. 1
byte chars are faster. Actually some of them for that reason have shorts of
1 byte in size.
<E-mail: sime AT fly DOT cc DOT fer DOT hr >
<2nd E-mail: simun DOT mikecin AT fer DOT hr >
<URL: http://fly.cc.fer.hr/~sime>
- Raw text -