refactor merge flags into xmparam_t