mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-23 14:25:07 +00:00
Reshuffling of APIs
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8354 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -35,7 +35,16 @@ protected:
|
|||||||
// used, but the subtypes have changed.
|
// used, but the subtypes have changed.
|
||||||
//
|
//
|
||||||
void typeIsRefined();
|
void typeIsRefined();
|
||||||
|
|
||||||
|
// dropAllTypeUses - When this (abstract) type is resolved to be equal to
|
||||||
|
// another (more concrete) type, we must eliminate all references to other
|
||||||
|
// types, to avoid some circular reference problems. This also removes the
|
||||||
|
// type from the internal tables of available types.
|
||||||
|
virtual void dropAllTypeUses(bool inMap) = 0;
|
||||||
|
|
||||||
|
|
||||||
|
void refineAbstractTypeToInternal(const Type *NewType, bool inMap);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
//===--------------------------------------------------------------------===//
|
//===--------------------------------------------------------------------===//
|
||||||
@@ -61,7 +70,9 @@ public:
|
|||||||
// This causes all users of 'this' to switch to reference the more concrete
|
// This causes all users of 'this' to switch to reference the more concrete
|
||||||
// type NewType and for 'this' to be deleted.
|
// type NewType and for 'this' to be deleted.
|
||||||
//
|
//
|
||||||
void refineAbstractTypeTo(const Type *NewType);
|
void refineAbstractTypeTo(const Type *NewType) {
|
||||||
|
refineAbstractTypeToInternal(NewType, true);
|
||||||
|
}
|
||||||
|
|
||||||
// Methods for support type inquiry through isa, cast, and dyn_cast:
|
// Methods for support type inquiry through isa, cast, and dyn_cast:
|
||||||
static inline bool classof(const DerivedType *T) { return true; }
|
static inline bool classof(const DerivedType *T) { return true; }
|
||||||
@@ -94,6 +105,12 @@ protected:
|
|||||||
FunctionType(const Type *Result, const std::vector<const Type*> &Params,
|
FunctionType(const Type *Result, const std::vector<const Type*> &Params,
|
||||||
bool IsVarArgs);
|
bool IsVarArgs);
|
||||||
|
|
||||||
|
// dropAllTypeUses - When this (abstract) type is resolved to be equal to
|
||||||
|
// another (more concrete) type, we must eliminate all references to other
|
||||||
|
// types, to avoid some circular reference problems. This also removes the
|
||||||
|
// type from the internal tables of available types.
|
||||||
|
virtual void dropAllTypeUses(bool inMap);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
inline bool isVarArg() const { return isVarArgs; }
|
inline bool isVarArg() const { return isVarArgs; }
|
||||||
@@ -186,6 +203,12 @@ protected:
|
|||||||
|
|
||||||
// Private ctor - Only can be created by a static member...
|
// Private ctor - Only can be created by a static member...
|
||||||
StructType(const std::vector<const Type*> &Types);
|
StructType(const std::vector<const Type*> &Types);
|
||||||
|
|
||||||
|
// dropAllTypeUses - When this (abstract) type is resolved to be equal to
|
||||||
|
// another (more concrete) type, we must eliminate all references to other
|
||||||
|
// types, to avoid some circular reference problems. This also removes the
|
||||||
|
// type from the internal tables of available types.
|
||||||
|
virtual void dropAllTypeUses(bool inMap);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
inline const ElementTypes &getElementTypes() const { return ETypes; }
|
inline const ElementTypes &getElementTypes() const { return ETypes; }
|
||||||
@@ -240,6 +263,7 @@ protected:
|
|||||||
SequentialType(PrimitiveID TID, const Type *ElType)
|
SequentialType(PrimitiveID TID, const Type *ElType)
|
||||||
: CompositeType(TID), ElementType(PATypeHandle(ElType, this)) {
|
: CompositeType(TID), ElementType(PATypeHandle(ElType, this)) {
|
||||||
}
|
}
|
||||||
|
|
||||||
public:
|
public:
|
||||||
inline const Type *getElementType() const { return ElementType; }
|
inline const Type *getElementType() const { return ElementType; }
|
||||||
|
|
||||||
@@ -287,6 +311,13 @@ protected:
|
|||||||
|
|
||||||
// Private ctor - Only can be created by a static member...
|
// Private ctor - Only can be created by a static member...
|
||||||
ArrayType(const Type *ElType, unsigned NumEl);
|
ArrayType(const Type *ElType, unsigned NumEl);
|
||||||
|
|
||||||
|
// dropAllTypeUses - When this (abstract) type is resolved to be equal to
|
||||||
|
// another (more concrete) type, we must eliminate all references to other
|
||||||
|
// types, to avoid some circular reference problems. This also removes the
|
||||||
|
// type from the internal tables of available types.
|
||||||
|
virtual void dropAllTypeUses(bool inMap);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
inline unsigned getNumElements() const { return NumElements; }
|
inline unsigned getNumElements() const { return NumElements; }
|
||||||
|
|
||||||
@@ -320,6 +351,12 @@ protected:
|
|||||||
|
|
||||||
// Private ctor - Only can be created by a static member...
|
// Private ctor - Only can be created by a static member...
|
||||||
PointerType(const Type *ElType);
|
PointerType(const Type *ElType);
|
||||||
|
|
||||||
|
// dropAllTypeUses - When this (abstract) type is resolved to be equal to
|
||||||
|
// another (more concrete) type, we must eliminate all references to other
|
||||||
|
// types, to avoid some circular reference problems. This also removes the
|
||||||
|
// type from the internal tables of available types.
|
||||||
|
virtual void dropAllTypeUses(bool inMap);
|
||||||
public:
|
public:
|
||||||
// PointerType::get - Named constructor for pointer types...
|
// PointerType::get - Named constructor for pointer types...
|
||||||
static PointerType *get(const Type *ElementType);
|
static PointerType *get(const Type *ElementType);
|
||||||
@@ -351,6 +388,12 @@ protected:
|
|||||||
|
|
||||||
// Private ctor - Only can be created by a static member...
|
// Private ctor - Only can be created by a static member...
|
||||||
OpaqueType();
|
OpaqueType();
|
||||||
|
|
||||||
|
// dropAllTypeUses - When this (abstract) type is resolved to be equal to
|
||||||
|
// another (more concrete) type, we must eliminate all references to other
|
||||||
|
// types, to avoid some circular reference problems.
|
||||||
|
virtual void dropAllTypeUses(bool inMap) {} // No type uses
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
// get - Static factory method for the OpaqueType class...
|
// get - Static factory method for the OpaqueType class...
|
||||||
|
Reference in New Issue
Block a user