We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6350272 commit 0e4bf82Copy full SHA for 0e4bf82
src/avr_opcodes.c
@@ -705,12 +705,12 @@ int avr_get_archlevel(const AVRPART *p) {
705
706
AVRMEM *mem = avr_locate_flash(p);
707
708
- if(mem) { // Add opcodes needed for large parts in any case
+ if(mem) { // Add opcodes needed for large parts (XMEGAs count as large)
709
if(mem->size > 8192)
710
ret |= OP_AVR_M; // JMP, CALL
711
- if(mem->size > 65536)
+ if(mem->size > 65536 || is_pdi(p))
712
ret |= OP_AVR_L; // ELPM
713
- if(mem->size > 128*1024)
+ if(mem->size > 128*1024 || is_pdi(p))
714
ret |= OP_AVR_XL; // EIJMP, EICALL
715
}
716
0 commit comments