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

Side by Side Diff: runtime/vm/os_linux.cc

Issue 2713803003: Revert "Updated MallocHooks to collect stack traces when memory is allocated." (Closed)
Patch Set: Created 3 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
« no previous file with comments | « runtime/vm/os_fuchsia.cc ('k') | runtime/vm/os_macos.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 (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_LINUX) 6 #if defined(TARGET_OS_LINUX)
7 7
8 #include "vm/os.h" 8 #include "vm/os.h"
9 9
10 #include <errno.h> // NOLINT 10 #include <errno.h> // NOLINT
(...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 280
281 281
282 // TODO(regis, iposva): When this function is no longer called from the 282 // TODO(regis, iposva): When this function is no longer called from the
283 // CodeImmutability test in object_test.cc, it will be called only from the 283 // CodeImmutability test in object_test.cc, it will be called only from the
284 // simulator, which means that only the Intel implementation is needed. 284 // simulator, which means that only the Intel implementation is needed.
285 void OS::DebugBreak() { 285 void OS::DebugBreak() {
286 __builtin_trap(); 286 __builtin_trap();
287 } 287 }
288 288
289 289
290 uintptr_t DART_NOINLINE OS::GetProgramCounter() {
291 return reinterpret_cast<uintptr_t>(
292 __builtin_extract_return_addr(__builtin_return_address(0)));
293 }
294
295
296 char* OS::StrNDup(const char* s, intptr_t n) { 290 char* OS::StrNDup(const char* s, intptr_t n) {
297 return strndup(s, n); 291 return strndup(s, n);
298 } 292 }
299 293
300 294
301 intptr_t OS::StrNLen(const char* s, intptr_t n) { 295 intptr_t OS::StrNLen(const char* s, intptr_t n) {
302 return strnlen(s, n); 296 return strnlen(s, n);
303 } 297 }
304 298
305 299
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
422 } 416 }
423 417
424 418
425 void OS::Exit(int code) { 419 void OS::Exit(int code) {
426 exit(code); 420 exit(code);
427 } 421 }
428 422
429 } // namespace dart 423 } // namespace dart
430 424
431 #endif // defined(TARGET_OS_LINUX) 425 #endif // defined(TARGET_OS_LINUX)
OLDNEW
« no previous file with comments | « runtime/vm/os_fuchsia.cc ('k') | runtime/vm/os_macos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698