summaryrefslogtreecommitdiffstats
path: root/llvm/lib/IR
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/IR')
-rw-r--r--llvm/lib/IR/DiagnosticInfo.cpp2
-rw-r--r--llvm/lib/IR/InlineAsm.cpp2
-rw-r--r--llvm/lib/IR/Verifier.cpp4
3 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/IR/DiagnosticInfo.cpp b/llvm/lib/IR/DiagnosticInfo.cpp
index cfb699a3171..5608589a56e 100644
--- a/llvm/lib/IR/DiagnosticInfo.cpp
+++ b/llvm/lib/IR/DiagnosticInfo.cpp
@@ -129,7 +129,7 @@ void DiagnosticInfoSampleProfile::print(DiagnosticPrinter &DP) const {
}
bool DiagnosticInfoOptimizationBase::isLocationAvailable() const {
- return getDebugLoc().isUnknown() == false;
+ return !getDebugLoc().isUnknown();
}
void DiagnosticInfoOptimizationBase::getLocation(StringRef *Filename,
diff --git a/llvm/lib/IR/InlineAsm.cpp b/llvm/lib/IR/InlineAsm.cpp
index 5b73561c503..b456d9f5869 100644
--- a/llvm/lib/IR/InlineAsm.cpp
+++ b/llvm/lib/IR/InlineAsm.cpp
@@ -75,7 +75,7 @@ bool InlineAsm::ConstraintInfo::Parse(StringRef Str,
ConstraintCodeVector *pCodes = &Codes;
// Initialize
- isMultipleAlternative = (multipleAlternativeCount > 1 ? true : false);
+ isMultipleAlternative = multipleAlternativeCount > 1;
if (isMultipleAlternative) {
multipleAlternatives.resize(multipleAlternativeCount);
pCodes = &multipleAlternatives[0].Codes;
diff --git a/llvm/lib/IR/Verifier.cpp b/llvm/lib/IR/Verifier.cpp
index 1b66fa0b1b8..06104d54cba 100644
--- a/llvm/lib/IR/Verifier.cpp
+++ b/llvm/lib/IR/Verifier.cpp
@@ -2709,7 +2709,7 @@ Verifier::VerifyIntrinsicIsVarArg(bool isVarArg,
// If there are no descriptors left, then it can't be a vararg.
if (Infos.empty())
- return isVarArg ? true : false;
+ return isVarArg;
// There should be only one descriptor remaining at this point.
if (Infos.size() != 1)
@@ -2719,7 +2719,7 @@ Verifier::VerifyIntrinsicIsVarArg(bool isVarArg,
IITDescriptor D = Infos.front();
Infos = Infos.slice(1);
if (D.Kind == IITDescriptor::VarArg)
- return isVarArg ? false : true;
+ return !isVarArg;
return true;
}
OpenPOWER on IntegriCloud