Changeset View
Changeset View
Standalone View
Standalone View
llvm/include/llvm/Transforms/Utils/LoopUtils.h
Show First 20 Lines • Show All 293 Lines • ▼ Show 20 Lines | |||||
/// Generates an ordered vector reduction using extracts to reduce the value. | /// Generates an ordered vector reduction using extracts to reduce the value. | ||||
Value * | Value * | ||||
getOrderedReduction(IRBuilder<> &Builder, Value *Acc, Value *Src, unsigned Op, | getOrderedReduction(IRBuilder<> &Builder, Value *Acc, Value *Src, unsigned Op, | ||||
RecurrenceDescriptor::MinMaxRecurrenceKind MinMaxKind = | RecurrenceDescriptor::MinMaxRecurrenceKind MinMaxKind = | ||||
RecurrenceDescriptor::MRK_Invalid, | RecurrenceDescriptor::MRK_Invalid, | ||||
ArrayRef<Value *> RedOps = None); | ArrayRef<Value *> RedOps = None); | ||||
/// Generates a vector reduction using shufflevectors to reduce the value. | /// Generates a vector reduction using shufflevectors to reduce the value. | ||||
/// Fast-math-flags are propagated using the IRBuilder's setting. | |||||
Value *getShuffleReduction(IRBuilder<> &Builder, Value *Src, unsigned Op, | Value *getShuffleReduction(IRBuilder<> &Builder, Value *Src, unsigned Op, | ||||
RecurrenceDescriptor::MinMaxRecurrenceKind | RecurrenceDescriptor::MinMaxRecurrenceKind | ||||
MinMaxKind = RecurrenceDescriptor::MRK_Invalid, | MinMaxKind = RecurrenceDescriptor::MRK_Invalid, | ||||
FastMathFlags FMF = FastMathFlags(), | |||||
ArrayRef<Value *> RedOps = None); | ArrayRef<Value *> RedOps = None); | ||||
/// Create a target reduction of the given vector. The reduction operation | /// Create a target reduction of the given vector. The reduction operation | ||||
/// is described by the \p Opcode parameter. min/max reductions require | /// is described by the \p Opcode parameter. min/max reductions require | ||||
/// additional information supplied in \p Flags. | /// additional information supplied in \p Flags. | ||||
/// The target is queried to determine if intrinsics or shuffle sequences are | /// The target is queried to determine if intrinsics or shuffle sequences are | ||||
/// required to implement the reduction. | /// required to implement the reduction. | ||||
/// Fast-math-flags are propagated using the IRBuilder's setting. | |||||
Value *createSimpleTargetReduction(IRBuilder<> &B, | Value *createSimpleTargetReduction(IRBuilder<> &B, | ||||
const TargetTransformInfo *TTI, | const TargetTransformInfo *TTI, | ||||
unsigned Opcode, Value *Src, | unsigned Opcode, Value *Src, | ||||
TargetTransformInfo::ReductionFlags Flags = | TargetTransformInfo::ReductionFlags Flags = | ||||
TargetTransformInfo::ReductionFlags(), | TargetTransformInfo::ReductionFlags(), | ||||
FastMathFlags FMF = FastMathFlags(), | |||||
ArrayRef<Value *> RedOps = None); | ArrayRef<Value *> RedOps = None); | ||||
/// Create a generic target reduction using a recurrence descriptor \p Desc | /// Create a generic target reduction using a recurrence descriptor \p Desc | ||||
/// The target is queried to determine if intrinsics or shuffle sequences are | /// The target is queried to determine if intrinsics or shuffle sequences are | ||||
/// required to implement the reduction. | /// required to implement the reduction. | ||||
/// Fast-math-flags are propagated using the RecurrenceDescriptor. | |||||
Value *createTargetReduction(IRBuilder<> &B, const TargetTransformInfo *TTI, | Value *createTargetReduction(IRBuilder<> &B, const TargetTransformInfo *TTI, | ||||
RecurrenceDescriptor &Desc, Value *Src, | RecurrenceDescriptor &Desc, Value *Src, | ||||
bool NoNaN = false); | bool NoNaN = false); | ||||
/// Get the intersection (logical and) of all of the potential IR flags | /// Get the intersection (logical and) of all of the potential IR flags | ||||
/// of each scalar operation (VL) that will be converted into a vector (I). | /// of each scalar operation (VL) that will be converted into a vector (I). | ||||
/// If OpValue is non-null, we only consider operations similar to OpValue | /// If OpValue is non-null, we only consider operations similar to OpValue | ||||
/// when intersecting. | /// when intersecting. | ||||
Show All 23 Lines |