[llvm-bugs] [Bug 45033] New: Assertion failed: !NodePtr->isKnownSentinel() with boost::intrusive_ptr on Windows

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Feb 26 08:27:44 PST 2020


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

            Bug ID: 45033
           Summary: Assertion failed: !NodePtr->isKnownSentinel() with
                    boost::intrusive_ptr on Windows
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
          Assignee: unassignedclangbugs at nondot.org
          Reporter: etienne at atnnn.com
                CC: blitzrakete at gmail.com, dgregor at apple.com,
                    erik.pilkington at gmail.com, llvm-bugs at lists.llvm.org,
                    richard-llvm at metafoo.co.uk

Created attachment 23172
  --> https://bugs.llvm.org/attachment.cgi?id=23172&action=edit
Minimal example

The following code seems to cause clang and clang-cl, 9.0.0 and trunk, to
crash:

    intrusive_ptr<C> a;
    try {
        a = mk();
        mk();
    }
    catch (...) {
    }

Debug logs show

    INSTCOMBINE ITERATION #1 on ?crash@@YAXXZ
    IC: ADDING: 27 instrs to worklist
    IC: Visiting:   %call1 = invoke %struct.C* @"?mk@@YAPEAUC@@XZ"()
              to label %invoke.cont2 unwind label %catch.dispatch
    IC: Visiting:   %a.sroa.0.0 = phi i64 [ %0, %invoke.cont2 ], [ 0, %entry ]
    IC: Visiting:   %1 = catchswitch within none [label %catch] unwind label
%ehcleanup
    IC: Visiting:   %2 = catchpad within %1 [i8* null, i32 64, i8* null]
    IC: Visiting:   catchret from %2 to label %try.cont
    IC: Visiting:   %a.sroa.0.1 = phi i64 [ %0, %invoke.cont2 ], [ %a.sroa.0.0,
%catch ]
    IC: ADD:   %a.sroa.0.1.ptr = phi %struct.C* 
    Assertion failed: !NodePtr->isKnownSentinel(), file
C:\src\llvm_package_2663a25f\llvm-project\llvm\include\llvm/ADT/ilist_iterator.h,
line 139

I've attached the logs and full trimmed down source.

Thanks.

-- 
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/20200226/40f5e673/attachment-0001.html>


More information about the llvm-bugs mailing list