Faster Positional-Population Counts for AVX2, AVX-512, and ASIMD

Fuente: arXiv
Guardado en:
Detalles Bibliográficos
Autores principales: Clausecker, Robert, Lemire, Daniel, Schintke, Florian
Formato: Preprint
Publicado: 2024
Materias:
Acceso en línea:
Etiquetas: Agregar Etiqueta
Sin Etiquetas, Sea el primero en etiquetar este registro!
_version_ 1866914373618892800
author Clausecker, Robert
Lemire, Daniel
Schintke, Florian
author_facet Clausecker, Robert
Lemire, Daniel
Schintke, Florian
contents The positional population count operation pospopcnt() counts for an array of w-bit words how often each of the w bits was set. Various applications in bioinformatics, database engineering, and digital processing exist. Building on earlier work by Klarqvist et al., we show how positional population counts can be rapidly computed using SIMD techniques with good performance from the first byte, approaching memory-bound speeds for input arrays of as little as 4 KiB. Improvements include an improved algorithm structure, better handling of unaligned and very short arrays, as well as faster bit-parallel accumulation of intermediate results. We provide a generic algorithm description as well as implementations for various SIMD instruction set extensions, including Intel AVX2, AVX-512, and ARM ASIMD, and discuss the adaption of our algorithm to other platforms.
format Preprint
id arxiv_https___arxiv_org_abs_2412_16370
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle Faster Positional-Population Counts for AVX2, AVX-512, and ASIMD
Clausecker, Robert
Lemire, Daniel
Schintke, Florian
Data Structures and Algorithms
The positional population count operation pospopcnt() counts for an array of w-bit words how often each of the w bits was set. Various applications in bioinformatics, database engineering, and digital processing exist. Building on earlier work by Klarqvist et al., we show how positional population counts can be rapidly computed using SIMD techniques with good performance from the first byte, approaching memory-bound speeds for input arrays of as little as 4 KiB. Improvements include an improved algorithm structure, better handling of unaligned and very short arrays, as well as faster bit-parallel accumulation of intermediate results. We provide a generic algorithm description as well as implementations for various SIMD instruction set extensions, including Intel AVX2, AVX-512, and ARM ASIMD, and discuss the adaption of our algorithm to other platforms.
title Faster Positional-Population Counts for AVX2, AVX-512, and ASIMD
topic Data Structures and Algorithms
url https://arxiv.org/abs/2412.16370