mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-20 16:17:38 +00:00
switch to use the new api for structtypes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137480 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -218,7 +218,7 @@ Constant *ShadowStackGC::GetFrameMap(Function &F) {
|
||||
};
|
||||
|
||||
Type *EltTys[] = { DescriptorElts[0]->getType(),DescriptorElts[1]->getType()};
|
||||
StructType *STy = StructType::createNamed("gc_map."+utostr(NumMeta), EltTys);
|
||||
StructType *STy = StructType::create(EltTys, "gc_map."+utostr(NumMeta));
|
||||
|
||||
Constant *FrameMap = ConstantStruct::get(STy, DescriptorElts);
|
||||
|
||||
@@ -253,7 +253,7 @@ Type* ShadowStackGC::GetConcreteStackEntryType(Function &F) {
|
||||
for (size_t I = 0; I != Roots.size(); I++)
|
||||
EltTys.push_back(Roots[I].second->getAllocatedType());
|
||||
|
||||
return StructType::createNamed("gc_stackentry."+F.getName().str(), EltTys);
|
||||
return StructType::create(EltTys, "gc_stackentry."+F.getName().str());
|
||||
}
|
||||
|
||||
/// doInitialization - If this module uses the GC intrinsics, find them now. If
|
||||
@@ -269,7 +269,7 @@ bool ShadowStackGC::initializeCustomLowering(Module &M) {
|
||||
EltTys.push_back(Type::getInt32Ty(M.getContext()));
|
||||
// Specifies length of variable length array.
|
||||
EltTys.push_back(Type::getInt32Ty(M.getContext()));
|
||||
FrameMapTy = StructType::createNamed("gc_map", EltTys);
|
||||
FrameMapTy = StructType::create(EltTys, "gc_map");
|
||||
PointerType *FrameMapPtrTy = PointerType::getUnqual(FrameMapTy);
|
||||
|
||||
// struct StackEntry {
|
||||
@@ -278,7 +278,7 @@ bool ShadowStackGC::initializeCustomLowering(Module &M) {
|
||||
// void *Roots[]; // Stack roots (in-place array, so we pretend).
|
||||
// };
|
||||
|
||||
StackEntryTy = StructType::createNamed(M.getContext(), "gc_stackentry");
|
||||
StackEntryTy = StructType::create(M.getContext(), "gc_stackentry");
|
||||
|
||||
EltTys.clear();
|
||||
EltTys.push_back(PointerType::getUnqual(StackEntryTy));
|
||||
|
||||
Reference in New Issue
Block a user