search for: isalignattribute

Displaying 3 results from an estimated 3 matches for "isalignattribute".

2013 Jul 16
0
[LLVMdev] New Attribute Group broke bitcode compatibility
...unstable bitcode. The problem is in BitcodeWriter.cpp, where the new WriteAttributeGroupTable() writes out the attributes using this piece of code: if (Attr.isEnumAttribute()) { Record.push_back(0); Record.push_back(Attr.getKindAsEnum()); } else if (Attr.isAlignAttribute()) { Record.push_back(1); Record.push_back(Attr.getKindAsEnum()); Record.push_back(Attr.getValueAsInt()); getKindAsEnum() returns the actual value of the enum, which is then stored in the bitcode. This direct connection makes the bitcode dependent of the order of...
2014 Mar 13
2
[LLVMdev] MergeFunctions: reduce complexity to O(log(N))
...ke_pair(V2, sn_mapR.size())); > > "auto"? > > 0005: > > Okay, this makes attributes ordered. > > + enum AttrType { > + Enum, > + Align, > + Other > + } LeftAttrType = Other, RightAttrType = Other; > + > + if (LA.isAlignAttribute()) LeftAttrType = Align; > + else if (LA.isEnumAttribute()) LeftAttrType = Enum; > + if (RA.isAlignAttribute()) RightAttrType = Align; > + else if (RA.isEnumAttribute()) RightAttrType = Enum; > + > + if (int Res = cmpNumbers(LeftAttrType, RightAttrType)) > +...
2014 Feb 27
3
[LLVMdev] MergeFunctions: reduce complexity to O(log(N))
Hi Nick, I tried to rework changes as you requested. One of patches (0004 with extra assertions) has been removed. > + bool isEquivalentType(Type *Ty1, Type *Ty2) const { > + return cmpType(Ty1, Ty2) == 0; > + } > > Why do we still need isEquivalentType? Can we nuke this? Yup. After applying all the patches isEquivalentType will be totally replaced with cmpType. All