From e1204236ac0fb111ff7e10d6e2ea2458bab328fc Mon Sep 17 00:00:00 2001 From: =?utf8?q?Pawe=C5=82=20Sikora?= Date: Thu, 18 Aug 2005 23:21:51 +0000 Subject: [PATCH] - obsolete. Changed files: gcc-pr23386.patch -> 1.2 gcc-pr23402.patch -> 1.2 --- gcc-pr23386.patch | 44 -------------------------------------------- gcc-pr23402.patch | 33 --------------------------------- 2 files changed, 77 deletions(-) delete mode 100644 gcc-pr23386.patch delete mode 100644 gcc-pr23402.patch diff --git a/gcc-pr23386.patch b/gcc-pr23386.patch deleted file mode 100644 index 37d1375..0000000 --- a/gcc-pr23386.patch +++ /dev/null @@ -1,44 +0,0 @@ ---- gcc/gcc/tree-data-ref.c 2005/08/14 06:28:03 2.37 -+++ gcc/gcc/tree-data-ref.c 2005/08/15 07:51:39 2.38 -@@ -751,7 +751,7 @@ - tree access_fn, - tree stmt) - { -- tree estimation; -+ tree estimation = NULL_TREE; - tree array_size, data_size, element_size; - tree init, step; - -@@ -773,11 +773,28 @@ - && TREE_CODE (init) == INTEGER_CST - && TREE_CODE (step) == INTEGER_CST) - { -- estimation = fold_build2 (CEIL_DIV_EXPR, integer_type_node, -- fold_build2 (MINUS_EXPR, integer_type_node, -- data_size, init), step); -+ tree i_plus_s = fold_build2 (PLUS_EXPR, integer_type_node, init, step); -+ tree sign = fold_build2 (GT_EXPR, boolean_type_node, i_plus_s, init); - -- record_estimate (loop, estimation, boolean_true_node, stmt); -+ if (sign == boolean_true_node) -+ estimation = fold_build2 (CEIL_DIV_EXPR, integer_type_node, -+ fold_build2 (MINUS_EXPR, integer_type_node, -+ data_size, init), step); -+ -+ /* When the step is negative, as in PR23386: (init = 3, step = -+ 0ffffffff, data_size = 100), we have to compute the -+ estimation as ceil_div (init, 0 - step) + 1. */ -+ else if (sign == boolean_false_node) -+ estimation = -+ fold_build2 (PLUS_EXPR, integer_type_node, -+ fold_build2 (CEIL_DIV_EXPR, integer_type_node, -+ init, -+ fold_build2 (MINUS_EXPR, unsigned_type_node, -+ integer_zero_node, step)), -+ integer_one_node); -+ -+ if (estimation) -+ record_estimate (loop, estimation, boolean_true_node, stmt); - } - } - diff --git a/gcc-pr23402.patch b/gcc-pr23402.patch deleted file mode 100644 index db7c3f3..0000000 --- a/gcc-pr23402.patch +++ /dev/null @@ -1,33 +0,0 @@ ---- gcc-4.1-20050815T0803UTC/gcc/gimplify.c 2005-08-16 19:35:38.541525608 +0000 -+++ gcc-4.1-20050815T0803UTC/gcc/gimplify.c 2005-08-16 19:36:46.005269560 +0000 -@@ -2552,6 +2552,17 @@ zero_sized_field_decl (tree fdecl) - return false; - } - -+/* Return true if TYPE is zero sized. */ -+ -+static bool -+zero_sized_type (tree type) -+{ -+ if (AGGREGATE_TYPE_P (type) && TYPE_SIZE (type) -+ && integer_zerop (TYPE_SIZE (type))) -+ return true; -+ return false; -+} -+ - /* A subroutine of gimplify_init_constructor. Generate individual - MODIFY_EXPRs for a CONSTRUCTOR. OBJECT is the LHS against which the - assignments should happen. ELTS is the CONSTRUCTOR_ELTS of the -@@ -2964,6 +2975,12 @@ gimplify_modify_expr_rhs (tree *expr_p, - tree *post_p, bool want_value) - { - enum gimplify_status ret = GS_OK; -+ tree type = TREE_TYPE (*from_p); -+ if (zero_sized_type (type)) -+ { -+ *expr_p = build_empty_stmt (); -+ return GS_ALL_DONE; -+ } - - while (ret != GS_UNHANDLED) - switch (TREE_CODE (*from_p)) -- 2.44.0