src/tests/compiler_tests/PruneUnusedFunctions_test.cpp


Log

Author Commit Date CI Message
Jamie Madill b980c563 2018-11-27T11:34:27 Reformat all cpp and h files. This applies git cl format --full to all ANGLE sources. Bug: angleproject:2986 Change-Id: Ib504e618c1589332a37e97696cdc3515d739308f Reviewed-on: https://chromium-review.googlesource.com/c/1351367 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Olli Etuaho fe48632f 2017-03-21T09:30:54 Prefer identifying functions by using symbol ids The shader translator code is now structured in a way that ensures that all function definition, function prototype and function call nodes store the integer symbol id for the function. This is guaranteed regardless of whether the function node is added while parsing or as a result of an AST transformation. TIntermAggregate nodes, which include function calls and constructors can now only be created by calling one of the TIntermAggregate::Create*() functions to ensure they have all the necessary properties. This makes it possible to keep track of functions using integer ids instead of their mangled name strings when generating the call graph and when using TLValueTrackingTraverser. This commit includes a few other small cleanups to the CallDAG class as well. BUG=angleproject:1490 TEST=angle_unittests, angle_end2end_tests Change-Id: Idd1013506cbe4c3380e20d90524a9cd09b890259 Reviewed-on: https://chromium-review.googlesource.com/459603 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Jamie Madill 45bcc784 2016-11-07T13:58:48 translator: Scope all classes with "sh". I was seeing an odd problem with our PoolAlloc conflicting with the glslang/Vulkan TIntermNode, so the fix was to move everything to a separate namespace. The bison grammars are also regenerated. No functional changes. BUG=angleproject:1576 Change-Id: I959c7afe4c092f0d458432c07b4dcee4d39513f3 Reviewed-on: https://chromium-review.googlesource.com/408267 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Olli Etuaho 10fcd9be 2016-06-30T12:24:09 Add a helper class for compiler string matching tests The MatchOutputCodeTest class makes it easier to implement tests that do string matching on compiler output. Inheriting test classes set the compiler settings, tests then call compile() with the shader string and can call foundInCode() to check if the output code contains a given string. Various compiler unit tests that already did string matching are refactored to make use of this new helper class. Some tests now use SH_GLES3_SPEC instead of SH_GLES2_SPEC - this should not have a significant impact on test coverage. Some compileTestShader function variants that are now unused can be removed from the code. BUG=angleproject:1430 TEST=angle_unittests Change-Id: I1fd3529d5a1c6ab192f95ace800cf162604e68e7 Reviewed-on: https://chromium-review.googlesource.com/357800 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho 7adfb184 2015-06-09T15:49:41 Refactor common compiler test functionality into helper functions Refactor translating a ESSL shader string into a target language so that compiler initialization and cleanup code can be reused between test classes. BUG=angleproject:817 TEST=angle_unittests Change-Id: Idb229dceb9e17b13ed6ad2a68ab55ed5c968780e Reviewed-on: https://chromium-review.googlesource.com/275814 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez a094a8a9 2015-04-07T11:53:06 Add a compiler option to prune unused function and prototypes Also adds a simple unit test checking the pruning BUG=angleproject:937 BUG=395048 Change-Id: I88440378f66178dcebebcd596f8f80235903f20e Reviewed-on: https://chromium-review.googlesource.com/264568 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 78b3a8b9 2015-04-08T16:04:24 Revert "Add a compiler option to prune unused function and prototypes" Compile error on Mac: http://build.chromium.org/p/chromium.gpu.fyi/builders/GPU%20Mac%20Builder/builds/29051 This reverts commit e423d9ca6e1b340ae06d543419b8a515de5ac3f2. Change-Id: Ie08d7f2bf86089a006f3177480aa7491a9405257 Reviewed-on: https://chromium-review.googlesource.com/264585 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez e423d9ca 2015-04-07T11:53:06 Add a compiler option to prune unused function and prototypes Also adds a simple unit test checking the pruning BUG=angleproject:937 BUG=395048 Change-Id: I49904c34d1a72949cdc579569967d99c736c7237 Reviewed-on: https://chromium-review.googlesource.com/264415 Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>