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

Side by Side Diff: src/platform.h

Issue 12089107: Determine number of available cores on all platforms. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 10 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 | « no previous file | src/platform-cygwin.cc » ('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 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
232 // Returns an indication of whether a pointer is in a space that 232 // Returns an indication of whether a pointer is in a space that
233 // has been allocated by Allocate(). This method may conservatively 233 // has been allocated by Allocate(). This method may conservatively
234 // always return false, but giving more accurate information may 234 // always return false, but giving more accurate information may
235 // improve the robustness of the stack dump code in the presence of 235 // improve the robustness of the stack dump code in the presence of
236 // heap corruption. 236 // heap corruption.
237 static bool IsOutsideAllocatedSpace(void* pointer); 237 static bool IsOutsideAllocatedSpace(void* pointer);
238 238
239 // Sleep for a number of milliseconds. 239 // Sleep for a number of milliseconds.
240 static void Sleep(const int milliseconds); 240 static void Sleep(const int milliseconds);
241 241
242 static int NumberOfCores();
243
242 // Abort the current process. 244 // Abort the current process.
243 static void Abort(); 245 static void Abort();
244 246
245 // Debug break. 247 // Debug break.
246 static void DebugBreak(); 248 static void DebugBreak();
247 249
248 // Dump C++ current stack trace (only functional on Linux). 250 // Dump C++ current stack trace (only functional on Linux).
249 static void DumpBacktrace(); 251 static void DumpBacktrace();
250 252
251 // Walk the stack. 253 // Walk the stack.
(...skipping 544 matching lines...) Expand 10 before | Expand all | Expand 10 after
796 Atomic32 active_; 798 Atomic32 active_;
797 PlatformData* data_; // Platform specific data. 799 PlatformData* data_; // Platform specific data.
798 int samples_taken_; // Counts stack samples taken. 800 int samples_taken_; // Counts stack samples taken.
799 DISALLOW_IMPLICIT_CONSTRUCTORS(Sampler); 801 DISALLOW_IMPLICIT_CONSTRUCTORS(Sampler);
800 }; 802 };
801 803
802 804
803 } } // namespace v8::internal 805 } } // namespace v8::internal
804 806
805 #endif // V8_PLATFORM_H_ 807 #endif // V8_PLATFORM_H_
OLDNEW
« no previous file with comments | « no previous file | src/platform-cygwin.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698