Skip to content

Run product state functions inplace to avoid copies where possible#6396

Merged
tanujkhattar merged 4 commits intoquantumlib:mainfrom
daxfohl:inline-transform
Feb 3, 2024
Merged

Run product state functions inplace to avoid copies where possible#6396
tanujkhattar merged 4 commits intoquantumlib:mainfrom
daxfohl:inline-transform

Conversation

@daxfohl
Copy link
Copy Markdown
Collaborator

@daxfohl daxfohl commented Jan 6, 2024

A few places were not running inplace. This PR has them run inplace so to avoid unnecessary copies.

@daxfohl daxfohl requested review from a team, cduck and vtomole as code owners January 6, 2024 05:54
@codecov
Copy link
Copy Markdown

codecov bot commented Jan 6, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (ee56c59) 97.81% compared to head (00837b8) 97.81%.
Report is 4 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #6396   +/-   ##
=======================================
  Coverage   97.81%   97.81%           
=======================================
  Files        1111     1111           
  Lines       97121    97167   +46     
=======================================
+ Hits        95000    95047   +47     
+ Misses       2121     2120    -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@CirqBot CirqBot added the size: S 10< lines changed <50 label Feb 1, 2024
@tanujkhattar tanujkhattar enabled auto-merge (squash) February 2, 2024 23:49
@tanujkhattar tanujkhattar merged commit 5dd05bf into quantumlib:main Feb 3, 2024
harry-phasecraft pushed a commit to PhaseCraft/Cirq that referenced this pull request Oct 31, 2024
…uantumlib#6396)

* Run product state merges inplace to avoid copies

* rename to merged_state

* comment
@daxfohl daxfohl deleted the inline-transform branch January 10, 2025 05:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size: S 10< lines changed <50

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants