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

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

Issue 9227007: Version 3.8.6 (Closed) Base URL: http://v8.googlecode.com/svn/trunk/
Patch Set: Created 8 years, 11 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-freebsd.cc ('k') | src/platform-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 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 71
72 72
73 double ceiling(double x) { 73 double ceiling(double x) {
74 return ceil(x); 74 return ceil(x);
75 } 75 }
76 76
77 77
78 static Mutex* limit_mutex = NULL; 78 static Mutex* limit_mutex = NULL;
79 79
80 80
81 void OS::Setup() { 81 void OS::SetUp() {
82 // Seed the random number generator. We preserve microsecond resolution. 82 // Seed the random number generator. We preserve microsecond resolution.
83 uint64_t seed = Ticks() ^ (getpid() << 16); 83 uint64_t seed = Ticks() ^ (getpid() << 16);
84 srandom(static_cast<unsigned int>(seed)); 84 srandom(static_cast<unsigned int>(seed));
85 limit_mutex = CreateMutex(); 85 limit_mutex = CreateMutex();
86 86
87 #ifdef __arm__ 87 #ifdef __arm__
88 // When running on ARM hardware check that the EABI used by V8 and 88 // When running on ARM hardware check that the EABI used by V8 and
89 // by the C code is the same. 89 // by the C code is the same.
90 bool hard_float = OS::ArmUsingHardFloat(); 90 bool hard_float = OS::ArmUsingHardFloat();
91 if (hard_float) { 91 if (hard_float) {
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after
505 // for a zero-length string because we know that we at least read the 505 // for a zero-length string because we know that we at least read the
506 // '/' character. 506 // '/' character.
507 lib_name[strlen(lib_name) - 1] = '\0'; 507 lib_name[strlen(lib_name) - 1] = '\0';
508 } else { 508 } else {
509 // No library name found, just record the raw address range. 509 // No library name found, just record the raw address range.
510 snprintf(lib_name, kLibNameLen, 510 snprintf(lib_name, kLibNameLen,
511 "%08" V8PRIxPTR "-%08" V8PRIxPTR, start, end); 511 "%08" V8PRIxPTR "-%08" V8PRIxPTR, start, end);
512 } 512 }
513 LOG(isolate, SharedLibraryEvent(lib_name, start, end)); 513 LOG(isolate, SharedLibraryEvent(lib_name, start, end));
514 } else { 514 } else {
515 // Entry not describing executable data. Skip to end of line to setup 515 // Entry not describing executable data. Skip to end of line to set up
516 // reading the next entry. 516 // reading the next entry.
517 do { 517 do {
518 c = getc(fp); 518 c = getc(fp);
519 } while ((c != EOF) && (c != '\n')); 519 } while ((c != EOF) && (c != '\n'));
520 if (c == EOF) break; 520 if (c == EOF) break;
521 } 521 }
522 } 522 }
523 free(lib_name); 523 free(lib_name);
524 fclose(fp); 524 fclose(fp);
525 } 525 }
(...skipping 682 matching lines...) Expand 10 before | Expand all | Expand 10 after
1208 1208
1209 1209
1210 void Sampler::Stop() { 1210 void Sampler::Stop() {
1211 ASSERT(IsActive()); 1211 ASSERT(IsActive());
1212 SignalSender::RemoveActiveSampler(this); 1212 SignalSender::RemoveActiveSampler(this);
1213 SetActive(false); 1213 SetActive(false);
1214 } 1214 }
1215 1215
1216 1216
1217 } } // namespace v8::internal 1217 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/platform-freebsd.cc ('k') | src/platform-macos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698