support find_first_common_node.