diff options
author | mrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-12-13 17:31:30 +0000 |
---|---|---|
committer | mrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-12-13 17:31:30 +0000 |
commit | 3dd775fb895cffb77ac74098a74e9fca28edaf79 (patch) | |
tree | f68062e9cfe09046337dc976767a5f7938462868 /gcc/tree-affine.h | |
parent | 84014c53e113ab540befd1eceb8598d28a323ab3 (diff) | |
parent | 34a5d2a56d4b0a0ea74339c985c919aabfc530a4 (diff) | |
download | gcc-3dd775fb895cffb77ac74098a74e9fca28edaf79.tar.gz |
Merge in trunk.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/wide-int@205966 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-affine.h')
-rw-r--r-- | gcc/tree-affine.h | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/gcc/tree-affine.h b/gcc/tree-affine.h index 961b9a6e5d2..68f2908eb6e 100644 --- a/gcc/tree-affine.h +++ b/gcc/tree-affine.h @@ -35,7 +35,7 @@ struct aff_comb_elt widest_int coef; }; -typedef struct affine_tree_combination +struct aff_tree { /* Type of the result of the combination. */ tree type; @@ -58,7 +58,7 @@ typedef struct affine_tree_combination than MAX_AFF_ELTS elements. Type of REST will be either sizetype for TYPE of POINTER_TYPEs or TYPE. */ tree rest; -} aff_tree; +}; widest_int wide_int_ext_for_comb (const widest_int &, aff_tree *); void aff_combination_const (aff_tree *, tree, const widest_int &); @@ -83,3 +83,16 @@ bool aff_comb_cannot_overlap_p (aff_tree *, const widest_int &, /* Debugging functions. */ void debug_aff (aff_tree *); + +/* Return true if AFF is actually ZERO. */ +static inline bool +aff_combination_zero_p (aff_tree *aff) +{ + if (!aff) + return true; + + if (aff->n == 0 && aff->offset.is_zero ()) + return true; + + return false; +} |