This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/59448] Code generation doesn't respect C11 address-dependency
- From: "joseph at codesourcery dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 29 Oct 2014 00:07:36 +0000
- Subject: [Bug middle-end/59448] Code generation doesn't respect C11 address-dependency
- Auto-submitted: auto-generated
- References: <bug-59448-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59448
--- Comment #19 from joseph at codesourcery dot com <joseph at codesourcery dot com> ---
On Tue, 28 Oct 2014, torvald at gcc dot gnu.org wrote:
> Alternatively, we could try to be conservative and add an acquire barrier
> before the function body if any parameter of the function has
> carries_dependency; and, likewise, add an acquire barrier after every call to a
> function which has carries_dependency.
>
> I don't have more input from the ISO C side, but I would guess that the
> situation there is similar.
As previously noted:
* ISO C does not have carries_dependency (or attributes at all).
* carries_dependency is about increasing optimization, not decreasing it.
If it affects when barriers are added, it does so by allowing some
barriers to be omitted that would otherwise be required.