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

Delta Between Two Patch Sets: misc/cgo/test/backdoor/runtime.c

Issue 160200044: [dev.power64] code review 160200044: build: merge default into dev.power64 (Closed)
Left Patch Set: Created 10 years, 4 months ago
Right Patch Set: diff -r be0c14f62257b42485019e9e1db23cf40d2e249f https://code.google.com/p/go Created 10 years, 4 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:
Right: Side by side diff | Download
« no previous file with change/comment | « misc/cgo/errors/test.bash ('k') | misc/cgo/test/backdoor/thunk.s » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
(no file at all)
1 // Copyright 2011 The Go Authors. All rights reserved. 1 // Copyright 2011 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 // Expose some runtime functions for testing. 5 // Expose some runtime functions for testing.
6 // Must be in a non-cgo-using package so that 6 // Must be in a non-cgo-using package so that
7 // the go command compiles this file with 6c, not gcc. 7 // the go command compiles this file with 6c, not gcc.
8 8
9 // +build gc 9 // +build gc
10 10
11 typedef char bool; 11 typedef char bool;
12 12
13 bool runtime·lockedOSThread(void);
14
15 static void
16 FLUSH(void*)
17 {
18 }
19
20 void
21 ·LockedOSThread(bool b)
22 {
23 b = runtime·lockedOSThread();
24 FLUSH(&b);
25 }
26
27 // This is what a cgo-compiled stub declaration looks like. 13 // This is what a cgo-compiled stub declaration looks like.
28 void 14 void
29 ·Issue7695(struct{void *y[8*sizeof(void*)];}p) 15 ·Issue7695(struct{void *y[8*sizeof(void*)];}p)
30 { 16 {
31 USED(p); 17 USED(p);
32 } 18 }
LEFTRIGHT

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