??? 06/24/10 17:33 Read: times |
#176904 - This is one of those architectural limitations Responding to: ???'s previous message |
David Good said:
In playing with pointers to structs, I've noticed that accessing the members is indeed more expansive (sic?) than accessing the members of a real object (i.e. not through a pointer de-reference). I guess you meant "expensive" there? Of course it is - because the compiler can't know (at compile time) the location to access, so it has to generate runtime code to compute it. But is the overhead really that great? It should just be a matter of adding an offset to the pointer - surely? I note that you're using a "generic" (ie, not memory-specific) pointer - that doesn't help! So, what is the general practice for 8051s (if one can generalize something like this) Use memory-specific pointers if you can! |
Topic | Author | Date |
General pointer usage techniques | 01/01/70 00:00 | |
This is one of those architectural limitations | 01/01/70 00:00 | |
Reimplement the standard library functions? | 01/01/70 00:00 | |
re pointers | 01/01/70 00:00 | |
As ever...![]() | 01/01/70 00:00 |