[llvm-bugs] [Bug 33519] New: llvm-pdbutil crash with bad runtime enum value

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Jun 19 18:17:52 PDT 2017


https://bugs.llvm.org/show_bug.cgi?id=33519

            Bug ID: 33519
           Summary: llvm-pdbutil crash with bad runtime enum value
           Product: libraries
           Version: trunk
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: DebugInfo
          Assignee: unassignedbugs at nondot.org
          Reporter: brendandg at nyu.edu
                CC: llvm-bugs at lists.llvm.org

The PDB file found here:

http://panda.moyix.net/~moyix/llvm_pdb_bug/ehiitv.pdb

Causes "llvm-pdbutil pdb2yaml -all" to hit an unreachable switch case. I think
this is similar to Bug 33428 and probably has the same fix.

Stack trace:

bad runtime enum value
UNREACHABLE executed at
/home/moyix/git/llvm-master/lib/Support/YAMLTraits.cpp:580!
#0 0x000000000070b5c9 llvm::sys::PrintStackTrace(llvm::raw_ostream&)
/home/moyix/git/llvm-master/lib/Support/Unix/Signals.inc:398:0
#1 0x000000000070b65c PrintStackTraceSignalHandler(void*)
/home/moyix/git/llvm-master/lib/Support/Unix/Signals.inc:462:0
#2 0x00000000007098a3 llvm::sys::RunSignalHandlers()
/home/moyix/git/llvm-master/lib/Support/Signals.cpp:49:0
#3 0x000000000070ae3e SignalHandler(int)
/home/moyix/git/llvm-master/lib/Support/Unix/Signals.inc:252:0
#4 0x00007f318201b390 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x11390)
#5 0x00007f31811ac428 gsignal
/build/glibc-9tT8Do/glibc-2.23/signal/../sysdeps/unix/sysv/linux/raise.c:54:0
#6 0x00007f31811ae02a abort /build/glibc-9tT8Do/glibc-2.23/stdlib/abort.c:91:0
#7 0x00000000006bc144 bindingsErrorHandler(void*,
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >
const&, bool) /home/moyix/git/llvm-master/lib/Support/ErrorHandling.cpp:127:0
#8 0x00000000006d32d7 llvm::yaml::Output::endEnumScalar()
/home/moyix/git/llvm-master/lib/Support/YAMLTraits.cpp:581:0
#9 0x00000000004b2a76
std::enable_if<llvm::yaml::has_ScalarEnumerationTraits<llvm::pdb::PDB_Machine>::value,
void>::type llvm::yaml::yamlize<llvm::pdb::PDB_Machine>(llvm::yaml::IO&,
llvm::pdb::PDB_Machine&, bool, llvm::yaml::EmptyContext&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:757:0
#10 0x00000000004afeb5 void
llvm::yaml::IO::processKeyWithDefault<llvm::pdb::PDB_Machine,
llvm::yaml::EmptyContext>(char const*, llvm::pdb::PDB_Machine&,
llvm::pdb::PDB_Machine const&, bool, llvm::yaml::EmptyContext&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:716:0
#11 0x00000000004ade89 void
llvm::yaml::IO::mapOptionalWithContext<llvm::pdb::PDB_Machine,
llvm::yaml::EmptyContext>(char const*, llvm::pdb::PDB_Machine&,
llvm::pdb::PDB_Machine const&, llvm::yaml::EmptyContext&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:682:0
#12 0x00000000004ad28e void
llvm::yaml::IO::mapOptional<llvm::pdb::PDB_Machine>(char const*,
llvm::pdb::PDB_Machine&, llvm::pdb::PDB_Machine const&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:655:0
#13 0x00000000004aa43e
llvm::yaml::MappingTraits<llvm::pdb::yaml::PdbDbiStream>::mapping(llvm::yaml::IO&,
llvm::pdb::yaml::PdbDbiStream&)
/home/moyix/git/llvm-master/tools/llvm-pdbutil/PdbYaml.cpp:201:0
#14 0x00000000004b3c7e void
llvm::yaml::detail::doMapping<llvm::pdb::yaml::PdbDbiStream>(llvm::yaml::IO&,
llvm::pdb::yaml::PdbDbiStream&, llvm::yaml::EmptyContext&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:747:0
#15 0x00000000004b1cca
std::enable_if<llvm::yaml::unvalidatedMappingTraits<llvm::pdb::yaml::PdbDbiStream,
llvm::yaml::EmptyContext>::value, void>::type
llvm::yaml::yamlize<llvm::pdb::yaml::PdbDbiStream,
llvm::yaml::EmptyContext>(llvm::yaml::IO&, llvm::pdb::yaml::PdbDbiStream&,
bool, llvm::yaml::EmptyContext&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:846:0
#16 0x00000000004af1e8 void
llvm::yaml::IO::processKeyWithDefault<llvm::pdb::yaml::PdbDbiStream,
llvm::yaml::EmptyContext>(char const*,
llvm::Optional<llvm::pdb::yaml::PdbDbiStream>&,
llvm::Optional<llvm::pdb::yaml::PdbDbiStream> const&, bool,
llvm::yaml::EmptyContext&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:700:0
#17 0x00000000004ad8e4 void
llvm::yaml::IO::mapOptionalWithContext<llvm::pdb::yaml::PdbDbiStream,
llvm::yaml::EmptyContext>(char const*,
llvm::Optional<llvm::pdb::yaml::PdbDbiStream>&, llvm::yaml::EmptyContext&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:668:0
#18 0x00000000004ace15 void
llvm::yaml::IO::mapOptional<llvm::Optional<llvm::pdb::yaml::PdbDbiStream>
>(char const*, llvm::Optional<llvm::pdb::yaml::PdbDbiStream>&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:649:0
#19 0x00000000004a9f4a
llvm::yaml::MappingTraits<llvm::pdb::yaml::PdbObject>::mapping(llvm::yaml::IO&,
llvm::pdb::yaml::PdbObject&)
/home/moyix/git/llvm-master/tools/llvm-pdbutil/PdbYaml.cpp:155:0
#20 0x0000000000453186 void
llvm::yaml::detail::doMapping<llvm::pdb::yaml::PdbObject>(llvm::yaml::IO&,
llvm::pdb::yaml::PdbObject&, llvm::yaml::EmptyContext&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:747:0
#21 0x000000000044ca06
std::enable_if<llvm::yaml::unvalidatedMappingTraits<llvm::pdb::yaml::PdbObject,
llvm::yaml::EmptyContext>::value, void>::type
llvm::yaml::yamlize<llvm::pdb::yaml::PdbObject,
llvm::yaml::EmptyContext>(llvm::yaml::IO&, llvm::pdb::yaml::PdbObject&, bool,
llvm::yaml::EmptyContext&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:846:0
#22 0x000000000051069a
std::enable_if<llvm::yaml::has_MappingTraits<llvm::pdb::yaml::PdbObject,
llvm::yaml::EmptyContext>::value, llvm::yaml::Output&>::type
llvm::yaml::operator<< <llvm::pdb::yaml::PdbObject>(llvm::yaml::Output&,
llvm::pdb::yaml::PdbObject&)
/home/moyix/git/llvm-master/include/llvm/Support/YAMLTraits.h:1487:0
#23 0x000000000050eeb4 llvm::pdb::YAMLOutputStyle::flush()
/home/moyix/git/llvm-master/tools/llvm-pdbutil/YAMLOutputStyle.cpp:332:0
#24 0x000000000050cec3 llvm::pdb::YAMLOutputStyle::dump()
/home/moyix/git/llvm-master/tools/llvm-pdbutil/YAMLOutputStyle.cpp:76:0
#25 0x0000000000434eec pdb2Yaml(llvm::StringRef)
/home/moyix/git/llvm-master/tools/llvm-pdbutil/llvm-pdbutil.cpp:621:0
#26 0x0000000000437b0f main
/home/moyix/git/llvm-master/tools/llvm-pdbutil/llvm-pdbutil.cpp:975:0
#27 0x00007f3181197830 __libc_start_main
/build/glibc-9tT8Do/glibc-2.23/csu/../csu/libc-start.c:325:0
#28 0x0000000000406249 _start
(/home/moyix/git/llvm-master/build/bin/llvm-pdbutil+0x406249)
Stack dump:
0.      Program arguments: /home/moyix/git/llvm-master/build/bin/llvm-pdbutil
pdb2yaml -all ./Windows/ehome/ehiitv.pdb

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20170620/9dd723ae/attachment-0001.html>


More information about the llvm-bugs mailing list