From 03a856807c463102755ac4c280272c44fb01ffa7 Mon Sep 17 00:00:00 2001 From: Davide Italiano Date: Fri, 11 Nov 2016 03:07:45 +0000 Subject: [PATCH] [lli] Simplify the code a bit. No functional change intended. llvm-svn: 286555 --- llvm/lib/Object/COFFObjectFile.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/llvm/lib/Object/COFFObjectFile.cpp b/llvm/lib/Object/COFFObjectFile.cpp index c95037f..243f1ae 100644 --- a/llvm/lib/Object/COFFObjectFile.cpp +++ b/llvm/lib/Object/COFFObjectFile.cpp @@ -161,9 +161,7 @@ uint32_t COFFObjectFile::getSymbolAlignment(DataRefImpl Ref) const { // MSVC/link.exe seems to align symbols to the next-power-of-2 // up to 32 bytes. COFFSymbolRef Symb = getCOFFSymbol(Ref); - uint32_t Value = Symb.getValue(); - return std::min(uint64_t(32), - isPowerOf2_64(Value) ? Value : NextPowerOf2(Value)); + return std::min(uint64_t(32), PowerOf2Ceil(Symb.getValue())); } Expected COFFObjectFile::getSymbolAddress(DataRefImpl Ref) const { -- 2.7.4