Skip to content

Ensure that multi qubit gates on targets with global multi qubit gates supported pass through sabre #14917

@mtreinish

Description

@mtreinish

Yeah, I suppose in this particular case with concrete cx but global ccx, it could be argued as a breaking change, though really I think there's a fair call that it was just undefined behaviour before. The documentation of Sabre previously stated that all multi-qubit gates already had to be decomposed, and it implicitly treated them as directives. #14605 fixes Sabre to loudly error on multi-q gates (since before they just got falsely treated as directives), though technically if the multi-q is valid everywhere, then the previous version would have returned a valid circuit in this situation.

I think we could merge this (and #14605) as-is now, and later add additional logic to Sabre such that SabreDAG::from_interactions queries the Target to see if a multi-q is globally supported, and formally lift it to a Synchronize node if so? That would the guarantee that Sabre is only returning results for circuits that are actually accurate, which is rather better than the silent nonsense we're doing right now.

Originally posted by @jakelishman in #14715 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions