Re: linearize bug?

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

 



On Sat, Aug 27, 2011 at 10:27 AM, Linus Torvalds
<torvalds@xxxxxxxxxxxxxxxxxxxx> wrote:
>
> Which *should* have been semantically no difference what-so-ever. But
> it's been so long, I can't recall all the rules. It may be that trying
> to linearize the same expression twice (once for the entry condition,
> once for the loop end) was just something invalid.
>
> So the patch is just broken. Never mind.

Yes indeed.

The reason we cannot linearize the same expression twice is that we
associate some state with the expression. For example, label symbols
in statement expressions are associated with the basic block they get
linearized to. If you linearize the same expression twice, that kind
of thing will completely screw things up..

So throw away my patch to linearize.c. It was fundamentally broken. I
suspect we don't want to duplicate the conditional for anything but
simple expressions anyway, so if I get a big spurt of energy, I might
add some logic to say "if it's a really simple conditional, then
duplicate it", since then we won't have issues with statement
expressions etc anyway.

                    Linus
--
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