Changeset 117227 in webkit


Ignore:
Timestamp:
May 16, 2012 12:36:06 AM (12 years ago)
Author:
commit-queue@webkit.org
Message:

Unreviewed, rolling out r117050.
http://trac.webkit.org/changeset/117050
https://bugs.webkit.org/show_bug.cgi?id=86587

"Some heap profiler tests started timing out" (Requested by
yurys on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-05-16

  • inspector/front-end/HeapSnapshotProxy.js:

(WebInspector.HeapSnapshotFakeWorker):
(WebInspector.HeapSnapshotFakeWorker.prototype.postMessage):
(WebInspector.HeapSnapshotFakeWorker.prototype._postMessageFromWorker):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r117226 r117227  
     12012-05-16  Sheriff Bot  <webkit.review.bot@gmail.com>
     2
     3        Unreviewed, rolling out r117050.
     4        http://trac.webkit.org/changeset/117050
     5        https://bugs.webkit.org/show_bug.cgi?id=86587
     6
     7        "Some heap profiler tests started timing out" (Requested by
     8        yurys on #webkit).
     9
     10        * inspector/front-end/HeapSnapshotProxy.js:
     11        (WebInspector.HeapSnapshotFakeWorker):
     12        (WebInspector.HeapSnapshotFakeWorker.prototype.postMessage):
     13        (WebInspector.HeapSnapshotFakeWorker.prototype._postMessageFromWorker):
     14
    1152012-05-16  Sheriff Bot  <webkit.review.bot@gmail.com>
    216
  • trunk/Source/WebCore/inspector/front-end/HeapSnapshotProxy.js

    r117051 r117227  
    7979/**
    8080 * @constructor
    81  */
    82 WebInspector.AsyncTaskQueue = function()
    83 {
    84     this._queue = [];
    85     this._isTimerSheduled = false;
    86 }
    87 
    88 WebInspector.AsyncTaskQueue.prototype = {
    89     /**
    90      * @param {function()} task
    91      */
    92     addTask: function(task)
    93     {
    94         this._queue.push(task);
    95         this._scheduleTimer();
    96     },
    97 
    98     _onTimeout: function()
    99     {
    100         this._isTimerSheduled = false;
    101         var task = this._queue.shift();
    102         try {
    103             task();
    104         } finally {
    105             this._scheduleTimer();
    106         }
    107     },
    108 
    109     _scheduleTimer: function()
    110     {
    111         if (this._queue.length && !this._isTimerSheduled) {
    112             setTimeout(this._onTimeout.bind(this), 0);
    113             this._isTimerSheduled = true;
    114         }
    115     }
    116 }
    117 
    118 /**
    119  * @constructor
    12081 * @extends {WebInspector.HeapSnapshotWorkerWrapper}
    12182 */
     
    12384{
    12485    this._dispatcher = new WebInspector.HeapSnapshotWorkerDispatcher(window, this._postMessageFromWorker.bind(this));
    125     this._asyncTaskQueue = new WebInspector.AsyncTaskQueue();
    12686}
    12787
     
    13494                this._dispatcher.dispatchMessage({data: message});
    13595        }
    136         this._asyncTaskQueue.addTask(dispatch.bind(this));
     96        setTimeout(dispatch.bind(this), 0);
    13797    },
    13898
     
    148108            this.dispatchEventToListeners("message", message);
    149109        }
    150         this._asyncTaskQueue.addTask(send.bind(this));
     110        setTimeout(send.bind(this), 0);
    151111    }
    152112};
Note: See TracChangeset for help on using the changeset viewer.