Bug 19833

Summary: REGRESSION(r34754): Start profile button in profiler now profiles inspector rather than actual page
Product: WebKit Reporter: Oliver Hunt <oliver>
Component: Web Inspector (Deprecated)Assignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: abarth, darin, kmccullough, timothy
Priority: P1 Keywords: InRadar, Regression
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: OS X 10.5   
URL: http://nerget.com/ParticleJS/Particles.html

Description Oliver Hunt 2008-06-30 19:31:00 PDT
I just found that when starting a profile by clicking the button to start profiles in the inspector results in us reporting profile data for the inspector which seems wholly unhelpful.

To reproduce
* Go to http://nerget.com/ParticleJS/Particles.html
* Open the inspector
* Go to the profile pane
* Click the profile button
* Wait a wee while
* Stop the profile
* Admire the profile of the inspector.
Comment 1 Kevin McCullough 2008-07-10 14:04:48 PDT
rdar://problem/6067178
Comment 2 Kevin McCullough 2008-07-10 14:38:04 PDT
It looks like r34753 is the culprit.
Comment 3 Adam Barth 2008-07-10 14:43:12 PDT
I'll take a look at this tonight.
Comment 4 Kevin McCullough 2008-07-10 15:03:33 PDT
Although that revision does not look like it could have possibly caused the issue.  I think the inspector needs to call startUserInitiatedProfiling() instead of console.profile();
Comment 5 Kevin McCullough 2008-07-10 15:49:51 PDT
Scratch that calling InspectorController.inspectedWindow().console should contextually be correct in that it should call the console on the inspected window.
Comment 6 Adam Barth 2008-07-10 16:19:29 PDT
> It looks like r34753 is the culprit.

Hum...  I can't repro the bug at r34753 but I can repro it at r34754.

http://trac.webkit.org/changeset/34754

That change seems more relevant as touches lines of code that actually run in this case.
Comment 7 Kevin McCullough 2008-07-10 17:18:07 PDT
Yeah I re-ran my tests and I also think r18754 is the real culprit.  Sorry to waste your time.  I just need to figure out how this caused the regression.
Comment 8 Kevin McCullough 2008-07-10 17:38:47 PDT
I'm guessing that somewhere under JSInspectedObjectWrapper::wrapone of these wrappers is holding the wrong ExecState.
Comment 9 Kevin McCullough 2008-07-11 15:43:59 PDT
Committed revision 35140.