remove useless loop in a function body
Bug #554190 reported by
Roman Marynchak
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
SBCL |
Confirmed
|
Wishlist
|
Unassigned |
Bug Description
I cannot imagine the simpler example than this one:
(defun completely-useless ()
(loop for i from 1 to 10000000000 do (= 1 1)))
However, it does iterates in that loop... Is there some misunderstanding from my side, or SBCL just gives up any loop optimizations? I will not even try more complex examples from the famous book "Optimizing Compilers for Modern Architectures: A Dependence-based Approach", since they require more advanced loop analysis logic in the compiler than SBCL seems to have these days.
Regards,
Roman
Changed in sbcl: | |
status: | New → Confirmed |
To post a comment you must log in.
SBCL does not do any classic loop optimizations (e.g. unrolling), let alone any of the higher-level transforms described in Allen and Kennedy.