58 #define DF_LAST_PROBLEM_PLUS1 (DF_MD + 1)
383 unsigned int ref_order;
391 struct df_base_ref base;
401 struct df_base_ref base;
412 struct df_base_ref base;
528 struct dataflow *problems_in_order[DF_LAST_PROBLEM_PLUS1];
529 struct dataflow *problems_by_index[DF_LAST_PROBLEM_PLUS1];
599 int changeable_flags : 8;
610 #define DF_SCAN_BB_INFO(BB) (df_scan_get_bb_info((BB)->index))
611 #define DF_RD_BB_INFO(BB) (df_rd_get_bb_info((BB)->index))
612 #define DF_LR_BB_INFO(BB) (df_lr_get_bb_info((BB)->index))
613 #define DF_LIVE_BB_INFO(BB) (df_live_get_bb_info((BB)->index))
614 #define DF_WORD_LR_BB_INFO(BB) (df_word_lr_get_bb_info((BB)->index))
615 #define DF_MD_BB_INFO(BB) (df_md_get_bb_info((BB)->index))
619 #define DF_LIVE_IN(BB) (&DF_LIVE_BB_INFO(BB)->in)
620 #define DF_LIVE_OUT(BB) (&DF_LIVE_BB_INFO(BB)->out)
625 #define DF_LR_IN(BB) (&DF_LR_BB_INFO(BB)->in)
626 #define DF_LR_OUT(BB) (&DF_LR_BB_INFO(BB)->out)
631 #define DF_WORD_LR_IN(BB) (&DF_WORD_LR_BB_INFO(BB)->in)
632 #define DF_WORD_LR_OUT(BB) (&DF_WORD_LR_BB_INFO(BB)->out)
637 #define DF_REF_REAL_REG(REF) (GET_CODE ((REF)->base.reg) == SUBREG \
638 ? SUBREG_REG ((REF)->base.reg) : ((REF)->base.reg))
639 #define DF_REF_REGNO(REF) ((REF)->base.regno)
640 #define DF_REF_REAL_LOC(REF) (GET_CODE (*((REF)->regular_ref.loc)) == SUBREG \
641 ? &SUBREG_REG (*((REF)->regular_ref.loc)) : ((REF)->regular_ref.loc))
642 #define DF_REF_REG(REF) ((REF)->base.reg)
643 #define DF_REF_LOC(REF) (DF_REF_CLASS(REF) == DF_REF_REGULAR ? \
644 (REF)->regular_ref.loc : NULL)
645 #define DF_REF_BB(REF) (DF_REF_IS_ARTIFICIAL(REF) ? \
646 (REF)->artificial_ref.bb : BLOCK_FOR_INSN (DF_REF_INSN(REF)))
647 #define DF_REF_BBNO(REF) (DF_REF_BB (REF)->index)
648 #define DF_REF_INSN_INFO(REF) ((REF)->base.insn_info)
649 #define DF_REF_INSN(REF) ((REF)->base.insn_info->insn)
650 #define DF_REF_INSN_UID(REF) (INSN_UID (DF_REF_INSN(REF)))
651 #define DF_REF_CLASS(REF) ((REF)->base.cl)
652 #define DF_REF_TYPE(REF) ((REF)->base.type)
653 #define DF_REF_CHAIN(REF) ((REF)->base.chain)
654 #define DF_REF_ID(REF) ((REF)->base.id)
655 #define DF_REF_FLAGS(REF) ((REF)->base.flags)
656 #define DF_REF_FLAGS_IS_SET(REF, v) ((DF_REF_FLAGS (REF) & (v)) != 0)
657 #define DF_REF_FLAGS_SET(REF, v) (DF_REF_FLAGS (REF) |= (v))
658 #define DF_REF_FLAGS_CLEAR(REF, v) (DF_REF_FLAGS (REF) &= ~(v))
659 #define DF_REF_ORDER(REF) ((REF)->base.ref_order)
663 #define DF_REF_IS_ARTIFICIAL(REF) (DF_REF_CLASS(REF) == DF_REF_ARTIFICIAL)
664 #define DF_REF_REG_MARK(REF) (DF_REF_FLAGS_SET ((REF),DF_REF_REG_MARKER))
665 #define DF_REF_REG_UNMARK(REF) (DF_REF_FLAGS_CLEAR ((REF),DF_REF_REG_MARKER))
666 #define DF_REF_IS_REG_MARKED(REF) (DF_REF_FLAGS_IS_SET ((REF),DF_REF_REG_MARKER))
667 #define DF_REF_NEXT_REG(REF) ((REF)->base.next_reg)
668 #define DF_REF_PREV_REG(REF) ((REF)->base.prev_reg)
671 #define DF_REF_EXTRACT_WIDTH(REF) ((REF)->extract_ref.width)
672 #define DF_REF_EXTRACT_OFFSET(REF) ((REF)->extract_ref.offset)
673 #define DF_REF_EXTRACT_MODE(REF) ((REF)->extract_ref.mode)
676 #define DF_REF_REG_DEF_P(REF) (DF_REF_TYPE (REF) == DF_REF_REG_DEF)
677 #define DF_REF_REG_USE_P(REF) ((REF) && !DF_REF_REG_DEF_P (REF))
678 #define DF_REF_REG_MEM_STORE_P(REF) (DF_REF_TYPE (REF) == DF_REF_REG_MEM_STORE)
679 #define DF_REF_REG_MEM_LOAD_P(REF) (DF_REF_TYPE (REF) == DF_REF_REG_MEM_LOAD)
680 #define DF_REF_REG_MEM_P(REF) (DF_REF_REG_MEM_STORE_P (REF) \
681 || DF_REF_REG_MEM_LOAD_P (REF))
683 #define DF_MWS_REG_DEF_P(MREF) (DF_MWS_TYPE (MREF) == DF_REF_REG_DEF)
684 #define DF_MWS_REG_USE_P(MREF) ((MREF) && !DF_MWS_REG_DEF_P (MREF))
685 #define DF_MWS_TYPE(MREF) ((MREF)->type)
698 #define DF_DEFS_TABLE_SIZE() (df->def_info.table_size)
699 #define DF_DEFS_GET(ID) (df->def_info.refs[(ID)])
700 #define DF_DEFS_SET(ID,VAL) (df->def_info.refs[(ID)]=(VAL))
701 #define DF_DEFS_COUNT(ID) (df->def_info.count[(ID)])
702 #define DF_DEFS_BEGIN(ID) (df->def_info.begin[(ID)])
703 #define DF_USES_TABLE_SIZE() (df->use_info.table_size)
704 #define DF_USES_GET(ID) (df->use_info.refs[(ID)])
705 #define DF_USES_SET(ID,VAL) (df->use_info.refs[(ID)]=(VAL))
706 #define DF_USES_COUNT(ID) (df->use_info.count[(ID)])
707 #define DF_USES_BEGIN(ID) (df->use_info.begin[(ID)])
711 #define DF_REG_SIZE(DF) (df->regs_inited)
712 #define DF_REG_DEF_GET(REG) (df->def_regs[(REG)])
713 #define DF_REG_DEF_CHAIN(REG) (df->def_regs[(REG)]->reg_chain)
714 #define DF_REG_DEF_COUNT(REG) (df->def_regs[(REG)]->n_refs)
715 #define DF_REG_USE_GET(REG) (df->use_regs[(REG)])
716 #define DF_REG_USE_CHAIN(REG) (df->use_regs[(REG)]->reg_chain)
717 #define DF_REG_USE_COUNT(REG) (df->use_regs[(REG)]->n_refs)
718 #define DF_REG_EQ_USE_GET(REG) (df->eq_use_regs[(REG)])
719 #define DF_REG_EQ_USE_CHAIN(REG) (df->eq_use_regs[(REG)]->reg_chain)
720 #define DF_REG_EQ_USE_COUNT(REG) (df->eq_use_regs[(REG)]->n_refs)
724 #define DF_REGNO_FIRST_DEF(REGNUM) \
725 (DF_REG_DEF_GET(REGNUM) ? DF_REG_DEF_GET(REGNUM) : 0)
726 #define DF_REGNO_LAST_USE(REGNUM) \
727 (DF_REG_USE_GET(REGNUM) ? DF_REG_USE_GET(REGNUM) : 0)
731 #define DF_INSN_SIZE() ((df)->insns_size)
732 #define DF_INSN_INFO_GET(INSN) (df->insns[(INSN_UID(INSN))])
733 #define DF_INSN_INFO_SET(INSN,VAL) (df->insns[(INSN_UID (INSN))]=(VAL))
734 #define DF_INSN_INFO_LUID(II) ((II)->luid)
735 #define DF_INSN_INFO_DEFS(II) ((II)->defs)
736 #define DF_INSN_INFO_USES(II) ((II)->uses)
737 #define DF_INSN_INFO_EQ_USES(II) ((II)->eq_uses)
739 #define DF_INSN_LUID(INSN) (DF_INSN_INFO_LUID (DF_INSN_INFO_GET(INSN)))
740 #define DF_INSN_DEFS(INSN) (DF_INSN_INFO_DEFS (DF_INSN_INFO_GET(INSN)))
741 #define DF_INSN_USES(INSN) (DF_INSN_INFO_USES (DF_INSN_INFO_GET(INSN)))
742 #define DF_INSN_EQ_USES(INSN) (DF_INSN_INFO_EQ_USES (DF_INSN_INFO_GET(INSN)))
744 #define DF_INSN_UID_GET(UID) (df->insns[(UID)])
745 #define DF_INSN_UID_SET(UID,VAL) (df->insns[(UID)]=(VAL))
746 #define DF_INSN_UID_SAFE_GET(UID) (((unsigned)(UID) < DF_INSN_SIZE()) \
747 ? DF_INSN_UID_GET (UID) \
749 #define DF_INSN_UID_LUID(INSN) (DF_INSN_UID_GET(INSN)->luid)
750 #define DF_INSN_UID_DEFS(INSN) (DF_INSN_UID_GET(INSN)->defs)
751 #define DF_INSN_UID_USES(INSN) (DF_INSN_UID_GET(INSN)->uses)
752 #define DF_INSN_UID_EQ_USES(INSN) (DF_INSN_UID_GET(INSN)->eq_uses)
753 #define DF_INSN_UID_MWS(INSN) (DF_INSN_UID_GET(INSN)->mw_hardregs)
872 #define df_scan (df->problems_by_index[DF_SCAN])
873 #define df_rd (df->problems_by_index[DF_RD])
874 #define df_lr (df->problems_by_index[DF_LR])
875 #define df_live (df->problems_by_index[DF_LIVE])
876 #define df_chain (df->problems_by_index[DF_CHAIN])
877 #define df_word_lr (df->problems_by_index[DF_WORD_LR])
878 #define df_note (df->problems_by_index[DF_NOTE])
879 #define df_md (df->problems_by_index[DF_MD])
1031 if (index < df_scan->block_info_size)
1040 if (index < df_rd->block_info_size)
1041 return &((
struct df_rd_bb_info *) df_rd->block_info)[index];
1049 if (index < df_lr->block_info_size)
1050 return &((
struct df_lr_bb_info *) df_lr->block_info)[index];
1058 if (index < df_md->block_info_size)
1059 return &((
struct df_md_bb_info *) df_md->block_info)[index];
1067 if (index < df_live->block_info_size)
1076 if (index < df_word_lr->block_info_size)
1087 static inline bitmap
1090 gcc_checking_assert (df_lr);
1093 return DF_LIVE_OUT (bb);
1095 return DF_LR_OUT (bb);
1103 static inline bitmap
1106 gcc_checking_assert (df_lr);
1109 return DF_LIVE_IN (bb);
1111 return DF_LR_IN (bb);
1117 static inline df_ref *
1126 static inline df_ref *