Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
GHC
GHC
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 4,391
    • Issues 4,391
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
    • Iterations
  • Merge Requests 371
    • Merge Requests 371
  • Requirements
    • Requirements
    • List
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Operations
    • Operations
    • Incidents
    • Environments
  • Analytics
    • Analytics
    • CI / CD
    • Code Review
    • Insights
    • Issue
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Glasgow Haskell Compiler
  • GHCGHC
  • Issues
  • #3591

Closed
Open
Opened Oct 16, 2009 by Ghost User@ghost

A working program reports <<loop>> when compiled with -O

If the attached module Trampoline.hs is compiled with no optimizations it works:

$ ghc --make Trampoline.hs   
[1 of 1] Compiling Main             ( Trampoline.hs, Trampoline.o )
Linking Trampoline ...
$ ./Trampoline 
...
((5,2),(1,2,6))
$ 

With optimizations on, it hangs:

$ ghc --make Trampoline.hs -O
[1 of 1] Compiling Main             ( Trampoline.hs, Trampoline.o )
Linking Trampoline ...
$ ./Trampoline 
bounce start
bounce end
liftOut
inject suspend
Trampoline: <<loop>>

That doesn't seem right. Oh, GHCi runs it with no problem as well.

Trac metadata
Trac field Value
Version 6.10.4
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Compiler
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
Assignee
Assign to
6.12.1
Milestone
6.12.1
Assign milestone
Time tracking
None
Due date
None
Reference: ghc/ghc#3591