How branch mispredictions affect quicksort

被引:0
|
作者
Kaligosi, Kanela [1 ]
Sanders, Peter
机构
[1] Max Planck Inst Informat, Saarbrucken, Germany
[2] Univ Karlsruhe, Karlsruhe, Germany
来源
关键词
D O I
暂无
中图分类号
TP301 [理论、方法];
学科分类号
081202 ;
摘要
We explain the counterintuitive observation that finding "good" pivots (close to the median of the array to be partitioned) may not improve performance of quicksort. Indeed, an intentionally skewed pivot improves performance. The reason is that while the instruction count decreases with the quality of the pivot, the likelihood that the direction of a branch is mispredicted also goes up. We analyze the effect of simple branch prediction schemes and measure the effects on real hardware.
引用
收藏
页码:780 / 791
页数:12
相关论文
共 50 条
  • [1] Dynamic Analysis of Branch Mispredictions in Ada
    Lathrop, Steven M.
    SIGADA 2009: PROCEEDINGS OF THE ACM INTERNATIONAL CONFERENCE ON ADA AND RELATED TECHNOLOGIES, 2009, : 79 - 84
  • [2] Automatic Source Code Analysis of Branch Mispredictions
    Ozturk, Celal
    Karsli, Ibrahim Burak
    Sendag, Resit
    2014 IEEE INTERNATIONAL SYMPOSIUM ON WORKLOAD CHARACTERIZATION (IISWC), 2014, : 82 - 83
  • [3] A taxonomy of branch mispredictions, and alloyed prediction as a robust solution to wrong-history mispredictions
    Skadron, K
    Martonosi, M
    Clark, DW
    2000 INTERNATIONAL CONFERENCE ON PARALLEL ARCHITECTURES AND COMPILATION TECHNIQUES, PROCEEDINGS, 2000, : 199 - 206
  • [4] Tradeoffs between branch mispredictions and comparisons for sorting algorithms
    Brodal, GS
    Moruz, G
    ALGORITHMS AND DATA STRUCTURES, PROCEEDINGS, 2005, 3608 : 385 - 395
  • [5] Reducing indirect mispredictions of two-stage branch predictors
    Chu, Y
    Ito, MR
    HIGH PERFORMANCE COMPUTING SYSTEMS AND APPLICATIONS, 2002, 657 : 187 - 205
  • [6] Dataflow analysis of branch mispredictions and its application to early resolution of branch outcomes
    Farcy, A
    Temam, O
    Espasa, R
    Juan, T
    31ST ANNUAL ACM/IEEE INTERNATIONAL SYMPOSIUM ON MICROARCHITECTURE, PROCEEDINGS, 1998, : 59 - 68
  • [7] Faster Set Intersection with SIMD instructions by Reducing Branch Mispredictions
    Inoue, Hiroshi
    Ohara, Moriyoshi
    Taura, Kenjiro
    PROCEEDINGS OF THE VLDB ENDOWMENT, 2014, 8 (03): : 293 - 304
  • [8] Affect, empathy, and regressive mispredictions of others' preferences under risk
    Faro, D
    Rottenstreich, Y
    MANAGEMENT SCIENCE, 2006, 52 (04) : 529 - 541
  • [9] How Good Is Multi-Pivot Quicksort?
    Aumuller, Martin
    Dietzfelbinger, Martin
    Klaue, Pascal
    ACM TRANSACTIONS ON ALGORITHMS, 2016, 13 (01)
  • [10] HOW MANY COMPARISONS DOES QUICKSORT USE
    EDDY, WF
    SCHERVISH, MJ
    JOURNAL OF ALGORITHMS, 1995, 19 (03) : 402 - 431