Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(140)

Delta Between Two Patch Sets: src/pkg/runtime/asm_amd64.s

Issue 129510043: code review 129510043: runtime: convert Stack to Go. (Closed)
Left Patch Set: diff -r d06e79685295c5e0da29106e139cfaafb3318258 https://go.googlecode.com/hg/ Created 10 years, 6 months ago
Right Patch Set: diff -r 1fadcb6ee46b84c1977d40ceecf14d0ffe100f80 https://go.googlecode.com/hg/ Created 10 years, 6 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
LEFTRIGHT
1 // Copyright 2009 The Go Authors. All rights reserved. 1 // Copyright 2009 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style 2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file. 3 // license that can be found in the LICENSE file.
4 4
5 #include "zasm_GOOS_GOARCH.h" 5 #include "zasm_GOOS_GOARCH.h"
6 #include "funcdata.h" 6 #include "funcdata.h"
7 #include "../../cmd/ld/textflag.h" 7 #include "../../cmd/ld/textflag.h"
8 8
9 TEXT _rt0_go(SB),NOSPLIT,$0 9 TEXT _rt0_go(SB),NOSPLIT,$0
10 // copy arguments forward on an even stack 10 // copy arguments forward on an even stack
(...skipping 930 matching lines...) Expand 10 before | Expand all | Expand 10 after
941 MOVQ x+8(FP), BX 941 MOVQ x+8(FP), BX
942 MOVQ BX, -8(AX) // set calling pc 942 MOVQ BX, -8(AX) // set calling pc
943 RET 943 RET
944 944
945 TEXT runtime·getcallersp(SB),NOSPLIT,$0-8 945 TEXT runtime·getcallersp(SB),NOSPLIT,$0-8
946 MOVQ sp+0(FP), AX 946 MOVQ sp+0(FP), AX
947 RET 947 RET
948 948
949 // func gogetcallersp(p unsafe.Pointer) uintptr 949 // func gogetcallersp(p unsafe.Pointer) uintptr
950 TEXT runtime·gogetcallersp(SB),NOSPLIT,$0-16 950 TEXT runtime·gogetcallersp(SB),NOSPLIT,$0-16
951 » MOVQ» sp+0(FP),AX» » // addr of first arg 951 » MOVQ» p+0(FP),AX» » // addr of first arg
952 MOVQ AX, ret+8(FP) 952 MOVQ AX, ret+8(FP)
953 RET 953 RET
954 954
955 // int64 runtime·cputicks(void) 955 // int64 runtime·cputicks(void)
956 TEXT runtime·cputicks(SB),NOSPLIT,$0-0 956 TEXT runtime·cputicks(SB),NOSPLIT,$0-0
957 RDTSC 957 RDTSC
958 SHLQ $32, DX 958 SHLQ $32, DX
959 ADDQ DX, AX 959 ADDQ DX, AX
960 RET 960 RET
961 961
962 TEXT runtime·gocputicks(SB),NOSPLIT,$0-8 962 TEXT runtime·gocputicks(SB),NOSPLIT,$0-8
963 RDTSC 963 RDTSC
964 » MOVL AX, ret+0(FP) 964 » SHLQ $32, DX
965 » MOVL DX, ret+4(FP) 965 » ADDQ DX, AX
966 » MOVQ AX, ret+0(FP)
966 RET 967 RET
967 968
968 TEXT runtime·stackguard(SB),NOSPLIT,$0-16 969 TEXT runtime·stackguard(SB),NOSPLIT,$0-16
969 MOVQ SP, DX 970 MOVQ SP, DX
970 MOVQ DX, sp+0(FP) 971 MOVQ DX, sp+0(FP)
971 get_tls(CX) 972 get_tls(CX)
972 MOVQ g(CX), BX 973 MOVQ g(CX), BX
973 MOVQ g_stackguard(BX), DX 974 MOVQ g_stackguard(BX), DX
974 MOVQ DX, limit+8(FP) 975 MOVQ DX, limit+8(FP)
975 RET 976 RET
(...skipping 1341 matching lines...) Expand 10 before | Expand all | Expand 10 after
2317 MOVQ g(CX), AX 2318 MOVQ g(CX), AX
2318 MOVQ g_m(AX), AX 2319 MOVQ g_m(AX), AX
2319 MOVL m_fastrand(AX), DX 2320 MOVL m_fastrand(AX), DX
2320 ADDL DX, DX 2321 ADDL DX, DX
2321 MOVL DX, BX 2322 MOVL DX, BX
2322 XORL $0x88888eef, DX 2323 XORL $0x88888eef, DX
2323 CMOVLMI BX, DX 2324 CMOVLMI BX, DX
2324 MOVL DX, m_fastrand(AX) 2325 MOVL DX, m_fastrand(AX)
2325 MOVL DX, ret+0(FP) 2326 MOVL DX, ret+0(FP)
2326 RET 2327 RET
LEFTRIGHT

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b