Skip to content

Fix potential integer overflow in getContractedOffsets#368

Merged
mtfishman merged 1 commit intoITensor:v3from
kyungminlee:fix-integer-overflow
Oct 14, 2020
Merged

Fix potential integer overflow in getContractedOffsets#368
mtfishman merged 1 commit intoITensor:v3from
kyungminlee:fix-integer-overflow

Conversation

@kyungminlee
Copy link
Copy Markdown
Contributor

Change size of Csize from int to size_t.
With the int Csize on LP64, contraction throws std::length_error at bond dimension of around a few tens of thousands.
Addresses the following issue:
http://itensor.org/support/2604/issue-with-size-of-the-vector-in-large-bond-dimension

Change size of Csize from int to size_t.
@mtfishman
Copy link
Copy Markdown
Member

Looks reasonable, thanks!

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.

2 participants