[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[RP] register variable considered BAD
From: |
Jonathan Walther |
Subject: |
[RP] register variable considered BAD |
Date: |
Sun, 6 May 2001 16:36:29 -0700 (PDT) |
-----BEGIN PGP SIGNED MESSAGE-----
Was reading the Gnu CC manual again. It had this interesting
tidbit: When the address of a variable is taken, it will never
be assigned a register. EVER. Even if the register keyword
was used. I believe this is the case with the code in ratpoison
that does use register, and that would be why I noticed no
code difference in the generated object files when I compiled
with and without the register keyword. If you want to actually
use registers, don't give the compiler hints, use inline assembly.
Jonathan
-----BEGIN PGP SIGNATURE-----
Version: 2.6.3ia
Charset: noconv
iQCVAwUBOvXf/sK9HT/YfGeBAQGKpAP+P8y+27jun1nZaiseeubVnT1yINsAIUr8
nbN133UiwJR2rPGMVjelh99HBuRN6Fpq6FwLEn6+LRjArDAuXqOhaOAI0olZGCRu
AhmbdHcO4iKQBTql7aeM8vr2OU13b9y3UvCCp6nUlHPCftL116g20R578UfQUQrm
8kEnbqbhAx8=
=b3ES
-----END PGP SIGNATURE-----
- [RP] register variable considered BAD,
Jonathan Walther <=