I found the trick here, in the web of cprogramming.com:
http://www.cprogramming.com/tips/sho...ount=30&page=0

what about using a register for store the pointer of a global struct:

Code:
register GlobalVars *g asm(\\"a4\\");
I found this link too: http://gcc.gnu.org/onlinedocs/gcc-4....-Reg-Vars.html

I would like to test by myself if this provoke a speed improvement in my program, but using MINGW for windows I don't know how to do it. I get this error for the above line:

Code:
syntax error before asm
Anyone knows how to do it for windows/intel plataform. Also "a4" is the name of the register to use. Any recomendation/tip on what register to use?

Want to test it. theory is good, but in speed issues I think it is better to test by myselg it in order to make conclusions. I will post my results

thx