What should happen here?
Walter Bright
newshound2 at digitalmars.com
Sun Sep 26 02:13:50 UTC 2021
On 9/25/2021 6:02 PM, Steven Schveighoffer wrote:
> As I said, the optimizer is fighting you the entire way.
I'd reframe it as the user is trying to impose his own semantics on the
optimizer :-)
Selecting semantics that enable aggressive optimizations is always a dance
between user predictability and high performance. High performance usually wins.
Disabling dead assignment elimination would have a catastrophic deleterious
effect on optimizations. A lot of template bloat would remain.
> But I still am wishing for a simple "keep this alive" mechanism that doesn't add
> too much cruft, and is guaranteed to keep it alive.
That's exactly what addRoot() is for.
More information about the Digitalmars-d
mailing list