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

Fail partial eval with error on Result literals #1409

Merged
merged 3 commits into from
Apr 26, 2024

Conversation

swernli
Copy link
Collaborator

@swernli swernli commented Apr 22, 2024

This change adds an error case that fails partial evaluation if any part of the output includes Result literals One or Zero. This matches the support in QIR, where result literals cannot be recorded as output.

This change adds an error case that fails partial evaluation if any part of the output includes Result literals `One` or `Zero`. This matches the support in QIR, where result literals cannot be recorded as output.
@swernli swernli mentioned this pull request Apr 22, 2024
64 tasks
Copy link

Benchmark for 97d7198

Click to view benchmark
Test Base PR %
Array append evaluation 344.8±5.11µs 337.5±1.68µs -2.12%
Array literal evaluation 207.4±1.97µs 174.3±5.02µs -15.96%
Array update evaluation 428.3±3.43µs 421.1±3.57µs -1.68%
Core + Standard library compilation 16.7±0.13ms 17.3±0.51ms +3.59%
Deutsch-Jozsa evaluation 5.1±0.06ms 5.1±0.06ms 0.00%
Large file parity evaluation 33.8±0.93ms 33.5±0.08ms -0.89%
Large input file compilation 11.3±0.18ms 11.5±0.32ms +1.77%
Large input file compilation (interpreter) 43.6±0.90ms 45.9±1.97ms +5.28%
Large nested iteration 33.3±0.30ms 32.9±0.35ms -1.20%
Perform Runtime Capabilities Analysis (RCA) on Deutsch-Jozsa sample 1492.6±31.31µs 1499.3±39.94µs +0.45%
Perform Runtime Capabilities Analysis (RCA) on large file sample 7.8±0.10ms 7.8±0.09ms 0.00%
Perform Runtime Capabilities Analysis (RCA) on teleport sample 1409.1±35.57µs 1419.4±49.26µs +0.73%
Perform Runtime Capabilities Analysis (RCA) on the core and std libraries 21.4±0.19ms 21.6±0.23ms +0.93%
Teleport evaluation 83.2±4.10µs 83.8±6.98µs +0.72%

@swernli swernli enabled auto-merge April 24, 2024 05:30
Copy link

Benchmark for 387db64

Click to view benchmark
Test Base PR %
Array append evaluation 337.7±9.18µs 340.8±6.53µs +0.92%
Array literal evaluation 176.8±2.17µs 189.8±2.29µs +7.35%
Array update evaluation 417.3±1.69µs 422.0±6.11µs +1.13%
Core + Standard library compilation 17.6±0.84ms 17.3±0.61ms -1.70%
Deutsch-Jozsa evaluation 5.0±0.05ms 5.0±0.17ms 0.00%
Large file parity evaluation 33.5±0.12ms 33.6±0.45ms +0.30%
Large input file compilation 11.6±0.50ms 11.7±0.35ms +0.86%
Large input file compilation (interpreter) 48.4±1.81ms 46.3±2.26ms -4.34%
Large nested iteration 32.7±0.19ms 33.2±0.71ms +1.53%
Perform Runtime Capabilities Analysis (RCA) on Deutsch-Jozsa sample 1541.8±117.57µs 1514.0±58.31µs -1.80%
Perform Runtime Capabilities Analysis (RCA) on large file sample 8.0±0.16ms 7.8±0.10ms -2.50%
Perform Runtime Capabilities Analysis (RCA) on teleport sample 1434.3±71.29µs 1423.9±33.18µs -0.73%
Perform Runtime Capabilities Analysis (RCA) on the core and std libraries 21.6±0.34ms 21.5±0.22ms -0.46%
Teleport evaluation 82.0±8.59µs 80.1±4.43µs -2.32%

@swernli swernli added this pull request to the merge queue Apr 25, 2024
Merged via the queue into main with commit e8b824c Apr 26, 2024
17 checks passed
@swernli swernli deleted the swernli/partial-eval-output-literal-error branch April 26, 2024 00:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants