Supported architectures

This section lists the backend architectures currently supported by OpenQL.

Architectures are organized into families, variants, and platforms. The architecture family typically refers to a particular control architecture, and may include custom passes and scheduler resources needed to compile for that control architecture. The variant usually refers to the kind of qubit chip being controlled by said control architecture, such as surface-5, surface-7, or surface-17 for CC-light. Finally, architecture variants may be configured with a JSON configuration file to get a complete target description, referred to as the platform.

Note

In older versions of OpenQL, there was no hierarchical definition like this. Instead, there was only a platform, defined by a hard-to-write JSON configuration file, with a backend selection using the "eqasm_compiler" key in the configuration file. The new system is fully backward-compatible: you can still just pass any custom JSON configuration file to the platform constructor, in which case the architecture family will be chosen based on the value in "eqasm_compiler", and the default variant for that family will be used. The purpose of the new system is to make the learning curve for using OpenQL less steep; instead of having to pluck one of the many JSON files from OpenQL’s tests directory and usually needing to modify it manually, you can start off by just using one of the architecture variants as default. Furthermore, each architecture variant may have its own set of defaults and preprocessing rules for the platform configuration file, such that even if you do need to make changes, it should be way easier to do so.

The active architecture is selected in one of the following ways:

  • by specifying the namespace name/variant pair for the desired architecture directly to the ql.Platform constructor (the architecture will then use the default platform configuration for that pair);

  • by specifying a recognized string for the "eqasm_compiler" key in the platform configuration file;

  • if "eqasm_compiler" is instead used for an inline compiler configuration, by setting "eqasm_compiler"."architecture" to the namespace name and variant of the desired architecture;

  • if none of the above apply, the dummy “none” architecture will be selected.

The variant is separated from the namespace name or eqasm_compiler name using a ..

Ultimately, the architecture variant system only serves to inject sane defaults into the platform and compiler configuration structures, and to separate unavoidable architecture-specific logic from architecture-agnostic logic in OpenQL’s codebase. That is, everything boils down to these (internal) platform and compiler configuration structures during platform construction, after which everything is agnostic to the selected architecture. This means that if you want to compile for a new architecture that’s sufficiently similar to an existing one to not need any new passes or resources, you may not even have to change or add to OpenQL’s codebase; you can just use the none.default architecture and build the platform and compiler configuration structures from scratch. This is intentional: the control architectures are still as much in flux as the quantum chips themselves, so being able to quickly piece together a compiler for an architecture we haven’t even thought of yet is important. It’s also very useful for design-space exploration, and doing research into compilation strategies and control architectures that will become relevant only when the quantum chips mature further.

QuTech Central Controller

  • Pass/resource/C++ namespace: arch.cc

  • Acceptable "eqasm_compiler" values: "cc" or "eqasm_backend_cc"

This architecture allows compilation for the QuTech Central Controller, as currently in use in DiCarloLab for the Starmon chip.

Platform configuration file additions

For the CC backend, contrary to the original one for CC-light, the final hardware output is entirely determined by the contents of the configuration file. That is, there is no built-in knowledge of instrument connectivity or codeword organization. This requires a few additional target-specific sections in the platform configuration.

Instrument definitions

The CC-specific "instrument_definitions" section of the configuration file defines immutable properties of instruments, i.e. independent of the actual control setup. The required structure is as follows:

"instrument_definitions": {
    "qutech-qwg": {
        "channels": 4,
        "control_group_sizes": [1, 4],
    },
    "zi-hdawg": {
        "channels": 8,
        // NB: size=1 needs special treatment of waveforms because one
        // AWG unit drives 2 channels
        "control_group_sizes": [1, 2, 4, 8],
    },
    "qutech-vsm": {
        "channels": 32,
        "control_group_sizes": [1],
    },
    "zi-uhfqa": {
        "channels": 9,
        "control_group_sizes": [1],
    }
}

In this:

  • "channels" defines the number of logical channels of the instrument. For most instruments there is one logical channel per physical channel, but the ‘zi-uhfqa’ provides 9 logical channels on one physical channel pair.

  • "control_group_sizes" states possible arrangements of channels operating as a vector.

Control modes

The "control_modes" section defines modes to control instruments. These define which bits are used to control groups of channels and/or get back measurement results. The expected structure is as follows:

"control_modes": {
    "awg8-mw-vsm-hack": {                     // ZI_HDAWG8.py::cfg_codeword_protocol() == 'microwave'. Old hack to skip DIO[8]
        "control_bits": [
            [7,6,5,4,3,2,1,0],                // group 0
            [16,15,14,13,12,11,10,9]          // group 1
        ],
        "trigger_bits": [31]
    },
    "awg8-mw-vsm": {                          // the way the mode above should have been
        "control_bits": [
            [7,6,5,4,3,2,1,0],                // group 0
            [15,14,13,12,11,10,9,8]           // group 1
        ],
        "trigger_bits": [31]
    },
    "awg8-mw-direct-iq": {                    // just I&Q to generate microwave without VSM. HDAWG8: "new_novsm_microwave"
        "control_bits": [
            [6,5,4,3,2,1,0],                  // group 0
            [13,12,11,10,9,8,7],              // group 1
            [22,21,20,19,18,17,16],           // group 2. NB: starts at bit 16 so twin-QWG can also support it
            [29,28,27,26,25,24,23]            // group 4
        ],
        "trigger_bits": [15,31]
    },
    "awg8-flux": {                             // ZI_HDAWG8.py::cfg_codeword_protocol() == 'flux'
        // NB: please note that internally one AWG unit handles 2 channels, which requires special handling of the waveforms
        "control_bits": [
            [2,1,0],                          // group 0
            [5,4,3],
            [8,7,6],
            [11,10,9],
            [18,17,16],                       // group 4. NB: starts at bit 16 so twin-QWG can also support it
            [21,20,19],
            [24,23,22],
            [27,26,25]                        // group 7
        ],
        "trigger_bits": [31]
    },
    "awg8-flux-vector-8": {                    // single code word for 8 flux channels.
        "control_bits": [
            [7,6,5,4,3,2,1,0]
        ],
        "trigger_bits": [31]
    },
    "uhfqa-9ch": {
        "control_bits": [[17],[18],[19],[20],[21],[22],[23],[24],[25]],    // group[0:8]
        "trigger_bits": [16],
        "result_bits": [[1],[2],[3],[4],[5],[6],[7],[8],[9]],              // group[0:8]
        "data_valid_bits": [0]
    },
    "vsm-32ch":{
        "control_bits": [
            [0],[1],[2],[3],[4],[5],[6],[7],                      // group[0:7]
            [8],[9],[10],[11],[12],[13],[14],[15],                // group[8:15]
            [16],[17],[18],[19],[20],[21],[22],[23],              // group[16:23]
            [24],[25],[26],[27],[28],[28],[30],[31]               // group[24:31]
        ],
        "trigger_bits": []                                       // no trigger
    }
}

In this:

  • <key> is a name which can be referred to from key instruments/[]/ref_control_mode.

  • "control_bits" defines G groups of B bits, where:

    • G determines which instrument_definitions/<key>/control_group_sizes is used; and

    • B is an ordered list of bits (MSB to LSB) used for the code word.

  • "trigger_bits" must be a vector of bits, used to trigger the instrument. Must either be size 1 (common trigger) or size G (separate trigger per group), or 2 (common trigger duplicated on 2 bits, to support dual-QWG).

  • "result_bits" is reserved for future use.

  • "data_valid_bits" is reserved for future use.

Signals

The "signals" section provides a signal library that gate definitions can refer to. The expected structure is as follows:

"signals": {
    "single-qubit-mw": [
        {   "type": "mw",
            "operand_idx": 0,
            "value": [
                "{gateName}-{instrumentName}:{instrumentGroup}-gi",  // FIXME: outdated
                "{gateName}-{instrumentName}:{instrumentGroup}-gq",
                "{gateName}-{instrumentName}:{instrumentGroup}-di",
                "{gateName}-{instrumentName}:{instrumentGroup}-dq"
            ]
        },
        {   "type": "switch",
            "operand_idx": 0,
            "value": ["dummy"]                                  // NB: no actual signal is generated
        }
    ],
    "two-qubit-flux": [
        {   "type": "flux",
            "operand_idx": 0,                                   // control
            "value": ["flux-0-{qubit}"]
        },
        {   "type": "flux",
            "operand_idx": 1,                                   // target
            "value": ["flux-1-{qubit}"]
        }
    ]
}

In this, the toplevel object key is a name which can be referred to from key instructions/<>/cc/ref_signal. It defines an array of records with the fields below:

  • "type" defines a signal type. This is used to select an instrument that provides that signal type through key instruments/*/signal_type. The types are entirely user defined, there is no builtin notion of their meaning.

  • "operand_idx" states the operand index of the instruction/gate this signal refers to. Signals must be defined for all operand_idx the gate refers to, so a 3-qubit gate needs to define 0 through 2. Several signals with the same operand_idx can be defined to select several signal types, as shown in “single-qubit-mw” which has both “mw” (provided by an AWG) and “switch” (provided by a VSM).

  • "value" defines the signal name. The CC backend itself makes no assumptions on this other that different instructions have different signal names.

Instruments

The "instruments" section defines instruments used in this setup, their configuration and connectivity. The expected structure is as follows:

"instruments": [
    // readout.
    {
        "name": "ro_0",
        "qubits": [[6], [11], [], [], [], [], [], [], []],
        "signal_type": "measure",
        "ref_instrument_definition": "zi-uhfqa",
        "ref_control_mode": "uhfqa-9ch",
        "controller": {
            "name": "cc",
            "slot": 0,
            "io_module": "CC-CONN-DIO"
        }
    },
    // ...

    // microwave.
    {
        "name": "mw_0",
        "qubits": [                                             // data qubits:
            [2, 8, 14],                                         // [freq L]
            [1, 4, 6, 10, 12, 15]                               // [freq H]
        ],
        "signal_type": "mw",
        "ref_instrument_definition": "zi-hdawg",
        "ref_control_mode": "awg8-mw-vsm-hack",
        "controller": {
            "name": "cc",
            "slot": 3,
            "io_module": "CC-CONN-DIO-DIFF"
        }
    },
    // ...

    // VSM
    {
        "name": "vsm_0",
        "qubits": [
            [2], [8], [14], [],  [], [], [], [],                // [freq L]
            [1], [4], [6], [10], [12], [15], [], [],            // [freq H]
            [0], [5], [9], [13], [], [], [], [],                // [freq Mg]
            [3], [7], [11], [16], [], [], [], []                // [freq My]
        ],
        "signal_type": "switch",
        "ref_instrument_definition": "qutech-vsm",
        "ref_control_mode": "vsm-32ch",
        "controller": {
            "name": "cc",
            "slot": 5,
            "io_module": "cc-conn-vsm"
        }
    },

    // flux
    {
        "name": "flux_0",
        "qubits": [[0], [1], [2], [3], [4], [5], [6], [7]],
        "signal_type": "flux",
        "ref_instrument_definition": "zi-hdawg",
        "ref_control_mode": "awg8-flux",
        "controller": {
            "name": "cc",
            "slot": 6,
            "io_module": "CC-CONN-DIO-DIFF"
        }
    },
    // ...
]

In this:

  • "name" is a friendly name for the instrument.

  • "ref_instrument_definition" selects a record under "instrument_definitions", which must exist or an error is raised.

  • "ref_control_mode" selects a record under "control_modes", which must exist or an error is raised.

  • "signal_type" defines which signal type this instrument instance provides.

  • "qubits" G groups of 1 or more qubits. G must match one of the available group sizes of instrument_definitions/<ref_instrument_definition>/control_group_sizes. If more than 1 qubits are stated per group - e.g. for an AWG used in conjunction with a VSM - they may not produce conflicting signals at any time slot, or an error is raised.

  • "force_cond_gates_on" is optional, reserved for future use.

  • "controller/slot" is the slot number of the CC this instrument is connected to.

  • "controller/name" is reserved for future use.

  • "controller/io_module" is reserved for future use.

Additional instruction data

The CC backend extends the instruction definitions with a "cc" subsection, as shown in the example below:

"ry180": {
    "duration": 20,
    "cc": {
        "ref_signal": "single-qubit-mw",
        "static_codeword_override": [2]
    }
},
"cz_park": {
    "duration": 40,
    "cc": {
        "signal": [
            {   "type": "flux",
                "operand_idx": 0,                                   // control
                "value": ["flux-0-{qubit}"]
            },
            {   "type": "flux",
                "operand_idx": 1,                                   // target
                "value": ["flux-1-{qubit}"]
            },
            {   "type": "flux",
                "operand_idx": 2,                                   // park
                "value": ["park_cz-{qubit}"]
            }
        ],
        "static_codeword_override": [1,2,3]
    }
}
"_wait_uhfqa": {
    "duration": 220,
    "cc": {
        "signal": []
    }
},
"_dist_dsm": {
    "duration": 20,
    "cc": {
        "readout_mode": "feedback",
        "signal": [
            {   "type": "measure",
                "operand_idx": 0,
                "value": []
            }
        ]
    }
},
"_wait_dsm": {
    "duration": 80,
    "cc": {
        "signal": []
    }
}

In this:

  • "ref_signal" points to a signal definition in hardware_settings/eqasm_backend_cc/signals, which must exist or an error is raised.

  • "signal" defines a signal in place, in an identical fashion as hardware_settings/eqasm_backend_cc/signals. May be empty ([]) to disable signal generation.

  • "static_codeword_override" provides a user defined array of codeword (one entry per operand) for this instruction. Currently, this key is compulsory (if signal is non-empty), but in the future, codewords will be assigned automatically to make better use of the limited codeword space.

  • if "readout_mode" with value “feedback” is used, code is generated to read and distribute the instrument result.

Program flow feedback

To support Repeat Until Success type experiments, a special field were added to the gate definition for the CC, as shown in the previous section:

  • the "readout_mode": "feedback" clause in the "_dist_dsm" gate causes the backend to generate code to retrieve the measurement result from the DIO interface and distribute it across the CC.

For convenience, the gate decomposition section can be extended with "measure_fb %0": ["measure %0", "_wait_uhfqa %0", "_dist_dsm %0", "_wait_dsm %0"]

This creates a measure_fb instruction consisting of four parts:

  • triggering a measurement (on the UHFQA);

  • waiting for the internal processing time of the UHFQA;

  • retrieve the measurement result, and distribute it across the CC; and

  • wait for the data distribution to finish.

Caveats:

  • It is not possible to mix measure_fb and measure in a single program. This is a consequence of the way measurements are read from the input DIO interface of the CC: every measurement (both from measure_fb and measure) is pushed onto an input FIFO. This FIFO is only popped by a measure_fb instruction. If the two types are mixed, misalignment occurs between what is written and read. No check is currently performed by the backend.

These limitations will vanish when integration with cQASM 2.0 is completed.

Code generation pass

Most of the magic for all of the above happens in the code generation pass, arch.cc.VQ1Asm. This generates the following file types:

  • .vq1asm: ‘Vectored Q1 assembly’ file for the Central Controller.

  • .vcd: timing file, can be viewed using GTKWave (http://gtkwave.sourceforge.net).

For configuration options, please refer to the documentation of this pass.

Default pass list

For the current/default global option values and the default variant (default), the following backend passes are used by default.

- scheduler: sch.ListSchedule
   |- resource_constraints: yes

- VQ1Asm: arch.cc.gen.VQ1Asm
   |- output_prefix: test_output/%N

Default configuration file

When no platform configuration file is specified, the following default file is used instead.

// This is a generated file, do NOT EDIT
//
// Generated by generate_CC_cfg_modular.py on 2022-02-14 10:58:47.654421.
//
// Parameters were:
// out_filename        = '/Volumes/Data/shared/GIT/PycQED_py3/pycqed/tests/openql/test_output_cc/config_cc_s17_direct_iq_openql_0_10.json'
// mw_pulse_duration   = 20
// flux_pulse_duration = 40
// ro_duration         = 800
// init_duration       = 200000
// in_filename         = 'config/config_cc_s17_direct_iq.json.in'

// File:    config_cc_s17_direct_iq.json.in
// notes:   requires OpenQL >= 0.10.2
//          see https://openql.readthedocs.io/en/latest/gen/reference_architectures.html#qutech-central-controller for documentation of this file
// author:  Wouter Vlothuizen e.a.

{
    "eqasm_compiler" : "cc",

    "hardware_settings": {
        "qubit_number": 17,
        "creg_number": 32,
        "breg_number": 32,
        "cycle_time" : 20,        // in [ns]

        "eqasm_backend_cc": {

            // Instruments used in this setup, their configuration and connectivity.
            "instruments": [
                // readout.
                {
                    "name": "ro_0",
                    "qubits": [[1], [4], [5], [8], [10], [7], [11], [14], [15]],
                    "signal_type": "measure",
                    "ref_instrument_definition": "zi-uhfqa",
                    "ref_control_mode": "uhfqa-9ch",
                    "controller": {
                        "name": "cc",
                        "slot": 2,
                        "io_module": "CC-CONN-DIO"
                    }
                },
                {
                    "name": "ro_1",
                    "qubits": [[0], [2], [3], [6], [9], [12], [], [], []],
                    "signal_type": "measure",
                    "ref_instrument_definition": "zi-uhfqa",
                    "ref_control_mode": "uhfqa-9ch",
                    "controller": {
                        "name": "cc",
                        "slot": 4,
                        "io_module": "CC-CONN-DIO"
                    }
                },
                {
                    "name": "ro_2",
                    "qubits": [[13], [16], [], [], [], [], [], [], []],
                    "signal_type": "measure",
                    "ref_instrument_definition": "zi-uhfqa",
                    "ref_control_mode": "uhfqa-9ch",
                    "controller": {
                        "name": "cc",
                        "slot": 5,
                        "io_module": "CC-CONN-DIO"
                    }
                },

                // microwave.
                {
                    "name": "mw_0",
                    "qubits": [                                             // data qubits:
                        [8],
                        [9],
                        [14],
                        [15]
                    ],
                    "signal_type": "mw",
                    "ref_instrument_definition": "zi-hdawg",
                    "ref_control_mode": "awg8-mw-direct-iq",
                    "controller": {
                        "name": "cc",
                        "slot": 0,
                        "io_module": "CC-CONN-DIO-DIFF"
                    }
                },
                {
                    "name": "mw_1",
                    "qubits": [                                             // ancilla qubits:
                        [11],
                        [10],
                        [12],
                        []
                    ],
                    "signal_type": "mw",
                    "ref_instrument_definition": "zi-hdawg",
                    "ref_control_mode": "awg8-mw-direct-iq",
                    "controller": {
                        "name": "cc",
                        "slot": 1,
                        "io_module": "CC-CONN-DIO-DIFF"
                    }
                },
                {
                    "name": "mw_2",
                    "qubits": [                                             // data qubits:
                        [0],
                        [1],
                        [2],
                        [3]
                    ],
                    "signal_type": "mw",
                    "ref_instrument_definition": "zi-hdawg",
                    "ref_control_mode": "awg8-mw-direct-iq",
                    "controller": {
                        "name": "cc",
                        "slot": 6,
                        "io_module": "CC-CONN-DIO-DIFF"
                    }
                },
                {
                    "name": "mw_3",
                    "qubits": [                                             // ancilla qubits:
                        [4],
                        [5],
                        [6],
                        [7]
                    ],
                    "signal_type": "mw",
                    "ref_instrument_definition": "zi-hdawg",
                    "ref_control_mode": "awg8-mw-direct-iq",
                    "controller": {
                        "name": "cc",
                        "slot": 7,
                        "io_module": "CC-CONN-DIO-DIFF"
                    }
                },
                {
                    "name": "mw_4",
                    "qubits": [                                             // ancilla qubits:
                        [13],
                        [16],
                        [],
                        []
                    ],
                    "signal_type": "mw",
                    "ref_instrument_definition": "zi-hdawg",
                    "ref_control_mode": "awg8-mw-direct-iq",
                    "controller": {
                        "name": "cc",
                        "slot": 8,
                        "io_module": "CC-CONN-DIO-DIFF"
                    }
                },
                // flux
                {
                    "name": "flux_0",
                    "qubits": [[8], [9], [10], [11], [12], [13], [14], [15]],
                    "signal_type": "flux",
                    "ref_instrument_definition": "zi-hdawg",
                    "ref_control_mode": "awg8-flux",
                    "controller": {
                        "name": "cc",
                        "slot": 3,
                        "io_module": "CC-CONN-DIO-DIFF"
                    }
                },
                {
                    "name": "flux_1",
                    "qubits": [[0], [1], [2], [3], [4], [5], [6], [7]],
                    "signal_type": "flux",
                    "ref_instrument_definition": "zi-hdawg",
                    "ref_control_mode": "awg8-flux",
                    "controller": {
                        "name": "cc",
                        "slot": 9,
                        "io_module": "CC-CONN-DIO-DIFF"
                    }
                },
                {
                    "name": "flux_2",
                    "qubits": [[16], [], [], [], [], [], [], []],
                    "signal_type": "flux",
                    "ref_instrument_definition": "zi-hdawg",
                    "ref_control_mode": "awg8-flux",
                    "controller": {
                        "name": "cc",
                        "slot": 10,
                        "io_module": "CC-CONN-DIO-DIFF"
                    }
                }
            ], // instruments

//--- start of include file '/Volumes/Data/shared/GIT/PycQED_py3/pycqed/measurement/openql_experiments/config/common_eqasm_backend_cc.json.in' ---
// File:    common_eqasm_backend_cc.json.in
// notes:   this file specifies commonalities between different setups for key "eqasm_backend_cc"
//          see https://openql.readthedocs.io/en/latest/gen/reference_architectures.html#qutech-central-controller for documentation of this file
// author:  Wouter Vlothuizen e.a.

//{
//  "hardware_settings": {
//      "eqasm_backend_cc": {
            "instrument_definitions": {
                "qutech-qwg": {
                    "channels": 4,
                    "control_group_sizes": [1, 4]
                },
                "zi-hdawg": {
                    "channels": 8,
                    "control_group_sizes": [1, 2, 4, 8] // NB: size=1 needs special treatment of waveforms because one AWG unit drives 2 channels
                },
                "qutech-vsm": {
                    "channels": 32,
                    "control_group_sizes": [1]
                },
                "zi-uhfqa": {
                    "channels": 9,
                    "control_group_sizes": [1]
                }
            },   // instrument_definitions

            "control_modes": {
                "awg8-mw-vsm-hack": {                     // ZI_HDAWG8.py::cfg_codeword_protocol() == 'microwave'. Old hack to skip DIO[8]. Doesn't support QWG
                    "control_bits": [
                        [7,6,5,4,3,2,1,0],                // group 0
                        [16,15,14,13,12,11,10,9]          // group 1
                    ],
                    "trigger_bits": [31]
                },
                "awg8-mw-vsm": {                          // the way the mode above should have been and support for QWG
                    "control_bits": [
                        [7,6,5,4,3,2,1,0],                // group 0
                        [23,22,21,20,19,18,17,16]         // group 1
                    ],
                    "trigger_bits": [31,15]
                },
                "awg8-mw-direct-iq": {                    // just I&Q to generate microwave without VSM. HDAWG8: "new_novsm_microwave"
                    "control_bits": [
                        [6,5,4,3,2,1,0],                  // group 0
                        [13,12,11,10,9,8,7],              // group 1
                        [22,21,20,19,18,17,16],           // group 2. NB: starts at bit 16 so twin-QWG can also support it
                        [29,28,27,26,25,24,23]            // group 4
                    ],
                    "trigger_bits": [31,15]
                },
                "awg8-flux": {                             // ZI_HDAWG8.py::cfg_codeword_protocol() == 'flux'
                    // NB: please note that internally one AWG unit handles 2 channels, which requires special handling of the waveforms
                    "control_bits": [
                        [2,1,0],                          // group 0
                        [5,4,3],
                        [8,7,6],
                        [11,10,9],
                        [18,17,16],                       // group 4. NB: starts at bit 16 so twin-QWG can also support it
                        [21,20,19],
                        [24,23,22],
                        [27,26,25]                        // group 7
                    ],
                    "trigger_bits": [31,15]
                },
                "awg8-flux-vector-8": {                    // single code word for 8 flux channels. FIXME: no official mode yet
                    "control_bits": [
                        [7,6,5,4,3,2,1,0]     // FIXME: how many bits are available
                    ],
                    "trigger_bits": [31]
                },
                "uhfqa-9ch": {
                    "control_bits": [[17],[18],[19],[20],[21],[22],[23],[24],[25]],    // group[0:8]
                    "trigger_bits": [16],
                    "result_bits": [[1],[2],[3],[4],[5],[6],[7],[8],[9]],              // group[0:8]
                    "data_valid_bits": [0]
                },
                "vsm-32ch":{
                    "control_bits": [
                        [0],[1],[2],[3],[4],[5],[6],[7],                      // group[0:7]
                        [8],[9],[10],[11],[12],[13],[14],[15],                // group[8:15]
                        [16],[17],[18],[19],[20],[21],[22],[23],              // group[16:23]
                        [24],[25],[26],[27],[28],[28],[30],[31]               // group[24:31]
                    ],
                    "trigger_bits": []                                       // no trigger
                }
            },   // control_modes

            "signals": {
                "single-qubit-mw": [
                    {   "type": "mw",
                        "operand_idx": 0,
                        "value": [
                            "{gateName}-{instrumentName}:{instrumentGroup}-i",
                            "{gateName}-{instrumentName}:{instrumentGroup}-q"
                        ]
                    }
                ],
                "two-qubit-flux": [
                    {   "type": "flux",
                        "operand_idx": 0,                                   // control
                        "value": ["flux-0-{qubit}"]
                    },
                    {   "type": "flux",
                        "operand_idx": 1,                                   // target
                        "value": ["flux-1-{qubit}"]
                    }
                ],
                "single-qubit-flux": [
                    {   "type": "flux",
                        "operand_idx": 0,
                        "value": ["flux-0-{qubit}"]
                    }
                ]
            }  // signals

//      }  // eqasm_backend_cc
//  },  // hardware_settings
//}
//--- end of include file '/Volumes/Data/shared/GIT/PycQED_py3/pycqed/measurement/openql_experiments/config/common_eqasm_backend_cc.json.in' ---

        }  // eqasm_backend_cc
    },  // hardware_settings

    "gate_decomposition": {
//--- start of include file '/Volumes/Data/shared/GIT/PycQED_py3/pycqed/measurement/openql_experiments/config/common_gate_decomposition.json.in' ---
// File:    common_gate_decomposition.json.in
// notes:   this file specifies commonalities between different setups for key "gate_decomposition"
//          see https://openql.readthedocs.io/en/latest/gen/reference_architectures.html#qutech-central-controller for documentation of this file
// author:  Wouter Vlothuizen e.a.

//{
//  "gate_decomposition": {
        // extracted from PyqQED_py3 'generate_CCL_cfg.py'
        "x %0": ["rx180 %0"],
        "y %0": ["ry180 %0"],
        "roty90 %0": ["ry90 %0"],

        // To support other forms of writing the same gates
        "x180 %0": ["rx180 %0"],
        "y180 %0": ["ry180 %0"],
        "y90 %0": ["ry90 %0"],
        "x90 %0": ["rx90 %0"],
        "my90 %0": ["rym90 %0"],
        "mx90 %0": ["rxm90 %0"],

        // Clifford decomposition per Epstein et al. Phys. Rev. A 89, 062321 (2014)
        // FIXME: only used by single_qubit_oql::randomized_benchmarking()
        "cl_0 %0": ["i %0"],
        "cl_1 %0": ["ry90 %0", "rx90 %0"],
        "cl_2 %0": ["rxm90 %0", "rym90 %0"],
        "cl_3 %0": ["rx180 %0"],
        "cl_4 %0": ["rym90 %0", "rxm90 %0"],
        "cl_5 %0": ["rx90 %0", "rym90 %0"],
        "cl_6 %0": ["ry180 %0"],
        "cl_7 %0": ["rym90 %0", "rx90 %0"],
        "cl_8 %0": ["rx90 %0", "ry90 %0"],
        "cl_9 %0": ["rx180 %0", "ry180 %0"],
        "cl_10 %0": ["ry90 %0", "rxm90 %0"],
        "cl_11 %0": ["rxm90 %0", "ry90 %0"],
        "cl_12 %0": ["ry90 %0", "rx180 %0"],
        "cl_13 %0": ["rxm90 %0"],
        "cl_14 %0": ["rx90 %0", "rym90 %0", "rxm90 %0"],
        "cl_15 %0": ["rym90 %0"],
        "cl_16 %0": ["rx90 %0"],
        "cl_17 %0": ["rx90 %0", "ry90 %0", "rx90 %0"],
        "cl_18 %0": ["rym90 %0", "rx180 %0"],
        "cl_19 %0": ["rx90 %0", "ry180 %0"],
        "cl_20 %0": ["rx90 %0", "rym90 %0", "rx90 %0"],
        "cl_21 %0": ["ry90 %0"],
        "cl_22 %0": ["rxm90 %0", "ry180 %0"],
        "cl_23 %0": ["rx90 %0", "ry90 %0", "rxm90 %0"],

        // feedback
        "measure_fb %0": ["measure %0", "_wait_uhfqa %0", "_dist_dsm %0", "_wait_dsm %0"]

//  },  // gate_decomposition
//}
//--- end of include file '/Volumes/Data/shared/GIT/PycQED_py3/pycqed/measurement/openql_experiments/config/common_gate_decomposition.json.in' ---

        // NB: is is not possible to decompose 'new style' decompositions into these 'legacy'
        // decompositions. Trying so will result in: "the duration of the schedule of the decomposition
        // (18446744073709551615) cannot be longer than the duration of the to-be-decomposed instruction (2)"
        // Since this is not easily solved and the bew system is far better anyway (although slightly more verbose)
        // we won't solve that.

//        ,

        // gate decompositions for S17, using new CZ helpers
//        "cz q8,q10":   ["_cz_sw_ne_park q8,q10,q11"],
//        "cz q10,q8":   ["_cz_sw_ne_park q8,q10,q11"],
//        "cz q8,q11":   ["_cz_se_nw_park q8,q11,q10"],
//        "cz q11,q8":   ["_cz_se_nw_park q8,q11,q10"],
//        "cz q11,q14":  ["_cz_sw_ne_park q11,q14,q15"],
//        "cz q14,q11":  ["_cz_sw_ne_park q11,q14,q15"],
//        "cz q10,q14":  ["_cz_se_nw q10,q14"],
//        "cz q14,q10":  ["_cz_se_nw q10,q14"],
//        "cz q9,q11":   ["_cz_sw_ne_park q9,q11,q12"],
//        "cz q11,q9":   ["_cz_sw_ne_park q9,q11,q12"],
//        "cz q9,q12":   ["_cz_se_nw_park q9,q12,q11"],
//        "cz q12,q9":   ["_cz_se_nw_park q9,q12,q11"],
//        "cz q11,q15":  ["_cz_se_nw_park q11,q15,q14"],
//        "cz q15,q11":  ["_cz_se_nw_park q11,q15,q14"],
//        "cz q12,q15":  ["_cz_sw_ne q12,q15"],
//        "cz q15,q12":  ["_cz_sw_ne q12,q15"]

        // FIXME: "flux_dance_*" ripped from config_cc_s17_direct_iq.json.in:
        // - changed "-" to "_" because of new naming conventions
        // - cleanup/rewrite along lines of new CZ helpers
        // - disabled because target instructions must exist

        // 2. flux-dance with hard-coded CZ gates in parallel.
        // Qubits are ordered in sf_cz target, control.
//        "flux_dance_1 q0": ["barrier q3, q5, q16, q8, q11, q2, q1, q10, q14, q6",
//                            "sf_cz_ne q3", "sf_cz_sw q5", "sf_cz_sw q16", "sf_cz_ne q8", "sf_cz_ne q11", "sf_cz_sw q2",
//                            "sf_park q1", "sf_park q10", "sf_park q14","sf_park q6",
//                            "barrier q3, q5, q16, q8, q11, q2, q1, q10, q14, q6"],
//
//
//        "flux_dance_2 q0": ["barrier q3, q1, q13, q8, q11, q6, q5, q10, q7, q2",
//                            "sf_cz_nw q3", "sf_cz_se q1", "sf_cz_se q13", "sf_cz_nw q8", "sf_cz_nw q11", "sf_cz_se q6",
//                             "sf_park q5", "sf_park q10", "sf_park q7","sf_park q2",
//                             "barrier q3, q1, q13, q8, q11, q6, q5, q10, q7, q2"],
//
//        "flux_dance_3 q0": ["barrier q9, q4, q13, q3, q8, q0, q5, q10, q7, q2",
//                            "sf_cz_se q9", "sf_cz_nw q4", "sf_cz_nw q13", "sf_cz_se q3", "sf_cz_se q8", "sf_cz_nw q0",
//                             "sf_park q5", "sf_park q10", "sf_park q7","sf_park q2",
//                             "barrier q9, q4, q13, q3, q8, q0, q5, q10, q7, q2"],
//
//        "flux_dance_4 q0": ["barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0",
//                            "sf_cz_sw q9", "sf_cz_ne q5", "sf_cz_ne q15", "sf_cz_sw q3", "sf_cz_sw q8", "sf_cz_ne q2",
//                             "sf_park q4", "sf_park q12", "sf_park q7","sf_park q0",
//                             "barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0"],
//
//        "flux_dance_5 q0": ["barrier q12, q1, q13, q7, q10, q4, q8, q3, q5",
//                            "sf_cz_ne q12", "sf_cz_sw q1", "sf_cz_sw q13", "sf_cz_ne q7", "sf_cz_ne q10", "sf_cz_sw q4",
//                             "sf_park q8", "sf_park q3", "sf_park q5",
//                             "barrier q12, q1, q13, q7, q10, q4, q8, q3, q5"],
//
//        "flux_dance_6 q0": ["barrier q15, q12, q7, q2, q16, q10, q8, q3, q6, q14",
//                            "sf_cz_nw q15", "sf_cz_se q12", "sf_cz_se q7", "sf_cz_nw q2", "sf_cz_nw q16", "sf_cz_se q10",
//                             "sf_park q8", "sf_park q3", "sf_park q6", "sf_park q14",
//                             "barrier q15, q12, q7, q2, q16, q10, q8, q3, q6, q14"],
//
//        "flux_dance_7 q0": ["barrier q15, q7, q10, q5, q16, q14, q8, q3, q4, q12",
//                            "sf_cz_se q15", "sf_cz_nw q7", "sf_cz_nw q10", "sf_cz_se q5", "sf_cz_se q16", "sf_cz_nw q14",
//                             "sf_park q8", "sf_park q3", "sf_park q4", "sf_park q12",
//                             "barrier q15, q7, q10, q5, q16, q14, q8, q3, q4, q12"],
//
//        "flux_dance_8 q0": ["barrier q7, q6, q13, q10, q14, q0, q8, q3, q2",
//                            "sf_cz_sw q7", "sf_cz_ne q6", "sf_cz_ne q13", "sf_cz_sw q10", "sf_cz_sw q14", "sf_cz_ne q0",
//                             "sf_park q8", "sf_park q3", "sf_park q2",
//                             "barrier q7, q6, q13, q10, q14, q0, q8, q3, q2"],
//
//
//        // // // Qubits are ordered in sf_cz target, control.
//        "flux_dance_1_refocus q0": ["barrier q3, q5, q16, q8, q11, q2, q1, q10, q14, q6, q0, q7, q15, q13, q12, q4, q9",
//                                    "sf_cz_ne q3", "sf_cz_sw q5","sf_cz_sw q16", "sf_cz_ne q8", "sf_cz_ne q11", "sf_cz_sw q2",
//                                    "sf_park q1", "sf_park q10", "sf_park q14","sf_park q6",
//                                    "cw_01 q0", "cw_01 q15", "cw_01 q13", "cw_01 q4", "cw_01 q9",
//                                    "cw_27 q0", "cw_27 q15", "cw_27 q13", "cw_27 q4", "cw_27 q9",
//                                    "barrier q3, q5, q16, q8, q11, q2, q1, q10, q14, q6, q0, q7, q15, q13, q12, q4, q9"],
//
//        "flux_dance_2_refocus q0": ["barrier q3, q1, q13, q8, q11, q6, q5, q10, q7, q2, q15, q4, q0, q9, q12, q16, q14",
//                                    "sf_cz_nw q3", "sf_cz_se q1","sf_cz_se q13", "sf_cz_nw q8", "sf_cz_nw q11", "sf_cz_se q6",
//                                    "sf_park q5", "sf_park q10", "sf_park q7","  q2",
//                                    "cw_01 q15", "cw_01 q4", "cw_01 q0", "cw_01 q9", "cw_01 q16",
//                                    "cw_27 q15", "cw_27 q4", "cw_27 q0", "cw_27 q9", "cw_27 q16",
//                                    "barrier q3, q1, q13, q8, q11, q6, q5, q10, q7, q2, q15, q4, q0, q9, q12, q16, q14"],
//
//        "flux_dance_3_refocus q0": ["barrier q9, q4, q13, q3, q8, q0, q5, q10, q7, q2, q14, q16, q1, q12, q15, q6, q11",
//                                    "sf_cz_se q9", "sf_cz_nw q4","sf_cz_nw q13", "sf_cz_se q3", "sf_cz_se q8", "sf_cz_nw q0",
//                                    "sf_park q5", "sf_park q10", "sf_park q7","sf_park q2",
//                                    "cw_01 q16", "cw_01 q1", "cw_01 q15", "cw_01 q6", "cw_01 q11",
//                                    "cw_27 q16", "cw_27 q1", "cw_27 q15", "cw_27 q6", "cw_27 q11",
//                                    "barrier q9, q4, q13, q3, q8, q0, q5, q10, q7, q2, q14, q16, q1, q12, q15, q6, q11"],
//
//        "flux_dance_4_refocus q0": ["barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0, q1, q10, q16, q13, q14, q11, q6",
//                                    "sf_cz_sw q9", "sf_cz_ne q5", "sf_cz_ne q15", "sf_cz_sw q3", "sf_cz_sw q8", "sf_cz_ne q2",
//                                    "sf_park q4", "sf_park q12", "sf_park q7","sf_park q0",
//                                    "cw_01 q1", "cw_01 q16", "cw_01 q13", "cw_01 q11", "cw_01 q6",
//                                    "cw_27 q1", "cw_27 q16", "cw_27 q13", "cw_27 q11", "cw_27 q6",
//                                    "barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0, q1, q10, q16, q13, q14, q11, q6"],
//
//        "flux_dance_5_refocus q0": ["barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0, q1, q10, q16, q13, q14, q11, q6",
//                                    "sf_cz_ne q12", "sf_cz_sw q1",
//                                    "sf_cz_sw q13", "sf_cz_ne q7", "sf_cz_ne q10", "sf_cz_sw q4",
//                                     "sf_park q8", "sf_park q3", "sf_park q5",
//                                     "cw_01 q15", "cw_01 q6", "cw_01 q0", "cw_01 q2", "cw_01 q16",
//                                     "cw_27 q15", "cw_27 q6", "cw_27 q0", "cw_27 q2", "cw_27 q16",
//                                     "barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0, q1, q10, q16, q13, q14, q11, q6"],
//
//        "flux_dance_6_refocus q0": ["barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0, q1, q10, q16, q13, q14, q11, q6",
//                                     "sf_cz_nw q15", "sf_cz_se q12",
//                                     "sf_cz_se q7", "sf_cz_nw q2", "sf_cz_nw q16", "sf_cz_se q10",
//                                     "sf_park q8", "sf_park q3", "sf_park q6", "sf_park q14",
//                                     "cw_01 q1", "cw_01 q5", "cw_01 q4", "cw_01 q13", "cw_01 q0",
//                                     "cw_27 q1", "cw_27 q5", "cw_27 q4", "cw_27 q13", "cw_27 q0",
//                                     "barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0, q1, q10, q16, q13, q14, q11, q6"],
//
//        "flux_dance_7_refocus q0": ["barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0, q1, q10, q16, q13, q14, q11, q6",
//                                     "sf_cz_se q15", "sf_cz_nw q7",
//                                     "sf_cz_nw q10", "sf_cz_se q5", "sf_cz_se q16", "sf_cz_nw q14",
//                                     "sf_park q8", "sf_park q3", "sf_park q4", "sf_park q12",
//                                     "cw_01 q1", "cw_01 q13", "cw_01 q6", "cw_01 q2", "cw_01 q0",
//                                     "cw_27 q1", "cw_27 q13", "cw_27 q6", "cw_27 q2", "cw_27 q0",
//                                     "barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0, q1, q10, q16, q13, q14, q11, q6"],
//
//        "flux_dance_8_refocus q0": ["barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0, q1, q10, q16, q13, q14, q11, q6",
//                                     "sf_cz_sw q7", "sf_cz_ne q6",
//                                     "sf_cz_ne q13", "sf_cz_sw q10", "sf_cz_sw q14", "sf_cz_ne q0",
//                                     "sf_park q8", "sf_park q3", "sf_park q2",
//                                     "cw_01 q1", "cw_01 q5", "cw_01 q4", "cw_01 q15", "cw_01 q16",
//                                     "cw_27 q1", "cw_27 q5", "cw_27 q4", "cw_27 q15", "cw_27 q16",
//                                     "barrier q9, q5, q15, q3, q8, q2, q4, q12, q7, q0, q1, q10, q16, q13, q14, q11, q6"]
},  // gate_decomposition

    "instructions": {
//--- start of include file '/Volumes/Data/shared/GIT/PycQED_py3/pycqed/measurement/openql_experiments/config/common_instructions.json.in' ---
// File:    common_instructions.json.in
// notes:   this file specifies commonalities between different setups for key "instructions"
//          see https://openql.readthedocs.io/en/latest/gen/reference_architectures.html#qutech-central-controller for documentation of this file
// author:  Wouter Vlothuizen e.a.

//{
//  "instructions": {
        //**************************************************************************************************************
        // microwave
        //**************************************************************************************************************

        // based on PyqQED_py3 'generate_CCL_cfg.py':
        "prepz": {
            "duration": 200000,
            "cc": {
                "signal": [],    // NB: no signal
                "static_codeword_override": [0]
            }
        },

        // based on PyqQED_py3 'mw_lutman.py' (matches default_mw_lutmap) and 'generate_CCL_cfg.py':
        // normal gates
        "i": {
            "duration": 20,
            "cc": {
                "signal": [],   // no signal
                "static_codeword_override": [0]
            }
        },
        "rx180": {
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "ge", "theta": 180, "phi": 0 }
                    }
                ],
                "static_codeword_override": [1]
            }
        },
        "ry180": {
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "ge", "theta": 180, "phi": 90 }
                    }
                ],
                "static_codeword_override": [2]
            }
        },
        "rx90": {
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "ge", "theta": 90, "phi": 0 }
                    }
                ],
                "static_codeword_override": [3]
            }
        },
        "ry90": {
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "ge", "theta": 90, "phi": 90 }
                    }
                ],
                "static_codeword_override": [4]
            }
        },
        "rxm90": {
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "ge", "theta": -90, "phi": 0 }
                    }
                ],
                "static_codeword_override": [5]
            }
        },
        "rym90": {
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "ge", "theta": -90, "phi": 90 }
                    }
                ],
                "static_codeword_override": [6]
            }
        },
        // FIXME: missing codeword 7

        // spectroscopy gate
        "spec": {
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "spec"}
                    }
                ],
                "static_codeword_override": [8]
            }
        },

        // pi pulse 2nd excited state
        "rx12": {
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "ef", "theta": 180, "phi": 0 }
                    }
                ],
                "static_codeword_override": [9]
            }
        },

        "square": {
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "square"}
                    }
                ],
                "static_codeword_override": [10]
            }
        },

        // normal gate
        "rx45": {
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "ge", "theta": 45, "phi": 0 }
                    }
                ],
                "static_codeword_override": [13]
            }
        },

        // RUS: replaces former gate decompositions
        // FIXME: replace signal/value/type with sensible info
        // FIXME: check codewords, fix conflicts, check prototypes
        "rx2theta": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_27"}
                    }
                ],
                "static_codeword_override": [27]
            }
        },
        "rxm2theta": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_28"}
                    }
                ],
                "static_codeword_override": [28]
            }
        },
        "rx2thetaalpha": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_29"}
                    }
                ],
                "static_codeword_override": [29]
            }
        },
        "rx180beta": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_29"}
                    }
                ],
                "static_codeword_override": [29]
            }
        },
        "rx90alpha": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_26"}
                    }
                ],
                "static_codeword_override": [26]
            }
        },
        "rx180alpha2": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_25"}
                    }
                ],
                "static_codeword_override": [25]
            }
        },

        "ry90beta": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_28"}
                    }
                ],
                "static_codeword_override": [28]
            }
        },
        "rym90alpha": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_29"}
                    }
                ],
                "static_codeword_override": [29]
            }
        },
        "ry90betapi": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_30"}
                    }
                ],
                "static_codeword_override": [30]
            }
        },

        "rphi180": {
            "prototype": ["Z:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_27"}
                    }
                ],
                "static_codeword_override": [27]
            }
        },
        "rphi180beta": {
            "prototype": ["Z:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_28"}
                    }
                ],
                "static_codeword_override": [28]
            }
        },
        "rphi180beta2": {
            "prototype": ["Z:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_30"}
                    }
                ],
                "static_codeword_override": [30]
            }
        },
        "rphi180alpha": {
            "prototype": ["Z:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_31"}
                    }
                ],
                "static_codeword_override": [31]
            }
        },
        "rphim2theta": {
            "prototype": ["Z:qubit"],
            "duration": 20,
            "cc": {
                "signal": [
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_28"}
                    }
                ],
                "static_codeword_override": [28]
            }
        },

        // cw_00 .. cw_31
        // FIXME: remove
        // FIXME: codewords overlap with RUS above, which originally used gate decomposition
        // FIXME: remove? Used by multi_qubit_oql.py and single_qubit_oql.py (echo/rabi_frequency/...)
        // ef_rabi_seq() uses codeword range [9, 26]
        "cw_00": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [0]
            }
        },
        "cw_01": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [1]
            }
        },
        "cw_02": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [2]
            }
        },
        "cw_03": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [3]
            }
        },
        "cw_04": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [4]
            }
        },
        "cw_05": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [5]
            }
        },
        "cw_06": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [6]
            }
        },
        "cw_07": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [7]
            }
        },
        "cw_08": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [8]
            }
        },
        "cw_09": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [9]
            }
        },
        "cw_10": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [10]
            }
        },
        "cw_11": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [11]
            }
        },
        "cw_12": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [12]
            }
        },
        "cw_13": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [13]
            }
        },
        "cw_14": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [14]
            }
        },
        "cw_15": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [15]
            }
        },
        "cw_16": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [16]
            }
        },
        "cw_17": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [17]
            }
        },
        "cw_18": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [18]
            }
        },
        "cw_19": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [19]
            }
        },
        "cw_20": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [20]
            }
        },
        "cw_21": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [21]
            }
        },
        "cw_22": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [22]
            }
        },
        "cw_23": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [23]
            }
        },
        "cw_24": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [24]
            }
        },
        "cw_25": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [25]
            }
        },
        "cw_26": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [26]
            }
        },
        "cw_27": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [27]
            }
        },
        "cw_28": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [28]
            }
        },
        "cw_29": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [29]
            }
        },
        "cw_30": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [30]
            }
        },
        "cw_31": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "cc": {
                "ref_signal": "single-qubit-mw",
                "static_codeword_override": [31]
            }
        },

        //**************************************************************************************************************
        // measure
        //**************************************************************************************************************

        // allow decompositions that prepend measurement with microwave gate
        "_do_measure": {
            "prototype": ["M:qubit"],
            "duration": 800,
            "cc": {
                "signal": [
                    {   "type": "measure",
                        "operand_idx": 0,
                        "value": ["dummy"]          // Future extension: specify output and weight, and generate code word
                    }
                ],
                "static_codeword_override": [0]   // FIXME
            }
        },
        "measure": {
            "prototype": ["M:qubit"],
            "duration": 800,
            "decomposition": {
                "into": "_do_measure op(0)"
            }
        },
        // FIXME: experiment to prefix some measurements with rx12
//        "measure q6": {
//            "prototype": ["M:qubit"],
//            "duration": 820,
//            "decomposition": {
//                "into": [
//                    "rx12 q[6];",
//                    "_do_measure q[6]"
//                ]
//            }
//        },

        //**************************************************************************************************************
        // flux
        //**************************************************************************************************************

        // helpers for CZ gate decomposition, flux_lutman compatible
        //
        // NB: the '*_park' instructions now use prototype "I:qubit" for the park parameter, which makes the scheduler
        // *ignore* that parameter. This allows for parallel scheduling of multiple instructions that perform the same
        // park, but can also arise in conflicts (signal conflict in the CC backend) if a qubit is both used for parking
        // and another fluxing operation.

        "_cz_sw_ne_park": {
            "prototype": ["Z:qubit", "Z:qubit", "I:qubit"],
            "duration": 40,
            "cc": {
                "signal": [
                    {
                        "type": "flux",
                        "operand_idx": 0,
                        "value": { "type": "cz",  "which": "SW" }
                    },
                    {
                        "type": "flux",
                        "operand_idx": 1,
                        "value": { "type": "idle_z",  "which": "NE" }
                    },
                    {
                        "type": "flux",
                        "operand_idx": 2,
                        "value": { "type": "park" }
                    }
                ],
                "static_codeword_override": [3,1,5]
            }
        },
        "_cz_sw_ne": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "cc": {
                "signal": [
                    {
                        "type": "flux",
                        "operand_idx": 0,
                        "value": { "type": "cz",  "which": "SW" }
                    },
                    {
                        "type": "flux",
                        "operand_idx": 1,
                        "value": { "type": "idle_z",  "which": "NE" }
                    }
                ],
                "static_codeword_override": [3,1]
            }
        },
        "_cz_se_nw_park": {
            "prototype": ["Z:qubit", "Z:qubit", "I:qubit"],
            "duration": 40,
            "cc": {
                "signal": [
                    {
                        "type": "flux",
                        "operand_idx": 0,
                        "value": { "type": "cz",  "which": "SE" }
                    },
                    {
                        "type": "flux",
                        "operand_idx": 1,
                        "value": { "type": "idle_z",  "which": "NW" }
                    },
                    {
                        "type": "flux",
                        "operand_idx": 2,
                        "value": { "type": "park" }
                    }
                ],
                "static_codeword_override": [2,4,5]
            }
        },
        "_cz_se_nw": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "cc": {
                "signal": [
                    {
                        "type": "flux",
                        "operand_idx": 0,
                        "value": { "type": "cz",  "which": "SE" }
                    },
                    {
                        "type": "flux",
                        "operand_idx": 1,
                        "value": { "type": "idle_z",  "which": "NW" }
                    }
                ],
                "static_codeword_override": [2,4]
            }
        },
        "_cz_park": {  // NB: fka 'sf_park'
            "prototype": ["Z:qubit"],
            "duration": 40,
            "cc": {
                "signal": [
                    {
                        "type": "flux",
                        "operand_idx": 0,
                        "value": { "type": "park" }
                    }
                ],
                "static_codeword_override": [5]
            }
        },

        // single qubit flux for calibration (compatible flux lutman)
        "sf_square": {
            "duration": 40,
            "cc": {
                "ref_signal": "single-qubit-flux",
                "static_codeword_override": [6]
            }
        },

        // fl_cw_00 .. fl_cw_07
        // FIXME: deprecated
//        "fl_cw_00": {
//            "duration": 40,
//            "cc": {
//                "ref_signal": "two-qubit-flux",
//                "static_codeword_override": [0]
//            }
//        },
//        "fl_cw_01": {
//            "duration": 40,
//            "cc": {
//                "ref_signal": "two-qubit-flux",
//                "static_codeword_override": [1]
//            }
//        },
//        "fl_cw_02": {
//            "duration": 40,
//            "cc": {
//                "ref_signal": "two-qubit-flux",
//                "static_codeword_override": [2]
//            }
//        },
//        "fl_cw_03": {
//            "duration": 40,
//            "cc": {
//                "ref_signal": "two-qubit-flux",
//                "static_codeword_override": [3]
//            }
//        },
//        "fl_cw_04": {
//            "duration": 40,
//            "cc": {
//                "ref_signal": "two-qubit-flux",
//                "static_codeword_override": [4]
//            }
//        },
//        "fl_cw_05": {
//            "duration": 40,
//            "cc": {
//                "ref_signal": "two-qubit-flux",
//                "static_codeword_override": [5]
//            }
//        },
//        "fl_cw_06": {
//            "duration": 40,
//            "cc": {
//                "ref_signal": "two-qubit-flux",
//                "static_codeword_override": [6]
//            }
//        },
//        "fl_cw_07": {
//            "duration": 40,
//            "cc": {
//                "ref_signal": "two-qubit-flux",
//                "static_codeword_override": [7]
//            }
//        },

        // additions for measurements using real time feedback
        "_wait_uhfqa": {
            "prototype": ["U:qubit"],
            "duration": 720,
            "cc": {
                "signal": []
            }
        },
        "_dist_dsm": {
            "prototype": ["U:qubit"],
            "duration": 20,
            "cc": {
                "readout_mode": "feedback",  // trigger special treatment to read and distribute measurement results
                // although we don't output anything, we still need to associate with the correct measurement instrument & group
                "signal": [
                    {   "type": "measure",
                        "operand_idx": 0,
                        "value": []  // don't generate output signal
                    }
                ]
            }
        },
        "_wait_dsm": {
            "prototype": ["U:qubit"],
            "duration": 280,
            "cc": {
                "signal": []
            }
        },

        // additions for pragma/break
        // Require OpenQL < 0.10.1 (use cQASM afterwards)
        "if_1_break": {
            "duration": 60,
            "cc": {
                "signal": [],
                "pragma": {
                    "break": 1
                }
            }
        },
        "if_0_break": {
            "duration": 60,
            "cc": {
                "signal": [],
                "pragma": {
                    "break": 0
                }
            }
        }

//  },  // end of "instructions"
//--- end of include file '/Volumes/Data/shared/GIT/PycQED_py3/pycqed/measurement/openql_experiments/config/common_instructions.json.in' ---

        ,

        //****************************************************************
        // decompositions, new style, require OpenQL >= 0.10.2
        // see https://openql.readthedocs.io/en/latest/gen/reference_configuration.html#instructions-section
        // Should be compatible with API, and cQASM1.2
        //
        // Note that for historical reasons, qubits referred to in the instruction name don't use "[]" (e.g. "q8"),
        // whereas the decomposition/into key requires them (e.g. "q[8]"), because it uses cQasm syntax
        //****************************************************************

        // was:         "measure_fb %0": ["measure %0", "_wait_uhfqa %0", "_dist_dsm %0", "_wait_dsm %0"],
//        "measure_fb": {
//            "prototype": ["U:qubit", "U:bit"],
//            "duration_cycles": 100, // FIXME: note the *_cycles*, should match duration of "into", "duration" is also allowed
//            "cc": { // FIXME: key is required
//                "ref_signal": "single-qubit-mw",
//                "static_codeword_override": [31]
//            },
//            "decomposition": {
//                "into": "measure op(0),op(1); _wait_uhfqa op(0); _dist_dsm op(0); _wait_dsm op(0)"
//            }
//        }
//,
        // CZ decompositions for S17, using new CZ helpers
        // Note the use of 'hierarchical gate decomposition' for every 2nd entry
        "cz q8,q10": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "_cz_sw_ne_park q[8],q[10],q[11]"
            }
        },
        "cz q10,q8": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "cz q[8],q[10]"
            }
        },

        "cz q8,q11": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "_cz_se_nw_park q[8],q[11],q[10]"
            }
        },
        "cz q11,q8": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "cz q[8],q[11]"
            }
        },

        "cz q11,q14": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "_cz_sw_ne_park q[11],q[14],q[15]"
            }
        },
        "cz q14,q11": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "cz q[11],q[14]"
            }
        },

        "cz q10,q14": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "_cz_se_nw q[10],q[14]"
            }
        },
        "cz q14,q10": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "cz q[10],q[14]"
            }
        },

        "cz q9,q11": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "_cz_sw_ne_park q[9],q[11],q[12]"
            }
        },
        "cz q11,q9": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "cz q[9],q[11]"
            }
        },

        "cz q9,q12": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "_cz_se_nw_park q[9],q[12],q[11]"
            }
        },
        "cz q12,q9": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "cz q[9],q[12]"
            }
        },

        "cz q11,q15": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "_cz_se_nw_park q[11],q[15],q[14]"
            }
        },
        "cz q15,q11": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "cz q[11],q[15]"
            }
        },

        "cz q12,q15": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "_cz_sw_ne q[12],q[15]"
            }
        },
        "cz q15,q12": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "decomposition": {
                "into": "cz q[12],q[15]"
            }
        },

        // Hierarchical gate decompositions (test)

        // Flux dance decompositions (test)
        "_fluxdance_conflict": {
            "prototype": [],
            "duration": 40,
            "decomposition": {
                "into": "{ cz q[8],q[10] | cz q[9],q[11] }" // FIXME: in custom instruction '_cz_sw_ne_park <Z:qubit> q[8], <Z:qubit> q[10], <I:qubit> q[11]': Signal conflict on instrument='flux_0', group=3, between '{type:idle_z,which:NE}' and '{type:park}'
            }
        },
        "_fluxdance_1": {
            "prototype": [],
            "duration": 40,
            "decomposition": {
                "into": "{ cz q[10],q[8] | cz q[9],q[12] }"  // NB: both CZs park q[11]
            }
        },

        // Parameterized gate decompositions (test)
        "_test_rotate": {
           "prototype": ["X:qubit", "L:int"],
           "duration": 20,
           "decomposition": {
               "into": [  // FIXME: makes no real sense, and currently fails in backend
                    "if (op(1) < 45) {",
                    "   rx45 op(0)",
                    "} else {",
                    "   rx90 op(0)",
                    "}"
                ]
           }
        },

        // based on TwoQubitClifford::gate_decomposition
        "_test_decompose_2q_clifford": {
           "prototype": ["X:qubit", "X:qubit", "L:int"],
           "duration": 20,  // FIXME: depends
           "decomposition": {
               "into": [  // FIXME: currently fails in backend
                    "if (op(2) < 576) {",
//                    "   _test_single_qubit_like_gates op(0),op(1),op(2)",
                    "   rx90 op(0)",
                    "} else if (op(2) < 576 + 5184) {",
//                    "   _test_CNOT_like_gates op(0),op(1),op(2)",
                    "   rx90 op(0)",
                    "}" // FIXME: etc
                ]
           }
        },
        "_test_single_qubit_like_gates": {
           "prototype": ["X:qubit", "X:qubit", "L:int"],
           "duration": 20,  // FIXME: depends
           "decomposition": {
               "into": [  // FIXME: currently fails in backend
                ]
           }
        },
        "_test_CNOT_like_gates": {
           "prototype": ["X:qubit", "X:qubit", "L:int"],
           "duration": 20,  // FIXME: depends
           "decomposition": {
               "into": [  // FIXME: currently fails in backend
                ]
           }
        },

        // CZ with park and refocus
        "__cz_sw_ne_park_refocus": {
            "prototype": ["Z:qubit", "Z:qubit", "I:qubit"],
            "duration": 40,
            "cc": {
                "signal": [
                    {
                        "type": "flux",
                        "operand_idx": 0,
                        "value": { "type": "cz",  "which": "SW" }
                    },
                    {
                        "type": "flux",
                        "operand_idx": 1,
                        "value": { "type": "idle_z",  "which": "NE" }
                    },
                    {
                        "type": "flux",
                        "operand_idx": 2,
                        "value": { "type": "park" }
                    },
                    {
                        "type": "mw",
                        "operand_idx": 0,
                        "value": { "type": "cw_27"}  // FIXME
                    }
                ],
                "static_codeword_override": [3,1,5,27]
            }
        }

        },  // instructions

//--- start of include file '/Volumes/Data/shared/GIT/PycQED_py3/pycqed/measurement/openql_experiments/config/common_keys.json.in' ---
// File:    common_keys.json.in
// notes:   this file specifies commonalities between different setups for key "hardware_settings"
//          see https://openql.readthedocs.io/en/latest/gen/reference_architectures.html#qutech-central-controller for documentation of this file
// author:  Wouter Vlothuizen e.a.

//{
    // NB: the "topology" is optional since OpenQl 0.9, a warning is issued if it does not exist
    "topology": {
    },

    // NB: the "resources" is optional since OpenQl 0.9, a warning is issued if it does not exist
    "resources": {
    }
//}
//--- end of include file '/Volumes/Data/shared/GIT/PycQED_py3/pycqed/measurement/openql_experiments/config/common_keys.json.in' ---

    }  // hardware_settings
}

CC-light

  • Pass/resource/C++ namespace: arch.cc_light

  • Acceptable "eqasm_compiler" values: "cc_light" or "cc_light_compiler"

This architecture represents what remains of the CC-light backend from past versions of OpenQL. The CC-light is being/has been phased out in our labs, thus code generation was no longer necessary, and has thus been removed entirely. However, most test cases and most compiler-development-related activities still rely on parts of the CC-light architecture, hence the architecture itself remains. It is also useful as an example for what a basic architecture should look like within OpenQL’s codebase.

For extensive documentation on what the architecture was and how it worked, please refer to the documentation pages of older versions of OpenQL. What still remains in OpenQL now is almost entirely based on configuring reusable generalizations of CC-light specific code; therefore, its function can largely be derived from the default configuration file and the documentation that documents the relevant sections of it.

Default pass list

For the current/default global option values and the default variant (default), the following backend passes are used by default.

- rcscheduler: sch.ListSchedule
   |- resource_constraints: yes

- lastqasmwriter: io.cqasm.Report
   |- output_prefix: test_output/%N
   |- output_suffix: _last.qasm

default variant

This is the default CC-light configuration, based on what used to be tests/hardware_config_cc_light.json, which in turn is a simplified version of the surface-7 configuration (the instruction durations are comparatively short and uniform).

When no platform configuration file is specified, the following default file is used instead.

{
    "eqasm_compiler": "cc_light",

    "hardware_settings": {
        "qubit_number": 7,
        "cycle_time": 20
    },

    "topology": {
        "form": "xy",
        "qubits": [
            { "id": 0, "x": 1, "y": 2 },
            { "id": 1, "x": 3, "y": 2 },
            { "id": 2, "x": 0, "y": 1 },
            { "id": 3, "x": 2, "y": 1 },
            { "id": 4, "x": 4, "y": 1 },
            { "id": 5, "x": 1, "y": 0 },
            { "id": 6, "x": 3, "y": 0 }
        ],
        "edges": [
            { "id": 0, "src": 2, "dst": 0 },
            { "id": 1, "src": 0, "dst": 3 },
            { "id": 2, "src": 3, "dst": 1 },
            { "id": 3, "src": 1, "dst": 4 },
            { "id": 4, "src": 2, "dst": 5 },
            { "id": 5, "src": 5, "dst": 3 },
            { "id": 6, "src": 3, "dst": 6 },
            { "id": 7, "src": 6, "dst": 4 },
            { "id": 8, "src": 0, "dst": 2 },
            { "id": 9, "src": 3, "dst": 0 },
            { "id": 10, "src": 1, "dst": 3 },
            { "id": 11, "src": 4, "dst": 1 },
            { "id": 12, "src": 5, "dst": 2 },
            { "id": 13, "src": 3, "dst": 5 },
            { "id": 14, "src": 6, "dst": 3 },
            { "id": 15, "src": 4, "dst": 6 }
        ]
    },

    "resources": {
        "qubits": {},
        "qwgs": {
            "connection_map": {
                "0": [0, 1],
                "1": [2, 3, 4],
                "2": [5, 6]
            }
        },
        "meas_units": {
            "connection_map": {
                "0": [0, 2, 3, 5, 6],
                "1": [1, 4]
            }
        },
        "edges": {
            "connection_map": {
                "0": [2, 10],
                "1": [3, 11],
                "2": [0, 8],
                "3": [1, 9],
                "4": [6, 14],
                "5": [7, 15],
                "6": [4, 12],
                "7": [5, 13],
                "8": [2, 10],
                "9": [3, 11],
                "10": [0, 8],
                "11": [1, 9],
                "12": [6, 14],
                "13": [7, 15],
                "14": [4, 12],
                "15": [5, 13]
            }
        },
        "detuned_qubits": {
            "connection_map": {
                "0": [3],
                "1": [2],
                "2": [4],
                "3": [3],
                "4": [],
                "5": [6],
                "6": [5],
                "7": [],
                "8": [3],
                "9": [2],
                "10": [4],
                "11": [3],
                "12": [],
                "13": [6],
                "14": [5],
                "15": []
            }
        }
    },

    "instructions": {
        "prepx": {
            "prototype": ["W:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "prepx"
        },
        "prepz": {
            "prototype": ["W:qubit"],
            "duration": 40,
            "type": "none",
            "cc_light_instr": "prepz"
        },
        "cprepz": {
            "prototype": ["W:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "cprepz"
        },
        "measz": {
            "prototype": ["M:qubit"],
            "duration": 40,
            "type": "readout",
            "cc_light_instr": "measz"
        },
        "measz ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 40,
            "type": "readout",
            "cc_light_instr": "measz"
        },
        "measure": {
            "prototype": ["M:qubit"],
            "duration": 40,
            "type": "readout",
            "cc_light_instr": "measz",
            "decomposition": {
                "name": "desugar",
                "into": "measure op(0), bit(op(0))"
            }
        },
        "measure ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 40,
            "type": "readout",
            "cc_light_instr": "measz"
        },
        "i": {
            "prototype": ["U:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "i"
        },
        "x": {
            "prototype": ["X:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "x"
        },
        "y": {
            "prototype": ["Y:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "y"
        },
        "z": {
            "prototype": ["Z:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "z"
        },
        "h": {
            "prototype": ["U:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "h"
        },
        "s": {
            "prototype": ["Z:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "s"
        },
        "sdag": {
            "prototype": ["Z:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "sdag"
        },
        "rx90": {
            "prototype": ["X:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "x90"
        },
        "xm90": {
            "prototype": ["X:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "xm90"
        },
        "ry90": {
            "prototype": ["Y:qubit"],
            "duration": 40,
            "qubits": ["q0"],
            "type": "mw",
            "cc_light_instr": "y90"
        },
        "ym90": {
            "prototype": ["Y:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "ym90"
        },
        "t": {
            "prototype": ["Z:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "t"
        },
        "tdag": {
            "prototype": ["Z:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "tdag"
        },
        "x45": {
            "prototype": ["X:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "x45"
        },
        "xm45": {
            "prototype": ["X:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "xm45"
        },
        "ry180": {
            "prototype": ["Y:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "ry180"
        },
        "cnot": {
            "prototype": ["Z:qubit", "X:qubit"],
            "duration": 80,
            "type": "flux",
            "cc_light_instr": "cnot"
        },
        "sqf": {
            "prototype": ["U:qubit"],
            "duration": 80,
            "type": "flux",
            "cc_light_instr": "sqf"
        },
        "cz": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 80,
            "type": "flux",
            "cc_light_instr": "cz"
        }
    },

    "gate_decomposition": {
        "rx180 %0" : ["x %0"],
        "cnot %0,%1" : ["ym90 %1","cz %0,%1","ry90 %1"]
    }
}

s5 variant

This variant models the surface-5 chip. It is primarily intended as a baseline configuration for testing mapping and scheduling, as the eQASM backend is no longer part of OpenQL.

When no platform configuration file is specified, the following default file is used instead.

{
    "eqasm_compiler": "cc_light",

    "hardware_settings": {
        "qubit_number": 5,
        "cycle_time": 20
    },

    "topology": {
        "form": "xy",
        "qubits": [
            { "id": 0,  "x": 1, "y": 2 },
            { "id": 1,  "x": 3, "y": 2 },
            { "id": 2,  "x": 2, "y": 1 },
            { "id": 3,  "x": 1, "y": 0 },
            { "id": 4,  "x": 3, "y": 0 }
        ],
        "edges": [
            { "id": 0,  "src": 0, "dst": 2 },
            { "id": 1,  "src": 2, "dst": 1 },
            { "id": 2,  "src": 3, "dst": 2 },
            { "id": 3,  "src": 2, "dst": 4 },
            { "id": 4,  "src": 2, "dst": 0 },
            { "id": 5,  "src": 1, "dst": 2 },
            { "id": 6,  "src": 2, "dst": 3 },
            { "id": 7,  "src": 4, "dst": 2 }
        ]
    },

    "resources": {
        "qubits": {},
        "meas_units": {
            "connection_map": {
                "0": [0, 2, 3, 4],
                "1": [1]
            }
        },
        "detuned_qubits": {
            "connection_map": {
                "0": [],
                "1": [],
                "2": [4],
                "3": [3],
                "4": [],
                "5": [],
                "6": [4],
                "7": [3]
            }
        }
    },

    "instructions": {
        "prepx": {
            "prototype": ["W:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "prepx"
        },
        "prepz": {
            "prototype": ["W:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "prepz"
        },
        "measx_keep": {
            "prototype": ["M:qubit"],
            "duration": 340,
            "type": "readout",
            "cc_light_instr": "measx",
            "decomposition": {
                "name": "desugar",
                "into": "measx_keep op(0), bit(op(0))"
            }
        },
        "measx_keep ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 340,
            "type": "readout",
            "cc_light_instr": "measx"
        },
        "measz_keep": {
            "prototype": ["M:qubit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz",
            "decomposition": {
                "name": "desugar",
                "into": "measz_keep op(0), bit(op(0))"
            }
        },
        "measz_keep ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz"
        },
        "measure": {
            "prototype": ["M:qubit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz",
            "decomposition": {
                "name": "desugar",
                "into": "measure op(0), bit(op(0))"
            }
        },
        "measure ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz"
        },
        "i": {
            "prototype": ["U:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "i"
        },
        "x": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "x"
        },
        "y": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "y"
        },
        "z": {
            "prototype": ["Z:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "z"
        },
        "rx": {
            "prototype": ["X:qubit", "L:real"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "rx"
        },
        "ry": {
            "prototype": ["Y:qubit", "L:real"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "ry"
        },
        "rz": {
            "prototype": ["Z:qubit", "L:real"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "rz"
        },
        "h": {
            "prototype": ["U:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "h"
        },
        "s": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "s"
        },
        "sdag": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "sdag"
        },
        "x90": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "x90"
        },
        "xm90": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "xm90"
        },
        "y90": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "y90"
        },
        "ym90": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "ym90"
        },
        "t": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "t"
        },
        "tdag": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "tdag"
        },
        "x45": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "x45"
        },
        "xm45": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "xm45"
        },
        "y45": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "y45"
        },
        "ym45": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "ym45"
        },
        "cz": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 60,
            "type": "flux",
            "cc_light_instr": "cz"
        },
        "cnot_keep": {
            "prototype": ["Z:qubit", "X:qubit"],
            "duration": 100,
            "type": "flux",
            "cc_light_instr": "cnot"
        },
        "swap_keep": {
            "prototype": ["U:qubit", "U:qubit"],
            "duration": 260,
            "type": "flux",
            "cc_light_instr": "swap"
        },
        "move_keep": {
            "prototype": ["U:qubit", "U:qubit"],
            "duration": 180,
            "type": "flux",
            "cc_light_instr": "move"
        }
    },

    "gate_decomposition": {
        "cnot %0,%1": ["ym90 %1","cz %0,%1","y90 %1"],
        "swap %0,%1": ["ym90 %1","cz %0,%1","y90 %1", "ym90 %0","cz %1,%0","y90 %0", "ym90 %1","cz %0,%1","y90 %1"],
        "move %0,%1": ["ym90 %0","cz %1,%0","y90 %0", "ym90 %1","cz %0,%1","y90 %1"],

        "toffoli %0,%1,%2" : ["y90 %0", "xm45 %0", "y %0", "y90 %1", "xm45 %1", "ym90 %1", "x %2", "ym90 %2", "cz %2,%0", "y %0", "x45 %0", "y %0", "ym90 %2","cz %1,%2","y %2","cz %1,%0","y %0", "x45 %2", "y %2", "xm45 %0", "y %0","cz %1,%2","y90 %2","cz %2,%0","y %0", "x45 %0", "y %0", "y90 %2", "xm45 %2", "ym90 %2", "cz %1,%0","y90 %0", "x %2", "ym90 %2"],

        "rx180 %0" : ["x %0"],
        "ry180 %0" : ["y %0"],
        "rx90 %0" : ["x90 %0"],
        "ry90 %0" : ["y90 %0"],
        "mrx90 %0" : ["xm90 %0"],
        "mry90 %0" : ["ym90 %0"],
        "rx45 %0" : ["x45 %0"],
        "ry45 %0" : ["y45 %0"],
        "mrx45 %0" : ["xm45 %0"],
        "mry45 %0" : ["ym45 %0"],
        "measx %0" : ["h %0", "measure %0"],
        "measz %0" : ["measure %0"],

        "swap_real %0,%1": ["cnot %0,%1", "cnot %1,%0", "cnot %0,%1"],
        "move_real %0,%1": ["cnot %1,%0", "cnot %0,%1"],
        "z_real %0" : ["x %0","y %0"],
        "h_real %0" : ["x %0", "ym90 %0"],
        "t_real %0" : ["y90 %0", "x45 %0", "ym90 %0"],
        "tdag_real %0" : ["y90 %0", "xm45 %0", "ym90 %0"],
        "s_real %0" : ["y90 %0", "x90 %0", "ym90 %0"],
        "sdag_real %0" : ["y90 %0", "xm90 %0", "ym90 %0"],

        "cnot_prim %0,%1": ["ym90 %1","cz %0,%1","y90 %1"],
        "swap_prim %0,%1": ["ym90 %1","cz %0,%1","y90 %1", "ym90 %0","cz %1,%0","y90 %0", "ym90 %1","cz %0,%1","y90 %1"],
        "move_prim %0,%1": ["ym90 %0","cz %1,%0","y90 %0", "ym90 %1","cz %0,%1","y90 %1"],
        "z_prim %0" : ["x %0","y %0"],
        "h_prim %0" : ["x %0", "ym90 %0"],
        "t_prim %0" : ["y90 %0", "x45 %0", "ym90 %0"],
        "tdag_prim %0" : ["y90 %0", "xm45 %0", "ym90 %0"],
        "s_prim %0" : ["y90 %0", "x90 %0", "ym90 %0"],
        "sdag_prim %0" : ["y90 %0", "xm90 %0", "ym90 %0"]
    }
}

s7 variant

This variant models the surface-7 chip. It is primarily intended as a baseline configuration for testing mapping and scheduling, as the eQASM backend is no longer part of OpenQL.

When no platform configuration file is specified, the following default file is used instead.

{
    "eqasm_compiler": "cc_light",

    "hardware_settings": {
        "qubit_number": 7,
        "cycle_time": 20
    },

    "topology": {
        "form": "xy",
        "qubits": [
            { "id": 0, "x": 1, "y": 2 },
            { "id": 1, "x": 3, "y": 2 },
            { "id": 2, "x": 0, "y": 1 },
            { "id": 3, "x": 2, "y": 1 },
            { "id": 4, "x": 4, "y": 1 },
            { "id": 5, "x": 1, "y": 0 },
            { "id": 6, "x": 3, "y": 0 }
        ],
        "edges": [
            { "id": 0, "src": 2, "dst": 0 },
            { "id": 1, "src": 0, "dst": 3 },
            { "id": 2, "src": 3, "dst": 1 },
            { "id": 3, "src": 1, "dst": 4 },
            { "id": 4, "src": 2, "dst": 5 },
            { "id": 5, "src": 5, "dst": 3 },
            { "id": 6, "src": 3, "dst": 6 },
            { "id": 7, "src": 6, "dst": 4 },
            { "id": 8, "src": 0, "dst": 2 },
            { "id": 9, "src": 3, "dst": 0 },
            { "id": 10, "src": 1, "dst": 3 },
            { "id": 11, "src": 4, "dst": 1 },
            { "id": 12, "src": 5, "dst": 2 },
            { "id": 13, "src": 3, "dst": 5 },
            { "id": 14, "src": 6, "dst": 3 },
            { "id": 15, "src": 4, "dst": 6 }
        ]
    },

    "resources": {
        "qubits": {},
        "qwgs": {
            "connection_map": {
                "0": [0, 1],
                "1": [2, 3, 4],
                "2": [5, 6]
            }
        },
        "meas_units": {
            "connection_map": {
                "0": [0, 2, 3, 5, 6],
                "1": [1, 4]
            }
        },
        "edges": {
            "connection_map": {
                "0": [2, 10],
                "1": [3, 11],
                "2": [0, 8],
                "3": [1, 9],
                "4": [6, 14],
                "5": [7, 15],
                "6": [4, 12],
                "7": [5, 13],
                "8": [2, 10],
                "9": [3, 11],
                "10": [0, 8],
                "11": [1, 9],
                "12": [6, 14],
                "13": [7, 15],
                "14": [4, 12],
                "15": [5, 13]
            }
        },
        "detuned_qubits": {
            "connection_map": {
                "0": [3],
                "1": [2],
                "2": [4],
                "3": [3],
                "4": [],
                "5": [6],
                "6": [5],
                "7": [],
                "8": [3],
                "9": [2],
                "10": [4],
                "11": [3],
                "12": [],
                "13": [6],
                "14": [5],
                "15": []
            }
        }
    },

    "instructions": {
        "prepx": {
            "prototype": ["W:qubit"],
            "duration": 640,
            "type": "mw",
            "cc_light_instr": "prepx"
        },
        "prepz": {
            "prototype": ["W:qubit"],
            "duration": 620,
            "type": "mw",
            "cc_light_instr": "prepz"
        },
        "measx_keep": {
            "prototype": ["M:qubit"],
            "duration": 340,
            "type": "readout",
            "cc_light_instr": "measx",
            "decomposition": {
                "name": "desugar",
                "into": "measx_keep op(0), bit(op(0))"
            }
        },
        "measx_keep ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 340,
            "type": "readout",
            "cc_light_instr": "measx"
        },
        "measz_keep": {
            "prototype": ["M:qubit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz",
            "decomposition": {
                "name": "desugar",
                "into": "measz_keep op(0), bit(op(0))"
            }
        },
        "measz_keep ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz"
        },
        "measure": {
            "prototype": ["M:qubit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz",
            "decomposition": {
                "name": "desugar",
                "into": "measure op(0), bit(op(0))"
            }
        },
        "measure ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz"
        },
        "i": {
            "prototype": ["W:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "i"
        },
        "x": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "x"
        },
        "y": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "y"
        },
        "z": {
            "prototype": ["Z:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "z"
        },
        "rx": {
            "prototype": ["X:qubit", "L:real"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "rx"
        },
        "ry": {
            "prototype": ["Y:qubit", "L:real"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "ry"
        },
        "rz": {
            "prototype": ["Z:qubit", "L:real"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "rz"
        },
        "h": {
            "prototype": ["W:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "h"
        },
        "s": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "s"
        },
        "sdag": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "sdag"
        },
        "x90": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "x90"
        },
        "xm90": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "xm90"
        },
        "y90": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "y90"
        },
        "ym90": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "ym90"
        },
        "t": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "t"
        },
        "tdag": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "tdag"
        },
        "x45": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "x45"
        },
        "xm45": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "xm45"
        },
        "y45": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "y45"
        },
        "ym45": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "ym45"
        },
        "cz": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "type": "flux",
            "cc_light_instr": "cz"
        },
        "cnot": {
            "prototype": ["Z:qubit", "X:qubit"],
            "duration": 80,
            "type": "flux",
            "cc_light_instr": "cnot"
        },
        "toffoli" : {
            "prototype": ["Z:qubit", "Z:qubit", "X:qubit"],
            "duration": 80,
            "type": "multi",
            "cc_light_instr": "toffoli"
        },
        "swap": {
            "prototype": ["U:qubit", "U:qubit"],
            "duration": 200,
            "type": "flux",
            "cc_light_instr": "swap"
        },
        "move": {
            "prototype": ["U:qubit", "U:qubit"],
            "duration": 140,
            "type": "flux",
            "cc_light_instr": "move"
        }
    },

    "gate_decomposition": {
        "toffoli_decomp %0,%1,%2" : ["y90 %0", "xm45 %0", "y %0", "y90 %1", "xm45 %1", "ym90 %1", "x %2", "ym90 %2", "cz %2,%0", "y %0", "x45 %0", "y %0", "ym90 %2","cz %1,%2","y %2","cz %1,%0","y %0", "x45 %2", "y %2", "xm45 %0", "y %0","cz %1,%2","y90 %2","cz %2,%0","y %0", "x45 %0", "y %0", "y90 %2", "xm45 %2", "ym90 %2", "cz %1,%0","y90 %0", "x %2", "ym90 %2"],

        "rx180 %0" : ["x %0"],
        "ry180 %0" : ["y %0"],
        "rx90 %0" : ["x90 %0"],
        "ry90 %0" : ["y90 %0"],
        "mrx90 %0" : ["xm90 %0"],
        "mry90 %0" : ["ym90 %0"],
        "rx45 %0" : ["x45 %0"],
        "ry45 %0" : ["y45 %0"],
        "mrx45 %0" : ["xm45 %0"],
        "mry45 %0" : ["ym45 %0"],
        "measx %0" : ["h %0", "measure %0"],
        "measz %0" : ["measure %0"],

        "swap_real %0,%1": ["cnot %0,%1", "cnot %1,%0", "cnot %0,%1"],
        "move_real %0,%1": ["cnot %1,%0", "cnot %0,%1"],
        "z_real %0" : ["x %0","y %0"],
        "h_real %0" : ["x %0", "ym90 %0"],
        "t_real %0" : ["y90 %0", "x45 %0", "ym90 %0"],
        "tdag_real %0" : ["y90 %0", "xm45 %0", "ym90 %0"],
        "s_real %0" : ["y90 %0", "x90 %0", "ym90 %0"],
        "sdag_real %0" : ["y90 %0", "xm90 %0", "ym90 %0"],

        "cnot_prim %0,%1": ["ym90 %1","cz %0,%1","y90 %1"],
        "swap_prim %0,%1": ["ym90 %1","cz %0,%1","y90 %1", "ym90 %0","cz %1,%0","y90 %0", "ym90 %1","cz %0,%1","y90 %1"],
        "move_prim %0,%1": ["ym90 %0","cz %1,%0","y90 %0", "ym90 %1","cz %0,%1","y90 %1"],
        "z_prim %0" : ["x %0","y %0"],
        "h_prim %0" : ["x %0", "ym90 %0"],
        "t_prim %0" : ["y90 %0", "x45 %0", "ym90 %0"],
        "tdag_prim %0" : ["y90 %0", "xm45 %0", "ym90 %0"],
        "s_prim %0" : ["y90 %0", "x90 %0", "ym90 %0"],
        "sdag_prim %0" : ["y90 %0", "xm90 %0", "ym90 %0"]
    }
}

s17 variant

This variant models the surface-17 chip. It is primarily intended as a baseline configuration for testing mapping and scheduling, as the eQASM backend is no longer part of OpenQL.

When no platform configuration file is specified, the following default file is used instead.

{
    "eqasm_compiler": "cc_light",

    "hardware_settings": {
        "qubit_number": 17,
        "cycle_time": 20
    },

    "topology": {
        "form": "xy",
        "qubits": [
            { "id": 0, "x": 4, "y": 6 },
            { "id": 1, "x": 1, "y": 5 },
            { "id": 2, "x": 3, "y": 5 },
            { "id": 3, "x": 5, "y": 5 },
            { "id": 4, "x": 0, "y": 4 },
            { "id": 5, "x": 2, "y": 4 },
            { "id": 6, "x": 4, "y": 4 },
            { "id": 7, "x": 1, "y": 3 },
            { "id": 8, "x": 3, "y": 3 },
            { "id": 9, "x": 5, "y": 3 },
            { "id": 10, "x": 2, "y": 2 },
            { "id": 11, "x": 4, "y": 2 },
            { "id": 12, "x": 6, "y": 2 },
            { "id": 13, "x": 1, "y": 1 },
            { "id": 14, "x": 3, "y": 1 },
            { "id": 15, "x": 5, "y": 1 },
            { "id": 16, "x": 2, "y": 0 }
        ],
        "edges": [
            { "id": 0, "src": 2, "dst": 0 },
            { "id": 1, "src": 0, "dst": 3 },
            { "id": 2, "src": 4, "dst": 1 },
            { "id": 3, "src": 1, "dst": 5 },
            { "id": 4, "src": 5, "dst": 2 },
            { "id": 5, "src": 2, "dst": 6 },
            { "id": 6, "src": 6, "dst": 3 },
            { "id": 7, "src": 4, "dst": 7 },
            { "id": 8, "src": 7, "dst": 5 },
            { "id": 9, "src": 5, "dst": 8 },
            { "id": 10, "src": 8, "dst": 6 },
            { "id": 11, "src": 6, "dst": 9 },
            { "id": 12, "src": 7, "dst": 10 },
            { "id": 13, "src": 10, "dst": 8 },
            { "id": 14, "src": 8, "dst": 11 },
            { "id": 15, "src": 11, "dst": 9 },
            { "id": 16, "src": 9, "dst": 12 },
            { "id": 17, "src": 13, "dst": 10 },
            { "id": 18, "src": 10, "dst": 14 },
            { "id": 19, "src": 14, "dst": 11 },
            { "id": 20, "src": 11, "dst": 15 },
            { "id": 21, "src": 15, "dst": 12 },
            { "id": 22, "src": 13, "dst": 16 },
            { "id": 23, "src": 16, "dst": 14 },

            { "id": 24, "src": 0, "dst": 2 },
            { "id": 25, "src": 3, "dst": 0 },
            { "id": 26, "src": 1, "dst": 4 },
            { "id": 27, "src": 5, "dst": 1 },
            { "id": 28, "src": 2, "dst": 5 },
            { "id": 29, "src": 6, "dst": 2 },
            { "id": 30, "src": 3, "dst": 6 },
            { "id": 31, "src": 7, "dst": 4 },
            { "id": 32, "src": 5, "dst": 7 },
            { "id": 33, "src": 8, "dst": 5 },
            { "id": 34, "src": 6, "dst": 8 },
            { "id": 35, "src": 9, "dst": 6 },
            { "id": 36, "src": 10, "dst": 7 },
            { "id": 37, "src": 8, "dst": 10 },
            { "id": 38, "src": 11, "dst": 8 },
            { "id": 39, "src": 9, "dst": 11 },
            { "id": 40, "src": 12, "dst": 9 },
            { "id": 41, "src": 10, "dst": 13 },
            { "id": 42, "src": 14, "dst": 10 },
            { "id": 43, "src": 11, "dst": 14 },
            { "id": 44, "src": 15, "dst": 11 },
            { "id": 45, "src": 12, "dst": 15 },
            { "id": 46, "src": 16, "dst": 13 },
            { "id": 47, "src": 14, "dst": 16 }
        ]
    },

    "resources": {
        "qubits": {},
        "qwgs": {
            "connection_map": {
                "0" : [1, 2, 3, 13, 14, 15],
                "1" : [7, 8, 9],
                "2" : [0, 5, 11, 16, 4, 6, 10, 12]
            }
        },
        "meas_units": {
            "connection_map": {
                "0" : [13,16],
                "1" : [1, 4, 5, 7, 8, 10, 11, 14, 15],
                "2" : [0, 2, 3, 6, 9, 12]
            }
        },
        "edges": {
            "connection_map": {
                "0": [3, 27, 6, 30],
                "1": [5, 29, 4, 28],
                "2": [4, 28],
                "3": [0, 24, 5, 29],
                "4": [2, 26, 1, 25, 6, 30],
                "5": [3, 27, 1, 25],
                "6": [4, 28, 0, 24],
                "7": [9, 23, 13, 37],
                "8": [10, 34, 13, 37, 14, 28],
                "9": [7, 31, 12, 36, 11, 35, 15, 39],
                "10": [8, 32, 12, 36, 15, 39],
                "11": [9, 33, 13, 37, 14, 38],
                "12": [9, 33, 10, 34, 14, 38],
                "13": [8, 32, 11, 35, 15, 39],
                "14": [8, 32, 12, 36, 11, 35, 16, 40],
                "15": [9, 33, 13, 37, 10, 34],
                "16": [10, 34, 14, 38],
                "17": [19, 43],
                "18": [22, 46, 20, 44],
                "19": [17, 41, 22, 46, 21, 45],
                "20": [18, 42, 23, 47],
                "21": [19, 43],
                "22": [18, 42, 19, 43],
                "23": [17, 41, 20, 44],

                "24": [3, 27, 6, 30],
                "25": [5, 29, 4, 28],
                "26": [4, 28],
                "27": [0, 24, 5, 29],
                "28": [2, 26, 1, 25, 6, 30],
                "29": [3, 27, 1, 25],
                "30": [4, 28, 0, 24],
                "31": [9, 23, 13, 37],
                "32": [10, 34, 13, 37, 14, 28],
                "33": [7, 31, 12, 36, 11, 35, 15, 39],
                "34": [8, 32, 12, 36, 15, 39],
                "35": [9, 33, 13, 37, 14, 38],
                "36": [9, 33, 10, 34, 14, 38],
                "37": [8, 32, 11, 35, 15, 39],
                "38": [8, 32, 12, 36, 11, 35, 16, 40],
                "39": [9, 33, 13, 37, 10, 34],
                "40": [10, 34, 14, 38],
                "41": [19, 43],
                "42": [22, 46, 20, 44],
                "43": [17, 41, 22, 46, 21, 45],
                "44": [18, 42, 23, 47],
                "45": [19, 43],
                "46": [18, 42, 19, 43],
                "47": [17, 41, 20, 44]
            }
        },
        "detuned_qubits": {
            "connection_map": {
                "0": [5, 6],
                "1": [6],
                "2": [5],
                "3": [4],
                "4": [0, 6],
                "5": [5, 0],
                "6": [0],
                "7": [],
                "8": [8],
                "9": [7],
                "10": [9],
                "11": [8],
                "12": [8],
                "13": [7],
                "14": [9],
                "15": [8],
                "16": [],
                "17": [16],
                "18": [16, 11],
                "19": [10, 16],
                "20": [12],
                "21": [11],
                "22": [10],
                "23": [10, 11],

                "24": [5, 6],
                "25": [6],
                "26": [5],
                "27": [4],
                "28": [0, 6],
                "29": [5, 0],
                "30": [0],
                "31": [],
                "32": [8],
                "33": [7],
                "34": [9],
                "35": [8],
                "36": [8],
                "37": [7],
                "38": [9],
                "39": [8],
                "40": [],
                "41": [16],
                "42": [16, 11],
                "43": [10, 16],
                "44": [12],
                "45": [11],
                "46": [10],
                "47": [10, 11]
            }
        }
    },

    "instructions": {
        "prepx": {
            "prototype": ["W:qubit"],
            "duration": 640,
            "type": "mw",
            "cc_light_instr": "prepx"
        },
        "prepz": {
            "prototype": ["W:qubit"],
            "duration": 620,
            "type": "mw",
            "cc_light_instr": "prepz"
        },
        "measx_keep": {
            "prototype": ["M:qubit"],
            "duration": 340,
            "type": "readout",
            "cc_light_instr": "measx",
            "decomposition": {
                "name": "desugar",
                "into": "measx_keep op(0), bit(op(0))"
            }
        },
        "measx_keep ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 340,
            "type": "readout",
            "cc_light_instr": "measx"
        },
        "measz_keep": {
            "prototype": ["M:qubit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz",
            "decomposition": {
                "name": "desugar",
                "into": "measz_keep op(0), bit(op(0))"
            }
        },
        "measz_keep ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz"
        },
        "measure": {
            "prototype": ["M:qubit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz",
            "decomposition": {
                "name": "desugar",
                "into": "measure op(0), bit(op(0))"
            }
        },
        "measure ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 300,
            "type": "readout",
            "cc_light_instr": "measz"
        },
        "i": {
            "prototype": ["U:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "i"
        },
        "x": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "x"
        },
        "y": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "y"
        },
        "z": {
            "prototype": ["Z:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "z"
        },
        "rx": {
            "prototype": ["X:qubit", "L:real"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "rx"
        },
        "ry": {
            "prototype": ["Y:qubit", "L:real"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "ry"
        },
        "rz": {
            "prototype": ["Z:qubit", "L:real"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "rz"
        },
        "h": {
            "prototype": ["U:qubit"],
            "duration": 40,
            "type": "mw",
            "cc_light_instr": "h"
        },
        "s": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "s"
        },
        "sdag": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "sdag"
        },
        "x90": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "x90"
        },
        "xm90": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "xm90"
        },
        "y90": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "y90"
        },
        "ym90": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "ym90"
        },
        "t": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "t"
        },
        "tdag": {
            "prototype": ["Z:qubit"],
            "duration": 60,
            "type": "mw",
            "cc_light_instr": "tdag"
        },
        "x45": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "x45"
        },
        "xm45": {
            "prototype": ["X:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "xm45"
        },
        "y45": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "y45"
        },
        "ym45": {
            "prototype": ["Y:qubit"],
            "duration": 20,
            "type": "mw",
            "cc_light_instr": "ym45"
        },
        "cz": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 40,
            "type": "flux",
            "cc_light_instr": "cz"
        },
        "cnot": {
            "prototype": ["Z:qubit", "X:qubit"],
            "duration": 80,
            "type": "flux",
            "cc_light_instr": "cnot"
        },
        "swap": {
            "prototype": ["U:qubit", "U:qubit"],
            "duration": 200,
            "type": "flux",
            "cc_light_instr": "swap"
        },
        "move": {
            "prototype": ["U:qubit", "U:qubit"],
            "duration": 140,
            "type": "flux",
            "cc_light_instr": "move"
        }
    },

    "gate_decomposition": {
        "toffoli %0,%1,%2" : ["y90 %0", "xm45 %0", "y %0", "y90 %1", "xm45 %1", "ym90 %1", "x %2", "ym90 %2", "cz %2,%0", "y %0", "x45 %0", "y %0", "ym90 %2","cz %1,%2","y %2","cz %1,%0","y %0", "x45 %2", "y %2", "xm45 %0", "y %0","cz %1,%2","y90 %2","cz %2,%0","y %0", "x45 %0", "y %0", "y90 %2", "xm45 %2", "ym90 %2", "cz %1,%0","y90 %0", "x %2", "ym90 %2"],

        "rx180 %0" : ["x %0"],
        "ry180 %0" : ["y %0"],
        "rx90 %0" : ["x90 %0"],
        "ry90 %0" : ["y90 %0"],
        "mrx90 %0" : ["xm90 %0"],
        "mry90 %0" : ["ym90 %0"],
        "rx45 %0" : ["x45 %0"],
        "ry45 %0" : ["y45 %0"],
        "mrx45 %0" : ["xm45 %0"],
        "mry45 %0" : ["ym45 %0"],
        "measx %0" : ["h %0", "measure %0"],
        "measz %0" : ["measure %0"],

        "swap_real %0,%1": ["cnot %0,%1", "cnot %1,%0", "cnot %0,%1"],
        "move_real %0,%1": ["cnot %1,%0", "cnot %0,%1"],
        "z_real %0" : ["x %0","y %0"],
        "h_real %0" : ["x %0", "ym90 %0"],
        "t_real %0" : ["y90 %0", "x45 %0", "ym90 %0"],
        "tdag_real %0" : ["y90 %0", "xm45 %0", "ym90 %0"],
        "s_real %0" : ["y90 %0", "x90 %0", "ym90 %0"],
        "sdag_real %0" : ["y90 %0", "xm90 %0", "ym90 %0"],

        "cnot_prim %0,%1": ["ym90 %1","cz %0,%1","y90 %1"],
        "swap_prim %0,%1": ["ym90 %1","cz %0,%1","y90 %1", "ym90 %0","cz %1,%0","y90 %0", "ym90 %1","cz %0,%1","y90 %1"],
        "move_prim %0,%1": ["ym90 %0","cz %1,%0","y90 %0", "ym90 %1","cz %0,%1","y90 %1"],
        "z_prim %0" : ["x %0","y %0"],
        "h_prim %0" : ["x %0", "ym90 %0"],
        "t_prim %0" : ["y90 %0", "x45 %0", "ym90 %0"],
        "tdag_prim %0" : ["y90 %0", "xm45 %0", "ym90 %0"],
        "s_prim %0" : ["y90 %0", "x90 %0", "ym90 %0"],
        "sdag_prim %0" : ["y90 %0", "xm90 %0", "ym90 %0"]
    }
}

Diamond

  • Pass/resource/C++ namespace: arch.diamond

  • Acceptable "eqasm_compiler" values: "diamond"

This architecture is aimed towards computing with qubits made in color centers in diamond. It is part of the Fujitsu project and is a work in progress. The backend will, for now as it is in its early stages, work as a translation tool from a high-level algorithm to our own defined microcode. It is mostly a proof of concept at this time.

Default pass list

For the current/default global option values and the default variant (default), the following backend passes are used by default.

- diamond_codegen: arch.diamond.gen.Microcode
   |- no options to dump

Default configuration file

When no platform configuration file is specified, the following default file is used instead.

{
  "eqasm_compiler": "diamond",

  "hardware_settings": {
    "qubit_number": 10,
    "cycle_time": 20
  },

  "gate_decomposition": {
    "toffoli %0, %1, %2" : ["h %2", "cnot %1 %2", "tdag %2", "cnot %0 %2", "t %2","cnot %1 %2", "tdag %2", "cnot %0 %2", "t %1", "t %2", "cnot %0 %1", "h %2", "t %0", "tdag %1", "cnot %0 %1"],
    "measure_z %0": ["measure %0"],
    "measure_y %0": ["mprep_y %0", "measure %0"],
    "measure_x %0": ["mprep_x %0", "measure %0"]
  },

  "instructions": {

    "prep_x": {
      "prototype": ["W:qubit"],
      "duration": 40,
      "diamond_type": "prepare"
    },

    "prep_y": {
      "prototype": ["W:qubit"],
      "duration": 40,
      "diamond_type": "prepare"
    },

    "prep_z": {
      "prototype": ["W:qubit"],
      "duration": 40,
      "diamond_type": "prepare"
    },

    "mprep_x": {
      "prototype": ["U:qubit"],
      "duration": 40,
      "diamond_type": "prepare"
    },

    "mprep_y": {
      "prototype": ["U:qubit"],
      "duration": 40,
      "diamond_type": "prepare"
    },

    "qnop": {
      "prototype": ["B:qubit"],
      "duration": 1
    },

    "calculate_current": {
      "prototype": ["U:qubit"],
      "duration": 1,
      "diamond_type": "classical"
    },

    "calculate_voltage": {
      "prototype": ["U:qubit"],
      "barrier": true,
      "duration": 1,
      "diamond_type": "classical"
    },

    "i": {
      "prototype": ["U:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "h": {
      "prototype": ["U:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "x": {
      "prototype": ["X:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "y": {
      "prototype": ["Y:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "z": {
      "prototype": ["Z:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "initialize": {
      "prototype": ["W:qubit"],
      "duration": 40
    },

    "x90": {
      "prototype": ["X:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "y90": {
      "prototype": ["Y:qubit"],
      "duration": 20,
      "diamond_type": "qgate"
    },

    "x180": {
      "prototype": ["X:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "y180": {
      "prototype": ["Y:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "mx90": {
      "prototype": ["X:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "my90": {
      "prototype": ["Y:qubit"],
      "duration": 20,
      "diamond_type": "qgate"
    },

    "rx": {
      "prototype": ["X:qubit", "L:real"],
      "duration": 40,
      "diamond_type": "rotation"
    },

    "ry": {
      "prototype": ["Y:qubit", "L:real"],
      "duration": 40,
      "diamond_type": "rotation"
    },

    "rz": {
      "prototype": ["Z:qubit", "L:real"],
      "duration": 40,
      "diamond_type": "rotation"
    },

    "cr": {
      "prototype": ["Z:qubit", "Z:qubit", "L:real"],
      "duration": 40,
      "diamond_type": "rotation"
    },

    "crk": {
      "prototype": ["Z:qubit", "Z:qubit", "L:int"],
      "duration": 40,
      "diamond_type": "rotation"
    },

    "s": {
      "prototype": ["Z:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "sdag": {
      "prototype": ["Z:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "t": {
      "prototype": ["Z:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "tdag": {
      "prototype": ["Z:qubit"],
      "duration": 40,
      "diamond_type": "qgate"
    },

    "cnot": {
      "prototype": ["Z:qubit", "X:qubit"],
      "duration": 80,
      "diamond_type": "qgate2"
    },

    "pmx90": {
      "prototype": ["U:qubit", "U:qubit"],
      "duration": 80,
      "diamond_type": "qgate2"
    },

    "pmy90": {
      "prototype": ["U:qubit", "U:qubit"],
      "duration": 80,
      "diamond_type": "qgate2"
    },

    "pmx180": {
      "prototype": ["U:qubit", "U:qubit"],
      "duration": 80,
      "diamond_type": "qgate2"
    },

    "pmy180": {
      "prototype": ["U:qubit", "U:qubit"],
      "duration": 80,
      "diamond_type": "qgate2"
    },

    "cz": {
      "prototype": ["Z:qubit", "Z:qubit"],
      "duration": 80,
      "diamond_type": "qgate2"
    },

    "measure": {
      "prototype": ["M:qubit"],
      "duration": 300,
      "decomposition": {
        "name": "desugar",
        "into": "measure op(0), bit(op(0))"
      }
    },

    "measure ": {
      "prototype": ["U:qubit", "W:bit"],
      "duration": 300
    },

    "display": {
      "prototype": [],
      "barrier": true,
      "duration": 20,
      "qubits": []
    },

    "display_binary": {
      "prototype": [],
      "barrier": true,
      "duration": 20,
      "qubits": []
    },

    "swap": {
      "prototype": ["U:qubit", "U:qubit"],
      "duration": 80,
      "diamond_type": "qgate2"
    },

    "memswap": {
      "prototype": ["U:qubit", "L:int"],
      "duration": 80
    },

    "qentangle": {
      "prototype": ["U:qubit", "L:int"],
      "duration": 60
    },

    "nventangle": {
      "prototype": ["U:qubit", "U:qubit"],
      "duration": 100
    },

    "sweep_bias": {
      "prototype": ["U:qubit", "L:int", "L:int", "L:int", "L:int", "L:int", "L:int"],
      "duration": 300
    },

    "excite_mw": {
      "prototype": ["U:qubit", "L:int", "L:int", "L:int", "L:int", "L:int"],
      "duration": 20
    },

    "crc": {
      "prototype": ["U:qubit", "L:int", "L:int"],
      "duration": 20,
      "diamond_type": "initial_checks"
    },

    "mag_bias": {
      "prototype": ["U:qubit"],
      "duration": 300,
      "diamond_type": "initial_checks"
    },

    "rabi_check": {
      "prototype": ["U:qubit", "L:int", "L:int", "L:int"],
      "duration": 300,
      "diamond_type": "initial_checks"
    },

    "decouple": {
      "prototype": ["U:qubit"],
      "duration": 300,
      "diamond_type": "calibration"
    },

    "cal_measure": {
      "prototype": ["U:qubit"],
      "duration": 300,
      "diamond_type": "calibration"
    },

    "cal_pi": {
      "prototype": ["U:qubit"],
      "duration": 300,
      "diamond_type": "calibration"
    },

    "cal_halfpi": {
      "prototype": ["U:qubit"],
      "duration": 300,
      "diamond_type": "calibration"
    }
  }
}

None

  • Pass/resource/C++ namespace: arch.none

  • Acceptable "eqasm_compiler" values: "none", "qx", or ""

This is just a dummy architecture that does not include any backend passes by default, does not provide shortcuts for any architecture-specific passes and resources, and does not do any platform-specific preprocessing on the platform configuration file. You can use it when you just want to try OpenQL out, or when your target is an architecture-agnostic simulator.

The default configuration file consists of relatively sane defaults for simulating the resulting cQASM output with the QX simulator.

Default pass list

For the current/default global option values, this architecture does not insert any backend passes.

Default configuration file

When no platform configuration file is specified, the following default file is used instead.

{
    "eqasm_compiler": "none",

    "hardware_settings": {
        "qubit_number": 10,
        "cycle_time": 20
    },

    "instructions": {

        "prep_x": {
            "prototype": ["W:qubit"],
            "duration": 40
        },

        "prep_y": {
            "prototype": ["W:qubit"],
            "duration": 40
        },

        "prep_z": {
            "prototype": ["W:qubit"],
            "duration": 40
        },

        "i": {
            "prototype": ["U:qubit"],
            "duration": 40
        },

        "h": {
            "prototype": ["U:qubit"],
            "duration": 40
        },

        "x": {
            "prototype": ["X:qubit"],
            "duration": 40
        },

        "y": {
            "prototype": ["Y:qubit"],
            "duration": 40
        },

        "z": {
            "prototype": ["Z:qubit"],
            "duration": 40
        },

        "x90": {
            "prototype": ["X:qubit"],
            "duration": 40
        },

        "y90": {
            "prototype": ["Y:qubit"],
            "duration": 20
        },

        "x180": {
            "prototype": ["X:qubit"],
            "duration": 40
        },

        "y180": {
            "prototype": ["Y:qubit"],
            "duration": 40
        },

        "mx90": {
            "prototype": ["X:qubit"],
            "duration": 40
        },

        "my90": {
            "prototype": ["Y:qubit"],
            "duration": 20
        },

        "rx": {
            "prototype": ["X:qubit", "L:real"],
            "duration": 40
        },

        "ry": {
            "prototype": ["Y:qubit", "L:real"],
            "duration": 40
        },

        "rz": {
            "prototype": ["Z:qubit", "L:real"],
            "duration": 40
        },

        "s": {
            "prototype": ["Z:qubit"],
            "duration": 40
        },

        "sdag": {
            "prototype": ["Z:qubit"],
            "duration": 40
        },

        "t": {
            "prototype": ["Z:qubit"],
            "duration": 40
        },

        "tdag": {
            "prototype": ["Z:qubit"],
            "duration": 40
        },

        "cnot": {
            "prototype": ["Z:qubit", "X:qubit"],
            "duration": 80
        },

        "toffoli": {
            "prototype": ["Z:qubit", "Z:qubit", "X:qubit"],
            "duration": 80
        },

        "cz": {
            "prototype": ["Z:qubit", "Z:qubit"],
            "duration": 80
        },

        "swap": {
            "prototype": ["U:qubit", "U:qubit"],
            "duration": 80
        },

        "measure": {
            "prototype": ["M:qubit"],
            "duration": 300,
            "decomposition": {
                "name": "desugar",
                "into": "measure op(0), bit(op(0))"
            }
        },

        "measure ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 300
        },

        "measure_x": {
            "prototype": ["M:qubit"],
            "duration": 300
        },

        "measure_x ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 300
        },

        "measure_y": {
            "prototype": ["M:qubit"],
            "duration": 300
        },

        "measure_y ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 300
        },

        "measure_z": {
            "prototype": ["M:qubit"],
            "duration": 300
        },

        "measure_z ": {
            "prototype": ["U:qubit", "W:bit"],
            "duration": 300
        },

        "display": {
            "prototype": [],
            "barrier": true,
            "duration": 20
        },

        "display_binary": {
            "prototype": [],
            "barrier": true,
            "duration": 20
        }
    }
}