17#ifndef LLVM_CODEGEN_BYTEPROVIDER_H
18#define LLVM_CODEGEN_BYTEPROVIDER_H
41 using check_has_getOpcode =
42 decltype(std::declval<std::remove_pointer_t<U> &>().
getOpcode());
45 static constexpr bool has_getOpcode =
51 std::optional<ISelOp>
Src = std::nullopt;
61 int64_t VectorOffset) {
62 static_assert(has_getOpcode<ISelOp>,
63 "ByteProviders must contain an operation in selection DAG.");
static std::optional< unsigned > getOpcode(ArrayRef< VPValue * > Values)
Returns the opcode of Values or ~0 if they do not all agree.
Represents known origin of an individual byte in combine pattern.
static ByteProvider getConstantZero()
bool operator==(const ByteProvider &Other) const
static ByteProvider getSrc(std::optional< ISelOp > Val, int64_t ByteOffset, int64_t VectorOffset)
bool hasSameSrc(const ByteProvider &Other) const
std::optional< ISelOp > Src
bool isConstantZero() const
This is an optimization pass for GlobalISel generic memory operations.
typename detail::detector< void, Op, Args... >::value_t is_detected
Detects if a given trait holds for some set of arguments 'Args'.