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

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

Issue 20283002: Don't duplicate OS::ActivationFrameAlignment() for every POSIX platform. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: REBASE Created 7 years, 5 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-cygwin.cc ('k') | src/platform-linux.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 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 #include "vm-state-inl.h" 59 #include "vm-state-inl.h"
60 60
61 61
62 namespace v8 { 62 namespace v8 {
63 namespace internal { 63 namespace internal {
64 64
65 65
66 static Mutex* limit_mutex = NULL; 66 static Mutex* limit_mutex = NULL;
67 67
68 68
69 int OS::ActivationFrameAlignment() {
70 // 16 byte alignment on FreeBSD
71 return 16;
72 }
73
74
75 const char* OS::LocalTimezone(double time) { 69 const char* OS::LocalTimezone(double time) {
76 if (std::isnan(time)) return ""; 70 if (std::isnan(time)) return "";
77 time_t tv = static_cast<time_t>(floor(time/msPerSecond)); 71 time_t tv = static_cast<time_t>(floor(time/msPerSecond));
78 struct tm* t = localtime(&tv); 72 struct tm* t = localtime(&tv);
79 if (NULL == t) return ""; 73 if (NULL == t) return "";
80 return t->tm_zone; 74 return t->tm_zone;
81 } 75 }
82 76
83 77
84 double OS::LocalTimeOffset() { 78 double OS::LocalTimeOffset() {
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
445 limit_mutex = CreateMutex(); 439 limit_mutex = CreateMutex();
446 } 440 }
447 441
448 442
449 void OS::TearDown() { 443 void OS::TearDown() {
450 delete limit_mutex; 444 delete limit_mutex;
451 } 445 }
452 446
453 447
454 } } // namespace v8::internal 448 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/platform-cygwin.cc ('k') | src/platform-linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698