On 10/26/2016 04:46 PM, Georg-Johann Lay wrote:
+    if { [istarget avr-*-*] } {
+       # If the value of a label does not fit into 16 bits, the linker
+       # will generate a stub (containing a direct jump) and we end up
+       # with the address of the stub instead of the address of the very
+       # label.  Whereas it is legitimate to use such addresses for
+       # indirect jumps, it makes no sense to perform any arithmetic
+       # on such addresses.
+       return [check_no_compiler_messages label_offsets assembly {
+           #ifdef __AVR_3_BYTE_PC__
+           #error NO
+           #endif
+       }]
+    }
+    return 1;

I'm not sure I understand the failure mode. Sure, you're not getting the address of the actual label, but the address of one that's equivalent - so why can't you do arithmetic on it? Where does it go wrong?

Am I right in thinking that only the execution test actually fails?


Bernd

Reply via email to