[llvm-commits] [llvm] r120974 - in /llvm/trunk: include/llvm/Analysis/AliasAnalysis.h lib/Transforms/Scalar/DeadStoreElimination.cpp test/Transforms/DeadStoreElimination/simple.ll

Benjamin Kramer benny.kra at googlemail.com
Mon Dec 6 00:24:02 PST 2010


On 06.12.2010, at 02:48, Chris Lattner wrote:

> Author: lattner
> Date: Sun Dec  5 19:48:06 2010
> New Revision: 120974
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=120974&view=rev
> Log:
> Fix PR8728, a miscompilation I recently introduced.  When optimizing
> memcpy's like:
>  memcpy(A, B)
>  memcpy(A, C)
> 
> we cannot delete the first memcpy as dead if A and C might be aliases.
> If so, we actually get:

Aren't the operands of memcpy guaranteed not to overlap, so this would be undefined behaviour?



More information about the llvm-commits mailing list