summaryrefslogtreecommitdiff
path: root/Android.mk
diff options
context:
space:
mode:
authorDiego Novillo <dnovillo@google.com>2018-02-22 16:18:29 -0500
committerDiego Novillo <dnovillo@google.com>2018-03-20 20:56:55 -0400
commit735d8a579ecb6c5b5d41c2a81d695b49f7bd3248 (patch)
treedc617f310644893abf70a51a0711eca9e9b0be06 /Android.mk
parentbdf421cf406f82366065e06d38d9e6dff2b7fcab (diff)
SSA rewrite pass.
This pass replaces the load/store elimination passes. It implements the SSA re-writing algorithm proposed in Simple and Efficient Construction of Static Single Assignment Form. Braun M., Buchwald S., Hack S., Leißa R., Mallon C., Zwinkau A. (2013) In: Jhala R., De Bosschere K. (eds) Compiler Construction. CC 2013. Lecture Notes in Computer Science, vol 7791. Springer, Berlin, Heidelberg https://link.springer.com/chapter/10.1007/978-3-642-37051-9_6 In contrast to common eager algorithms based on dominance and dominance frontier information, this algorithm works backwards from load operations. When a target variable is loaded, it queries the variable's reaching definition. If the reaching definition is unknown at the current location, it searches backwards in the CFG, inserting Phi instructions at join points in the CFG along the way until it finds the desired store instruction. The algorithm avoids repeated lookups using memoization. For reducible CFGs, which are a superset of the structured CFGs in SPIRV, this algorithm is proven to produce minimal SSA. That is, it inserts the minimal number of Phi instructions required to ensure the SSA property, but some Phi instructions may be dead (https://en.wikipedia.org/wiki/Static_single_assignment_form).
Diffstat (limited to 'Android.mk')
-rw-r--r--Android.mk1
1 files changed, 1 insertions, 0 deletions
diff --git a/Android.mk b/Android.mk
index 04a84a17..ec2a0f07 100644
--- a/Android.mk
+++ b/Android.mk
@@ -118,6 +118,7 @@ SPVTOOLS_OPT_SRC_FILES := \
source/opt/scalar_replacement_pass.cpp \
source/opt/set_spec_constant_default_value_pass.cpp \
source/opt/simplification_pass.cpp \
+ source/opt/ssa_rewrite_pass.cpp \
source/opt/strength_reduction_pass.cpp \
source/opt/strip_debug_info_pass.cpp \
source/opt/strip_reflect_info_pass.cpp \