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

clearing bit utils #2301

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

DenisYaroshevskiy
Copy link
Contributor

Summary:
make_maskl
make_maskr
set_lzero
set_lone
set_rzero
set_lone

Simple utils that correctly handle corner cases, such as shift == 64.
I looked at the assembly a bit, probably that's ok.
For x86 I used bmi2 where was appropriate.

Differential Revision: D63329499

@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D63329499

@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D63329499

DenisYaroshevskiy added a commit to DenisYaroshevskiy/folly that referenced this pull request Sep 26, 2024
Summary:
Pull Request resolved: facebook#2301

make_maskl
make_maskr
set_lzero
set_lone
set_rzero
set_lone

Simple utils that correctly handle corner cases, such as shift == 64.
I looked at the assembly a bit, probably that's ok.
For x86 I used bmi2 where was appropriate.

Differential Revision: D63329499
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D63329499

DenisYaroshevskiy added a commit to DenisYaroshevskiy/folly that referenced this pull request Sep 27, 2024
Summary:
Pull Request resolved: facebook#2301

make_maskl
make_maskr
set_lzero
set_lone
set_rzero
set_lone

Simple utils that correctly handle corner cases, such as shift == 64.
I looked at the assembly a bit, probably that's ok.
For x86 I used bmi2 where was appropriate.

Differential Revision: D63329499
Summary:
Pull Request resolved: facebook#2301

n_least_significant_bits
n_most_significant_bits

clear_n_least_significant_bits
set_n_least_significant_bits
clear_n_most_significant_bits
set_n_most_significant_bits

Simple utils that correctly handle corner cases, such as shift == 64.
I looked at the assembly a bit, probably that's ok.
For x86 I used bmi2 where was appropriate.

Differential Revision: D63329499
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D63329499

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants