@@ -3688,7 +3688,7 @@ void AssemblyWriter::printFunction(const Function *F) {
3688
3688
Out << " ; Materializable\n " ;
3689
3689
3690
3690
const AttributeList &Attrs = F->getAttributes ();
3691
- if (Attrs.hasAttributes (AttributeList::FunctionIndex )) {
3691
+ if (Attrs.hasFnAttrs ( )) {
3692
3692
AttributeSet AS = Attrs.getFnAttrs ();
3693
3693
std::string AttrStr;
3694
3694
@@ -3726,7 +3726,7 @@ void AssemblyWriter::printFunction(const Function *F) {
3726
3726
}
3727
3727
3728
3728
FunctionType *FT = F->getFunctionType ();
3729
- if (Attrs.hasAttributes (AttributeList::ReturnIndex ))
3729
+ if (Attrs.hasRetAttrs ( ))
3730
3730
Out << Attrs.getAsString (AttributeList::ReturnIndex) << ' ' ;
3731
3731
TypePrinter.print (F->getReturnType (), Out);
3732
3732
Out << ' ' ;
@@ -3775,7 +3775,7 @@ void AssemblyWriter::printFunction(const Function *F) {
3775
3775
if (F->getAddressSpace () != 0 || !Mod ||
3776
3776
Mod->getDataLayout ().getProgramAddressSpace () != 0 )
3777
3777
Out << " addrspace(" << F->getAddressSpace () << " )" ;
3778
- if (Attrs.hasAttributes (AttributeList::FunctionIndex ))
3778
+ if (Attrs.hasFnAttrs ( ))
3779
3779
Out << " #" << Machine.getAttributeGroupSlot (Attrs.getFnAttrs ());
3780
3780
if (F->hasSection ()) {
3781
3781
Out << " section \" " ;
@@ -4132,7 +4132,7 @@ void AssemblyWriter::printInstruction(const Instruction &I) {
4132
4132
Type *RetTy = FTy->getReturnType ();
4133
4133
const AttributeList &PAL = CI->getAttributes ();
4134
4134
4135
- if (PAL.hasAttributes (AttributeList::ReturnIndex ))
4135
+ if (PAL.hasRetAttrs ( ))
4136
4136
Out << ' ' << PAL.getAsString (AttributeList::ReturnIndex);
4137
4137
4138
4138
// Only print addrspace(N) if necessary:
@@ -4161,7 +4161,7 @@ void AssemblyWriter::printInstruction(const Instruction &I) {
4161
4161
Out << " , ..." ;
4162
4162
4163
4163
Out << ' )' ;
4164
- if (PAL.hasAttributes (AttributeList::FunctionIndex ))
4164
+ if (PAL.hasFnAttrs ( ))
4165
4165
Out << " #" << Machine.getAttributeGroupSlot (PAL.getFnAttrs ());
4166
4166
4167
4167
writeOperandBundles (CI);
@@ -4177,7 +4177,7 @@ void AssemblyWriter::printInstruction(const Instruction &I) {
4177
4177
PrintCallingConv (II->getCallingConv (), Out);
4178
4178
}
4179
4179
4180
- if (PAL.hasAttributes (AttributeList::ReturnIndex ))
4180
+ if (PAL.hasRetAttrs ( ))
4181
4181
Out << ' ' << PAL.getAsString (AttributeList::ReturnIndex);
4182
4182
4183
4183
// Only print addrspace(N) if necessary:
@@ -4199,7 +4199,7 @@ void AssemblyWriter::printInstruction(const Instruction &I) {
4199
4199
}
4200
4200
4201
4201
Out << ' )' ;
4202
- if (PAL.hasAttributes (AttributeList::FunctionIndex ))
4202
+ if (PAL.hasFnAttrs ( ))
4203
4203
Out << " #" << Machine.getAttributeGroupSlot (PAL.getFnAttrs ());
4204
4204
4205
4205
writeOperandBundles (II);
@@ -4220,7 +4220,7 @@ void AssemblyWriter::printInstruction(const Instruction &I) {
4220
4220
PrintCallingConv (CBI->getCallingConv (), Out);
4221
4221
}
4222
4222
4223
- if (PAL.hasAttributes (AttributeList::ReturnIndex ))
4223
+ if (PAL.hasRetAttrs ( ))
4224
4224
Out << ' ' << PAL.getAsString (AttributeList::ReturnIndex);
4225
4225
4226
4226
// If possible, print out the short form of the callbr instruction. We can
@@ -4239,7 +4239,7 @@ void AssemblyWriter::printInstruction(const Instruction &I) {
4239
4239
}
4240
4240
4241
4241
Out << ' )' ;
4242
- if (PAL.hasAttributes (AttributeList::FunctionIndex ))
4242
+ if (PAL.hasFnAttrs ( ))
4243
4243
Out << " #" << Machine.getAttributeGroupSlot (PAL.getFnAttrs ());
4244
4244
4245
4245
writeOperandBundles (CBI);
0 commit comments