Drop all unknown metadata except for debug locations.

Synopsis

Declared in <llvm/IR/Instruction.h>

void
dropUnknownNonDebugMetadata(ArrayRef<unsigned int> KnownIDs = {});

Description

Passes are required to drop metadata they don't understand. This is a convenience method for passes to do so. dropUBImplyingAttrsAndUnknownMetadata should be used instead of this API if the Instruction being modified is a call.

Parameters

Name

Description

KnownIDs

Metadata kind IDs that should be retained.

Created with MrDocs