Ignore:
Timestamp:
Jul 7, 2008, 11:12:09 AM (17 years ago)
Author:
[email protected]
Message:

JavaScriptCore:

2008-07-07 Kevin McCullough <[email protected]>

Reviewed by Darin.

When the profiler is running it gathers information and creates a
Profile. After it finishes the Profile can be sorted and have other
data refinements run over it. Both of these were done in the same class
before. Now I split the gathering operations into a new class called
ProfileGenerator.

  • JavaScriptCore.xcodeproj/project.pbxproj:
  • profiler/Profile.cpp: Removed code related to the gather stage of a Profile's creation. (KJS::Profile::create): (KJS::Profile::Profile):
  • profiler/Profile.h: Ditto. (KJS::Profile::title): (KJS::Profile::callTree): (KJS::Profile::setHead):
  • profiler/ProfileGenerator.cpp: Added. This is the class that will handle the stage of creating a Profile. Once the Profile is finished being created, this class goes away. (KJS::ProfileGenerator::create): (KJS::ProfileGenerator::ProfileGenerator): (KJS::ProfileGenerator::title): (KJS::ProfileGenerator::willExecute): (KJS::ProfileGenerator::didExecute): (KJS::ProfileGenerator::stopProfiling): (KJS::ProfileGenerator::didFinishAllExecution): (KJS::ProfileGenerator::removeProfileStart): (KJS::ProfileGenerator::removeProfileEnd):
  • profiler/ProfileGenerator.h: Added. (KJS::ProfileGenerator::profile): (KJS::ProfileGenerator::originatingGlobalExec): (KJS::ProfileGenerator::pageGroupIdentifier): (KJS::ProfileGenerator::client): (KJS::ProfileGenerator::stoppedProfiling):
  • profiler/Profiler.cpp: Now operates with the ProfileGenerator instead of the Profile. (KJS::Profiler::startProfiling): (KJS::Profiler::stopProfiling): (KJS::Profiler::didFinishAllExecution): It is here that the Profile is handed off to its client and the Profile Generator is no longer needed. (KJS::dispatchFunctionToProfiles): (KJS::Profiler::willExecute): (KJS::Profiler::didExecute):
  • profiler/Profiler.h: Cleaned up the includes and subsequently the forward declarations. Also use the new ProfileGenerator. (KJS::ProfilerClient::~ProfilerClient): (KJS::Profiler::currentProfiles):
  • profiler/TreeProfile.cpp: Use Profile's new interface. (KJS::TreeProfile::create): (KJS::TreeProfile::TreeProfile):
  • profiler/TreeProfile.h:

WebCore:

2008-07-07 Kevin McCullough <[email protected]>

Reviewed by Darin.

Because profiler.h no longer #includes profile.h we need to explicitly
include it in console.cpp.

  • page/Console.cpp:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj

    r35022 r35039  
    9292                95CD41B30E1BF6560085358E /* TreeProfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 95CD41B10E1BF6560085358E /* TreeProfile.cpp */; };
    9393                95CD41B40E1BF6560085358E /* TreeProfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 95CD41B20E1BF6560085358E /* TreeProfile.h */; };
     94                95CD45760E1C4FDD0085358E /* ProfileGenerator.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 95CD45740E1C4FDD0085358E /* ProfileGenerator.cpp */; };
     95                95CD45770E1C4FDD0085358E /* ProfileGenerator.h in Headers */ = {isa = PBXBuildFile; fileRef = 95CD45750E1C4FDD0085358E /* ProfileGenerator.h */; settings = {ATTRIBUTES = (); }; };
    9496                95E3BC050E1AE68200B2D1C1 /* CallIdentifier.h in Headers */ = {isa = PBXBuildFile; fileRef = 95E3BC040E1AE68200B2D1C1 /* CallIdentifier.h */; settings = {ATTRIBUTES = (Private, ); }; };
    9597                A72700900DAC6BBC00E548D7 /* JSNotAnObject.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A72700780DAC605600E548D7 /* JSNotAnObject.cpp */; };
     
    593595                95CD41B10E1BF6560085358E /* TreeProfile.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = TreeProfile.cpp; path = profiler/TreeProfile.cpp; sourceTree = "<group>"; };
    594596                95CD41B20E1BF6560085358E /* TreeProfile.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TreeProfile.h; path = profiler/TreeProfile.h; sourceTree = "<group>"; };
     597                95CD45740E1C4FDD0085358E /* ProfileGenerator.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ProfileGenerator.cpp; path = profiler/ProfileGenerator.cpp; sourceTree = "<group>"; };
     598                95CD45750E1C4FDD0085358E /* ProfileGenerator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ProfileGenerator.h; path = profiler/ProfileGenerator.h; sourceTree = "<group>"; };
    595599                95E3BC040E1AE68200B2D1C1 /* CallIdentifier.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CallIdentifier.h; path = profiler/CallIdentifier.h; sourceTree = "<group>"; };
    596600                A72700770DAC605600E548D7 /* JSNotAnObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSNotAnObject.h; sourceTree = "<group>"; };
     
    12561260                        isa = PBXGroup;
    12571261                        children = (
     1262                                95E3BC040E1AE68200B2D1C1 /* CallIdentifier.h */,
     1263                                95742F630DD11F5A000917FB /* Profile.cpp */,
     1264                                95742F640DD11F5A000917FB /* Profile.h */,
     1265                                95CD45740E1C4FDD0085358E /* ProfileGenerator.cpp */,
     1266                                95CD45750E1C4FDD0085358E /* ProfileGenerator.h */,
     1267                                95AB83540DA43B4400BC83F3 /* ProfileNode.cpp */,
     1268                                95AB83550DA43B4400BC83F3 /* ProfileNode.h */,
     1269                                95AB832E0DA42CAD00BC83F3 /* Profiler.cpp */,
     1270                                95AB832F0DA42CAD00BC83F3 /* Profiler.h */,
    12581271                                95CD41B10E1BF6560085358E /* TreeProfile.cpp */,
    12591272                                95CD41B20E1BF6560085358E /* TreeProfile.h */,
    1260                                 95E3BC040E1AE68200B2D1C1 /* CallIdentifier.h */,
    1261                                 95AB83540DA43B4400BC83F3 /* ProfileNode.cpp */,
    1262                                 95AB83550DA43B4400BC83F3 /* ProfileNode.h */,
    1263                                 95742F630DD11F5A000917FB /* Profile.cpp */,
    1264                                 95742F640DD11F5A000917FB /* Profile.h */,
    1265                                 95AB832E0DA42CAD00BC83F3 /* Profiler.cpp */,
    1266                                 95AB832F0DA42CAD00BC83F3 /* Profiler.h */,
    12671273                        );
    12681274                        name = profiler;
     
    14761482                                BC7F8FB90E19D1C3008632C0 /* JSNumberCell.h in Headers */,
    14771483                                95CD41B40E1BF6560085358E /* TreeProfile.h in Headers */,
     1484                                95CD45770E1C4FDD0085358E /* ProfileGenerator.h in Headers */,
    14781485                                5D53726F0E1C54880021E549 /* Tracing.h in Headers */,
    14791486                                5D53727E0E1C55EC0021E549 /* TracingDtrace.h in Headers */,
     
    17861793                                E18E3A590DF9278C00D90B34 /* JSGlobalData.cpp in Sources */,
    17871794                                95CD41B30E1BF6560085358E /* TreeProfile.cpp in Sources */,
     1795                                95CD45760E1C4FDD0085358E /* ProfileGenerator.cpp in Sources */,
    17881796                        );
    17891797                        runOnlyForDeploymentPostprocessing = 0;
Note: See TracChangeset for help on using the changeset viewer.