Lines Matching defs:lacc
281 struct access *lacc, *racc;
577 /* Add LINK to the linked list of lhs assign links of LACC. */
580 add_link_to_lhs (struct access *lacc, struct assign_link *link)
582 gcc_assert (link->lacc == lacc);
584 if (!lacc->first_lhs_link)
586 gcc_assert (!lacc->last_lhs_link);
587 lacc->first_lhs_link = link;
590 lacc->last_lhs_link->next_lhs = link;
592 lacc->last_lhs_link = link;
1269 struct access *lacc, *racc;
1283 lacc = build_access_from_expr_1 (lhs, stmt, true);
1285 if (lacc)
1287 lacc->grp_assignment_write = 1;
1289 lacc->grp_unscalarizable_region = 1;
1291 if (should_scalarize_away_bitmap && !is_gimple_reg_type (lacc->type))
1297 DECL_UID (lacc->base));
1320 if (lacc && racc
1322 && !lacc->grp_unscalarizable_region
1325 && lacc->size == racc->size
1326 && useless_type_conversion_p (lacc->type, racc->type))
1333 link->lacc = lacc;
1336 add_link_to_lhs (lacc, link);
1338 add_access_to_lhs_work_queue (lacc);
1344 lacc->write = false;
1347 return lacc || racc;
2801 to LACC. Enqueue sub-accesses as necessary so that the write flag is
2803 RACC is a scalar access but LACC is not, change the type of the latter, if
2807 propagate_subaccesses_from_rhs (struct access *lacc, struct access *racc)
2810 HOST_WIDE_INT norm_delta = lacc->offset - racc->offset;
2815 if (!lacc->grp_write)
2820 subtree_mark_written_and_rhs_enqueue (lacc);
2825 if (is_gimple_reg_type (lacc->type)
2826 || lacc->grp_unscalarizable_region
2829 if (!lacc->grp_write)
2832 subtree_mark_written_and_rhs_enqueue (lacc);
2839 if (!lacc->grp_write)
2842 subtree_mark_written_and_rhs_enqueue (lacc);
2844 if (!lacc->first_child && !racc->first_child)
2849 = TYPE_REVERSE_STORAGE_ORDER (lacc->type)
2852 tree t = lacc->base;
2854 lacc->type = racc->type;
2856 lacc->offset, racc->type))
2858 lacc->expr = t;
2859 lacc->grp_same_access_path = true;
2863 lacc->expr = build_ref_for_model (EXPR_LOCATION (lacc->base),
2864 lacc->base, lacc->offset,
2866 if (TREE_CODE (lacc->expr) == MEM_REF)
2867 REF_REVERSE_STORAGE_ORDER (lacc->expr) = reverse;
2868 lacc->grp_no_warning = true;
2869 lacc->grp_same_access_path = false;
2871 lacc->reverse = reverse;
2881 if (child_would_conflict_in_acc (lacc, norm_offset, rchild->size,
2888 gcc_assert (!lacc->grp_write);
2904 if (!lacc->grp_write)
2907 subtree_mark_written_and_rhs_enqueue (lacc);
2914 || !budget_for_propagation_access (lacc->base))
2916 if (!lacc->grp_write && access_or_its_child_written (rchild))
2919 subtree_mark_written_and_rhs_enqueue (lacc);
2929 if (!types_compatible_p (lacc->type, rchild->type))
2930 new_acc = create_artificial_child_access (lacc, rchild, norm_offset,
2932 (lacc->grp_write
2935 new_acc = lacc;
2940 add_access_to_rhs_work_queue (lacc);
2947 /* Propagate subaccesses of LACC across an assignment link to RACC if they
2952 propagate_subaccesses_from_lhs (struct access *lacc, struct access *racc)
2955 || lacc->grp_unscalarizable_region
2960 scalarization if lacc is a scalar access (and none fo the two have
2964 HOST_WIDE_INT norm_delta = racc->offset - lacc->offset;
2965 for (struct access *lchild = lacc->first_child;
3019 struct access *lacc = link->lacc;
3021 if (!bitmap_bit_p (candidate_bitmap, DECL_UID (lacc->base)))
3023 lacc = lacc->group_representative;
3028 if (!lacc->grp_write)
3030 subtree_mark_written_and_rhs_enqueue (lacc);
3034 else if (propagate_subaccesses_from_rhs (lacc, racc))
3040 add_access_to_rhs_work_queue (lacc);
3041 lacc = lacc->parent;
3043 while (lacc);
3049 struct access *lacc = pop_access_from_lhs_work_queue ();
3052 if (lacc->group_representative)
3053 lacc = lacc->group_representative;
3054 gcc_assert (lacc->first_lhs_link);
3056 if (!bitmap_bit_p (candidate_bitmap, DECL_UID (lacc->base)))
3059 for (link = lacc->first_lhs_link; link; link = link->next_lhs)
3067 if (propagate_subaccesses_from_lhs (lacc, racc))
4001 formed by children of LACC from scalar replacements in the SAD->top_racc
4006 load_assign_lhs_subreplacements (struct access *lacc,
4009 for (lacc = lacc->first_child; lacc; lacc = lacc->next_sibling)
4012 offset = lacc->offset - sad->left_offset + sad->top_racc->offset;
4014 if (lacc->grp_to_be_replaced)
4020 racc = find_access_in_subtree (sad->top_racc, offset, lacc->size);
4024 if (!useless_type_conversion_p (lacc->type, racc->type))
4026 lacc->type, rhs);
4028 if (racc->grp_partial_lhs && lacc->grp_partial_lhs)
4041 lacc->offset - sad->left_offset,
4042 lacc, sad->new_gsi, true);
4045 lacc->offset - sad->left_offset,
4046 lacc, sad->new_gsi, true);
4047 if (lacc->grp_partial_lhs)
4053 stmt = gimple_build_assign (get_access_replacement (lacc), rhs);
4062 && lacc->grp_read && !lacc->grp_covered)
4065 if (lacc && lacc->grp_to_be_debug_replaced)
4071 lacc->size);
4081 drhs = build_debug_ref_for_model (sad->loc, lacc->base,
4082 lacc->offset, lacc);
4085 offset, lacc);
4089 && !useless_type_conversion_p (lacc->type, TREE_TYPE (drhs)))
4091 lacc->type, drhs);
4092 ds = gimple_build_debug_bind (get_access_replacement (lacc),
4098 if (lacc->first_child)
4099 load_assign_lhs_subreplacements (lacc, sad);
4269 struct access *lacc, *racc;
4295 lacc = get_access_for_expr (lhs);
4297 if (!lacc && !racc)
4304 if (lacc && lacc->grp_to_be_replaced)
4306 lhs = get_access_replacement (lacc);
4309 if (lacc->grp_partial_lhs)
4346 else if (lacc
4348 && TYPE_REVERSE_STORAGE_ORDER (TREE_TYPE (rhs)) == lacc->reverse
4350 rhs = build_ref_for_model (loc, rhs, 0, lacc, gsi, false);
4361 if (lacc && lacc->grp_to_be_debug_replaced)
4363 tree dlhs = get_access_replacement (lacc);
4369 drhs = build_debug_ref_for_model (loc, drhs, 0, lacc);
4423 if (access_has_children_p (lacc))
4431 generate_subtree_copies (lacc->first_child, lhs, lacc->offset, 0, 0,
4453 if (access_has_children_p (lacc)
4458 && !lacc->grp_unscalarizable_region
4463 sad.left_offset = lacc->offset;
4472 if (lacc->grp_read && !lacc->grp_covered)
4475 load_assign_lhs_subreplacements (lacc, &sad);
4515 if (access_has_children_p (lacc))
4516 generate_subtree_copies (lacc->first_child, rhs, lacc->offset,