Merge pull request #1526 from practicalswift/fix-pep8-violations-ii

[Python] Fix five classes of PEP-8 violations (E101/E111/E128/E302/W191)
This commit is contained in:
Brian Gesiak
2016-03-08 23:55:46 -05:00
38 changed files with 1010 additions and 678 deletions

View File

@@ -3,6 +3,7 @@ import pass_pipeline as ppipe
import passes as p
def diagnostic_passlist():
return ppipe.PassList([
p.CapturePromotion,
@@ -17,6 +18,7 @@ def diagnostic_passlist():
p.SplitNonCondBrCriticalEdges,
])
def simplifycfg_silcombine_passlist():
return ppipe.PassList([
p.SimplifyCFG,
@@ -24,6 +26,7 @@ def simplifycfg_silcombine_passlist():
p.SimplifyCFG,
])
def highlevel_loopopt_passlist():
return ppipe.PassList([
p.LowerAggregateInstrs,
@@ -45,6 +48,7 @@ def highlevel_loopopt_passlist():
p.SwiftArrayOpts,
])
def lowlevel_loopopt_passlist():
return ppipe.PassList([
p.LICM,
@@ -54,6 +58,7 @@ def lowlevel_loopopt_passlist():
p.SimplifyCFG,
])
def inliner_for_optlevel(optlevel):
if optlevel == 'high':
return p.EarlyInliner
@@ -64,6 +69,7 @@ def inliner_for_optlevel(optlevel):
else:
raise RuntimeError('Unknown opt level')
def ssapass_passlist(optlevel):
return ppipe.PassList([
simplifycfg_silcombine_passlist(),
@@ -90,6 +96,7 @@ def ssapass_passlist(optlevel):
p.GlobalARCOpts,
])
def lower_passlist():
return ppipe.PassList([
p.DeadFunctionElimination,
@@ -101,6 +108,7 @@ def lower_passlist():
p.FunctionSignatureOpts,
])
def normal_passpipelines():
result = []