Home
last modified time | relevance | path

Searched refs:ConstantSubscripts (Results 1 – 22 of 22) sorted by relevance

/llvm-project-15.0.7/flang/include/flang/Evaluate/
H A Dconstant.h45 inline int GetRank(const ConstantSubscripts &s) { in GetRank()
57 bool HasNegativeExtent(const ConstantSubscripts &);
63 explicit ConstantBounds(ConstantSubscripts &&shape);
68 void set_lbounds(ConstantSubscripts &&);
85 ConstantSubscripts shape_;
86 ConstantSubscripts lbounds_;
147 Element At(const ConstantSubscripts &) const;
149 Constant Reshape(ConstantSubscripts &&) const;
185 Scalar<Result> At(const ConstantSubscripts &) const;
190 Constant Reshape(ConstantSubscripts &&) const;
[all …]
H A Dshape.h46 Constant<ExtentType> AsConstantShape(const ConstantSubscripts &);
48 ConstantSubscripts AsConstantExtents(const Constant<ExtentType> &);
49 std::optional<ConstantSubscripts> AsConstantExtents(
51 Shape AsShape(const ConstantSubscripts &);
52 std::optional<Shape> AsShape(const std::optional<ConstantSubscripts> &);
109 ConstantSubscript GetSize(const ConstantSubscripts &);
254 std::optional<ConstantSubscripts> GetConstantExtents( in GetConstantExtents()
303 ConstantSubscripts &, const ConstantSubscripts &extents);
H A Dtools.h1034 explicit ScalarConstantExpander(ConstantSubscripts &&extents) in ScalarConstantExpander()
1037 ConstantSubscripts &&extents, std::optional<ConstantSubscripts> &&lbounds) in ScalarConstantExpander()
1040 ConstantSubscripts &&extents, ConstantSubscripts &&lbounds) in ScalarConstantExpander()
1063 ConstantSubscripts extents_;
1064 std::optional<ConstantSubscripts> lbounds_;
1072 const Constant<T> &reference, const ConstantSubscripts &shape) { in PackageConstant()
1075 reference.LEN(), std::move(elements), ConstantSubscripts{shape}}; in PackageConstant()
1078 std::move(elements), ConstantSubscripts{shape}}; in PackageConstant()
1080 return Constant<T>{std::move(elements), ConstantSubscripts{shape}}; in PackageConstant()
H A Dinitial-image.h108 const DynamicType &, const ConstantSubscripts &, bool padWithZero = false,
/llvm-project-15.0.7/flang/lib/Evaluate/
H A Dconstant.cpp17 ConstantBounds::ConstantBounds(const ConstantSubscripts &shape) in ConstantBounds()
20 ConstantBounds::ConstantBounds(ConstantSubscripts &&shape) in ConstantBounds()
25 void ConstantBounds::set_lbounds(ConstantSubscripts &&lb) { in set_lbounds()
35 ConstantSubscripts ConstantBounds::ComputeUbounds( in ComputeUbounds()
41 ConstantSubscripts ubounds(Rank()); in ComputeUbounds()
60 const ConstantSubscripts &index) const { in SubscriptsToOffset()
116 bool HasNegativeExtent(const ConstantSubscripts &shape) { in HasNegativeExtent()
161 ConstantSubscripts sourceSubscripts{source.lbounds()}; in CopyFrom()
267 ConstantSubscripts &&dims) const -> Constant<Result> { in Reshape()
297 ConstantSubscripts sourceSubscripts{source.lbounds()}; in CopyFrom()
[all …]
H A Dfold-reduction.h25 std::optional<ActualArgument> &maskArg, const ConstantSubscripts &shape,
63 ConstantSubscripts at{folded->lbounds()};
72 std::move(elements), ConstantSubscripts{folded->shape()}};
75 std::move(elements), ConstantSubscripts{folded->shape()}};
91 ConstantSubscripts at{array.lbounds()}; in DoReduction()
93 ConstantSubscripts resultShape; // empty -> scalar in DoReduction()
135 auto accumulator{[&](Element &element, const ConstantSubscripts &at) { in FoldMaxvalMinval()
163 auto accumulator{[&](Element &element, const ConstantSubscripts &at) { in FoldProduct()
197 auto accumulator{[&](Element &element, const ConstantSubscripts &at) { in FoldSum()
H A Dfold-implementation.h200 ConstantSubscripts resultShape; in ApplySubscripts()
201 ConstantSubscripts ssLB; in ApplySubscripts()
469 ConstantSubscripts shape; in FoldElementalIntrinsicHelper()
617 ConstantSubscripts arrayAt{arrayLB}; in CSHIFT()
624 ConstantSubscripts shiftAt; in CSHIFT()
725 ConstantSubscripts arrayAt{arrayLB}; in EOSHIFT()
730 ConstantSubscripts boundaryLB; in EOSHIFT()
736 ConstantSubscripts shiftAt; in EOSHIFT()
750 ConstantSubscripts boundaryAt; in EOSHIFT()
953 ConstantSubscripts at(2); in TRANSPOSE()
[all …]
H A Dfold.cpp57 ConstantSubscripts{ in GetConstantSubscript()
243 std::optional<ConstantSubscripts> extents; in FoldTransfer()
247 extents = ConstantSubscripts{}; // empty extents (scalar result) in FoldTransfer()
252 extents = ConstantSubscripts{ in FoldTransfer()
261 extents = ConstantSubscripts{*sizeValue}; in FoldTransfer()
H A Dfold-integer.cpp19 const ConstantSubscripts &&bounds, bool asScalar = false) { in PackageConstantBounds()
28 return Expr<T>{Constant<T>{std::move(packed), ConstantSubscripts{rank}}}; in PackageConstantBounds()
57 template <typename T> ConstantSubscripts Get(const T &) { in Get()
64 template <typename T> ConstantSubscripts Get(const Constant<T> &x) { in Get()
87 template <typename T> ConstantSubscripts Get(const Parentheses<T> &x) { in Get()
91 return ConstantSubscripts(x.Rank(), ConstantSubscript{1}); in Get()
100 template <typename T> ConstantSubscripts Get(const Expr<T> &x) { in Get()
158 ConstantSubscripts ones(rank, ConstantSubscript{1}); in LBOUND()
323 std::move(mask_elements), ConstantSubscripts{n}}; in Test()
369 resultShape = ConstantSubscripts{array->Rank()}; // always a vector in Test()
[all …]
H A Dshape.cpp110 Constant<SubscriptInteger> AsConstantShape(const ConstantSubscripts &shape) { in AsConstantShape()
116 return {std::move(result), ConstantSubscripts{GetRank(shape)}}; in AsConstantShape()
119 ConstantSubscripts AsConstantExtents(const Constant<ExtentType> &shape) { in AsConstantExtents()
120 ConstantSubscripts result; in AsConstantExtents()
127 std::optional<ConstantSubscripts> AsConstantExtents( in AsConstantExtents()
136 Shape AsShape(const ConstantSubscripts &shape) { in AsShape()
144 std::optional<Shape> AsShape(const std::optional<ConstantSubscripts> &shape) { in AsShape()
210 ConstantSubscript GetSize(const ConstantSubscripts &shape) { in GetSize()
1028 ConstantSubscripts &indices, const ConstantSubscripts &extents) { in IncrementSubscripts()
H A Dinitial-image.cpp74 const ConstantSubscripts &extents, const InitialImage &image, in AsConstantHelper()
184 ConstantSubscripts extents_; // a copy
190 const DynamicType &type, const ConstantSubscripts &extents, in AsConstant()
H A Dfold-reduction.cpp34 std::optional<ActualArgument> &maskArg, const ConstantSubscripts &shape, in GetReductionMASK()
H A Dfold-logical.cpp22 Constant<LargestInt>(std::move(exts), ConstantSubscripts(c.shape()))); in ZeroExtend()
36 auto accumulator{[&](Element &element, const ConstantSubscripts &at) { in FoldAllAny()
H A Dcheck-expression.cpp367 ArrayConstantBoundChanger(ConstantSubscripts &&lbounds) in ArrayConstantBoundChanger()
388 ConstantSubscripts &&lbounds_;
H A Dfold-designator.cpp368 ConstantSubscripts at(rank, 1); in From()
H A Dfold-real.cpp36 std::move(results), ConstantSubscripts{std::max(n2 - n1 + 1, 0)}}}; in FoldTransformationalBessel()
H A Dformatting.cpp23 llvm::raw_ostream &o, const ConstantSubscripts &shape) { in ShapeAsFortran()
H A Dintrinsics.cpp1524 shapeArgSize = constShape->At(ConstantSubscripts{1}).ToInt64(); in Match()
/llvm-project-15.0.7/flang/lib/Semantics/
H A Druntime-type-info.cpp280 std::move(x), evaluate::ConstantSubscripts{elements}})); in SaveNumericPointerTarget()
295 evaluate::ConstantSubscripts &&shape) { in SaveDerivedPointerTarget()
548 evaluate::ConstantSubscripts{ in DescribeType()
554 evaluate::ConstantSubscripts{ in DescribeType()
563 evaluate::ConstantSubscripts{ in DescribeType()
594 evaluate::ConstantSubscripts{ in DescribeType()
788 evaluate::ConstantSubscripts{ in DescribeComponent()
812 std::move(bounds), evaluate::ConstantSubscripts{2, rank})); in DescribeComponent()
/llvm-project-15.0.7/flang/include/flang/Lower/
H A DMangler.h64 const Fortran::evaluate::ConstantSubscripts &shape,
/llvm-project-15.0.7/flang/lib/Lower/
H A DMangler.cpp222 const Fortran::evaluate::ConstantSubscripts &shape, in mangleArrayLiteral()
H A DConvertExpr.cpp1632 Fortran::evaluate::ConstantSubscripts subscripts = con.lbounds(); in genArrayLit()
1663 Fortran::evaluate::ConstantSubscripts nextSubscripts = subscripts; in genArrayLit()
1714 Fortran::evaluate::ConstantSubscripts subscripts = con.lbounds(); in genArrayLit()
4090 if (std::optional<Fortran::evaluate::ConstantSubscripts> constantShape = in determineShapeOfDest()