Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
  • GHC GHC
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 4,868
    • Issues 4,868
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
  • Merge requests 456
    • Merge requests 456
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Glasgow Haskell Compiler
  • GHCGHC
  • Issues
  • #77
Closed
Open
Created Sep 05, 2002 by nobody@trac-nobody

Compiling with -O yields broken .hc file

When compiling the attached source file (part of
AFrob) with GHC 5.04 under Linux (RH 7.2) and
optimizations turned on, an invalid .hc file is
generated. I'm actually surprised that there is an
.hc file in the first place, since I thought I was
using the native code generator? The generated .hc
file is also included.

The command I use is:

ghc -c -fglasgow-exts -O -package lang -package posix
-package concurrent
-i/usr/local/lib/ghc/imports/hgl:/usr/local/lib/ghc/imports/arrow:/usr/local/lib/ghc/imports/afrp:../Common
-keep-hc-files -o RSWorldGeometry.o RSWorldGeometry.hs

The error message I get is:

RSWorldGeometry.hc: In function `saF6_ret':
RSWorldGeometry.hc:79: invalid lvalue in decrement
RSWorldGeometry.hc:79: parse error before `5.0'

which makes sense if one looks at the C code.

The source module and the generated c file are
included in the form of a gzipped tar file. If you
need the entire context,  try our AFRP/AFrob hacker's
pre-release available from www.haskell.org/afrp.

All the best,

/Henrik

--
Henrik Nilsson
Yale University
nilsson@cs.yale.edu
Trac metadata
Trac field Value
Version 5.04
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution ResolvedFixed
Component Compiler
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking