LoopSimplify (and other passes) destroyed llvm.loop infos
Open
loopoptim
- Dominant language
- LLVM
- Stars
- 40.5k
- Forks
- 18.7k
- PR merge metrics
- PR metrics pending
Description
When I was checking loop-unroll in O1, I thought any loops would not be unrolled since loopunroll was disabled.
LoopSimplify destroyed the loop info !27 at while.end (loop %while.cond), making it enable to be unrolled.
https://godbolt.org/z/v97ojTsn7
I wonder if it is a bug.
Contributor guide
Research direction
The issue names LoopSimplify, loop-unroll, and a Godbolt reproducer. Start by reproducing the example and tracing the LoopSimplify and loop-unroll pass entry points to confirm how the loop metadata affects unrolling. Done means establishing whether the metadata loss is a bug and documenting or testing the expected O1 behavior.
Written by the indexing model from the issue text.
Assessment
- Domain
- compilers
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 45/100