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

Delta Between Two Patch Sets: src/pkg/runtime/os_linux_arm.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 | « src/pkg/runtime/os_linux_386.c ('k') | src/pkg/runtime/os_nacl.c » ('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 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 "runtime.h" 5 #include "runtime.h"
6 #include "defs_GOOS_GOARCH.h" 6 #include "defs_GOOS_GOARCH.h"
7 #include "os_GOOS.h" 7 #include "os_GOOS.h"
8 #include "../../cmd/ld/textflag.h" 8 #include "textflag.h"
9 9
10 #define AT_NULL 0 10 #define AT_NULL 0
11 #define AT_PLATFORM 15 // introduced in at least 2.6.11 11 #define AT_PLATFORM 15 // introduced in at least 2.6.11
12 #define AT_HWCAP 16 // introduced in at least 2.6.11 12 #define AT_HWCAP 16 // introduced in at least 2.6.11
13 #define AT_RANDOM 25 // introduced in 2.6.29 13 #define AT_RANDOM 25 // introduced in 2.6.29
14 #define HWCAP_VFP (1 << 6) // introduced in at least 2.6.11 14 #define HWCAP_VFP (1 << 6) // introduced in at least 2.6.11
15 #define HWCAP_VFPv3 (1 << 13) // introduced in 2.6.30 15 #define HWCAP_VFPv3 (1 << 13) // introduced in 2.6.30
16 static uint32 runtime·randomNumber; 16 static uint32 runtime·randomNumber;
17 uint8 runtime·armArch = 6; // we default to ARMv6 17 uint8 runtime·armArch = 6; // we default to ARMv6
18 uint32 runtime·hwcap; // set by setup_auxv 18 uint32 runtime·hwcap; // set by setup_auxv
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 71
72 #pragma textflag NOSPLIT 72 #pragma textflag NOSPLIT
73 int64 73 int64
74 runtime·cputicks(void) 74 runtime·cputicks(void)
75 { 75 {
76 // Currently cputicks() is used in blocking profiler and to seed runtime ·fastrand1(). 76 // Currently cputicks() is used in blocking profiler and to seed runtime ·fastrand1().
77 // runtime·nanotime() is a poor approximation of CPU ticks that is enoug h for the profiler. 77 // runtime·nanotime() is a poor approximation of CPU ticks that is enoug h for the profiler.
78 // runtime·randomNumber provides better seeding of fastrand1. 78 // runtime·randomNumber provides better seeding of fastrand1.
79 return runtime·nanotime() + runtime·randomNumber; 79 return runtime·nanotime() + runtime·randomNumber;
80 } 80 }
LEFTRIGHT

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