Remove duplicate merge_opens option in compile.py

The merge_opens option is available in the options received from the
command line and will apply to a Program instance and its tapes.

The merge_opens attribute is preserved on the Tape class as this allows
turning off merging (setting merge_opens to False) for specific tapes.

See #121 for more details.
This commit is contained in:
Sylvain Bellemare
2020-09-29 12:21:06 +01:00
parent 273580a58f
commit 22cfc4183d
2 changed files with 4 additions and 7 deletions

View File

@@ -9,12 +9,11 @@ import time
import sys
def run(args, options, merge_opens=True,
reallocate=True, debug=False):
def run(args, options, reallocate=True, debug=False):
""" Compile a file and output a Program object.
If merge_opens is set to True, will attempt to merge any parallelisable open
instructions. """
If options.merge_opens is set to True, will attempt to merge any
parallelisable open instructions. """
prog = Program(args, options)
instructions.program = prog

View File

@@ -80,9 +80,7 @@ def main():
print('Note that -O/--optimize-hard currently has no effect')
def compilation():
prog = Compiler.run(args, options,
merge_opens=options.merge_opens,
debug=options.debug)
prog = Compiler.run(args, options, debug=options.debug)
prog.write_bytes(options.outfile)
if options.asmoutfile: