From 168daea0661f6e18dc85e967ff572f33a76a2bc5 Mon Sep 17 00:00:00 2001 From: Frank Busse Date: Fri, 22 Apr 2022 17:17:37 +0100 Subject: .err files: minor readability changes to stack trace output --- lib/Core/ExecutionState.cpp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'lib/Core') diff --git a/lib/Core/ExecutionState.cpp b/lib/Core/ExecutionState.cpp index 54fe752e..5231f7fb 100644 --- a/lib/Core/ExecutionState.cpp +++ b/lib/Core/ExecutionState.cpp @@ -327,18 +327,22 @@ void ExecutionState::dumpStack(llvm::raw_ostream &out) const { std::stringstream AssStream; AssStream << std::setw(8) << std::setfill('0') << ii.assemblyLine; out << AssStream.str(); - out << " in " << f->getName().str() << " ("; + out << " in " << f->getName().str() << "("; // Yawn, we could go up and print varargs if we wanted to. unsigned index = 0; for (Function::arg_iterator ai = f->arg_begin(), ae = f->arg_end(); ai != ae; ++ai) { if (ai!=f->arg_begin()) out << ", "; - out << ai->getName().str(); - // XXX should go through function + if (ai->hasName()) + out << ai->getName().str() << "="; + ref value = sf.locals[sf.kf->getArgRegister(index++)].value; - if (isa_and_nonnull(value)) - out << "=" << value; + if (isa_and_nonnull(value)) { + out << value; + } else { + out << "symbolic"; + } } out << ")"; if (ii.file != "") -- cgit 1.4.1