-
Notifications
You must be signed in to change notification settings - Fork 86
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add helper methods to dynamic Dory structure (PROOF-919) (#198)
# Rationale for this change The GPU implementation of the dynamic Dory commitment computation requires a number of helper methods in the dynamic Dory structure. This PR implements methods that will be used by the GPU implementation. # What changes are included in this PR? - Add `index_from_row_and_column` method which is the inverse of `row_and_column_from_index` method. Given a `row` and `column` it will provide the `index` of the original data. The method also handles cases where `row` and `column` do not provide a valid `index`. - Add `matrix_size` method which returns the width and height of the dynamic Dory matrix structure that will hold the given data. - Made helper methods `const` for compile-time evaluation. - Add temporary `#[allow(dead_code)]` to address `cargo clippy` warnings - these will be removed when the dynamic Dory commit computation is implemented for the GPU. # Are these changes tested? Yes
- Loading branch information
1 parent
be2fbf2
commit 3fb460f
Showing
1 changed file
with
159 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters