From: Guoqi Chen Date: Mon, 25 Jul 2022 07:30:53 +0000 (+0800) Subject: runtime: refactor the linux/loong64 entrypoint X-Git-Tag: go1.21rc1~1280 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=574c6209019f1efbca2a058b576b227c2e7b5e61;p=gostls13.git runtime: refactor the linux/loong64 entrypoint Remove the meaningless jump, and add the missing NOFRAME flag to _rt0_loong64_linux. Change-Id: I1aec68c556615b42042684bd176dfc2a8af094d1 Reviewed-on: https://go-review.googlesource.com/c/go/+/420977 Run-TryBot: M Zhuo TryBot-Result: Gopher Robot Reviewed-by: xiaodong liu Reviewed-by: Ian Lance Taylor Reviewed-by: Meidan Li Reviewed-by: Cherry Mui Reviewed-by: WANG Xuerui --- diff --git a/src/runtime/rt0_linux_loong64.s b/src/runtime/rt0_linux_loong64.s index b23ae7837a..b9aaa510e1 100644 --- a/src/runtime/rt0_linux_loong64.s +++ b/src/runtime/rt0_linux_loong64.s @@ -4,16 +4,13 @@ #include "textflag.h" -TEXT _rt0_loong64_linux(SB),NOSPLIT,$0 - JMP _main<>(SB) - -TEXT _main<>(SB),NOSPLIT|NOFRAME,$0 +TEXT _rt0_loong64_linux(SB),NOSPLIT|NOFRAME,$0 // In a statically linked binary, the stack contains argc, // argv as argc string pointers followed by a NULL, envv as a // sequence of string pointers followed by a NULL, and auxv. // There is no TLS base pointer. - MOVW 0(R3), R4 // argc - ADDV $8, R3, R5 // argv + MOVW 0(R3), R4 // argc + ADDV $8, R3, R5 // argv JMP main(SB) TEXT main(SB),NOSPLIT|NOFRAME,$0