Re: Question about Sparse Linear form and pseudos

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

 



On Sun, Aug 20, 2017 at 06:45:09PM +0200, Luc Van Oostenryck wrote:
> On Sun, Aug 20, 2017 at 6:33 PM, Linus Torvalds
> <torvalds@xxxxxxxxxxxxxxxxxxxx> wrote:
> >
> > I wouldn't guarantee it - I *think* it may be the case that even the
> > initial linearization is actually proper SSA (just with everything
> > going through memory)
> 
> It's odd to me to talk about SSA when there is no phi-nodes
> because all accesses are made via memory, but yes, I'm positively
> sure that even before we call simplify_symbol_usage() (which
> to me is where the real conversion to SSA is done) no pseudo
> is defined at two different places. So yes, the SSA properties is
> already true at the initial linearization.

There is at least one exceptional case, though:
	int foo(int c)
	{
		if (c)
			return 0;
	}

It's, of course, wrong code and should be somehow rejected but
currently, nothing wrong is detected and since returns are
linearized directly with phi-node, we end up with the exit
block having two parents but with a phi-node with a single
operands. It's annoying.

I don't know of any other situations at initial linearization.
So, nothing fundamental but some complications.

There is another whole class of problems concerning SSA correctness
other than the conversion to SSA. It's when correctness is destroyed
by some code transformations involving changes in the CFG:
- packing of BB
- branch simplification: insert_branch()
- possibly try_to_simplify_bb() too

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