[all-commits] [llvm/llvm-project] 668045: [VPlan] Unify Value2VPValue and VPExternalDefs map...

Florian Hahn via All-commits all-commits at lists.llvm.org
Sun Apr 16 07:38:56 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 668045eb77628be13e448ffbb855473ffca1cc43
      https://github.com/llvm/llvm-project/commit/668045eb77628be13e448ffbb855473ffca1cc43
  Author: Florian Hahn <flo at fhahn.com>
  Date:   2023-04-16 (Sun, 16 Apr 2023)

  Changed paths:
    M llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
    M llvm/lib/Transforms/Vectorize/VPlan.cpp
    M llvm/lib/Transforms/Vectorize/VPlan.h
    M llvm/lib/Transforms/Vectorize/VPlanHCFGBuilder.cpp
    M llvm/lib/Transforms/Vectorize/VPlanTransforms.cpp
    M llvm/unittests/Transforms/Vectorize/VPlanHCFGTest.cpp
    M llvm/unittests/Transforms/Vectorize/VPlanTest.cpp

  Log Message:
  -----------
  [VPlan] Unify Value2VPValue and VPExternalDefs maps (NFCI).

Before this patch, a VPlan contained 2 mappings for Values -> VPValue:
1) Value2VPValue and 2) VPExternalDefs.

This duplication is unnecessary and there are already cases where
external defs are added to Value2VPValue. This patch replaces all uses
of VPExternalDefs with Value2VPValue.

It clarifies the naming of getOrAddVPValue (to getOrAddExternalVPValue)
and addVPValue (to addExternalVPValue).

At the moment, this is NFC, but will enable additional simplifications
in D147783.

Depends on D147891.

Reviewed By: Ayal

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




More information about the All-commits mailing list