IR: Sink MDNode::Hash down to GenericMDNode::Hash

Part of PR21532.