Skip to content

Commit

Permalink
Expose cobra_apply for fast bit reverseal
Browse files Browse the repository at this point in the history
  • Loading branch information
smu160 committed Feb 12, 2024
1 parent e5e60c5 commit 356cd6a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cobra.rs
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ pub(crate) fn bit_reverse_permutation<T>(buf: &mut [T]) {
/// [2] Christian Knauth, Boran Adas, Daniel Whitfield, Xuesong Wang, Lydia Ickler, Tim Conrad, Oliver Serang:
/// Practically efficient methods for performing bit-reversed permutation in C++11 on the x86-64 architecture
/// [3] <https://bitbucket.org/orserang/bit-reversal-methods/src/master/src_and_bin/src/algorithms/COBRAShuffle.hpp>
pub(crate) fn cobra_apply<T: Default + Copy + Clone>(v: &mut [T], log_n: usize) {
pub fn cobra_apply<T: Default + Copy + Clone>(v: &mut [T], log_n: usize) {
if log_n <= 2 * LOG_BLOCK_WIDTH {
bit_rev(v, log_n);
return;
Expand Down

0 comments on commit 356cd6a

Please sign in to comment.