@Deniil
Be careful "register" keyword is strong, the compiler quicly removes every thing, if GCC find out your not going to save the values.
yes its a "hint" to the compiler if you abuse it most likely wont work, but as you see it does cut down a allot when it works.
Easy to test if compile your code whit --ggdb flag and the use objdump to see what result is.
register int v32;
register long long int v64;
v64 = 0;
1000270: 39 20 00 00 li r9,0
1000274: 39 40 00 00 li r10,0
v64+=1000;
1000278: 31 4a 03 e8 addic r10,r10,1000
100027c: 7d 29 01 94 addze r9,r9
v32 = 0;
1000280: 39 00 00 00 li r8,0
v32+=1000;
1000284: 39 08 03 e8 addi r8,r8,1000
(But if you use optimization flags it might be done automaticly.)
32 registers becomes 16 when you have lot of 64bit variables on 32bit CPU
![](https://www.amigans.net/uploads/smil3dbd4d6422f04.gif)
some registers are reserved like r1 (stack pointer).
http://www.ibm.com/developerworks/linux/library/l-powarch/Well PowerPC has many registers, and many special registers like CTR that is reserved for loop, and branches, maybe this what your where thinking about?
Edited by LiveForIt on 2012/9/25 0:28:24
Edited by LiveForIt on 2012/9/25 0:38:34
Edited by LiveForIt on 2012/9/25 8:39:50