• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Qiskit / qiskit / 17306652456

28 Aug 2025 08:04PM UTC coverage: 88.442% (+0.003%) from 88.439%
17306652456

push

github

web-flow
Add fast-path parameter binding (#14782)

* Add fast-path parameter binding

The new `ParameterExpresion.bind_all` is a fast path for producing a
numeric result.  This has a couple of advantages over
`ParameterExpression.bind`:

- we can allocate fewer objects, since we do not need to allocate output
  name names, or other deeper metadata involved in the
  `ParameterExpression` struct

- we have no historical API reasons to scan through the incoming mapping
  looking for invalid keys or values.  This is a huge performance
  improvement for the case of using the same mapping to bind many
  different expressions (though there are always ways that
  `ParameterExpression.bind` could be improved in-place without breaking
  its API).

There is still a sizeable amount of performance gain to be had, because
the interfaces in the Rust-space `ParameterExpression` and `SymbolExpr`
require rather more heap allocations per binding call than are entirely
necessary.  That said, this already provides a large performance
improvement, and a complexity improvement for the case of a large values
dictionary being used many times.

* Remove unnecessary lifetime

* Add comment on non-finite values

14 of 17 new or added lines in 1 file covered. (82.35%)

10 existing lines in 2 files now uncovered.

91011 of 102905 relevant lines covered (88.44%)

482630.27 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

82.79
/crates/circuit/src/parameter/parameter_expression.rs


Source Not Available

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc