Skip to content

Use unsigned comparison operators for unsigned SIMD types.#21720

Merged
alexcrichton merged 1 commit intorust-lang:masterfrom
huonw:simd-cmp
Jan 31, 2015
Merged

Use unsigned comparison operators for unsigned SIMD types.#21720
alexcrichton merged 1 commit intorust-lang:masterfrom
huonw:simd-cmp

Conversation

@huonw
Copy link
Contributor

@huonw huonw commented Jan 28, 2015

Previously comparisons of SIMD types were always signed, even unsigned
comparisons, meaning 0xFFFF_FFFF_u32 < 0 inside a SIMD vector.

Fixes #21719.

@rust-highfive
Copy link
Contributor

r? @alexcrichton

(rust_highfive has picked a reviewer for you, use r? to override)

@sanxiyn
Copy link
Contributor

sanxiyn commented Jan 28, 2015

@bors r+ 5487422

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! I did something similar in my branch, though I had all the matching in another function and only needed the signedness from this one.

Previously comparisons of SIMD types were always signed, even unsigned
comparisons, meaning 0xFFFF_FFFF_u32 < 0 inside a SIMD vector.

Fixes rust-lang#21719.
@huonw
Copy link
Contributor Author

huonw commented Jan 28, 2015

@bors r=sanxiyn 76d66ba

alexcrichton added a commit to alexcrichton/rust that referenced this pull request Jan 30, 2015
Previously comparisons of SIMD types were always signed, even unsigned
comparisons, meaning 0xFFFF_FFFF_u32 < 0 inside a SIMD vector.

Fixes rust-lang#21719.
@alexcrichton alexcrichton merged commit 76d66ba into rust-lang:master Jan 31, 2015
lnicola pushed a commit to lnicola/rust that referenced this pull request Feb 28, 2026
Migrate `generate_derive` assist to SyntaxEditor
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.

SIMD comparison operators are always signed.

6 participants