diff options
| author | Eric Christopher <echristo@apple.com> | 2011-06-23 06:24:52 +0000 |
|---|---|---|
| committer | Eric Christopher <echristo@apple.com> | 2011-06-23 06:24:52 +0000 |
| commit | 96513120b73821726d0e33f2a64afbe464cd8b74 (patch) | |
| tree | bb51f3ebc9ee79cd1dfc742611d26577244684cc /llvm/lib/VMCore/User.cpp | |
| parent | b0d8199925611f010f87a5c1450d054b4ab9293e (diff) | |
| download | bcm5719-llvm-96513120b73821726d0e33f2a64afbe464cd8b74.tar.gz bcm5719-llvm-96513120b73821726d0e33f2a64afbe464cd8b74.zip | |
Revert r133513:
"Reinstate r133435 and r133449 (reverted in r133499) now that the clang
self-hosted build failure has been fixed (r133512)."
Due to some additional warnings.
llvm-svn: 133700
Diffstat (limited to 'llvm/lib/VMCore/User.cpp')
| -rw-r--r-- | llvm/lib/VMCore/User.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/llvm/lib/VMCore/User.cpp b/llvm/lib/VMCore/User.cpp index f01fa349adf..9601da7011e 100644 --- a/llvm/lib/VMCore/User.cpp +++ b/llvm/lib/VMCore/User.cpp @@ -40,10 +40,8 @@ void User::replaceUsesOfWith(Value *From, Value *To) { //===----------------------------------------------------------------------===// Use *User::allocHungoffUses(unsigned N) const { - // Allocate the array of Uses, followed by a pointer (with bottom bit set) to - // the User. - size_t size = N * sizeof(Use) + sizeof(Use::UserRef); - Use *Begin = static_cast<Use*>(::operator new(size)); + Use *Begin = static_cast<Use*>(::operator new(sizeof(Use) * N + + sizeof(Use::UserRef))); Use *End = Begin + N; (void) new(End) Use::UserRef(const_cast<User*>(this), 1); return Use::initTags(Begin, End); |

