-
Notifications
You must be signed in to change notification settings - Fork 396
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
AArch64: Implement arraycmp evaluator
This commit implements arraycmp evaluator. It implements two variants. One of them returns the length of the identical data from the beginning of the arrays. The other returns 2/0/1 when the first array is greater than/equal to/less than the second array. The main loop reads a 16-byte chunk from the both array in a single interation. It uses ldp instruction to read 16-byte data into two 64-bit registers. Then, it compares each 64-bit registers to find mismatch. If any mismatch is found in 16-byte chunks, the bit position of the first mismatch is searched by clz instruction for the variant returning the length. If no mismatch is found in 16-byte chunks and there is still remaining data to be compared (which is smaller than 16 bytes), the secondary loop, which reads a single byte in each iteration, is executed. Signed-off-by: Akira Saitoh <[email protected]>
- Loading branch information
Akira Saitoh
committed
Feb 28, 2023
1 parent
084e87a
commit 80ec4b1
Showing
2 changed files
with
360 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters