[commit: ghc] master: Fix PPC NCG after blockID patch (f8e7fec)
git at git.haskell.org
git at git.haskell.org
Thu Nov 9 23:35:25 UTC 2017
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/f8e7fece58fa082b8b5a87fb84ffd5d18500d26a/ghc
>---------------------------------------------------------------
commit f8e7fece58fa082b8b5a87fb84ffd5d18500d26a
Author: Peter Trommler <ptrommler at acm.org>
Date: Thu Nov 9 17:55:01 2017 -0500
Fix PPC NCG after blockID patch
Commit rGHC8b007ab assigns the same label to the first basic block
of a proc and to the proc entry point. This violates the PPC 64-bit ELF
v. 1.9 and v. 2.0 ABIs and leads to duplicate symbols.
This patch fixes duplicate symbols caused by block labels
In commit rGHCd7b8da1 an info table label is generated from a block id.
Getting the entry label from that info label leads to an undefined
symbol because a suffix "_entry" that is not present in the block label.
To fix that issue add a new info table label flavour for labels
derived from block ids. Converting such a label with toEntryLabel
produces the original block label.
Fixes #14311
Test Plan: ./validate
Reviewers: austin, bgamari, simonmar, erikd, hvr, angerman
Reviewed By: bgamari
Subscribers: rwbarton, thomie
GHC Trac Issues: #14311
Differential Revision: https://phabricator.haskell.org/D4149
>---------------------------------------------------------------
f8e7fece58fa082b8b5a87fb84ffd5d18500d26a
compiler/cmm/BlockId.hs | 3 ++-
compiler/cmm/CLabel.hs | 30 +++++++++++++++++++++++++++++-
compiler/nativeGen/PPC/CodeGen.hs | 14 ++++++++++++--
compiler/nativeGen/PPC/Instr.hs | 4 ----
compiler/nativeGen/PPC/Ppr.hs | 22 ++++++++++------------
5 files changed, 53 insertions(+), 20 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 f8e7fece58fa082b8b5a87fb84ffd5d18500d26a
More information about the ghc-commits
mailing list