[DebugInfo][NFC] Add RawLocationWrapper to wrap location operand metadata [1/x]
authorOCHyams <orlando.hyams@sony.com>
Thu, 16 Mar 2023 08:46:02 +0000 (08:46 +0000)
committerOCHyams <orlando.hyams@sony.com>
Thu, 16 Mar 2023 09:55:14 +0000 (09:55 +0000)
commitaf9e52208d76fa9ddcf68564ab5371f6434c62e5
treedd1cfc3660af13bb41d76578280e5cdb3753f00e
parentd4320cb2a5ef1680e519fa6b7cfd3a2f88cfed16
[DebugInfo][NFC] Add RawLocationWrapper to wrap location operand metadata [1/x]

RawLocationWrapper wraps the location operand of a debug intrinsic which may be
either (wrapped in MetadataAsValue) a DIArgList, ValueAsMetadata, or an empty
MDTuple. This class lets us avoid duplicating location handling code in a later
patch in this stack.

Reviewed By: StephenTozer

Differential Revision: https://reviews.llvm.org/D145909
llvm/include/llvm/IR/IntrinsicInst.h
llvm/lib/IR/IntrinsicInst.cpp