}
}
- if (inst->predicate) {
+ if (inst->reads_flag()) {
add_dep(last_conditional_mod[inst->flag_subreg], n);
}
}
}
- /* Treat FS_OPCODE_MOV_DISPATCH_TO_FLAGS as though it had a
- * conditional_mod, because it sets the flag register.
- */
- if (inst->conditional_mod ||
- inst->opcode == FS_OPCODE_MOV_DISPATCH_TO_FLAGS) {
+ if (inst->writes_flag()) {
add_dep(last_conditional_mod[inst->flag_subreg], n, 0);
last_conditional_mod[inst->flag_subreg] = n;
}
}
}
- if (inst->predicate) {
+ if (inst->reads_flag()) {
add_dep(n, last_conditional_mod[inst->flag_subreg]);
}
}
}
- /* Treat FS_OPCODE_MOV_DISPATCH_TO_FLAGS as though it had a
- * conditional_mod, because it sets the flag register.
- */
- if (inst->conditional_mod ||
- inst->opcode == FS_OPCODE_MOV_DISPATCH_TO_FLAGS) {
+ if (inst->writes_flag()) {
last_conditional_mod[inst->flag_subreg] = n;
}
}