This introduces LLVMExperimentalGetPtrProvenanceOperand and LLVMExperimentalSetPtrProvenanceOperand. They can be used to get/set/remove the ptr_provenance operand of a load or store instruction.
You need to clone the values, just like it is done for the Ptr one.
First, it ensures that the value is generated properly, but second, these value belong to different (even though identical if the test passes) modules. This is not expected to work and kind of is a miracle that this doesn't crash.