Re: [PATCH v2 00/27] LLVM fixes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Mar 11, 2017 at 09:21:34PM +0000, Dibyendu Majumdar wrote:
> On 11 March 2017 at 20:44, Luc Van Oostenryck > But there is still
> some bad issues that remains,
> > for example pointer subtraction with NULL and some
> > optimization that destroy correct typing info.
> > They're bad enough to make me doubt of the value of this change.
> >
> > Here are some failing cases:
> >         #define NULL ((void *)0)
> >         int  tst(int  *ip) { return !ip; }
> >         int  foo(int  *ip) { return ip != NULL; }
> >         long bar(void *vp) { return vp - NULL; }
> >         long baz(int  *ip) { return ip - ((int *)0); }
> >
> 
> I only get a failure on the last one. But I am synced with master - so
> it may be an issue with sparse-next branch?

It's on my development branch:
	next
	+ today's 2nd serie
	+ today's 1st serie - 2 patches now unneeded.
So it's normal that you don't the same.

> For the last one, looks like linearized output is incorrect?
> 
> baz:
> .L6:
>         <entry-point>
>         divs.64     %r13 <- %arg1, $4
>         scast.32    %r14 <- (64) %r13
>         ret.32      %r14

It's not incorrect, only that the scast is unneeded.
But strangely, I don't see that cast here.

-- Luc
--
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Newbies FAQ]     [LKML]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Trinity Fuzzer Tool]

  Powered by Linux