[Issue 9243] Order locals to prevent buffer overflow attacks

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Dec 29 20:33:21 PST 2012


http://d.puremagic.com/issues/show_bug.cgi?id=9243



--- Comment #3 from bearophile_hugs at eml.cc 2012-12-29 20:33:19 PST ---
(In reply to comment #2)

> Dmd already does this using graph coloring. I guess dmd is advanced? :-)

Despite in some cases DMD compiles in a sub-optimal way compared to LDC/GDC,
given the complexity of D language DMD is surely an advanced compiler.


> Dmd doesn't do this one, although it could based on the same weighting
> algorithm used to prioritize register assignments.

The point of my comments isn't about what dmd does or doesn't. The point is
that some compilers perform optimizations that go against the safety feature
you propose here. So I have suggested that it's better to activate this safety
feature only when the programmer wants it, and let the compiler do things its
way otherwise.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list