]> Cypherpunks repositories - gostls13.git/commit
cmd/internal/obj/loong64: improve the definition of plan9 assembly format in optab
authorGuoqi Chen <chenguoqi@loongson.cn>
Sun, 7 May 2023 22:20:21 +0000 (06:20 +0800)
committerGopher Robot <gobot@golang.org>
Mon, 13 May 2024 15:52:19 +0000 (15:52 +0000)
commit9ea4770e144d27877e5fe7635b662d20f6b86a6b
tree780eb51e8e72757ba01b5e7325171982250d1237
parentec711aaaaa31b551a47b3677d05014e8aa60f9ea
cmd/internal/obj/loong64: improve the definition of plan9 assembly format in optab

In the three formats corresponding to case 7 of the function asmout, BREAK actually
corresponds to the cacop instruction of Loong64, refer to the loong64 instruction
manual volume 1 [1], the cacop instruction is a privileged instruction used to
maintain the cache, and the user mode does not have permission to execute.

Referring to the loong64 instruction manual volume 1 [1], the SYSCALL, BREAK and DBAR
instructions have similar formats and can be grouped into one category, the RDTIMED,
RDTIMELW and RDTIMEHW instructions can be grouped into one category, and the NOOP and
UNDEF instructions can be grouped into one category.

[1]: https://loongson.github.io/LoongArch-Documentation/LoongArch-Vol1-EN.html

Change-Id: I0b8998270102d1557fc2b2410cf8c0b078bd0c2e
Reviewed-on: https://go-review.googlesource.com/c/go/+/493435
Reviewed-by: sophie zhao <zhaoxiaolin@loongson.cn>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Meidan Li <limeidan@loongson.cn>
Reviewed-by: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: abner chenc <chenguoqi@loongson.cn>
Reviewed-by: Qiqi Huang <huangqiqi@loongson.cn>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Auto-Submit: Cherry Mui <cherryyz@google.com>
src/cmd/asm/internal/asm/testdata/loong64enc1.s
src/cmd/internal/obj/loong64/asm.go