summaryrefslogtreecommitdiffstats
path: root/utils
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@gmail.com>2014-06-18 03:57:25 +0000
committerCraig Topper <craig.topper@gmail.com>2014-06-18 03:57:25 +0000
commit6356f564c351af8b22e7c2699d52e2062ae9e76e (patch)
tree99013f36503cea113868493481e52227619c11e2 /utils
parentce9d90b35aee0430b8e16e33f0c82cecb487cc83 (diff)
Replace some assert(0)'s with llvm_unreachable.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@211139 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils')
-rw-r--r--utils/TableGen/NeonEmitter.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/utils/TableGen/NeonEmitter.cpp b/utils/TableGen/NeonEmitter.cpp
index 83c3c048e4..9d6ae3497b 100644
--- a/utils/TableGen/NeonEmitter.cpp
+++ b/utils/TableGen/NeonEmitter.cpp
@@ -562,14 +562,14 @@ std::string Type::builtin_str() const {
case 32: S += "i"; break;
case 64: S += "Wi"; break;
case 128: S += "LLLi"; break;
- default: assert(0 && "Unhandled case!");
+ default: llvm_unreachable("Unhandled case!");
}
else
switch (ElementBitwidth) {
case 16: S += "h"; break;
case 32: S += "f"; break;
case 64: S += "d"; break;
- default: assert(0 && "Unhandled case!");
+ default: llvm_unreachable("Unhandled case!");
}
if (isChar() && !Pointer)
@@ -742,7 +742,7 @@ void Type::applyTypespec(bool &Quad) {
NumVectors = 0;
break;
default:
- assert(0 && "Unhandled type code!");
+ llvm_unreachable("Unhandled type code!");
}
}
assert(ElementBitwidth != ~0U && "Bad element bitwidth!");
@@ -907,7 +907,7 @@ void Type::applyModifier(char Mod) {
Bitwidth *= 2;
break;
default:
- assert(0 && "Unhandled character!");
+ llvm_unreachable("Unhandled character!");
}
}
@@ -1061,7 +1061,7 @@ std::string Intrinsic::mangleName(std::string Name, ClassKind LocalCK) {
case 16: Suffix = 'h'; break;
case 32: Suffix = 's'; break;
case 64: Suffix = 'd'; break;
- default: assert(0 && "Bad suffix!");
+ default: llvm_unreachable("Bad suffix!");
}
}
if (Suffix != '\0') {
@@ -2282,6 +2282,6 @@ void EmitNeonSema(RecordKeeper &Records, raw_ostream &OS) {
NeonEmitter(Records).runHeader(OS);
}
void EmitNeonTest(RecordKeeper &Records, raw_ostream &OS) {
- assert(0 && "Neon test generation no longer implemented!");
+ llvm_unreachable("Neon test generation no longer implemented!");
}
} // End namespace clang