Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(179)

Side by Side Diff: src/platform-openbsd.cc

Issue 9959093: Merged r11194, r11198, r11201, r11214 into trunk branch. (Closed) Base URL: https://v8.googlecode.com/svn/trunk
Patch Set: Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/platform-nullos.cc ('k') | src/platform-posix.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 #include <unistd.h> // sysconf 44 #include <unistd.h> // sysconf
45 #include <execinfo.h> // backtrace, backtrace_symbols 45 #include <execinfo.h> // backtrace, backtrace_symbols
46 #include <strings.h> // index 46 #include <strings.h> // index
47 #include <errno.h> 47 #include <errno.h>
48 #include <stdarg.h> 48 #include <stdarg.h>
49 49
50 #undef MAP_TYPE 50 #undef MAP_TYPE
51 51
52 #include "v8.h" 52 #include "v8.h"
53 53
54 #include "platform-posix.h"
54 #include "platform.h" 55 #include "platform.h"
55 #include "v8threads.h" 56 #include "v8threads.h"
56 #include "vm-state-inl.h" 57 #include "vm-state-inl.h"
57 58
58 59
59 namespace v8 { 60 namespace v8 {
60 namespace internal { 61 namespace internal {
61 62
62 // 0 is never a valid thread id on Linux and OpenBSD since tids and pids share a 63 // 0 is never a valid thread id on Linux and OpenBSD since tids and pids share a
63 // name space and pid 0 is reserved (see man 2 kill). 64 // name space and pid 0 is reserved (see man 2 kill).
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 101
101 102
102 void OS::SetUp() { 103 void OS::SetUp() {
103 // Seed the random number generator. We preserve microsecond resolution. 104 // Seed the random number generator. We preserve microsecond resolution.
104 uint64_t seed = Ticks() ^ (getpid() << 16); 105 uint64_t seed = Ticks() ^ (getpid() << 16);
105 srandom(static_cast<unsigned int>(seed)); 106 srandom(static_cast<unsigned int>(seed));
106 limit_mutex = CreateMutex(); 107 limit_mutex = CreateMutex();
107 } 108 }
108 109
109 110
111 void OS::PostSetUp() {
112 // Math functions depend on CPU features therefore they are initialized after
113 // CPU.
114 MathSetup();
115 }
116
117
110 uint64_t OS::CpuFeaturesImpliedByPlatform() { 118 uint64_t OS::CpuFeaturesImpliedByPlatform() {
111 return 0; 119 return 0;
112 } 120 }
113 121
114 122
115 int OS::ActivationFrameAlignment() { 123 int OS::ActivationFrameAlignment() {
116 // With gcc 4.4 the tree vectorization optimizer can generate code 124 // With gcc 4.4 the tree vectorization optimizer can generate code
117 // that requires 16 byte alignment such as movdqa on x86. 125 // that requires 16 byte alignment such as movdqa on x86.
118 return 16; 126 return 16;
119 } 127 }
(...skipping 839 matching lines...) Expand 10 before | Expand all | Expand 10 after
959 967
960 968
961 void Sampler::Stop() { 969 void Sampler::Stop() {
962 ASSERT(IsActive()); 970 ASSERT(IsActive());
963 SignalSender::RemoveActiveSampler(this); 971 SignalSender::RemoveActiveSampler(this);
964 SetActive(false); 972 SetActive(false);
965 } 973 }
966 974
967 975
968 } } // namespace v8::internal 976 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/platform-nullos.cc ('k') | src/platform-posix.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698