Skip to content
This repository was archived by the owner on May 27, 2024. It is now read-only.

Add Shift-Right, Shift-Left, and XOR - #2

Open
rsaxvc wants to merge 1 commit into
Maratyszcza:masterfrom
rsaxvc:master
Open

Add Shift-Right, Shift-Left, and XOR#2
rsaxvc wants to merge 1 commit into
Maratyszcza:masterfrom
rsaxvc:master

Conversation

@rsaxvc

@rsaxvc rsaxvc commented Aug 3, 2018

Copy link
Copy Markdown

Add a few more bit-twiddling operations

@Maratyszcza

Copy link
Copy Markdown
Owner

sr and sl are too ambiguous, could you change to shr/shl, or shiftr/shiftl?

@rsaxvc

rsaxvc commented Aug 23, 2018

Copy link
Copy Markdown
Author

Changed to shr/shl

Comment thread include/psimd.h Outdated

/* Vector shift right */
PSIMD_INTRINSIC psimd_s8 psimd_shr_s8(psimd_s8 a, uint32_t b) {
return a >> b;

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Clang before 4.0 requires both parts of a >> operator to be vectors, so you should use a >> psimd_splat_s8((int8_t) b)

@breznak

breznak commented Jul 11, 2019

Copy link
Copy Markdown

@Maratyszcza can you merge this change?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants