Functions are considered intrinsics if their names begin with "llvm.",
even if they don't have a valid intrinsic ID. This is a cached property,
stored in GlobalValue's HasLLVMReservedName.
When calling Value::setName(), this property is recalculated. However,
this property is not recalculated when taking names from another Value.
While it's not documented as doing such, the semantics of "takeName"
suggest that A.takeName(B) is the same as A.setName(B.getName())
followed by B.setName("").
This patch updates Value::takeName to act in this fashion, to avoid any
unexpected behaviour: The new function is an intrinsic since it now starts with
"llvm." and the old function is no longer considered an intrinsic, since it no
longer begins with "llvm.".