diff options
| author | Owen Anderson <resistor@mac.com> | 2008-02-26 23:06:17 +0000 |
|---|---|---|
| committer | Owen Anderson <resistor@mac.com> | 2008-02-26 23:06:17 +0000 |
| commit | d29ed0b1227f641a8cc57e7add3abff2a62dfa71 (patch) | |
| tree | 369eb7cdf3f5e813ef230ad0b961a3207918d0f3 /llvm/lib | |
| parent | 448538d86054fb732d6ca873093334b7881dc4d8 (diff) | |
| download | bcm5719-llvm-d29ed0b1227f641a8cc57e7add3abff2a62dfa71.tar.gz bcm5719-llvm-d29ed0b1227f641a8cc57e7add3abff2a62dfa71.zip | |
Fix an issue where GVN had the sizes of the two memcpy's reverse, resulting
in an invalid transformation.
llvm-svn: 47639
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Transforms/Scalar/GVN.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/Scalar/GVN.cpp b/llvm/lib/Transforms/Scalar/GVN.cpp index 4b7e82c927e..8bb811c45b6 100644 --- a/llvm/lib/Transforms/Scalar/GVN.cpp +++ b/llvm/lib/Transforms/Scalar/GVN.cpp @@ -1188,8 +1188,8 @@ bool GVN::processMemCpy(MemCpyInst* M, MemCpyInst* MDep, if (!C1 || !C2) return false; - uint64_t CpySize = C1->getValue().getZExtValue(); - uint64_t DepSize = C2->getValue().getZExtValue(); + uint64_t DepSize = C1->getValue().getZExtValue(); + uint64_t CpySize = C2->getValue().getZExtValue(); if (DepSize < CpySize) return false; |

