Skip to content

  • Projects
  • Groups
  • Snippets
  • Help
  • This project
    • Loading...
  • Sign in / Register
A
angle
  • Project
    • Overview
    • Details
    • Activity
    • Cycle Analytics
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Charts
  • Issues 0
    • Issues 0
    • List
    • Board
    • Labels
    • Milestones
  • Merge Requests 0
    • Merge Requests 0
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
    • Charts
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Charts
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Chen Yisong
  • angle
  • Repository

Switch branch/tag
  • angle
  • src
  • compiler
  • translator
  • RemoveUnreferencedVariables.cpp
Find file
BlameHistoryPermalink
  • Olli Etuaho's avatar
    Remove unreferenced variables from the AST · 3d70ca9c
    Olli Etuaho authored Nov 10, 2017
    Unreferenced local and global variables are now pruned from the AST.
    They will be removed unless their initializer has side effects.
    
    The CollectVariables step needs to be run after the pruning, as the
    pruning may affect which interface variables are statically used.
    
    It's also good to gather built-ins that need to be emulated after the
    pruning, so unnecessary built-in emulation functions are not added to
    the translator output.
    
    This will help handle some dEQP tests for arrays of arrays that have
    extremely large local arrays that are only used in an array length
    query. By constant folding the length and pruning unused variables we
    will avoid adding a large amount of array initialization code to the
    generated shaders.
    
    BUG=angleproject:2166
    TEST=angle_unittests, angle_end2end_tests
    
    Change-Id: Ic918bfe8f16460bcd6101d73a7a674145f5aeecd
    Reviewed-on: https://chromium-review.googlesource.com/766434
    Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
    Reviewed-by: 's avatarCorentin Wallez <cwallez@chromium.org>
    3d70ca9c
RemoveUnreferencedVariables.cpp 7.47 KB
EditWeb IDE
×

Replace RemoveUnreferencedVariables.cpp

Attach a file by drag & drop or click to upload


Cancel
A new branch will be created in your fork and a new merge request will be started.