summaryrefslogtreecommitdiff
path: root/src/cmd/5l
diff options
context:
space:
mode:
authorElias Naur <elias.naur@gmail.com>2014-02-03 14:07:54 -0800
committerElias Naur <elias.naur@gmail.com>2014-02-03 14:07:54 -0800
commit70a195094ee9d393ef3da734f47370625e2a48df (patch)
treeabfc4d0af1929b90365b3934c072b02d045e4d5b /src/cmd/5l
parent1deb0d415aa12533c30bd2c1136e594ac0737053 (diff)
downloadgo-70a195094ee9d393ef3da734f47370625e2a48df.tar.gz
liblink, cmd/5a, cmd/5l: restore cgo on older ARM processors
CL 56120043 fixed TLS handling on ARM after the introduction of liblink but left older ARM processors broken. Before liblink, the MRC instruction was replaced with a fallback on older ARMs. CL 56120043 removed that, because the rewrite matched bit patterns on the AWORD pseudo-instruction and could therefore change unrelated AWORDs that happened to match. This CL adds an AMRC instruction to encode both MRC and MCR previously encoded as AWORDs. Then, in liblink, the AMRC instructions are either rewritten to AWORD, or, on goarm < 7, replaced with a branch to the fallback. ./all.bash completes successfully on an ARMv7 with either GOARM=7 or GOARM=5. I have verified that the fallback is indeed present in both runtime.save_gm and runtime.load_gm when GOARM=5 but not when GOARM=7. If all goes well, this should fix the armv5 builders. LGTM=iant R=iant, rsc CC=golang-codereviews https://codereview.appspot.com/55540044 Committer: Ian Lance Taylor <iant@golang.org>
Diffstat (limited to 'src/cmd/5l')
-rw-r--r--src/cmd/5l/5.out.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/cmd/5l/5.out.h b/src/cmd/5l/5.out.h
index f832f2af8..99836cb7f 100644
--- a/src/cmd/5l/5.out.h
+++ b/src/cmd/5l/5.out.h
@@ -200,6 +200,8 @@ enum as
ACHECKNIL,
AFATVARDEF,
+ AMRC, // MRC/MCR
+
ALAST,
};