mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-13 22:24:07 +00:00
encode and read param attrs along with function type. WE can now roundtrip Olden/voronoi loslessly
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36735 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -145,11 +145,11 @@ static void WriteTypeTable(const ValueEnumerator &VE, BitstreamWriter &Stream) {
|
||||
|
||||
case Type::FunctionTyID: {
|
||||
const FunctionType *FT = cast<FunctionType>(T);
|
||||
// FUNCTION: [isvararg, #pararms, paramty x N]
|
||||
// FUNCTION: [isvararg, attrid, #pararms, paramty x N]
|
||||
Code = bitc::TYPE_CODE_FUNCTION;
|
||||
TypeVals.push_back(FT->isVarArg());
|
||||
TypeVals.push_back(VE.getParamAttrID(FT->getParamAttrs()));
|
||||
TypeVals.push_back(VE.getTypeID(FT->getReturnType()));
|
||||
// FIXME: PARAM ATTR ID!
|
||||
TypeVals.push_back(FT->getNumParams());
|
||||
for (unsigned i = 0, e = FT->getNumParams(); i != e; ++i)
|
||||
TypeVals.push_back(VE.getTypeID(FT->getParamType(i)));
|
||||
|
Reference in New Issue
Block a user