[llvm] [VPlan] First step towards VPlan cost modeling (LegacyCM in CostCtx) (PR #92555)
via llvm-commits
llvm-commits at lists.llvm.org
Thu May 23 05:04:49 PDT 2024
================
@@ -1472,3 +1555,16 @@ VPValue *vputils::getOrCreateVPValueForSCEVExpr(VPlan &Plan, const SCEV *Expr,
Plan.addSCEVExpansion(Expr, Expanded);
return Expanded;
}
+
+bool vputils::isUniformCompare(VPValue *Cond) {
----------------
ayalz wrote:
This checks not only if Cond is a (uniform) compare, but also if it's live-in, and the negation of a uniform compare or live-in. In general, it should probably detect uniform i1 VPValues, to infer that branches using them are uniform, and may be computed by compares and/or boolean operators. I.e., `isUniformBoolean()`?
https://github.com/llvm/llvm-project/pull/92555
More information about the llvm-commits
mailing list