-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
[X86AsmPrinter] Assertion `!NodePtr->isKnownSentinel()' failed #117206
Comments
@llvm/issue-subscribers-backend-x86 Author: Arthur Eubanks (aeubanks)
```
$ cat /tmp/a.ll
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-grtev4-linux-gnu"
; Function Attrs: noinline optnone do.body: ; preds = %entry ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(none) attributes #0 = { noinline optnone "frame-pointer"="all" } !llvm.dbg.cu = !{!0} !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus_14, file: !1, producer: "clang", isOptimized: false, runtimeVersion: 0, emissionKind: LineTablesOnly, splitDebugInlining: false, nameTableKind: None) $ llc -o /dev/null /tmp/a.ll
#0 0x000056416e8a76a8 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) llvm-project/build/rel/../../llvm/lib/Support/Unix/Signals.inc:723:13
|
@llvm/issue-subscribers-debuginfo Author: Arthur Eubanks (aeubanks)
```
$ cat /tmp/a.ll
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-grtev4-linux-gnu"
; Function Attrs: noinline optnone do.body: ; preds = %entry ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(none) attributes #0 = { noinline optnone "frame-pointer"="all" } !llvm.dbg.cu = !{!0} !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus_14, file: !1, producer: "clang", isOptimized: false, runtimeVersion: 0, emissionKind: LineTablesOnly, splitDebugInlining: false, nameTableKind: None) $ llc -o /dev/null /tmp/a.ll
#0 0x000056416e8a76a8 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) llvm-project/build/rel/../../llvm/lib/Support/Unix/Signals.inc:723:13
|
Thanks for the report; patch in #117320 |
…ot (#117320) The optimiser will produce empty blocks that are unconditionally executed according to the CFG -- while it may not be meaningful code, and won't get a prologue_end position, we need to not crash on this input. The fault comes from assuming that there's always a next block with some instructions in it, that will eventually produce some meaningful control flow to stop at -- in the given reproducer in issue #117206 this isn't true, because the function terminates with `unreachable`. Thus, I've refactored the "get next instruction logic" into a helper that'll step through all blocks and terminate if there aren't any more. Reproducer from aeubanks
This was fixed by 624e52b |
The text was updated successfully, but these errors were encountered: