| Index: src/IceInst.cpp
|
| diff --git a/src/IceInst.cpp b/src/IceInst.cpp
|
| index 3e1ecf7d991bdddeb5a533597b655d5e51946b86..0ad80007956a673d9863690c94e62e8da2e6ddae 100644
|
| --- a/src/IceInst.cpp
|
| +++ b/src/IceInst.cpp
|
| @@ -619,13 +619,21 @@ void InstCall::dump(const Cfg *Func) const {
|
| Str << ")";
|
| }
|
|
|
| +const char *InstCast::getCastName(InstCast::OpKind Kind) {
|
| + size_t Index = static_cast<size_t>(Kind);
|
| + if (Index < InstCast::OpKind::_num)
|
| + return InstCastAttributes[Index].DisplayString;
|
| + llvm_unreachable("Invalid InstCast::OpKind");
|
| + return "???";
|
| +}
|
| +
|
| void InstCast::dump(const Cfg *Func) const {
|
| if (!ALLOW_DUMP)
|
| return;
|
| Ostream &Str = Func->getContext()->getStrDump();
|
| dumpDest(Func);
|
| - Str << " = " << InstCastAttributes[getCastKind()].DisplayString << " "
|
| - << getSrc(0)->getType() << " ";
|
| + Str << " = " << getCastName(getCastKind()) << " " << getSrc(0)->getType()
|
| + << " ";
|
| dumpSources(Func);
|
| Str << " to " << getDest()->getType();
|
| }
|
|
|