Re: AVR registers
Even if you'll ever find the answer to this question, that would change your programming approach ?
Most of the AVR instruction have a single 16-bit word format.
As you probably notice, only 8 instructions suffers of the drawbacks of the AVR architecture.
These are : ANDI, CBR, SBR, SER, CPI, LDI, SBCI and SUBI.
More exactly when an immediate constant is involved in the operation with register.
Since the constant is stored on 8 bits (range 0 - 255) and 4 bits are reserved for operation code, from the 16-bit word format, there are only 4 bits left available for designed register.
Because with 4 bits you can have only 16 value, you can ask why the AVR designer choose the upper ones, r16-r31.
Well, the answer is because the r26-r31 are already used as indirect address pointers (alterable as well but in narrow range (0 - 63) with ADIW and SBIW).