[all-commits] [llvm/llvm-project] cc3f40: [FuncSpec] Move invariant computation for spec cos...

Chuanqi Xu via All-commits all-commits at lists.llvm.org
Fri Aug 6 00:47:09 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: cc3f40bb41a7e818f68c9bda4457cb6776a183f3
      https://github.com/llvm/llvm-project/commit/cc3f40bb41a7e818f68c9bda4457cb6776a183f3
  Author: Chuanqi Xu <yedeng.yd at linux.alibaba.com>
  Date:   2021-08-06 (Fri, 06 Aug 2021)

  Changed paths:
    M llvm/lib/Transforms/IPO/FunctionSpecialization.cpp

  Log Message:
  -----------
  [FuncSpec] Move invariant computation for spec cost out of loop (NFC-ish)

Noticed that the computation for function specialization cost of a
function wouldn't change during the traversal of the arguments for the
function. We could hoist the computation out of the traversal. I
observed about ~1% improvement on compile time for spec2017. But I guess
it may not be precise. This should be NFC and fine.

Reviewed By: Sjoerd Meijer

Differential Revision: https://reviews.llvm.org/D107621




More information about the All-commits mailing list