LWN.net Logo

GCC Explorer - an interactive take on compilation

GCC Explorer - an interactive take on compilation

Posted Jun 3, 2012 5:37 UTC (Sun) by quotemstr (subscriber, #45331)
In reply to: GCC Explorer - an interactive take on compilation by vonbrand
Parent article: GCC Explorer - an interactive take on compilation

Your transformation isn't valid: consider multithreading. One printf will write to a stream as an atomic operation (enforced by internal stdio locks), but the output from discrete output functions may overlap.


(Log in to post comments)

GCC Explorer - an interactive take on compilation

Posted Jun 3, 2012 9:23 UTC (Sun) by dgm (subscriber, #49227) [Link]

That's why a naive coder with a optimizing compiler cannot beat a good coder. The compiler is bound by the precise semantics of the code, even if there are aspects of it that you don't care. The compiler has to care.

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds