> This approach requires two byte more RAM. That is true >Then bitwise operation or ((unsigned char *)&add)[0] method.
I did not quite follow what you wrote ... but extrapolating that you were offering ((unsigned char *)&add)[0] as a better alternative, shouldn't that be *((unsigned char *)&add)[0]? Also SDCC/PIC generates poor code for pointers ...especially for generic pointers, so *((__data unsigned char *)&add)[0] could potentially be better. Don't know how well the optimizer would optimize any of above but I do know that access to global variables/arrays with constant indexes and struct members with are handled reasonably optimized. I don't have SDCC at hand right now to check any of this with the compiler, so this is all speculation from my part. cheerios Kusti ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ Sdcc-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/sdcc-user
