diff options
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r-- | clang/lib/CodeGen/CodeGenModule.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp index 236cc3d..834b1c0 100644 --- a/clang/lib/CodeGen/CodeGenModule.cpp +++ b/clang/lib/CodeGen/CodeGenModule.cpp @@ -4418,8 +4418,9 @@ void CodeGenModule::EmitGlobalDefinition(GlobalDecl GD, llvm::GlobalValue *GV) { static void ReplaceUsesOfNonProtoTypeWithRealFunction(llvm::GlobalValue *Old, llvm::Function *NewFn); -static uint64_t getFMVPriority(const TargetInfo &TI, - const CodeGenFunction::FMVResolverOption &RO) { +static llvm::APInt +getFMVPriority(const TargetInfo &TI, + const CodeGenFunction::FMVResolverOption &RO) { llvm::SmallVector<StringRef, 8> Features{RO.Features}; if (RO.Architecture) Features.push_back(*RO.Architecture); @@ -4544,7 +4545,7 @@ void CodeGenModule::emitMultiVersionFunctions() { llvm::stable_sort( Options, [&TI](const CodeGenFunction::FMVResolverOption &LHS, const CodeGenFunction::FMVResolverOption &RHS) { - return getFMVPriority(TI, LHS) > getFMVPriority(TI, RHS); + return getFMVPriority(TI, LHS).ugt(getFMVPriority(TI, RHS)); }); CodeGenFunction CGF(*this); CGF.EmitMultiVersionResolver(ResolverFunc, Options); |