Faster Population Counts Using AVX2 Instructions

被引:30
|
作者
Mula, Wojciech [1 ]
Kurz, Nathan [1 ]
Lemire, Daniel [1 ]
机构
[1] Univ Quebec TELUQ, 5800 St Denis, Montreal, PQ H2S 3L5, Canada
来源
COMPUTER JOURNAL | 2018年 / 61卷 / 01期
基金
加拿大自然科学与工程研究理事会;
关键词
software performance; SIMD instructions; vectorization; bitset; Jaccard index;
D O I
10.1093/comjnl/bxx046
中图分类号
TP3 [计算技术、计算机技术];
学科分类号
0812 ;
摘要
Counting the number of ones in a binary stream is a common operation in database, information-retrieval, cryptographic and machine-learning applications. Most processors have dedicated instructions to count the number of ones in a word (e.g. popcnt on x64 processors). Maybe surprisingly, we show that a vectorized approach using SIMD instructions can be twice as fast as using the dedicated instructions on recent Intel processors. The benefits can be even greater for applications such as similarity measures (e.g. the Jaccard index) that require additional Boolean operations. Our approach has been adopted by LLVM: it is used by its popular C compiler (Clang).
引用
收藏
页码:111 / 120
页数:10
相关论文
共 50 条
  • [41] Estimating population abundance using counts from an auxiliary population
    Matthew R. P. Parker
    Vivian Pattison
    Laura L. E. Cowen
    Environmental and Ecological Statistics, 2020, 27 : 509 - 526
  • [42] Estimating population abundance using counts from an auxiliary population
    Parker, Matthew R. P.
    Pattison, Vivian
    Cowen, Laura L. E.
    ENVIRONMENTAL AND ECOLOGICAL STATISTICS, 2020, 27 (03) : 509 - 526
  • [43] Faster multiplication over F2[X] sing AVX512 instruction set and VPCLMULQDQ instruction
    Robert, Jean-Marc
    Veron, Pascal
    JOURNAL OF CRYPTOGRAPHIC ENGINEERING, 2023, 13 (01) : 37 - 55
  • [44] Computing the sparse matrix vector product using block-based kernels without zero padding on processors with AVX-512 instructions
    Bramas, Berenger
    Kus, Pavel
    PEERJ COMPUTER SCIENCE, 2018,
  • [45] Estimating a Seal Population Using Automated Counts of Drone Photographs
    Hawkins, Samuel
    Lundberg, Allister
    Lundberg, Aiden
    Oliver, Guy
    Condit, Richard
    APPLICATIONS OF MACHINE LEARNING 2023, 2023, 12675
  • [46] Quantifying regional variation in population trends using migrating counts
    Crewe, Tara L.
    Taylor, Philip D.
    Lepage, Denis
    Smith, Adam C.
    Francis, Charles M.
    JOURNAL OF WILDLIFE MANAGEMENT, 2016, 80 (02): : 245 - 255
  • [47] C-reactive protein and leucocyte counts drop faster using the HeartShield® device in patients with DSWI
    Lindstedt, Sandra
    Malmsjo, Malin
    Ingemansson, Richard
    INTERNATIONAL WOUND JOURNAL, 2015, 12 (02) : 189 - 194
  • [48] Using citizen science butterfly counts to predict species population trends
    Dennis, Emily B.
    Morgan, Byron J. T.
    Brereton, Tom M.
    Roy, David B.
    Fox, Richard
    CONSERVATION BIOLOGY, 2017, 31 (06) : 1350 - 1361
  • [49] Using spotlight counts to estimate mule deer population size and trends
    Kie, JG
    Boroski, BB
    CALIFORNIA FISH AND GAME, 1995, 81 (02): : 55 - 70
  • [50] An empirical test of using counts of individuals captured as indices of population size
    Slade, NA
    Blair, SM
    JOURNAL OF MAMMALOGY, 2000, 81 (04) : 1035 - 1045