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

Side by Side Diff: include/v8.h

Issue 750813003: Use deadline in IdleNotification. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 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 | « no previous file | src/api.cc » ('j') | src/heap/gc-idle-time-handler.cc » ('J')
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 /** \mainpage V8 API Reference Guide 5 /** \mainpage V8 API Reference Guide
6 * 6 *
7 * V8 is Google's open source JavaScript engine. 7 * V8 is Google's open source JavaScript engine.
8 * 8 *
9 * This set of documents provides reference material generated from the 9 * This set of documents provides reference material generated from the
10 * V8 header file, include/v8.h. 10 * V8 header file, include/v8.h.
(...skipping 4969 matching lines...) Expand 10 before | Expand all | Expand 10 after
4980 * Enables the host application to provide a mechanism for recording 4980 * Enables the host application to provide a mechanism for recording
4981 * histograms. The CreateHistogram function returns a 4981 * histograms. The CreateHistogram function returns a
4982 * histogram which will later be passed to the AddHistogramSample 4982 * histogram which will later be passed to the AddHistogramSample
4983 * function. 4983 * function.
4984 */ 4984 */
4985 void SetCreateHistogramFunction(CreateHistogramCallback); 4985 void SetCreateHistogramFunction(CreateHistogramCallback);
4986 void SetAddHistogramSampleFunction(AddHistogramSampleCallback); 4986 void SetAddHistogramSampleFunction(AddHistogramSampleCallback);
4987 4987
4988 /** 4988 /**
4989 * Optional notification that the embedder is idle. 4989 * Optional notification that the embedder is idle.
4990 * V8 uses the notification to reduce memory footprint. 4990 * V8 uses the notification to perform garbage collection.
4991 * This call can be used repeatedly if the embedder remains idle. 4991 * This call can be used repeatedly if the embedder remains idle.
4992 * Returns true if the embedder should stop calling IdleNotification 4992 * Returns true if the embedder should stop calling IdleNotification
4993 * until real work has been done. This indicates that V8 has done 4993 * until real work has been done. This indicates that V8 has done
4994 * as much cleanup as it will be able to do. 4994 * as much cleanup as it will be able to do.
4995 * 4995 *
4996 * The idle_time_in_ms argument specifies the time V8 has to do reduce 4996 * The idle_time_in_ms argument specifies the time V8 has to perform
4997 * the memory footprint. There is no guarantee that the actual work will be 4997 * garbage collection. There is no guarantee that the actual work will be
4998 * done within the time limit. 4998 * done within the time limit.
4999 * The deadline_in_seconds argument specifies the deadline V8 has to finish
5000 * garbage collection work. deadline_in_seconds is compared with
5001 * MonotonicallyIncreasingTime() and should be based on the same timebase as
5002 * that function. There is no guarantee that the actual work will be done
5003 * within the time limit.
4999 */ 5004 */
5000 bool IdleNotification(int idle_time_in_ms); 5005 bool IdleNotification(int idle_time_in_ms);
5006 bool IdleNotificationDeadline(double deadline_in_seconds);
5001 5007
5002 /** 5008 /**
5003 * Optional notification that the system is running low on memory. 5009 * Optional notification that the system is running low on memory.
5004 * V8 uses these notifications to attempt to free memory. 5010 * V8 uses these notifications to attempt to free memory.
5005 */ 5011 */
5006 void LowMemoryNotification(); 5012 void LowMemoryNotification();
5007 5013
5008 /** 5014 /**
5009 * Optional notification that a context has been disposed. V8 uses 5015 * Optional notification that a context has been disposed. V8 uses
5010 * these notifications to guide the GC heuristic. Returns the number 5016 * these notifications to guide the GC heuristic. Returns the number
(...skipping 2366 matching lines...) Expand 10 before | Expand all | Expand 10 after
7377 */ 7383 */
7378 7384
7379 7385
7380 } // namespace v8 7386 } // namespace v8
7381 7387
7382 7388
7383 #undef TYPE_CHECK 7389 #undef TYPE_CHECK
7384 7390
7385 7391
7386 #endif // V8_H_ 7392 #endif // V8_H_
OLDNEW
« no previous file with comments | « no previous file | src/api.cc » ('j') | src/heap/gc-idle-time-handler.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698