Actually, using GCC, you can use globals anywhere. In our product, TotalCross
(www.totalcross.com), you can use ARM native threads with globals support, and
works fine on all palm os arm devices.
The idea is tell GCC to use a register for globals (e.g.: r10), then in the
main program you save the R10 (selected globals register) and in your thread
you recover the r10.
These are the flags you use on the makefile:
-ffixed-r8 -ffixed-r9 -mpic-register=r10 -msingle-pic-base
Here i tell gcc to don't use r8 and r9 because they are being used by the main
app, and use r10 for globals.
In the main app, i save the current r10 using this:
register uint32 got asm("r10");
mythreadparam->got = got;
Then in the thread i recover the r10.
This is not directly related to your problem, but you may want to use it if you
need, later.
regards
guich
--
For information on using the ACCESS Developer Forums, or to unsubscribe, please
see http://www.access-company.com/developers/forums/