Changeset 94470 in webkit


Ignore:
Timestamp:
Sep 2, 2011 5:41:32 PM (13 years ago)
Author:
msaboff@apple.com
Message:

Add JSC:RegExp functional tests
https://bugs.webkit.org/show_bug.cgi?id=67339

Source/JavaScriptCore:

Added new test driver program (testRegExp) and corresponding data file
along with build scripts changes.

Reviewed by Gavin Barraclough.

(Options::Options):
(StopWatch::start):
(StopWatch::stop):
(StopWatch::getElapsedMS):
(RegExpTest::RegExpTest):
(GlobalObject::create):
(GlobalObject::className):
(GlobalObject::GlobalObject):
(main):
(cleanupGlobalData):
(testOneRegExp):
(scanString):
(parseRegExpLine):
(parseTestLine):
(runFromFiles):
(printUsageStatement):
(parseArguments):
(realMain):

  • tests/regexp: Added.
  • tests/regexp/RegExpTest.data: Added.

Tools:

New perl script to build JavaScriptCore and run the RegExp tests.

Reviewed by Gavin Barraclough.

  • Scripts/run-regexp-tests: Added.
Location:
trunk
Files:
4 added
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/ChangeLog

    r94468 r94470  
     12011-09-02  Michael Saboff  <msaboff@apple.com>
     2
     3        Add JSC:RegExp functional tests
     4        https://bugs.webkit.org/show_bug.cgi?id=67339
     5
     6        Added new test driver program (testRegExp) and corresponding data file
     7        along with build scripts changes.
     8
     9        Reviewed by Gavin Barraclough.
     10
     11        * JavaScriptCore.exp:
     12        * JavaScriptCore.xcodeproj/project.pbxproj:
     13        * testRegExp.cpp: Added.
     14        (Options::Options):
     15        (StopWatch::start):
     16        (StopWatch::stop):
     17        (StopWatch::getElapsedMS):
     18        (RegExpTest::RegExpTest):
     19        (GlobalObject::create):
     20        (GlobalObject::className):
     21        (GlobalObject::GlobalObject):
     22        (main):
     23        (cleanupGlobalData):
     24        (testOneRegExp):
     25        (scanString):
     26        (parseRegExpLine):
     27        (parseTestLine):
     28        (runFromFiles):
     29        (printUsageStatement):
     30        (parseArguments):
     31        (realMain):
     32        * tests/regexp: Added.
     33        * tests/regexp/RegExpTest.data: Added.
     34
    1352011-09-02  Michael Saboff  <msaboff@apple.com>
    236
  • trunk/Source/JavaScriptCore/JavaScriptCore.exp

    r94452 r94470  
    269269__ZN3JSC6JSLock9lockCountEv
    270270__ZN3JSC6JSLockC1EPNS_9ExecStateE
     271__ZN3JSC6RegExp5matchERNS_12JSGlobalDataERKNS_7UStringEiPN3WTF6VectorIiLm32EEE
    271272__ZN3JSC6RegExp6createERNS_12JSGlobalDataERKNS_7UStringENS_11RegExpFlagsE
    272273__ZN3JSC6RegExpD1Ev
  • trunk/Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj

    r94461 r94470  
    2828                                932F5BE90822A1C700736975 /* PBXTargetDependency */,
    2929                                14BD59C70A3E8FA400BAF59C /* PBXTargetDependency */,
     30                                651123091404768B002B101D /* PBXTargetDependency */,
    3031                        );
    3132                        name = All;
     
    228229                5DE6E5B30E1728EC00180407 /* create_hash_table in Headers */ = {isa = PBXBuildFile; fileRef = F692A8540255597D01FF60F7 /* create_hash_table */; settings = {ATTRIBUTES = (); }; };
    229230                6507D29E0E871E5E00D7D896 /* JSTypeInfo.h in Headers */ = {isa = PBXBuildFile; fileRef = 6507D2970E871E4A00D7D896 /* JSTypeInfo.h */; settings = {ATTRIBUTES = (Private, ); }; };
     231                651122FD14046A4C002B101D /* JavaScriptCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 932F5BD90822A1C700736975 /* JavaScriptCore.framework */; };
     232                651122FE14046A4C002B101D /* libedit.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 5D5D8AD00E0D0EBE00F9C692 /* libedit.dylib */; };
     233                6511230714046B0A002B101D /* testRegExp.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 651122E5140469BA002B101D /* testRegExp.cpp */; };
    230234                651DCA04136A6FEF00F74194 /* PassTraits.h in Headers */ = {isa = PBXBuildFile; fileRef = 651DCA02136A6FAB00F74194 /* PassTraits.h */; settings = {ATTRIBUTES = (Private, ); }; };
    231235                655EB29B10CE2581001A990E /* NodesCodegen.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 655EB29A10CE2581001A990E /* NodesCodegen.cpp */; };
     
    677681                        remoteInfo = testapi;
    678682                };
     683                651122F914046A4C002B101D /* PBXContainerItemProxy */ = {
     684                        isa = PBXContainerItemProxy;
     685                        containerPortal = 0867D690FE84028FC02AAC07 /* Project object */;
     686                        proxyType = 1;
     687                        remoteGlobalIDString = 932F5B3E0822A1C700736975;
     688                        remoteInfo = JavaScriptCore;
     689                };
     690                651123081404768B002B101D /* PBXContainerItemProxy */ = {
     691                        isa = PBXContainerItemProxy;
     692                        containerPortal = 0867D690FE84028FC02AAC07 /* Project object */;
     693                        proxyType = 1;
     694                        remoteGlobalIDString = 651122F714046A4C002B101D;
     695                        remoteInfo = testRegExp;
     696                };
    679697                65FB3F7D09D11EF300F49DEB /* PBXContainerItemProxy */ = {
    680698                        isa = PBXContainerItemProxy;
     
    905923                5DE3D0F40DD8DDFB00468714 /* WebKitAvailability.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebKitAvailability.h; sourceTree = "<group>"; };
    906924                6507D2970E871E4A00D7D896 /* JSTypeInfo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSTypeInfo.h; sourceTree = "<group>"; };
     925                651122E5140469BA002B101D /* testRegExp.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = testRegExp.cpp; sourceTree = "<group>"; };
     926                651122EE14046A19002B101D /* main.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = main.cpp; sourceTree = "<group>"; };
     927                651122F014046A19002B101D /* regexp_test.1 */ = {isa = PBXFileReference; lastKnownFileType = text.man; path = regexp_test.1; sourceTree = "<group>"; };
     928                6511230514046A4C002B101D /* testRegExp */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = testRegExp; sourceTree = BUILT_PRODUCTS_DIR; };
    907929                651DCA02136A6FAB00F74194 /* PassTraits.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PassTraits.h; sourceTree = "<group>"; };
    908930                651F6412039D5B5F0078395C /* dtoa.cpp */ = {isa = PBXFileReference; fileEncoding = 30; indentWidth = 4; lastKnownFileType = sourcecode.cpp.cpp; path = dtoa.cpp; sourceTree = "<group>"; tabWidth = 8; };
     
    13981420                        runOnlyForDeploymentPostprocessing = 0;
    13991421                };
     1422                651122FC14046A4C002B101D /* Frameworks */ = {
     1423                        isa = PBXFrameworksBuildPhase;
     1424                        buildActionMask = 2147483647;
     1425                        files = (
     1426                                651122FD14046A4C002B101D /* JavaScriptCore.framework in Frameworks */,
     1427                                651122FE14046A4C002B101D /* libedit.dylib in Frameworks */,
     1428                        );
     1429                        runOnlyForDeploymentPostprocessing = 0;
     1430                };
    14001431                932F5BD20822A1C700736975 /* Frameworks */ = {
    14011432                        isa = PBXFrameworksBuildPhase;
     
    14281459                                141211200A48793C00480255 /* minidom */,
    14291460                                14BD59BF0A3E8F9000BAF59C /* testapi */,
     1461                                6511230514046A4C002B101D /* testRegExp */,
    14301462                        );
    14311463                        name = Products;
     
    14451477                        isa = PBXGroup;
    14461478                        children = (
     1479                                651122E5140469BA002B101D /* testRegExp.cpp */,
    14471480                                A718F8211178EB4B002465A7 /* create_regex_tables */,
    14481481                                937B63CC09E766D200A671DD /* DerivedSources.make */,
     
    14721505                                1C90513E0BA9E8830081E9D0 /* Configurations */,
    14731506                                650FDF8D09D0FCA700769E54 /* Derived Sources */,
     1507                                651122ED14046A19002B101D /* regexp_test */,
    14741508                                0867D69AFE84028FC02AAC07 /* Frameworks */,
    14751509                                034768DFFF38A50411DB9C8B /* Products */,
     
    17051739                        tabWidth = 4;
    17061740                        usesTabs = 0;
     1741                };
     1742                651122ED14046A19002B101D /* regexp_test */ = {
     1743                        isa = PBXGroup;
     1744                        children = (
     1745                                651122EE14046A19002B101D /* main.cpp */,
     1746                                651122F014046A19002B101D /* regexp_test.1 */,
     1747                        );
     1748                        path = regexp_test;
     1749                        sourceTree = "<group>";
    17071750                };
    17081751                65162EF108E6A21C007556CD /* wtf */ = {
     
    27342777                        productType = "com.apple.product-type.tool";
    27352778                };
     2779                651122F714046A4C002B101D /* testRegExp */ = {
     2780                        isa = PBXNativeTarget;
     2781                        buildConfigurationList = 6511230014046A4C002B101D /* Build configuration list for PBXNativeTarget "testRegExp" */;
     2782                        buildPhases = (
     2783                                651122FA14046A4C002B101D /* Sources */,
     2784                                651122FC14046A4C002B101D /* Frameworks */,
     2785                                651122FF14046A4C002B101D /* Copy Into Framework */,
     2786                        );
     2787                        buildRules = (
     2788                        );
     2789                        dependencies = (
     2790                                651122F814046A4C002B101D /* PBXTargetDependency */,
     2791                        );
     2792                        name = testRegExp;
     2793                        productInstallPath = /usr/local/bin;
     2794                        productName = jsc;
     2795                        productReference = 6511230514046A4C002B101D /* testRegExp */;
     2796                        productType = "com.apple.product-type.tool";
     2797                };
    27362798                932F5B3E0822A1C700736975 /* JavaScriptCore */ = {
    27372799                        isa = PBXNativeTarget;
     
    28062868                                14BD59BE0A3E8F9000BAF59C /* testapi */,
    28072869                                932F5BDA0822A1C700736975 /* jsc */,
     2870                                651122F714046A4C002B101D /* testRegExp */,
    28082871                        );
    28092872                };
     
    28722935                        shellPath = /bin/sh;
    28732936                        shellScript = "# Skip for Production builds.\nif [[ ${CONFIGURATION:=Debug} == \"Production\" ]]; then\n    exit\nfi\n\n# Copy and update the jsc binary to refer to JavaScriptcore.framework relative to its location.\nditto \"${BUILT_PRODUCTS_DIR}/jsc\" \"${BUILT_PRODUCTS_DIR}/JavaScriptCore.framework/Resources/jsc\"\ninstall_name_tool -change \"${BUILT_PRODUCTS_DIR}/JavaScriptCore.framework/Versions/A/JavaScriptCore\" \"@loader_path/../JavaScriptCore\" \"${BUILT_PRODUCTS_DIR}/JavaScriptCore.framework/Resources/jsc\"\n";
     2937                };
     2938                651122FF14046A4C002B101D /* Copy Into Framework */ = {
     2939                        isa = PBXShellScriptBuildPhase;
     2940                        buildActionMask = 2147483647;
     2941                        files = (
     2942                        );
     2943                        inputPaths = (
     2944                                "$(BUILT_PRODUCTS_DIR)/JavaScriptCore.framework/Resources/jsc",
     2945                        );
     2946                        name = "Copy Into Framework";
     2947                        outputPaths = (
     2948                        );
     2949                        runOnlyForDeploymentPostprocessing = 0;
     2950                        shellPath = /bin/sh;
     2951                        shellScript = "# Skip for Production builds.\nif [[ ${CONFIGURATION:=Debug} == \"Production\" ]]; then\n    exit\nfi\n\n# Copy and update the testRegExp binary to refer to JavaScriptcore.framework relative to its location.\nditto \"${BUILT_PRODUCTS_DIR}/testRegExp\" \"${BUILT_PRODUCTS_DIR}/JavaScriptCore.framework/Resources/testRegExp\"\ninstall_name_tool -change \"${BUILT_PRODUCTS_DIR}/JavaScriptCore.framework/Versions/A/JavaScriptCore\" \"@loader_path/../JavaScriptCore\" \"${BUILT_PRODUCTS_DIR}/JavaScriptCore.framework/Resources/testRegExp\"\n";
    28742952                };
    28752953                65FB3F6509D11E9100F49DEB /* Generate Derived Sources */ = {
     
    29373015                        files = (
    29383016                                1440F6100A4F85670005F061 /* testapi.c in Sources */,
     3017                        );
     3018                        runOnlyForDeploymentPostprocessing = 0;
     3019                };
     3020                651122FA14046A4C002B101D /* Sources */ = {
     3021                        isa = PBXSourcesBuildPhase;
     3022                        buildActionMask = 2147483647;
     3023                        files = (
     3024                                6511230714046B0A002B101D /* testRegExp.cpp in Sources */,
    29393025                        );
    29403026                        runOnlyForDeploymentPostprocessing = 0;
     
    31863272                        targetProxy = 14BD59C60A3E8FA400BAF59C /* PBXContainerItemProxy */;
    31873273                };
     3274                651122F814046A4C002B101D /* PBXTargetDependency */ = {
     3275                        isa = PBXTargetDependency;
     3276                        target = 932F5B3E0822A1C700736975 /* JavaScriptCore */;
     3277                        targetProxy = 651122F914046A4C002B101D /* PBXContainerItemProxy */;
     3278                };
     3279                651123091404768B002B101D /* PBXTargetDependency */ = {
     3280                        isa = PBXTargetDependency;
     3281                        target = 651122F714046A4C002B101D /* testRegExp */;
     3282                        targetProxy = 651123081404768B002B101D /* PBXContainerItemProxy */;
     3283                };
    31883284                65FB3F7E09D11EF300F49DEB /* PBXTargetDependency */ = {
    31893285                        isa = PBXTargetDependency;
     
    33423438                        name = Production;
    33433439                };
     3440                6511230114046A4C002B101D /* Debug */ = {
     3441                        isa = XCBuildConfiguration;
     3442                        buildSettings = {
     3443                                PRODUCT_NAME = testRegExp;
     3444                        };
     3445                        name = Debug;
     3446                };
     3447                6511230214046A4C002B101D /* Release */ = {
     3448                        isa = XCBuildConfiguration;
     3449                        buildSettings = {
     3450                                PRODUCT_NAME = testRegExp;
     3451                        };
     3452                        name = Release;
     3453                };
     3454                6511230314046A4C002B101D /* Profiling */ = {
     3455                        isa = XCBuildConfiguration;
     3456                        buildSettings = {
     3457                                PRODUCT_NAME = testRegExp;
     3458                        };
     3459                        name = Profiling;
     3460                };
     3461                6511230414046A4C002B101D /* Production */ = {
     3462                        isa = XCBuildConfiguration;
     3463                        buildSettings = {
     3464                                INSTALL_PATH = "$(JAVASCRIPTCORE_FRAMEWORKS_DIR)/JavaScriptCore.framework/Resources";
     3465                                PRODUCT_NAME = testRegExp;
     3466                        };
     3467                        name = Production;
     3468                };
    33443469                65FB3F7809D11EBD00F49DEB /* Debug */ = {
    33453470                        isa = XCBuildConfiguration;
     
    34843609                        defaultConfigurationName = Production;
    34853610                };
     3611                6511230014046A4C002B101D /* Build configuration list for PBXNativeTarget "testRegExp" */ = {
     3612                        isa = XCConfigurationList;
     3613                        buildConfigurations = (
     3614                                6511230114046A4C002B101D /* Debug */,
     3615                                6511230214046A4C002B101D /* Release */,
     3616                                6511230314046A4C002B101D /* Profiling */,
     3617                                6511230414046A4C002B101D /* Production */,
     3618                        );
     3619                        defaultConfigurationIsVisible = 0;
     3620                        defaultConfigurationName = Production;
     3621                };
    34863622                65FB3F7709D11EBD00F49DEB /* Build configuration list for PBXAggregateTarget "Derived Sources" */ = {
    34873623                        isa = XCConfigurationList;
  • trunk/Tools/ChangeLog

    r94458 r94470  
     12011-09-02  Michael Saboff  <msaboff@apple.com>
     2
     3        Add JSC:RegExp functional tests
     4        https://bugs.webkit.org/show_bug.cgi?id=67339
     5
     6        New perl script to build JavaScriptCore and run the RegExp tests.
     7
     8        Reviewed by Gavin Barraclough.
     9
     10        * Scripts/run-regexp-tests: Added.
     11
     122011-09-02  Michael Saboff  <msaboff@apple.com>
     13
     14        Add JSC:RegExp functional tests
     15        https://bugs.webkit.org/show_bug.cgi?id=67339
     16
     17        New perl script to build JavaScriptCore and run the RegExp tests.
     18
     19        Reviewed by Gavin Barraclough.
     20
     21        * Scripts/run-regexp-tests: Added.
     22
    1232011-09-02  Eric Seidel  <eric@webkit.org>
    224
Note: See TracChangeset for help on using the changeset viewer.