x86 max/min asm instructions?

前端 未结 6 830
礼貌的吻别
礼貌的吻别 2021-02-06 06:55

Are there any asm instructions that can speed up computation of min/max of vector of doubles/integers on Core i7 architecture?

Update:

I didn\'t

6条回答
  •  庸人自扰
    2021-02-06 07:08

    In response to your second question, it may be worthwhile to you to think about the way you collect and store this data.

    You may store the data in a B-tree that keeps the data sorted at all times, requiring only logarithmic compare operations.

    Then you know at all times where the maximum is.

    http://en.wikipedia.org/wiki/B_tree

提交回复
热议问题