Introduce a new SIL-level "undef" value, useful for SIL transformations.

IRGen support is missing, Joe volenteers to implement it.


Swift SVN r9776
This commit is contained in:
Chris Lattner
2013-10-30 00:58:09 +00:00
parent 7ce3892588
commit ef93c81ffb
15 changed files with 120 additions and 26 deletions

View File

@@ -41,6 +41,7 @@ namespace swift {
class SILFunction;
class SILVTable;
class SILTypeList;
class SILUndef;
class SourceFile;
class TranslationUnit;
@@ -78,6 +79,7 @@ private:
friend class SILFunction;
friend class SILType;
friend class SILVTable;
friend class SILUndef;
friend class Lowering::SILGenModule;
friend class Lowering::TypeConverter;
@@ -107,6 +109,9 @@ private:
/// This is a cache of builtin Function declarations to numeric ID mappings.
llvm::DenseMap<const FuncDecl*, BuiltinInfo> BuiltinIDCache;
/// This is the set of undef values we've created, for uniquing purposes.
llvm::DenseMap<SILType, SILUndef*> UndefValues;
/// The stage of processing this module is at.
SILStage Stage;