diff options
author | Chad Rosier <mcrosier@apple.com> | 2011-06-21 02:09:03 +0000 |
---|---|---|
committer | Chad Rosier <mcrosier@apple.com> | 2011-06-21 02:09:03 +0000 |
commit | a88a0ca8082006b37d14d8aee4a644b20bae8bc9 (patch) | |
tree | 50672ebd357c0af7075c51ab546813243c10b978 /lib/VMCore/User.cpp | |
parent | 805569f54aa5ac3ac4c59a008ba68913177b3ce8 (diff) |
Revert r133435 and r133449 to appease buildbots.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133499 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/User.cpp')
-rw-r--r-- | lib/VMCore/User.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/VMCore/User.cpp b/lib/VMCore/User.cpp index f01fa349ad..9601da7011 100644 --- a/lib/VMCore/User.cpp +++ b/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); |