unsigned getStackAlignment(unsigned Index) const;
/// \brief Return the attributes at the index as a string.
- std::string getAsString(unsigned Index, bool TargetIndependent = false,
+ std::string getAsString(unsigned Index, bool TargetIndependent = true,
bool InAttrGrp = false) const;
typedef ArrayRef<Attribute>::iterator iterator;
const AttributeSet &Attrs = F->getAttributes();
if (!OldStyleAttrSyntax && Attrs.hasAttributes(AttributeSet::FunctionIndex)) {
AttributeSet AS = Attrs.getFnAttributes();
- std::string AttrStr = AS.getAsString(AttributeSet::FunctionIndex, true);
+ std::string AttrStr = AS.getAsString(AttributeSet::FunctionIndex, false);
if (!AttrStr.empty())
Out << "; Function Attrs: " << AttrStr << '\n';
}
Out << " #" << Machine.getAttributeGroupSlot(Attrs.getFnAttributes());
} else {
AttributeSet AS = Attrs.getFnAttributes();
- std::string AttrStr = AS.getAsString(AttributeSet::FunctionIndex, true);
+ std::string AttrStr = AS.getAsString(AttributeSet::FunctionIndex, false);
if (!AttrStr.empty())
Out << ' ' << AttrStr;
}
for (std::vector<std::pair<AttributeSet, unsigned> >::iterator
I = asVec.begin(), E = asVec.end(); I != E; ++I)
Out << "attributes #" << I->second << " = { "
- << I->first.getAsString(AttributeSet::FunctionIndex, false, true)
+ << I->first.getAsString(AttributeSet::FunctionIndex, true, true)
<< " }\n";
}
std::string Str = "";
for (SmallVectorImpl<Attribute>::const_iterator I = AttrList.begin(),
E = AttrList.end(); I != E; ) {
- if (!TargetIndependent || !I->isStringAttribute()) {
+ if (TargetIndependent || !I->isStringAttribute()) {
Str += I->getAsString(InAttrGrp);
if (++I != E) Str += " ";
} else {