comp.lang.ada
 help / color / mirror / Atom feed
From: Per Jakobsen <pdj@knaldgas.dk>
Subject: Re: Odd AVR-Ada code generation issue with constant record type
Date: Fri, 5 Jul 2019 05:19:46 -0700 (PDT)
Date: 2019-07-05T05:19:46-07:00	[thread overview]
Message-ID: <fd788881-59d9-4ce1-89aa-f2fc40331aa7@googlegroups.com> (raw)
In-Reply-To: <b78a975c-8ef1-41ac-b4c2-c1c07675765a@googlegroups.com>


> First of all you are using an old compiler... Maybe upgrading the compiler (if possible) would help.

It might, although I *am* using the newest avr-ada version I can find. If there is a newer I will certainly try!?


> I would (in the following order):
> 1) declare the registers as Atomic (or Atomic and Volatile but that doesn't matter as Atomic implies Volatile).

Declaring the registers Atomic certainly helped a lot - No more run-time "calculations", although all constants are put into SRAM (like Reg_C above), instead of pure "LDI" instructions (Reg_B).


> 2) define constants for the values you are assigning.

Does not help - Exactly the same behavior.


Thanks for the Atomic hint!

Anyone knows if there is a newer version of avr-ada out there? Or have instructions on how to create a new?


  parent reply	other threads:[~2019-07-05 12:19 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-05  8:57 Odd AVR-Ada code generation issue with constant record type Per Jakobsen
2019-07-05  9:24 ` Mark Lorenzen
2019-07-05 12:19 ` Per Jakobsen [this message]
2019-07-08 14:49   ` Stéphane Rivière
2019-07-09 12:12 ` Per Jakobsen
2019-07-09 15:30 ` Simon Wright
2019-07-09 18:10 ` Per Jakobsen
2019-07-09 18:46 ` Per Jakobsen
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox