Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add stage plugin interface for transpile #8305

Merged
merged 42 commits into from
Aug 30, 2022

Commits on Jul 6, 2022

  1. Add stage plugin interface for transpile

    This commit adds a new plugin interface to qiskit for enabling external
    packages to write plugins that will replace a stage in the transpilation
    pipeline. For example, if an external package had a custom layout pass
    that they wanted to integrate into transpile() they could export a
    plugin using this new interface and then users would just need to run
    
    transpile(.., layout_method=foo)
    
    This adds long asked for extensibility to the transpiler so that to
    cleanly integrate new transpiler passes we're no longer required to
    merge the features into terra. This should hopefully make it easier for
    downstream pass authors to integrate their passes into terra and make it
    easier for the terra maintainers to evaluate new transpiler passes.
    mtreinish committed Jul 6, 2022
    Configuration menu
    Copy the full SHA
    16c4ab6 View commit details
    Browse the repository at this point in the history

Commits on Jul 7, 2022

  1. Fix docs builds

    mtreinish committed Jul 7, 2022
    Configuration menu
    Copy the full SHA
    5ec9324 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    5eca33c View commit details
    Browse the repository at this point in the history
  3. Fix doc warning

    mtreinish committed Jul 7, 2022
    Configuration menu
    Copy the full SHA
    dfeb064 View commit details
    Browse the repository at this point in the history

Commits on Jul 20, 2022

  1. Configuration menu
    Copy the full SHA
    c1afe2c View commit details
    Browse the repository at this point in the history
  2. Make routing methods all plugins

    This commit converts all the built-in routing method options into
    separate plugins and also adds a default plugin for the default behavior
    at each optimization level. To support using plugins for routing method
    adding the optimization_level to the passmanager config was necessary so
    that the plugin has sufficient context on how to construct the routing
    pass used for the routing stage. As depending on the optimization level
    the settings for each pass differs. For example on stochastic swap the
    number of stochastic trials increases for level 3 to try and find a
    better solution at the cost of more runtime.
    mtreinish committed Jul 20, 2022
    Configuration menu
    Copy the full SHA
    150c838 View commit details
    Browse the repository at this point in the history

Commits on Jul 21, 2022

  1. Configuration menu
    Copy the full SHA
    d900f8a View commit details
    Browse the repository at this point in the history

Commits on Jul 22, 2022

  1. Configuration menu
    Copy the full SHA
    2839d5e View commit details
    Browse the repository at this point in the history
  2. Add plugin usage to level 3

    mtreinish committed Jul 22, 2022
    Configuration menu
    Copy the full SHA
    19df4a0 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    0e11723 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    fb72d1d View commit details
    Browse the repository at this point in the history
  5. Add release notes

    mtreinish committed Jul 22, 2022
    Configuration menu
    Copy the full SHA
    4ea9949 View commit details
    Browse the repository at this point in the history
  6. Add tests

    mtreinish committed Jul 22, 2022
    Configuration menu
    Copy the full SHA
    e96b120 View commit details
    Browse the repository at this point in the history

Commits on Jul 27, 2022

  1. Apply suggestions from code review

    Co-authored-by: Alexander Ivrii <alexi@il.ibm.com>
    mtreinish and alexanderivrii committed Jul 27, 2022
    Configuration menu
    Copy the full SHA
    a0054ed View commit details
    Browse the repository at this point in the history
  2. Apply suggestions from code review

    Co-authored-by: Alexander Ivrii <alexi@il.ibm.com>
    mtreinish and alexanderivrii committed Jul 27, 2022
    Configuration menu
    Copy the full SHA
    0599830 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    26ae3c4 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    62b4f3f View commit details
    Browse the repository at this point in the history
  5. Fix typo

    mtreinish committed Jul 27, 2022
    Configuration menu
    Copy the full SHA
    a52f7ed View commit details
    Browse the repository at this point in the history
  6. Deduplicate code in built-in routing plugins

    This commit deduplicates the code in the built-in routing stage plugins.
    First it removes the default plugin which was duplicated with the
    stochastic and sabre plugins. There was no functional difference between
    just setting the implicit default method name and using a per method
    plugin and having a standalone default plugin. Secondly all the vf2 call
    limit code is abstracted into a helper function which reduces code
    duplication.
    mtreinish committed Jul 27, 2022
    Configuration menu
    Copy the full SHA
    5dec6c8 View commit details
    Browse the repository at this point in the history

Commits on Jul 29, 2022

  1. Configuration menu
    Copy the full SHA
    adaa169 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    58f6306 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    7963e84 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    b2d186d View commit details
    Browse the repository at this point in the history
  5. Update qiskit/transpiler/preset_passmanagers/level1.py

    Co-authored-by: Luciano Bello <bel@zurich.ibm.com>
    mtreinish and 1ucian0 committed Jul 29, 2022
    Configuration menu
    Copy the full SHA
    3c19b4a View commit details
    Browse the repository at this point in the history
  6. Add missing TODO comment

    mtreinish committed Jul 29, 2022
    Configuration menu
    Copy the full SHA
    2c03969 View commit details
    Browse the repository at this point in the history

Commits on Jul 30, 2022

  1. Configuration menu
    Copy the full SHA
    e0a7d38 View commit details
    Browse the repository at this point in the history

Commits on Aug 2, 2022

  1. Configuration menu
    Copy the full SHA
    eca7f38 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    08a4972 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    4190774 View commit details
    Browse the repository at this point in the history
  4. Update qiskit/transpiler/preset_passmanagers/plugin.py

    Co-authored-by: Luciano Bello <bel@zurich.ibm.com>
    mtreinish and 1ucian0 committed Aug 2, 2022
    Configuration menu
    Copy the full SHA
    38931c8 View commit details
    Browse the repository at this point in the history
  5. Prefer toqm plugin if one is available

    The qiskit-toqm project will be one of the first users of this plugin
    interface. Once this is released in qiskit, qiskit-toqm will likely
    publish their own plugin soon after and if they do we want that plugin
    to be used instead of the hardcoded stage in terra. This commit updates
    the logic for toqm handling to only use the built-in toqm if a version
    of qiskit-toqm is installed without a plugin present.
    mtreinish committed Aug 2, 2022
    Configuration menu
    Copy the full SHA
    9b928a0 View commit details
    Browse the repository at this point in the history

Commits on Aug 4, 2022

  1. Apply suggestions from code review

    Co-authored-by: Kevin Hartman <kevin@hart.mn>
    Co-authored-by: Toshinari Itoko <15028342+itoko@users.noreply.github.com>
    3 people committed Aug 4, 2022
    Configuration menu
    Copy the full SHA
    7b67905 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    89b6d3b View commit details
    Browse the repository at this point in the history

Commits on Aug 17, 2022

  1. Configuration menu
    Copy the full SHA
    0afc56d View commit details
    Browse the repository at this point in the history
  2. Fix lint

    mtreinish committed Aug 17, 2022
    Configuration menu
    Copy the full SHA
    23a2b36 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    6cb6b20 View commit details
    Browse the repository at this point in the history

Commits on Aug 25, 2022

  1. Apply suggestions from code review

    Co-authored-by: Luciano Bello <bel@zurich.ibm.com>
    mtreinish and 1ucian0 committed Aug 25, 2022
    Configuration menu
    Copy the full SHA
    d756597 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7120d2d View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    d731d06 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    f185c59 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    6d344c0 View commit details
    Browse the repository at this point in the history

Commits on Aug 30, 2022

  1. Configuration menu
    Copy the full SHA
    c4816d3 View commit details
    Browse the repository at this point in the history