[llvm-bugs] [Bug 44226] New: opt -loop-unroll -iv-users crashes when doing "Freeing Pass 'Induction Variable Users' on Loop '<deleted>'..."

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Dec 5 00:55:16 PST 2019


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

            Bug ID: 44226
           Summary: opt -loop-unroll -iv-users crashes when doing "Freeing
                    Pass 'Induction Variable Users' on Loop
                    '<deleted>'..."
           Product: new-bugs
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: mikael.holmen at ericsson.com
                CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org

Created attachment 22895
  --> https://bugs.llvm.org/attachment.cgi?id=22895&action=edit
bbi-36444.ll reproducer

llvm version: f3dafd21a36f

Reproduce with:
 opt -o /dev/null bbi-36444.ll -loop-unroll -iv-users

Result:
Stack dump:
0.      Program arguments: build-all-builtins/bin/opt -o /dev/null bbi-36444.ll
-loop-unroll -iv-users 
1.      Running pass 'Function Pass Manager' on module 'bbi-36444.ll'.
2.      Running pass 'Loop Pass Manager' on function '@test'
3.      Releasing pass 'Induction Variable Users'
 #0 0x0000000003e69574 PrintStackTraceSignalHandler(void*)
(build-all-builtins/bin/opt+0x3e69574)
 #1 0x0000000003e6725e llvm::sys::RunSignalHandlers()
(build-all-builtins/bin/opt+0x3e6725e)
 #2 0x0000000003e6997c SignalHandler(int)
(build-all-builtins/bin/opt+0x3e6997c)
 #3 0x00007efe32333890 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x12890)
 #4 0x000000000303e185 llvm::IVUsersWrapperPass::releaseMemory()
(build-all-builtins/bin/opt+0x303e185)
 #5 0x0000000003709b4f llvm::PMDataManager::freePass(llvm::Pass*,
llvm::StringRef, llvm::PassDebuggingString)
(build-all-builtins/bin/opt+0x3709b4f)
 #6 0x00000000030be57d llvm::LPPassManager::runOnFunction(llvm::Function&)
(build-all-builtins/bin/opt+0x30be57d)
 #7 0x000000000370c683 llvm::FPPassManager::runOnFunction(llvm::Function&)
(build-all-builtins/bin/opt+0x370c683)
 #8 0x000000000370c968 llvm::FPPassManager::runOnModule(llvm::Module&)
(build-all-builtins/bin/opt+0x370c968)
 #9 0x000000000370cfcd llvm::legacy::PassManagerImpl::run(llvm::Module&)
(build-all-builtins/bin/opt+0x370cfcd)
#10 0x000000000207cdaa main (build-all-builtins/bin/opt+0x207cdaa)
#11 0x00007efe30dbfb97 __libc_start_main
/build/glibc-OTsEL5/glibc-2.27/csu/../csu/libc-start.c:344:0
#12 0x000000000206502a _start (build-all-builtins/bin/opt+0x206502a)
Segmentation fault (core dumped)

-debug-pass=Executions gives

[2019-12-05 09:54:16.848083739] 0x51f7480   Executing Pass 'Function Pass
Manager' on Module 'bbi-36444.ll'...
[2019-12-05 09:54:16.848188364] 0x51fc2e0     Executing Pass 'Dominator Tree
Construction' on Function 'test'...
[2019-12-05 09:54:16.848226289] 0x51fc2e0     Executing Pass 'Natural Loop
Information' on Function 'test'...
[2019-12-05 09:54:16.848261630] 0x51fc2e0     Executing Pass 'Canonicalize
natural loops' on Function 'test'...
[2019-12-05 09:54:16.848300952] 0x51fc2e0     Made Modification 'Canonicalize
natural loops' on Function 'test'...
[2019-12-05 09:54:16.848325816] 0x51fc2e0     Executing Pass 'LCSSA Verifier'
on Function 'test'...
[2019-12-05 09:54:16.848348655] 0x51fc2e0     Executing Pass 'Loop-Closed SSA
Form Pass' on Function 'test'...
[2019-12-05 09:54:16.848382808] 0x51fc2e0     Executing Pass 'Basic Alias
Analysis (stateless AA impl)' on Function 'test'...
[2019-12-05 09:54:16.848411025] 0x51fc2e0     Executing Pass 'Function Alias
Analysis Results' on Function 'test'...
[2019-12-05 09:54:16.848436098] 0x51fc2e0     Executing Pass 'Scalar Evolution
Analysis' on Function 'test'...
[2019-12-05 09:54:16.848475001] 0x51fc2e0     Executing Pass 'Loop Pass
Manager' on Function 'test'...
[2019-12-05 09:54:16.848507828] 0x51fd370       Executing Pass 'Unroll loops'
on Loop 'do.body'...
[2019-12-05 09:54:16.848693960] 0x51fd370       Made Modification 'Unroll
loops' on Loop '<deleted loop>'...
[2019-12-05 09:54:16.848724062] 0x51fd370        Freeing Pass 'Unroll loops' on
Loop '<deleted>'...
[2019-12-05 09:54:16.848745015] 0x51fd370        Freeing Pass 'Unroll loops' on
Loop '<deleted>'...
[2019-12-05 09:54:16.848763733] 0x51fd370        Freeing Pass 'Induction
Variable Users' on Loop '<deleted>'...

Old passmanager problem perhaps?

-- 
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/20191205/32492314/attachment-0001.html>


More information about the llvm-bugs mailing list