Reverts commit r301424, r301425 and r301426
Commits were:
"Use WeakVH instead of WeakTrackingVH in AliasSetTracker's UnkownInsts"
"Add a new WeakVH value handle; NFC"
"Rename WeakVH to WeakTrackingVH; NFC"
The changes assumed pointers are 8 byte aligned on all architectures.
llvm-svn: 301429
diff --git a/llvm/lib/IR/Value.cpp b/llvm/lib/IR/Value.cpp
index 18e44dc..d83bdf2 100644
--- a/llvm/lib/IR/Value.cpp
+++ b/llvm/lib/IR/Value.cpp
@@ -826,9 +826,7 @@
Entry->operator=(DenseMapInfo<Value *>::getTombstoneKey());
break;
case Weak:
- case WeakTracking:
- // WeakTracking and Weak just go to null, which unlinks them
- // from the list.
+ // Weak just goes to null, which will unlink it from the list.
Entry->operator=(nullptr);
break;
case Callback:
@@ -876,20 +874,17 @@
switch (Entry->getKind()) {
case Assert:
- case Weak:
- // Asserting and Weak handles do not follow RAUW implicitly.
+ // Asserting handle does not follow RAUW implicitly.
break;
case Tracking:
- // Tracking goes to new value like a WeakTrackingVH. Note that this may
- // make it something incompatible with its templated type. We don't want
- // to have a virtual (or inline) interface to handle this though, so
- // instead we make the TrackingVH accessors guarantee that a client never
- // sees this value.
+ // Tracking goes to new value like a WeakVH. Note that this may make it
+ // something incompatible with its templated type. We don't want to have a
+ // virtual (or inline) interface to handle this though, so instead we make
+ // the TrackingVH accessors guarantee that a client never sees this value.
LLVM_FALLTHROUGH;
- case WeakTracking:
- // WeakTracking goes to the new value, which will unlink it from Old's
- // list.
+ case Weak:
+ // Weak goes to the new value, which will unlink it from Old's list.
Entry->operator=(New);
break;
case Callback:
@@ -906,7 +901,7 @@
for (Entry = pImpl->ValueHandles[Old]; Entry; Entry = Entry->Next)
switch (Entry->getKind()) {
case Tracking:
- case WeakTracking:
+ case Weak:
dbgs() << "After RAUW from " << *Old->getType() << " %"
<< Old->getName() << " to " << *New->getType() << " %"
<< New->getName() << "\n";