do refactoring for create_deep_copy()

reduce nest
emit IR for one-to-multi substitution
revert ir_builder_helper() refactoring
remove implementation dependant code