aboutsummaryrefslogtreecommitdiffstats
path: root/lib/VMCore
diff options
context:
space:
mode:
authorDuncan Sands <baldrick@free.fr>2012-04-14 12:36:06 +0000
committerDuncan Sands <baldrick@free.fr>2012-04-14 12:36:06 +0000
commit5e5c5f8259b90ba77c0b30e67cb360165000d1f6 (patch)
tree34b6232fb2d46356c6eca0f8c2ff513ab9f92e50 /lib/VMCore
parent164dfb094df947db2117c182ae033ea85c6c42a1 (diff)
downloadexternal_llvm-5e5c5f8259b90ba77c0b30e67cb360165000d1f6.zip
external_llvm-5e5c5f8259b90ba77c0b30e67cb360165000d1f6.tar.gz
external_llvm-5e5c5f8259b90ba77c0b30e67cb360165000d1f6.tar.bz2
Rename "fpaccuracy" metadata to the more generic "fpmath". That's because I'm
thinking of generalizing it to be able to specify other freedoms beyond accuracy (such as that NaN's don't have to be respected). I'd like the 3.1 release (the first one with this metadata) to have the more generic name already rather than having to auto-upgrade it in 3.2. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154744 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore')
-rw-r--r--lib/VMCore/LLVMContext.cpp6
-rw-r--r--lib/VMCore/Verifier.cpp12
2 files changed, 9 insertions, 9 deletions
diff --git a/lib/VMCore/LLVMContext.cpp b/lib/VMCore/LLVMContext.cpp
index 68c5621..f07f0b3 100644
--- a/lib/VMCore/LLVMContext.cpp
+++ b/lib/VMCore/LLVMContext.cpp
@@ -44,9 +44,9 @@ LLVMContext::LLVMContext() : pImpl(new LLVMContextImpl(*this)) {
unsigned ProfID = getMDKindID("prof");
assert(ProfID == MD_prof && "prof kind id drifted"); (void)ProfID;
- // Create the 'fpaccuracy' metadata kind.
- unsigned FPAccuracyID = getMDKindID("fpaccuracy");
- assert(FPAccuracyID == MD_fpaccuracy && "fpaccuracy kind id drifted");
+ // Create the 'fpmath' metadata kind.
+ unsigned FPAccuracyID = getMDKindID("fpmath");
+ assert(FPAccuracyID == MD_fpmath && "fpmath kind id drifted");
(void)FPAccuracyID;
// Create the 'range' metadata kind.
diff --git a/lib/VMCore/Verifier.cpp b/lib/VMCore/Verifier.cpp
index 96492e4..ab79d8c 100644
--- a/lib/VMCore/Verifier.cpp
+++ b/lib/VMCore/Verifier.cpp
@@ -1653,16 +1653,16 @@ void Verifier::visitInstruction(Instruction &I) {
}
}
- if (MDNode *MD = I.getMetadata(LLVMContext::MD_fpaccuracy)) {
+ if (MDNode *MD = I.getMetadata(LLVMContext::MD_fpmath)) {
Assert1(I.getType()->isFPOrFPVectorTy(),
- "fpaccuracy requires a floating point result!", &I);
- Assert1(MD->getNumOperands() == 1, "fpaccuracy takes one operand!", &I);
+ "fpmath requires a floating point result!", &I);
+ Assert1(MD->getNumOperands() == 1, "fpmath takes one operand!", &I);
ConstantFP *Op = dyn_cast_or_null<ConstantFP>(MD->getOperand(0));
- Assert1(Op, "fpaccuracy ULPs not a floating point number!", &I);
+ Assert1(Op, "fpmath ULPs not a floating point number!", &I);
APFloat ULPs = Op->getValueAPF();
Assert1(ULPs.isNormal() || ULPs.isZero(),
- "fpaccuracy ULPs not a normal number!", &I);
- Assert1(!ULPs.isNegative(), "fpaccuracy ULPs is negative!", &I);
+ "fpmath ULPs not a normal number!", &I);
+ Assert1(!ULPs.isNegative(), "fpmath ULPs is negative!", &I);
}
MDNode *MD = I.getMetadata(LLVMContext::MD_range);