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

Side by Side Diff: src/perf-jit.cc

Issue 893533003: Revert "Make GCC happy again." and "Initial switch to Chromium-style CHECK_* and DCHECK_* macros.". (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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 | « src/optimizing-compiler-thread.cc ('k') | src/ppc/full-codegen-ppc.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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 } 50 }
51 51
52 // Open the perf JIT dump file. 52 // Open the perf JIT dump file.
53 int bufferSize = sizeof(kFilenameFormatString) + kFilenameBufferPadding; 53 int bufferSize = sizeof(kFilenameFormatString) + kFilenameBufferPadding;
54 ScopedVector<char> perf_dump_name(bufferSize); 54 ScopedVector<char> perf_dump_name(bufferSize);
55 int size = SNPrintF(perf_dump_name, kFilenameFormatString, 55 int size = SNPrintF(perf_dump_name, kFilenameFormatString,
56 base::OS::GetCurrentProcessId()); 56 base::OS::GetCurrentProcessId());
57 CHECK_NE(size, -1); 57 CHECK_NE(size, -1);
58 perf_output_handle_ = 58 perf_output_handle_ =
59 base::OS::FOpen(perf_dump_name.start(), base::OS::LogFileOpenMode); 59 base::OS::FOpen(perf_dump_name.start(), base::OS::LogFileOpenMode);
60 CHECK_NOT_NULL(perf_output_handle_); 60 CHECK_NE(perf_output_handle_, NULL);
61 setvbuf(perf_output_handle_, NULL, _IOFBF, kLogBufferSize); 61 setvbuf(perf_output_handle_, NULL, _IOFBF, kLogBufferSize);
62 62
63 LogWriteHeader(); 63 LogWriteHeader();
64 } 64 }
65 65
66 66
67 PerfJitLogger::~PerfJitLogger() { 67 PerfJitLogger::~PerfJitLogger() {
68 fclose(perf_output_handle_); 68 fclose(perf_output_handle_);
69 perf_output_handle_ = NULL; 69 perf_output_handle_ = NULL;
70 } 70 }
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
139 header.elf_mach = GetElfMach(); 139 header.elf_mach = GetElfMach();
140 header.pid = base::OS::GetCurrentProcessId(); 140 header.pid = base::OS::GetCurrentProcessId();
141 header.timestamp = 141 header.timestamp =
142 static_cast<uint64_t>(base::OS::TimeCurrentMillis() * 1000.0); 142 static_cast<uint64_t>(base::OS::TimeCurrentMillis() * 1000.0);
143 LogWriteBytes(reinterpret_cast<const char*>(&header), sizeof(header)); 143 LogWriteBytes(reinterpret_cast<const char*>(&header), sizeof(header));
144 } 144 }
145 145
146 #endif // V8_OS_LINUX 146 #endif // V8_OS_LINUX
147 } 147 }
148 } // namespace v8::internal 148 } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/optimizing-compiler-thread.cc ('k') | src/ppc/full-codegen-ppc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698