comparison python/zcc.py @ 317:e30a77ae359b

Added glue blocks
author Windel Bouwman
date Sun, 22 Dec 2013 15:50:59 +0100
parents 56e6ff84f646
children e84047f29c78
comparison
equal deleted inserted replaced
316:56e6ff84f646 317:e30a77ae359b
11 import outstream 11 import outstream
12 from utils import HexFile 12 from utils import HexFile
13 import target 13 import target
14 from ppci import irutils 14 from ppci import irutils
15 import io 15 import io
16 from ppci.transform import CleanPass 16 from ppci.transform import CleanPass, RemoveAddZero
17 17
18 18
19 logformat='%(asctime)s|%(levelname)s|%(name)s|%(message)s' 19 logformat='%(asctime)s|%(levelname)s|%(name)s|%(message)s'
20 20
21 21
164 Verifier().verify(ircode) 164 Verifier().verify(ircode)
165 165
166 # Optimization passes: 166 # Optimization passes:
167 CleanPass().run(ircode) 167 CleanPass().run(ircode)
168 Verifier().verify(ircode) 168 Verifier().verify(ircode)
169 RemoveAddZero().run(ircode)
170 Verifier().verify(ircode)
171 CleanPass().run(ircode)
172 Verifier().verify(ircode)
169 173
170 # Code generation: 174 # Code generation:
171 d = {'ircode':ircode} 175 d = {'ircode':ircode}
172 logger.info('Starting code generation for {}'.format(ircode), extra=d) 176 logger.info('Starting code generation for {}'.format(ircode), extra=d)
173 cg.generate(ircode, outs) 177 cg.generate(ircode, outs)