From: Borja F. <bor...@gm...> - 2011-04-21 12:14:09
|
I'm 50% done with the global lds/sts stuff. Currently, these instructions get selected for non array variables for char and int types. For the array case, something like char g_var[11] = 0 is generating: ldi r24, 0 ldi r30, g_var // should have the lo8, hi8 macros, i know xD ldi r31, g_var std Z+11, r24 obviously this add has to be performed at compile time to this: ldi r24, 0 sts g_var+11, r24 also I'm looking into how how generate the hi8/lo8 macros that are needed to get the lo and hi part of the addresses. So at this stage I'm working out these cases to get the optimal code sequence, i'll post an update when i advance further with this. |