| OLD | NEW |
| 1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 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 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 221 | 221 |
| 222 // Safe formatting print. Ensures that str is always null-terminated. | 222 // Safe formatting print. Ensures that str is always null-terminated. |
| 223 // Returns the number of chars written, or -1 if output was truncated. | 223 // Returns the number of chars written, or -1 if output was truncated. |
| 224 static int SNPrintF(Vector<char> str, const char* format, ...); | 224 static int SNPrintF(Vector<char> str, const char* format, ...); |
| 225 static int VSNPrintF(Vector<char> str, | 225 static int VSNPrintF(Vector<char> str, |
| 226 const char* format, | 226 const char* format, |
| 227 va_list args); | 227 va_list args); |
| 228 | 228 |
| 229 static char* StrChr(char* str, int c); | 229 static char* StrChr(char* str, int c); |
| 230 static void StrNCpy(Vector<char> dest, const char* src, size_t n); | 230 static void StrNCpy(Vector<char> dest, const char* src, size_t n); |
| 231 static char* StrDup(const char* str); | |
| 232 static char* StrNDup(const char* str, size_t n); | |
| 233 | 231 |
| 234 // Support for profiler. Can do nothing, in which case ticks | 232 // Support for profiler. Can do nothing, in which case ticks |
| 235 // occuring in shared libraries will not be properly accounted | 233 // occuring in shared libraries will not be properly accounted |
| 236 // for. | 234 // for. |
| 237 static void LogSharedLibraryAddresses(); | 235 static void LogSharedLibraryAddresses(); |
| 238 | 236 |
| 239 // Returns the double constant NAN | 237 // Returns the double constant NAN |
| 240 static double nan_value(); | 238 static double nan_value(); |
| 241 | 239 |
| 242 // Returns the activation frame alignment constraint or zero if | 240 // Returns the activation frame alignment constraint or zero if |
| (...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 498 bool active_; | 496 bool active_; |
| 499 PlatformData* data_; // Platform specific data. | 497 PlatformData* data_; // Platform specific data. |
| 500 DISALLOW_IMPLICIT_CONSTRUCTORS(Sampler); | 498 DISALLOW_IMPLICIT_CONSTRUCTORS(Sampler); |
| 501 }; | 499 }; |
| 502 | 500 |
| 503 #endif // ENABLE_LOGGING_AND_PROFILING | 501 #endif // ENABLE_LOGGING_AND_PROFILING |
| 504 | 502 |
| 505 } } // namespace v8::internal | 503 } } // namespace v8::internal |
| 506 | 504 |
| 507 #endif // V8_PLATFORM_H_ | 505 #endif // V8_PLATFORM_H_ |
| OLD | NEW |