Summary
This code will trigger an inlining loop
Metadata
- Id: d5400b07bd8fb725e2809a251ce371e5c952dc46
- Trac id: 1226
- Type: defect
- Reporter: ckeen
- Owner:
- Cc:
- Status: closed
- Component: compiler
- Estimated difficulty: hard
- Resolution: fixed
- Priority: major
- Milestone: someday
- Version: 4.10.x
- Changetime: 2022-10-21 16:16:09 UTC
- Created: 2015-11-27 21:40:08 UTC
- Keywords:
Description
When compiling the following code with -O3 it will trigger an inlining loop observable with -debug i
(define (main-loop renderer)
(main-loop renderer))
(when (zero? 0)
(let ()
(when #t
(when #t
(main-loop renderer)))))
...
inlining: "(t.scm:2) main-loop" f_193 14
inlining: "(t.scm:2) main-loop" f_193 14
...
Changes and comments
[2015-11-27 21:40:53 UTC] ckeen changed version from 4.9.x to 4.10.x
[2015-11-27 21:40:53 UTC] ckeen changed component from unknown to compiler
[2015-11-27 21:42:09 UTC] ckeen wrote:
Also -O2
[2016-08-25 20:23:24 UTC] sjamaan set difficulty to hard
[2022-10-21 16:16:09 UTC] felix changed status from new to closed
[2022-10-21 16:16:09 UTC] felix set resolution to fixed
[2022-10-21 16:16:09 UTC] felix wrote:
Seems to have been fixed a while ago:
inlining: "(x.scm:2) main-loop" f_128 14 inlining: "(x.scm:2) main-loop" f_128 18 not inlining as unroll-limit is exceeded: "(x.scm:2) main-loop" f_128 f_128 inlining: "(x.scm:8) main-loop" f_128 10 inlining: "(x.scm:2) main-loop" f_128 10 not inlining as unroll-limit is exceeded: "(x.scm:2) main-loop" f_128 f_126 not inlining as unroll-limit is exceeded: "(x.scm:2) main-loop" f_128 f_128 not inlining as unroll-limit is exceeded: "(x.scm:2) main-loop" f_128 f_126 not inlining as unroll-limit is exceeded: "(x.scm:2) main-loop" f_128 f_128 not inlining as unroll-limit is exceeded: "(x.scm:2) main-loop" f_128 f_126 not inlining as unroll-limit is exceeded: "(x.scm:2) main-loop" f_128 f_128 not inlining as unroll-limit is exceeded: "(x.scm:2) main-loop" f_128 f_126 not inlining as unroll-limit is exceeded: "(x.scm:2) main-loop" f_128 f_128 not inlining as unroll-limit is exceeded: "(x.scm:2) main-loop" f_128 f_126