[commit: ghc] master: Make the linker more robust to errors (5300099)

git at git.haskell.org git at git.haskell.org
Wed Oct 8 12:57:26 UTC 2014


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/5300099edf106c1f5938c0793bd6ca199a0eebf0/ghc

>---------------------------------------------------------------

commit 5300099edf106c1f5938c0793bd6ca199a0eebf0
Author: Simon Marlow <marlowsd at gmail.com>
Date:   Wed Oct 1 13:15:05 2014 +0100

    Make the linker more robust to errors
    
    Summary:
    When linking fails because there was a problem with the supplied
    object file, then we should not barf() or exit, we should emit a
    suitable error message and return an error code to the caller.  We
    should also free all memory that might have been allocated during
    linking, and generally not do any damage.  This patch fixes most
    common instances of this problem.
    
    Test Plan: validate
    
    Reviewers: rwbarton, austin, ezyang
    
    Reviewed By: ezyang
    
    Subscribers: simonmar, ezyang, carter, thomie
    
    Differential Revision: https://phabricator.haskell.org/D294


>---------------------------------------------------------------

5300099edf106c1f5938c0793bd6ca199a0eebf0
 includes/rts/Linker.h               |   2 +-
 rts/Linker.c                        | 380 +++++++++++++++++++++++-------------
 testsuite/tests/rts/Makefile        |  50 ++++-
 testsuite/tests/rts/all.T           |  17 ++
 testsuite/tests/rts/linker_error.c  |  66 +++++++
 testsuite/tests/rts/linker_error2.c |   6 +
 testsuite/tests/rts/linker_error3.c |   6 +
 testsuite/tests/rts/linker_unload.c |   4 +-
 8 files changed, 388 insertions(+), 143 deletions(-)

Diff suppressed because of size. To see it, use:

    git diff-tree --root --patch-with-stat --no-color --find-copies-harder --ignore-space-at-eol --cc 5300099edf106c1f5938c0793bd6ca199a0eebf0


More information about the ghc-commits mailing list