[SelectOpti][3/5] Base Heuristics
authorSotiris Apostolakis <apostolakis@google.com>
Mon, 23 May 2022 20:26:09 +0000 (16:26 -0400)
committerSotiris Apostolakis <apostolakis@google.com>
Tue, 24 May 2022 02:01:12 +0000 (22:01 -0400)
commit8b42bc5662ca13c97746b7301bd503b2662dc444
treeb352307cd9758479ff53618437a6b596bb003f0b
parentc0ec1036d6532143998fa393b5a469b4a5e964ff
[SelectOpti][3/5] Base Heuristics

This patch adds the base heuristics for determining whether branches are more profitable than conditional moves.
Base heuristics apply to all code apart from inner-most loops.

Depends on D122259

Reviewed By: davidxl

Differential Revision: https://reviews.llvm.org/D120231
llvm/lib/CodeGen/SelectOptimize.cpp
llvm/test/CodeGen/X86/select-optimize.ll