Sorry for the newb questions, but I can't find the answers in either the UV2 or C51 manuals. 1) When UV2 gives the Program Data Size after building a project, is this JUST data (first 128 bytes), or is idata included in this total as well? I think it is all 256 bytes, but wanted to make sure. 2) If all internal data memory is exceeded, is the data simply truncated there or is it moved to xdata or something else? 3) I understand that access to xdata is slower than for internal RAM, but is it possible to put a quantification on "slower"? I realize this is likely micro dependent, but a ballpark would be fine. I'm using the T89C51CC01 from Atmel if anyone knows the exact value for that micro. Could not find this either in the CC01 manual.
if I exceed the 128 bytes of data space but do not explicitly locate this extra data in idata space, will I also get a linker error YES a linker error or will the compiler simply place this data in idata space? the compiler can not detect space usage and the linker can not change mov a,addr to mov r0,#addr mov a,@r0 which would upset each and every jmp in the whole module/program. Anyhow, such an automatic action would be truly a nuisance, you would never know what was changed and what not. "The '51 aint no PC" and thus you do NOT want "automatic relocation" Erik
"the compiler can not detect space usage" The compiler only sees a single "compilation unit" at a time. So the compiler can - and does - detect the memory usage of each "compilation unit" in isolation - and reports it in the Listing file. What the compiler cannot do is to see the entire application as a whole - only the Linker can do that. Also, the Linker handles Overlaying; not the compiler - so the compiler can't tell what difference that might make...