Thursday, 15 September 2011

c++ - Using datatypes according to OS Architecture -



c++ - Using datatypes according to OS Architecture -

i revising concepts in c/c++. started datatypes , came across 1 question, when utilize datatypes following?

we have uint_64 uint_32 , uint_16. clear understanding please tell me number (i.e. 64, 32, 16) meant number of bits particular datatype , how affected os architecture ?

your understanding correct. 64, 32, 16 stand number of bits used store uint. os architecture not constrain utilize specific type, can influence performance of program.

the os can influence maximum amount of memory process can use, because gives virtual address length.

also if utilize 32bit os, utilize 32bit registers in cpu performance of using uint_64 lower. using 64bit os enable using 64bit registers in cpu , using uint_64 fit in 1 register.

c++ c types

No comments:

Post a Comment