Skip to content

Commit

Permalink
Merge pull request #423 from QE-Lab/release-0.10.0
Browse files Browse the repository at this point in the history
Release 0.10.0
  • Loading branch information
jvanstraten authored Jul 15, 2021
2 parents f628155 + a3f7867 commit be0b1dd
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 15 deletions.
23 changes: 23 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,29 @@ This project adheres to [Semantic Versioning](http://semver.org/).
- ...


## [ 0.10.0 ] - [ 2021-07-15 ]
### Added
- scalability options for coping with large multi-core systems, including a progress bar for the mapping process
- initial implementation of the Diamond architecture developed for Fujitsu (lead by Stephan Wong)
- full cQASM 1.2 read and write support, with options for different version levels and various language quirks
- new internal representation that encompasses the entire cQASM 1.2 language, and has many new generalized platform features
- lossless conversion functions between the two IR representations until all passes have been converted to the new representation
- new pass-based decomposition logic that supports arbitrary cQASM 1.2 code for the expansion and doesn't clobber scheduling information
- new pass for converting structured cQASM 1.2 control flow to basic block form
- new list scheduler based on the new IR

### Changed
- all written cQASM files are now in 1.2 format by default
- the cQASM reader no longer has a JSON configuration file for mapping cQASM gates to OpenQL gates; this translation is now part of OpenQL's platform data
- the old scheduler is replaced with a new implementation for most option variations, that outputs slightly different schedules
- statistics report output is also formatted slightly different, though information content is the same
- CC backend:
- scheduling is now done using resource constraints by default

### Fixed
- excessive memory usage and slow platform construction for large multi-core systems


## [ 0.9.0 ] - [ 2021-05-27 ]
### Added
- architecture system: platform and compilation strategy defaults are now built into OpenQL, preventing the need for users to copypaste configuration files from the tests directory
Expand Down
2 changes: 1 addition & 1 deletion include/ql/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@
*
* OPENQL_VERSION_STRING is also decoded by setup.py
*/
#define OPENQL_VERSION_STRING "0.9.0"
#define OPENQL_VERSION_STRING "0.10.0"
12 changes: 1 addition & 11 deletions tests/test_cqasm.py
Original file line number Diff line number Diff line change
@@ -1,24 +1,14 @@
import os
import filecmp
import unittest
from utils import file_compare
from openql import openql as ql

curdir = os.path.dirname(os.path.realpath(__file__))
platf = ql.Platform("starmon", "none")

output_dir = os.path.join(curdir, 'test_output')

def file_compare(fn1, fn2):
isSame = False
with open(fn1, 'r') as f1:
with open(fn2, 'r') as f2:
a = f1.read()
b = f2.read()
f1.close()
f2.close()
isSame = (a==b)
return isSame

class Test_cqasm(unittest.TestCase):

@classmethod
Expand Down
11 changes: 8 additions & 3 deletions tests/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,18 @@

def file_compare(fn1, fn2):
"""
Compare two files and raise an Assertion error if files are different.
Compare two cQASM files and raise an Assertion error if they are different,
but ignoring for the # comment block that the files start with.
The assertion error contains a diff of the files.
"""
with open(fn1) as f, open(fn2) as g:
flines = f.readlines()
glines = g.readlines()
flines = list(f.readlines())
while flines and flines[0].startswith('#'):
flines.pop(0)
glines = list(g.readlines())
while glines and glines[0].startswith('#'):
glines.pop(0)
d = difflib.Differ()
diffs = [x for x in d.compare(flines, glines) if x[0] in ('+', '-')]
if diffs:
Expand Down

0 comments on commit be0b1dd

Please sign in to comment.