diff options
| author | Ben Shi <powerman1st@163.com> | 2018-08-08 04:10:19 +0000 |
|---|---|---|
| committer | Ben Shi <powerman1st@163.com> | 2018-08-20 14:09:51 +0000 |
| commit | 26d62b4ca9bb8f7342d337ba43b0cc1aedaf7852 (patch) | |
| tree | d8c81b95c0e6beade2050d8460f5ab443eb23332 /src/cmd/asm | |
| parent | 285747b900ac8e1b006d8d88d876e8a08452b7ef (diff) | |
| download | go-26d62b4ca9bb8f7342d337ba43b0cc1aedaf7852.tar.xz | |
cmd/internal/obj/arm64: add SWPALD/SWPALW/SWPALH/SWPALB
Those new instructions have acquire/release semantics, besides
normal atomic SWPD/SWPW/SWPH/SWPB.
Change-Id: I24821a4d21aebc342897ae52903aef612c8d8a4a
Reviewed-on: https://go-review.googlesource.com/128476
Run-TryBot: Ben Shi <powerman1st@163.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
Diffstat (limited to 'src/cmd/asm')
| -rw-r--r-- | src/cmd/asm/internal/arch/arm64.go | 1 | ||||
| -rw-r--r-- | src/cmd/asm/internal/asm/testdata/arm64.s | 8 |
2 files changed, 9 insertions, 0 deletions
diff --git a/src/cmd/asm/internal/arch/arm64.go b/src/cmd/asm/internal/arch/arm64.go index 475d7da5f9..7cbc139bce 100644 --- a/src/cmd/asm/internal/arch/arm64.go +++ b/src/cmd/asm/internal/arch/arm64.go @@ -74,6 +74,7 @@ func IsARM64STLXR(op obj.As) bool { arm64.ASTXRB, arm64.ASTXRH, arm64.ASTXRW, arm64.ASTXR, arm64.ASTXP, arm64.ASTXPW, arm64.ASTLXP, arm64.ASTLXPW, arm64.ASWPB, arm64.ASWPH, arm64.ASWPW, arm64.ASWPD, + arm64.ASWPALB, arm64.ASWPALH, arm64.ASWPALW, arm64.ASWPALD, arm64.ALDADDB, arm64.ALDADDH, arm64.ALDADDW, arm64.ALDADDD, arm64.ALDANDB, arm64.ALDANDH, arm64.ALDANDW, arm64.ALDANDD, arm64.ALDEORB, arm64.ALDEORH, arm64.ALDEORW, arm64.ALDEORD, diff --git a/src/cmd/asm/internal/asm/testdata/arm64.s b/src/cmd/asm/internal/asm/testdata/arm64.s index 3a4410f10b..3a1b2f79be 100644 --- a/src/cmd/asm/internal/asm/testdata/arm64.s +++ b/src/cmd/asm/internal/asm/testdata/arm64.s @@ -572,6 +572,14 @@ again: SWPH R5, (RSP), R7 // e7832578 SWPB R5, (R6), R7 // c7802538 SWPB R5, (RSP), R7 // e7832538 + SWPALD R5, (R6), R7 // c780e5f8 + SWPALD R5, (RSP), R7 // e783e5f8 + SWPALW R5, (R6), R7 // c780e5b8 + SWPALW R5, (RSP), R7 // e783e5b8 + SWPALH R5, (R6), R7 // c780e578 + SWPALH R5, (RSP), R7 // e783e578 + SWPALB R5, (R6), R7 // c780e538 + SWPALB R5, (RSP), R7 // e783e538 LDADDD R5, (R6), R7 // c70025f8 LDADDD R5, (RSP), R7 // e70325f8 LDADDW R5, (R6), R7 // c70025b8 |
