Skip to content

Proposal: improve @clz, @ctz and @popCount builtins #7936

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

Closed
data-man opened this issue Feb 2, 2021 · 2 comments
Closed

Proposal: improve @clz, @ctz and @popCount builtins #7936

data-man opened this issue Feb 2, 2021 · 2 comments
Milestone

Comments

@data-man
Copy link
Contributor

data-man commented Feb 2, 2021

Change:

@clz(comptime T: type, integer: T)
@ctz(comptime T: type, integer: T)
@popCount(comptime T: type, integer: T)

to

@clz(value: anytype)
@ctz(value: anytype)
@popCount(value: anytype)

Because llvm.ctlz, llvm.cttz and llvm.ctpop supports vectors with integer element type.

It's breaking changes.

@LemonBoy
Copy link
Contributor

LemonBoy commented Feb 2, 2021

You've already proposed this in #6835...

@data-man
Copy link
Contributor Author

data-man commented Feb 2, 2021

Sorry. :(

@data-man data-man closed this as completed Feb 2, 2021
@andrewrk andrewrk added this to the 0.8.0 milestone Jun 4, 2021
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

No branches or pull requests

3 participants