<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - bugpoint: UNREACHABLE executed at llvm/lib/Bitcode/Writer/BitcodeWriter.cpp:2447"
   href="https://bugs.llvm.org/show_bug.cgi?id=37685">37685</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>bugpoint: UNREACHABLE executed at llvm/lib/Bitcode/Writer/BitcodeWriter.cpp:2447
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>tools
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>bugpoint
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>vlad@tsyrklevich.net
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>$ cat ASTContext.cpp.o.ll
%"class.clang::ObjCCategoryDecl" = type {}
define i1 @a(%"class.clang::ObjCCategoryDecl"*) {
  unreachable, !dbg !8
}
!llvm.module.flags = !{!0}
!llvm.dbg.cu = !{!1}
!0 = !{i32 2, !"Debug Info Version", i32 3}
!1 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !2,
retainedTypes: !3)
!2 = !DIFile(filename: "ASTContext.cpp", directory: "")
!3 = !{!4}
!4 = !DICompositeType(tag: DW_TAG_class_type, file: !2, templateParams: !6)
!6 = !{!7}
!7 = !DITemplateValueParameter(value: i1 (%"class.clang::ObjCCategoryDecl"*)*
@a)
!8 = !DILocation(scope: !9)
!9 = distinct !DISubprogram(unit: !1)

$ bugpoint -compile-custom -compile-command /bin/echo ASTContext.cpp.o.ll
Read input file      : 'ASTContext.cpp.o.ll'
*** All input ok
Initializing execution environment: Found command in: /bin/echo
Running the code generator to test for a crash:
Generating reference output from raw program: <llc>
Error running tool:
  /llvm-build-debug/bin/llc --relocation-model=pic -o
bugpoint-test-program-b992e80.bc-087b26a.llc.s bugpoint-test-program-b992e80.bc
/llvm-build-debug/bin/llc: bugpoint-test-program-b992e80.bc: error: Could not
open input file: No such file or directory

*** There is a bug running the "safe" backend.  Either debug it (for example
with the -run-jit bugpoint option, if JIT is being used as the "safe" backend),
or fix the error some other way.
*** Debugging code generator crash!
Checking for crash with changing conditionals to always jump to true: :
define i1 @a(%"class.clang::ObjCCategoryDecl"*) {
  unreachable, !dbg !7
}

Unknown constant!
UNREACHABLE executed at /llvm/lib/Bitcode/Writer/BitcodeWriter.cpp:2447!
Stack dump:
0.      Program arguments: /llvm-build-debug/bin/bugpoint -compile-custom
-compile-command /bin/echo ASTContext.cpp.o.ll
#0 0x0000562d720664e6 llvm::sys::PrintStackTrace(llvm::raw_ostream&)
/llvm/lib/Support/Unix/Signals.inc:488:0
#1 0x0000562d72066579 PrintStackTraceSignalHandler(void*)
/llvm/lib/Support/Unix/Signals.inc:552:0
#2 0x0000562d72064b09 llvm::sys::RunSignalHandlers()
/llvm/lib/Support/Signals.cpp:67:0
#3 0x0000562d72065fa9 SignalHandler(int)
/llvm/lib/Support/Unix/Signals.inc:351:0
#4 0x00007f29cf93d0c0 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x110c0)
#5 0x00007f29ce4cefcf gsignal (/lib/x86_64-linux-gnu/libc.so.6+0x32fcf)
#6 0x00007f29ce4d03fa abort (/lib/x86_64-linux-gnu/libc.so.6+0x343fa)
#7 0x0000562d71fd4416 bindingsErrorHandler(void*,
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >
const&, bool) /llvm/lib/Support/ErrorHandling.cpp:231:0
#8 0x0000562d71316b40 (anonymous
namespace)::ModuleBitcodeWriter::writeConstants(unsigned int, unsigned int,
bool) /llvm/lib/Bitcode/Writer/BitcodeWriter.cpp:2378:0
#9 0x0000562d71316c2b (anonymous
namespace)::ModuleBitcodeWriter::writeModuleConstants()
/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp:2464:0
#10 0x0000562d713200bb (anonymous namespace)::ModuleBitcodeWriter::write()
/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp:3949:0
#11 0x0000562d71320e51 llvm::BitcodeWriter::writeModule(llvm::Module const&,
bool, llvm::ModuleSummaryIndex const*, bool, std::array<unsigned int, 5ul>*)
/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp:4141:0
#12 0x0000562d71321036 llvm::WriteBitcodeToFile(llvm::Module const&,
llvm::raw_ostream&, bool, llvm::ModuleSummaryIndex const*, bool,
std::array<unsigned int, 5ul>*)
/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp:4170:0
#13 0x0000562d70c4f94c llvm::BugDriver::runPasses(llvm::Module&,
std::vector<std::__cxx11::basic_string<char, std::char_traits<char>,
std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > > > const&,
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>
<span class="quote">>&, bool, bool, unsigned int, char const* const*) const</span >
/llvm/tools/bugpoint/OptimizerDriver.cpp:160:0
#14 0x0000562d70c507f1 llvm::BugDriver::runPassesOn(llvm::Module*,
std::vector<std::__cxx11::basic_string<char, std::char_traits<char>,
std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > > > const&, unsigned int, char
const* const*) /llvm/tools/bugpoint/OptimizerDriver.cpp:273:0
#15 0x0000562d70c0377c (anonymous
namespace)::ReduceCrashingConditionals::TestBlocks(std::vector<llvm::BasicBlock
const*, std::allocator<llvm::BasicBlock const*> >&)
/llvm/tools/bugpoint/CrashDebugger.cpp:554:0
#16 0x0000562d70c02fa9 (anonymous
namespace)::ReduceCrashingConditionals::doTest(std::vector<llvm::BasicBlock
const*, std::allocator<llvm::BasicBlock const*> >&,
std::vector<llvm::BasicBlock const*, std::allocator<llvm::BasicBlock const*>
<span class="quote">>&) /llvm/tools/bugpoint/CrashDebugger.cpp:492:0</span >
#17 0x0000562d70c11e13 llvm::ListReducer<llvm::BasicBlock
const*>::reduceList(std::vector<llvm::BasicBlock const*,
std::allocator<llvm::BasicBlock const*> >&)
/llvm/tools/bugpoint/ListReducer.h:52:0
#18 0x0000562d70c06d55 DebugACrash(llvm::BugDriver&, bool (*)(llvm::BugDriver
const&, llvm::Module*)) /llvm/tools/bugpoint/CrashDebugger.cpp:1068:0
#19 0x0000562d70c0828c llvm::BugDriver::debugCodeGeneratorCrash()
/llvm/tools/bugpoint/CrashDebugger.cpp:1225:0
#20 0x0000562d70bfa3b5 llvm::BugDriver::run()
/llvm/tools/bugpoint/BugDriver.cpp:204:0
#21 0x0000562d70c5ae3c main /llvm/tools/bugpoint/bugpoint.cpp:215:0
#22 0x00007f29ce4bc2b1 __libc_start_main
(/lib/x86_64-linux-gnu/libc.so.6+0x202b1)
#23 0x0000562d70bf93fa _start (/llvm-build-debug/bin/bugpoint+0xd0f3fa)</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>