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]

Re: [RFTesting] New POINTER_DIFF_EXPR


On Mon, Nov 27, 2017 at 10:41:42AM -0500, David Malcolm wrote:
> On Sun, 2017-11-26 at 01:11 +0100, Gerald Pfeifer wrote:
> > On Mon, 20 Nov 2017, Marc Glisse wrote:
> > > new version, regtested on powerpc64le-unknown-linux-gnu. The front-
> > > end 
> > > parts are up for review.
> > > 
> > > 2017-10-28  Marc Glisse  <marc.glisse@inria.fr>
> > > 
> > > gcc/c/
> > > 	* c-fold.c (c_fully_fold_internal): Handle POINTER_DIFF_EXPR.
> > > 	* c-typeck.c (pointer_diff): Use POINTER_DIFF_EXPR.
> > > 
> > > gcc/c-family/
> > > 	* c-pretty-print.c (pp_c_additive_expression,
> > > 	c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
> > > 
> > > gcc/cp/
> > > 	* constexpr.c (cxx_eval_constant_expression,
> > > 	potential_constant_expression_1): Handle POINTER_DIFF_EXPR.
> > > 	* cp-gimplify.c (cp_fold): Likewise.
> > > 	* error.c (dump_expr): Likewise.
> > > 	* typeck.c (pointer_diff): Use POINTER_DIFF_EXPR.
> > 
> > I'm afraid this broke building Wine.
> > 
> > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83164
> > 
> > 
> > ddeml.c: In function ‘DDEML_AddThunk’:
> > ddeml.c:181:28: error: type mismatch in pointer diff expression
> >  static struct ddeml_thunk*      DDEML_AddThunk(DWORD instId, DWORD
> > pfn16)
> >                             ^~~~~~~~~~~~~~
> > int
> > 
> > struct HDDEDATA__ * (*<T1c96>) (DWORD, UINT, UINT, struct HCONV__ *, 
> > struct HSZ__ *, struct HSZ__ *, struct HDDEDATA__ *, ULONG_PTR,
> > ULONG_PTR)
> > 
> > DWORD *
> > 
> > _6 = WDML_InvokeCallback16 - _5;
> > ddeml.c:181:28: internal compiler error: verify_gimple failed
> > 
> > 
> > David, in addition to the ICE diagnostics also looks, umm, 
> > rather confusing?

This is a checking ICE, so in a non-buggy compiler it should never happen,
so doesn't need to be too user friendly, it is enough that we can
find out what's going on.

> Indeed.  I've added some comments about that to BZ.

	Jakub


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