| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef RUNTIME_VM_OS_H_ | 5 #ifndef RUNTIME_VM_OS_H_ |
| 6 #define RUNTIME_VM_OS_H_ | 6 #define RUNTIME_VM_OS_H_ |
| 7 | 7 |
| 8 #include "vm/globals.h" | 8 #include "vm/globals.h" |
| 9 | 9 |
| 10 // Forward declarations. | 10 // Forward declarations. |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 static intptr_t ActivationFrameAlignment(); | 69 static intptr_t ActivationFrameAlignment(); |
| 70 | 70 |
| 71 // This constant is guaranteed to be greater or equal to the | 71 // This constant is guaranteed to be greater or equal to the |
| 72 // preferred code alignment on all platforms. | 72 // preferred code alignment on all platforms. |
| 73 static const int kMaxPreferredCodeAlignment = 32; | 73 static const int kMaxPreferredCodeAlignment = 32; |
| 74 | 74 |
| 75 // Returns the preferred code alignment or zero if | 75 // Returns the preferred code alignment or zero if |
| 76 // the platform doesn't care. Guaranteed to be a power of two. | 76 // the platform doesn't care. Guaranteed to be a power of two. |
| 77 static intptr_t PreferredCodeAlignment(); | 77 static intptr_t PreferredCodeAlignment(); |
| 78 | 78 |
| 79 // Returns true if StackFrameIterator can be used from an isolate that isn't | |
| 80 // the calling thread's current isolate. | |
| 81 static bool AllowStackFrameIteratorFromAnotherThread(); | |
| 82 | |
| 83 // Returns number of available processor cores. | 79 // Returns number of available processor cores. |
| 84 static int NumberOfAvailableProcessors(); | 80 static int NumberOfAvailableProcessors(); |
| 85 | 81 |
| 86 // Returns the maximium resident set size of this process. | 82 // Returns the maximium resident set size of this process. |
| 87 static uintptr_t MaxRSS(); | 83 static uintptr_t MaxRSS(); |
| 88 | 84 |
| 89 // Sleep the currently executing thread for millis ms. | 85 // Sleep the currently executing thread for millis ms. |
| 90 static void Sleep(int64_t millis); | 86 static void Sleep(int64_t millis); |
| 91 | 87 |
| 92 // Sleep the currently executing thread for micros microseconds. | 88 // Sleep the currently executing thread for micros microseconds. |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 151 static void Shutdown(); | 147 static void Shutdown(); |
| 152 | 148 |
| 153 static void Abort(); | 149 static void Abort(); |
| 154 | 150 |
| 155 static void Exit(int code); | 151 static void Exit(int code); |
| 156 }; | 152 }; |
| 157 | 153 |
| 158 } // namespace dart | 154 } // namespace dart |
| 159 | 155 |
| 160 #endif // RUNTIME_VM_OS_H_ | 156 #endif // RUNTIME_VM_OS_H_ |
| OLD | NEW |