flat assembler
Message board for the users of flat assembler.
Index
> Main > SSE3 max value for signed bytes |
Author |
|
Overclick 01 Jul 2022, 03:21
Or I can PADDB 128 for each byte, then PMAXUB, then PSUBB 128...
Even better sub 128 from last byte at the end... |
|||
01 Jul 2022, 03:21 |
|
macomics 01 Jul 2022, 03:30
Code: PCMPGTB dest, src PAND dest, result PANDN src, result POR dest, src |
|||
01 Jul 2022, 03:30 |
|
Overclick 01 Jul 2022, 03:43
That is exactly as I said in my first thinks. But second one is more than twice faster. After first check it needs only one instruction to run -- PMAXUB. Just checked Agners tables, the result should be super fast.
|
|||
01 Jul 2022, 03:43 |
|
macomics 01 Jul 2022, 05:15
Overclick wrote: PAND to first source, then PANDN to second first = src. second = dest - this is the reverse order. Besides, there was a question at the end. I specified how to do it correctly. |
|||
01 Jul 2022, 05:15 |
|
Overclick 01 Jul 2022, 05:55
Oh ok, thanks. I used this numeration:
https://www.officedaytime.com/simd512e/simdimg/pcmp.php?f=pcmpgtb |
|||
01 Jul 2022, 05:55 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.