wolfgang    2005/03/09 00:51:45 PST

  Modified files:
    ghc/includes         Storage.h 
    ghc/rts              GC.c Linker.c Storage.c 
  Log:
  Retain all CAFs when dynamic Haskell libraries are used from GHCi.
  The Linker usually replaces references to newCAF with references to newDynCAF,
  but the system dynamic linker won't do that for us.
  
  Also, the situation is slightly different - we never want CAFs from dylibs
  to be reverted, because the dylibs might be used both by the interpreted
  program and by GHCi itself.
  
  So instead of just caf_list, there's now both caf_list and 
revertible_caf_list.
  newDynCAF adds a CAF to revertible_caf_list, and newCAF either adds the CAF
  to caf_list or to the mutable list, depending on whether we are in GHCi.
  
  This hack is only active when Linker.c has loaded libHSbase_dyn.[so|dylib],
  but for now, it applies to all CAFs, not just dynamically-linked ones.
  If that is worth fixing, we could do that by checking whether the the CAF
  closure or it's info pointer is in the main executable's address range.
  
  MERGE TO STABLE
  
  Revision  Changes    Path
  1.6       +5 -0      fptools/ghc/includes/Storage.h
  1.180     +7 -2      fptools/ghc/rts/GC.c
  1.179     +18 -0     fptools/ghc/rts/Linker.c
  1.87      +36 -13    fptools/ghc/rts/Storage.c
_______________________________________________
Cvs-ghc mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/cvs-ghc

Reply via email to