SIL Serialiation: add implementation to serialize SIL basic block and a

few SIL instructions types.

This will be tested when we have a SIL deserializer. Testing cases covering
each implemented SIL instruction will be added.


Swift SVN r8094
This commit is contained in:
Manman Ren
2013-09-11 17:52:05 +00:00
parent 2c8e7e45a5
commit ddd7fb4d46
6 changed files with 268 additions and 15 deletions

View File

@@ -408,6 +408,13 @@ ModuleFile::ModuleFile(llvm::OwningPtr<llvm::MemoryBuffer> &&input)
break;
}
// FIXME: for now, skip the SIL block.
case SIL_BLOCK_ID: {
if (cursor.SkipBlock())
return error();
break;
}
default:
// Unknown top-level block, possibly for use by a future version of the
// module format.