Hi again, >> Like the manual says, when a variable has an >>absolute location but no initializer it is not allocated by the >>compiler/linker. > > Hmm....can you elaborate a bit...as this is just a hardware register > I do not want it to be allocated...but that of course depends on what > allocated means here. My worry is that the access to it might be slower > if the compiler/assembler does not see the full definition.
Allocated means that you nor the linker can place any other variable at that address. It is marked occupied and if it is global then it must be zeroed unless initialized before reaching main as specified by the C spec. When you use __at without initializer however, SDCC does not allocate and you can define another variable (with __at) at the same address. It will also not zero the variable at startup. This is probably exactly what you need for a hardware register. Maarten ------------------------------------------------------------------------------ HPCC Systems Open Source Big Data Platform from LexisNexis Risk Solutions Find What Matters Most in Your Big Data with HPCC Systems Open Source. Fast. Scalable. Simple. Ideal for Dirty Data. Leverages Graph Analysis for Fast Processing & Easy Data Exploration http://p.sf.net/sfu/hpccsystems _______________________________________________ Sdcc-user mailing list Sdcc-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sdcc-user