H1 2015 Priorities and Bare-Metal Programming

Iain Buclaw via Digitalmars-d digitalmars-d at puremagic.com
Sun Feb 1 09:20:36 PST 2015


On 1 February 2015 at 16:58, Daniel Murphy via Digitalmars-d
<digitalmars-d at puremagic.com> wrote:
> "Iain Buclaw via Digitalmars-d"  wrote in message
> news:mailman.5711.1422808332.9932.digitalmars-d at puremagic.com...
>
>> Only if optimisation passes removes the promise the compiler gives to
>> the user.  I'll have to check whether or not the proposed
>> implementation in gdc is even viable vs. having a 'C volatile' type.
>
>
> How could it not be?  It's just *(volatile T*)ptr = value; - which gcc ir
> can obviously express.

Depends on how you represent it.  :)

I believe the correct way would be mem_ref[(volatile T*) ptr] = value;

Miss a propagation of volatile or side_effects flag setting though,
then *poof* the volatility is gone.

Iain.


More information about the Digitalmars-d mailing list