Matcher for memcpy‐like instructions. For non‐zero lengths, MemOps contains the load/store types to emit.

Synopsis

Declared in <llvm/CodeGen/GlobalISel/Utils.h>

bool
canLowerMemCpyFamily(
    MachineInstr const& MI,
    MachineRegisterInfo const& MRI,
    unsigned int MaxLen,
    Register& Dst,
    Register& Src,
    uint64_t& KnownLen,
    Align& Alignment,
    bool& DstAlignCanChange,
    std::vector<LLT>& MemOps);

Return Value

True if the memcpy‐family intrinsic can be lowered.

Parameters

Name

Description

MI

Memcpy‐family instruction to match.

MRI

Register information for the function.

MaxLen

Maximum length for which lowering is attempted.

Dst

Set to the destination pointer register on success.

Src

Set to the source pointer register on success.

KnownLen

Set to the known copy length on success.

Alignment

Set to the inferred access alignment on success.

DstAlignCanChange

Set when destination alignment may change.

MemOps

Filled with load/store types to emit for the copy.

Created with MrDocs