search for: debugpass

Displaying 2 results from an estimated 2 matches for "debugpass".

2017 Jun 09
2
Get segfault with ModulePass
...st a better place, otherwise. I'm currently writing a LLVM ModulePass and ran into strange segfaults or endless loops within LLVM. My main question is, if this is a programming error or API misuse from me or a LLVM bug? Here is some minimal code, that triggers the bug: ---------------- class DebugPass : public ModulePass { public: static char ID; DebugPass() : ModulePass(ID) {} virtual bool runOnModule(Module &M) override { DILocation* loc; for (auto &F : M) { for (auto &B : F) { for (auto &I : B) { errs() << "op_code: " << I.get...
2017 Jun 11
2
Get segfault with ModulePass
...r<llvm::ilist_detail::node_options<llvm::Argument, true, false, void>, false, true>::operator->() const /usr/lib/llvm/4/include/llvm/ADT/ilist_iterator.h:142:0 #10 0x00007fc2aed895da (anonymous namespace)::GremlinPass::runOnModule(llvm::Module&) /home/gerion/sourcecode/debug-pass/debugpass/DebugPass.cpp:41:0 ... -------------------- > FWIW, StringRefs aren't guaranteed to be nul-terminated. They support > a similar comparison API as std::strings, though, so things like > `user->getOpcodeName() == "<Invalid operator>"` should just work™. getOpcodeName...