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

Side by Side Diff: src/d8.cc

Issue 988893003: Implement tracing interface for v8 (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Update BUILD.gn to include trace_event_common.h Created 5 years 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/DEPS ('k') | src/libplatform/default-platform.h » ('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 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 5
6 // Defined when linking against shared lib on Windows. 6 // Defined when linking against shared lib on Windows.
7 #if defined(USING_V8_SHARED) && !defined(V8_SHARED) 7 #if defined(USING_V8_SHARED) && !defined(V8_SHARED)
8 #define V8_SHARED 8 #define V8_SHARED
9 #endif 9 #endif
10 10
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 IdleTask* task) override { 128 IdleTask* task) override {
129 UNREACHABLE(); 129 UNREACHABLE();
130 } 130 }
131 131
132 bool IdleTasksEnabled(v8::Isolate* isolate) override { return false; } 132 bool IdleTasksEnabled(v8::Isolate* isolate) override { return false; }
133 133
134 double MonotonicallyIncreasingTime() override { 134 double MonotonicallyIncreasingTime() override {
135 return synthetic_time_in_sec_ += 0.00001; 135 return synthetic_time_in_sec_ += 0.00001;
136 } 136 }
137 137
138 uint64_t AddTraceEvent(char phase, const uint8_t* categoryEnabledFlag,
139 const char* name, uint64_t id, uint64_t bind_id,
140 int numArgs, const char** argNames,
141 const uint8_t* argTypes, const uint64_t* argValues,
142 unsigned int flags) override {
143 return 0;
144 }
145
146 void UpdateTraceEventDuration(const uint8_t* categoryEnabledFlag,
147 const char* name, uint64_t handle) override {}
148
149 const uint8_t* GetCategoryGroupEnabled(const char* name) override {
150 static uint8_t no = 0;
151 return &no;
152 }
153
154 const char* GetCategoryGroupName(
155 const uint8_t* categoryEnabledFlag) override {
156 static const char* dummy = "dummy";
157 return dummy;
158 }
159
138 private: 160 private:
139 double synthetic_time_in_sec_ = 0.0; 161 double synthetic_time_in_sec_ = 0.0;
140 162
141 DISALLOW_COPY_AND_ASSIGN(PredictablePlatform); 163 DISALLOW_COPY_AND_ASSIGN(PredictablePlatform);
142 }; 164 };
143 #endif // !V8_SHARED 165 #endif // !V8_SHARED
144 166
145 167
146 v8::Platform* g_platform = NULL; 168 v8::Platform* g_platform = NULL;
147 169
(...skipping 2381 matching lines...) Expand 10 before | Expand all | Expand 10 after
2529 } 2551 }
2530 2552
2531 } // namespace v8 2553 } // namespace v8
2532 2554
2533 2555
2534 #ifndef GOOGLE3 2556 #ifndef GOOGLE3
2535 int main(int argc, char* argv[]) { 2557 int main(int argc, char* argv[]) {
2536 return v8::Shell::Main(argc, argv); 2558 return v8::Shell::Main(argc, argv);
2537 } 2559 }
2538 #endif 2560 #endif
OLDNEW
« no previous file with comments | « src/DEPS ('k') | src/libplatform/default-platform.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698