diff options
author | bstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-03-11 15:19:27 +0000 |
---|---|---|
committer | bstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-03-11 15:19:27 +0000 |
commit | 84e39114ef36f4f202028695936e3725b9a08474 (patch) | |
tree | 1b76344540036a57ec23806ad0e4e22b62c916c3 /gcc/df.h | |
parent | f778423557464b07c76cbf36e2032cccb94c02bc (diff) | |
download | gcc-84e39114ef36f4f202028695936e3725b9a08474.tar.gz |
2008-03-11 Basile Starynkevitch <basile@starynkevitch.net>
merged with trunk r133107
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@133113 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/df.h')
-rw-r--r-- | gcc/df.h | 41 |
1 files changed, 32 insertions, 9 deletions
@@ -117,14 +117,18 @@ enum df_ref_flags DF_REF_MUST_CLOBBER = 1 << 7, - /* This flag is set if this ref is inside a pre/post modify. */ - DF_REF_PRE_POST_MODIFY = 1 << 8, + /* If the ref has one of the following two flags set, then the + struct df_ref can be cast to struct df_ref_extract to access + the width and offset fields. */ + + /* This flag is set if the ref contains a SIGN_EXTRACT. */ + DF_REF_SIGN_EXTRACT = 1 << 8, - /* This flag is set if the ref contains a ZERO_EXTRACT or SIGN_EXTRACT. */ - DF_REF_EXTRACT = 1 << 9, + /* This flag is set if the ref contains a ZERO_EXTRACT. */ + DF_REF_ZERO_EXTRACT = 1 << 9, - /* This flag is set if the ref contains a STRICT_LOWER_PART. */ - DF_REF_STRICT_LOWER_PART = 1 << 10, + /* This flag is set if the ref contains a STRICT_LOW_PART. */ + DF_REF_STRICT_LOW_PART = 1 << 10, /* This flag is set if the ref contains a SUBREG. */ DF_REF_SUBREG = 1 << 11, @@ -138,7 +142,11 @@ enum df_ref_flags DF_REF_CALL_STACK_USAGE = 1 << 13, /* This flag is used for verification of existing refs. */ - DF_REF_REG_MARKER = 1 << 14 + DF_REF_REG_MARKER = 1 << 14, + + /* This flag is set if this ref is inside a pre/post modify. */ + DF_REF_PRE_POST_MODIFY = 1 << 15 + }; /* The possible ordering of refs within the df_ref_info. */ @@ -381,6 +389,17 @@ struct df_ref struct df_ref *prev_reg; /* Prev ref with same regno and type. */ }; +/* A df_ref_extract is just a df_ref with a width and offset field at + the end of it. It is used to hold this information if the ref was + wrapped by a SIGN_EXTRACT or a ZERO_EXTRACT and to pass this info + to passes that wish to process partial regs precisely. */ +struct df_ref_extract +{ + struct df_ref ref; + int width; + int offset; +}; + /* These links are used for two purposes: 1) def-use or use-def chains. 2) Multiword hard registers that underly a single hardware register. */ @@ -598,7 +617,10 @@ struct df #define DF_REF_IS_REG_MARKED(REF) (DF_REF_FLAGS_IS_SET ((REF),DF_REF_REG_MARKER)) #define DF_REF_NEXT_REG(REF) ((REF)->next_reg) #define DF_REF_PREV_REG(REF) ((REF)->prev_reg) - +/* The following two macros may only be applied if one of + DF_REF_SIGN_EXTRACT | DF_REF_ZERO_EXTRACT is true. */ +#define DF_REF_WIDTH(REF) (((struct df_ref_extract *)(REF))->width) +#define DF_REF_OFFSET(REF) (((struct df_ref_extract *)(REF))->offset) /* Macros to determine the reference type. */ #define DF_REF_REG_DEF_P(REF) (DF_REF_TYPE (REF) == DF_REF_REG_DEF) @@ -862,7 +884,8 @@ extern void df_grow_reg_info (void); extern void df_grow_insn_info (void); extern void df_scan_blocks (void); extern struct df_ref *df_ref_create (rtx, rtx *, rtx,basic_block, - enum df_ref_type, enum df_ref_flags); + enum df_ref_type, enum df_ref_flags, + int, int); extern void df_ref_remove (struct df_ref *); extern struct df_insn_info * df_insn_create_insn_record (rtx); extern void df_insn_delete (basic_block, unsigned int); |