| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 #include "vm/globals.h" | 5 #include "vm/globals.h" |
| 6 #if defined(TARGET_OS_ANDROID) | 6 #if defined(TARGET_OS_ANDROID) |
| 7 | 7 |
| 8 #include "vm/os.h" | 8 #include "vm/os.h" |
| 9 | 9 |
| 10 #include <android/log.h> // NOLINT | 10 #include <android/log.h> // NOLINT |
| (...skipping 295 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 306 ASSERT(retval == 0); | 306 ASSERT(retval == 0); |
| 307 if (stack_limit.rlim_cur > INT_MAX) { | 307 if (stack_limit.rlim_cur > INT_MAX) { |
| 308 retval = INT_MAX; | 308 retval = INT_MAX; |
| 309 } else { | 309 } else { |
| 310 retval = stack_limit.rlim_cur; | 310 retval = stack_limit.rlim_cur; |
| 311 } | 311 } |
| 312 return retval; | 312 return retval; |
| 313 } | 313 } |
| 314 | 314 |
| 315 | 315 |
| 316 bool OS::AllowStackFrameIteratorFromAnotherThread() { |
| 317 return false; |
| 318 } |
| 319 |
| 320 |
| 316 int OS::NumberOfAvailableProcessors() { | 321 int OS::NumberOfAvailableProcessors() { |
| 317 return sysconf(_SC_NPROCESSORS_ONLN); | 322 return sysconf(_SC_NPROCESSORS_ONLN); |
| 318 } | 323 } |
| 319 | 324 |
| 320 | 325 |
| 321 void OS::Sleep(int64_t millis) { | 326 void OS::Sleep(int64_t millis) { |
| 322 int64_t micros = millis * kMicrosecondsPerMillisecond; | 327 int64_t micros = millis * kMicrosecondsPerMillisecond; |
| 323 SleepMicros(micros); | 328 SleepMicros(micros); |
| 324 } | 329 } |
| 325 | 330 |
| (...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 483 } | 488 } |
| 484 | 489 |
| 485 | 490 |
| 486 void OS::Exit(int code) { | 491 void OS::Exit(int code) { |
| 487 exit(code); | 492 exit(code); |
| 488 } | 493 } |
| 489 | 494 |
| 490 } // namespace dart | 495 } // namespace dart |
| 491 | 496 |
| 492 #endif // defined(TARGET_OS_ANDROID) | 497 #endif // defined(TARGET_OS_ANDROID) |
| OLD | NEW |