[llvm] [VPlan] Add initial anlysis to infer scalar type of VPValues. (PR #69013)

via llvm-commits llvm-commits at lists.llvm.org
Sun Oct 22 12:50:18 PDT 2023


================
@@ -2080,7 +2082,7 @@ class VPCanonicalIVPHIRecipe : public VPHeaderPHIRecipe {
 #endif
 
   /// Returns the scalar type of the induction.
-  const Type *getScalarType() const {
+  Type *getScalarType() const {
     return getOperand(0)->getLiveInIRValue()->getType();
----------------
ayalz wrote:

```suggestion
    return getStartValue()->getLiveInIRValue()->getType();
```
while we're here

https://github.com/llvm/llvm-project/pull/69013


More information about the llvm-commits mailing list