This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/64567] missed optimization: redundant test before clearing bit(s)
- From: "rv at rasmusvillemoes dot dk" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 12 Jan 2015 13:41:03 +0000
- Subject: [Bug tree-optimization/64567] missed optimization: redundant test before clearing bit(s)
- Auto-submitted: auto-generated
- References: <bug-64567-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64567
--- Comment #2 from Rasmus Villemoes <rv at rasmusvillemoes dot dk> ---
(In reply to Andreas Schwab from comment #1)
> This transformation is incorrect if the lvalue may be pointing to a
> read-only object.
True. And one may also incur an extra cache penalty if the cache line
containing foo was already held shared but not exclusive.