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

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

Issue 9251043: code review 9251043: runtime: make arm signal handler call runtime.badsignal (Closed)
Left Patch Set: diff -r 3aed68ee68dc https://code.google.com/p/go/ Created 11 years, 10 months ago
Right Patch Set: diff -r 139919984600 https://code.google.com/p/go/ Created 11 years, 9 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
« no previous file with change/comment | « src/pkg/runtime/sys_linux_arm.s ('k') | no next file » | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
1 // Copyright 2013 The Go Authors. All rights reserved. 1 // Copyright 2013 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 // System calls and other sys.stuff for ARM, NetBSD 5 // System calls and other sys.stuff for ARM, NetBSD
6 // /usr/src/sys/kern/syscalls.master for syscall numbers. 6 // /usr/src/sys/kern/syscalls.master for syscall numbers.
7 // 7 //
8 8
9 #include "zasm_GOOS_GOARCH.h" 9 #include "zasm_GOOS_GOARCH.h"
10 10
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
199 199
200 TEXT runtime·sigtramp(SB),7,$24 200 TEXT runtime·sigtramp(SB),7,$24
201 // this might be called in external code context, 201 // this might be called in external code context,
202 // where g and m are not set. 202 // where g and m are not set.
203 // first save R0, because _cgo_load_gm will clobber it 203 // first save R0, because _cgo_load_gm will clobber it
204 MOVW R0, 4(R13) // signum 204 MOVW R0, 4(R13) // signum
205 MOVW _cgo_load_gm(SB), R0 205 MOVW _cgo_load_gm(SB), R0
206 CMP $0, R0 206 CMP $0, R0
207 BL.NE (R0) 207 BL.NE (R0)
208 208
209 » CMP» » $0, m 209 » CMP $0, m
210 » BNE» » 3(PC) 210 » BNE 3(PC)
211 // signal number is already prepared in 4(R13) 211 // signal number is already prepared in 4(R13)
212 » BL » runtime·badsignal(SB) 212 » BL runtime·badsignal(SB)
213 RET 213 RET
214 214
215 // save g 215 // save g
216 MOVW R10, R4 216 MOVW R10, R4
217 MOVW R10, 20(R13) 217 MOVW R10, 20(R13)
218 218
219 // g = m->signal 219 // g = m->signal
220 MOVW m_gsignal(R9), R10 220 MOVW m_gsignal(R9), R10
221 221
222 // R0 is already saved 222 // R0 is already saved
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
295 // TODO(minux): this is only valid for ARMv6+ 295 // TODO(minux): this is only valid for ARMv6+
296 // bool armcas(int32 *val, int32 old, int32 new) 296 // bool armcas(int32 *val, int32 old, int32 new)
297 // Atomically: 297 // Atomically:
298 // if(*val == old){ 298 // if(*val == old){
299 // *val = new; 299 // *val = new;
300 // return 1; 300 // return 1;
301 // }else 301 // }else
302 // return 0; 302 // return 0;
303 TEXT runtime·cas(SB),7,$0 303 TEXT runtime·cas(SB),7,$0
304 B runtime·armcas(SB) 304 B runtime·armcas(SB)
LEFTRIGHT

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