Actually privatize a IntegerTypes, and fix a few bugs exposed by this.
llvm-svn: 78955
diff --git a/llvm/lib/CodeGen/ShadowStackGC.cpp b/llvm/lib/CodeGen/ShadowStackGC.cpp
index 5b4cc7fe..18c4936 100644
--- a/llvm/lib/CodeGen/ShadowStackGC.cpp
+++ b/llvm/lib/CodeGen/ShadowStackGC.cpp
@@ -279,7 +279,7 @@
// FrameMap *Map; // Pointer to constant FrameMap.
// void *Roots[]; // Stack roots (in-place array, so we pretend).
// };
- OpaqueType *RecursiveTy = OpaqueType::get();
+ OpaqueType *RecursiveTy = OpaqueType::get(M.getContext());
EltTys.clear();
EltTys.push_back(PointerType::getUnqual(RecursiveTy));