This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Fix PR24238


This fixes a verify_ssa failure where we forgot about some used
parts in a RESULT_DECL.

Bootstrapped on x86_64-unknown-linux-gnu, testing in progress.

Ok for mainline, if it succeeds?

Thanks,
Richard.


2005-10-06  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/24238
	* tree-ssa-alias.c (find_used_portions): Handle PARAM_DECL.

	* g++.dg/tree-ssa/pr24238.C: New testcase.

Index: tree-ssa-alias.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/tree-ssa-alias.c,v
retrieving revision 2.110
diff -c -3 -p -r2.110 tree-ssa-alias.c
*** tree-ssa-alias.c	15 Sep 2005 01:28:10 -0000	2.110
--- tree-ssa-alias.c	6 Oct 2005 14:56:42 -0000
*************** find_used_portions (tree *tp, int *walk_
*** 2765,2770 ****
--- 2765,2771 ----
        break;
      case VAR_DECL:
      case PARM_DECL:
+     case RESULT_DECL:
        {
  	tree var = *tp;
  	if (DECL_SIZE (var)


/* { dg-do compile } */
/* { dg-options "-O2" } */

typedef struct SDL_Rect {
    unsigned short w, h;
}SDL_Rect;
SDL_Rect *location();
SDL_Rect inner_location()
{
    SDL_Rect r = *location();
    r.w -= 1;
    return r;
}


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]