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,251
    • Issues 4,251
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
    • Iterations
  • Merge Requests 393
    • Merge Requests 393
  • Requirements
    • Requirements
    • List
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
  • Security & Compliance
    • Security & Compliance
    • Dependency List
    • License Compliance
  • Operations
    • Operations
    • Incidents
    • Environments
  • Analytics
    • Analytics
    • CI / CD
    • Code Review
    • Insights
    • Issue
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Glasgow Haskell Compiler
  • GHCGHC
  • Issues
  • #11777

Closed
Open
Opened Mar 31, 2016 by Simon Peyton Jones@simonpjDeveloper

RTS source code issues

Tiago Silva <tiagosilva@hush.com> writes: Last night I started looking at the C files used in GHC and noticed these issues [edit: this list now shows only those issues that haven't been fixed yet]:

  • driver/utils/dynwrapper.c:
int main(int argc, char *argv[]) {
    void *p;
    ...
}

void *p is apparently unused, even if the compiler optimizes it away.. you should check if something went missing.

  • rts/RetainerSet.c:
#elif defined(RETAINER_SCHEME_CC)
// Retainer scheme 3: retainer = cost centre
void
printRetainerSetShort(FILE *f, RetainerSet *rs, nat max_length)

{
    char tmp[max_length + 1];
    int size;
    nat j;

}

Unlike the other functions around it, this function does nothing. Its variables are also not unused?

  • rts/win32/IOManager.c:
AddIORequest, AddDelayRequest, AddProcRequest functions

If (!ioMan || !wItem) the functions either return 0 or FALSE, but they don't free wItem before. Is this optimized by the compiler?

Edited Mar 10, 2019 by thomie
Assignee
Assign to
8.6.1
Milestone
8.6.1 (Past due)
Assign milestone
Time tracking
None
Due date
None
Reference: ghc/ghc#11777