Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SR-14341] crash in lldb: TypeSystemSwiftTypeRef.cpp:448: virtual bool lldb_private::TypeSystemSwiftTypeRef::IsFunctionType(lldb::opaque_compiler_type_t, bool *).... #4318

Open
hassila opened this issue Mar 12, 2021 · 2 comments
Labels
bug Something isn't working LLDB for Swift

Comments

@hassila
Copy link

hassila commented Mar 12, 2021

Previous ID SR-14341
Radar rdar://problem/75356739
Original Reporter @hassila
Type Bug
Environment

jocke@swift511 ~/s/swiftnio511 (jh-liburing-refactor-selector) [SIGABRT]> uname -a

Linux swift511 5.11.0-051100-generic #202102142330 SMP Sun Feb 14 23:33:21 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux

jocke@swift511 ~/s/swiftnio511 (jh-liburing-refactor-selector)> swift --version

Swift version 5.3.3 (swift-5.3.3-RELEASE)

Target: x86_64-unknown-linux-gnu

Additional Detail from JIRA
Votes 0
Component/s LLDB for Swift
Labels Bug, LLDBCrash
Assignee None
Priority Medium

md5: 4e6930443352a68b42813b420443b032

Issue Description:

I provide a reproducer at:

https://www.icloud.com/iclouddrive/0Sh_84ApNWmZa78Oj1n4JTbIA#reproducer-a515ea

reregister interested SelectorEventSet(rawValue: 5)

Process 30785 stopped

* thread #​3, name = 'NIO-ELT-0-#1', stop reason = step over

    frame #&#8203;0: 0x000055555562b8cd NIOEchoServer`closure #&#8203;1 in URingSelector.reregister<R>(fd=$ss4CIntaD @ 0x00007ffff4bb57c8, self=<invalid> @ 0x00007ffff4bb5788, interested=<unavailable>) at Selector.swift:849:13 [opt]

   846         try selectable.withUnsafeHandle { fd in

   847             var reg = registrations[Int(fd)]!

   848  print("reregister interested \(interested)")

-> 849             ring.io_uring_prep_poll_add(fd: fd, poll_mask: interested.uringEventSet)

   850  

   851             reg.interested = interested

   852             registrations[Int(fd)] = reg

Target 0: (NIOEchoServer) stopped.

(lldb) bt

lldb: /home/build-user/llvm-project/lldb/source/Symbol/TypeSystemSwiftTypeRef.cpp:448: virtual bool lldb_private::TypeSystemSwiftTypeRef::IsFunctionType(lldb::opaque_compiler_type_t, bool *): Assertion `Equivalent(result, (m_swift_ast_context->IsFunctionType( ReconstructType(type), nullptr))) && "TypeSystemSwiftTypeRef diverges from SwiftASTContext"' failed.

Stack dump:

0. Program arguments: lldb .build/x86_64-unknown-linux-gnu/release/NIOEchoServer 

lldb[0x420814]

lldb[0x41e99e]

lldb[0x420d95]

/lib/x86_64-linux-gnu/libpthread.so.0(+0x153c0)[0x7fbe9f18f3c0]

/lib/x86_64-linux-gnu/libc.so.6(gsignal+0xcb)[0x7fbe94dc118b]

/lib/x86_64-linux-gnu/libc.so.6(abort+0x12b)[0x7fbe94da0859]

/lib/x86_64-linux-gnu/libc.so.6(+0x25729)[0x7fbe94da0729]

/lib/x86_64-linux-gnu/libc.so.6(+0x36f36)[0x7fbe94db1f36]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xe44835)[0x7fbe976df835]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xe44f3f)[0x7fbe976dff3f]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0x10657d3)[0x7fbe979007d3]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xd550cc)[0x7fbe975f00cc]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xd52f69)[0x7fbe975edf69]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xd50179)[0x7fbe975eb179]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xd4fe59)[0x7fbe975eae59]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xd4a68f)[0x7fbe975e568f]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xd325d8)[0x7fbe975cd5d8]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xd383d3)[0x7fbe975d33d3]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xd3aa7e)[0x7fbe975d5a7e]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0x10ab17b)[0x7fbe9794617b]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xcf7e30)[0x7fbe97592e30]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xcf7471)[0x7fbe97592471]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xcf7471)[0x7fbe97592471]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xcf7063)[0x7fbe97592063]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xe9fd1f)[0x7fbe9773ad1f]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xea03db)[0x7fbe9773b3db]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xea4cba)[0x7fbe9773fcba]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xf0f746)[0x7fbe977aa746]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0x1444833)[0x7fbe97cdf833]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0x14440bc)[0x7fbe97cdf0bc]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xdb5be7)[0x7fbe97650be7]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xdad177)[0x7fbe97648177]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xdb6d75)[0x7fbe97651d75]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xdb5e63)[0x7fbe97650e63]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xdad177)[0x7fbe97648177]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xdb06e3)[0x7fbe9764b6e3]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xcfef46)[0x7fbe97599f46]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xce40af)[0x7fbe9757f0af]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(+0xdb12f6)[0x7fbe9764c2f6]

/home/jocke/swift/swift-5.3.3-RELEASE-ubuntu20.04/usr/bin/../lib/liblldb.so.10git(_ZN4lldb10SBDebugger21RunCommandInterpreterEbb+0xe9)[0x7fbe972c7869]

lldb[0x40ab04]

lldb[0x40c2d3]

/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf3)[0x7fbe94da20b3]

lldb[0x4073ae]


Crash reproducer for lldb version 10.0.0 (git@github.com:apple/llvm-project.git revision 3093af41dd65ad466dcd5603e9289244edfee4f5)

Swift version 5.3.3 (swift-5.3.3-RELEASE)

 

Reproducer written to '/tmp/reproducer-a515ea'
 

Before attaching the reproducer to a bug report:

 - Look at the directory to ensure you're willing to share its content.

 - Make sure the reproducer works by replaying the reproducer.

 

Replay the reproducer with the following command:

lldb -replay /tmp/reproducer-a515ea

********************

fish: Job 1, 'lldb .build/x86_64-unknown-linu?' terminated by signal SIGABRT (Abort)
@weissi
Copy link
Member

weissi commented Mar 12, 2021

@swift-ci create

@weissi
Copy link
Member

weissi commented Mar 12, 2021

@adrian-prantl just to be sure that these reports have all the info you need. If not, is there anything else you’d need apart from the reproducer?

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
@shahmishal shahmishal transferred this issue from apple/swift May 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working LLDB for Swift
Projects
None yet
Development

No branches or pull requests

2 participants