summaryrefslogtreecommitdiff
path: root/Source/JavaScriptCore/dfg/DFGSSAConversionPhase.h
diff options
context:
space:
mode:
authorLorry Tar Creator <lorry-tar-importer@lorry>2017-06-27 06:07:23 +0000
committerLorry Tar Creator <lorry-tar-importer@lorry>2017-06-27 06:07:23 +0000
commit1bf1084f2b10c3b47fd1a588d85d21ed0eb41d0c (patch)
tree46dcd36c86e7fbc6e5df36deb463b33e9967a6f7 /Source/JavaScriptCore/dfg/DFGSSAConversionPhase.h
parent32761a6cee1d0dee366b885b7b9c777e67885688 (diff)
downloadWebKitGtk-tarball-master.tar.gz
Diffstat (limited to 'Source/JavaScriptCore/dfg/DFGSSAConversionPhase.h')
-rw-r--r--Source/JavaScriptCore/dfg/DFGSSAConversionPhase.h23
1 files changed, 5 insertions, 18 deletions
diff --git a/Source/JavaScriptCore/dfg/DFGSSAConversionPhase.h b/Source/JavaScriptCore/dfg/DFGSSAConversionPhase.h
index 2fa5ff41a..03766896f 100644
--- a/Source/JavaScriptCore/dfg/DFGSSAConversionPhase.h
+++ b/Source/JavaScriptCore/dfg/DFGSSAConversionPhase.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2013 Apple Inc. All rights reserved.
+ * Copyright (C) 2013, 2014 Apple Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -23,10 +23,7 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef DFGSSAConversionPhase_h
-#define DFGSSAConversionPhase_h
-
-#include <wtf/Platform.h>
+#pragma once
#if ENABLE(DFG_JIT)
@@ -36,10 +33,9 @@ class Graph;
// Convert ThreadedCPS form into SSA form. This results in a form that has:
//
-// - Roughly minimal Phi's. We use the Aycock & Horspool fixpoint for
-// converting the CPS maximal Phis into SSA minimal Phis, with the caveat
-// that irreducible control flow may result in some missed opportunities
-// for Phi reduction.
+// - Minimal Phi's. We use the the Cytron et al (TOPLAS'91) algorithm for
+// Phi insertion. Most of the algorithm is implemented in SSACalculator
+// and Dominators.
//
// - No uses of GetLocal/SetLocal except for captured variables and flushes.
// After this, any remaining SetLocal means Flush. PhantomLocals become
@@ -84,12 +80,6 @@ class Graph;
// the caveat that the Phi predecessor block lists would have to be
// updated).
//
-// The easiest way to convert from this SSA form into a different SSA
-// form is to redo SSA conversion for Phi functions. That is, treat each
-// Phi in our IR as a non-SSA variable in the foreign IR (so, as an
-// alloca in LLVM IR, for example); the Upsilons that refer to the Phi
-// become stores and the Phis themselves become loads.
-//
// Fun fact: Upsilon is so named because it comes before Phi in the
// alphabet. It can be written as "Y".
@@ -98,6 +88,3 @@ bool performSSAConversion(Graph&);
} } // namespace JSC::DFG
#endif // ENABLE(DFG_JIT)
-
-#endif // DFGSSAConversionPhase_h
-