|
From: Julian S. <js...@ac...> - 2008-07-02 20:26:00
|
On Wednesday 02 July 2008 20:11, Stephen McCamant wrote: > >>>>> "JC" == Jim Clause <cl...@cc...> writes: > > JC> Will VEX ever generate code that defines an IRTemp that is never > JC> subsequently used? > > >From some informal testing, it appears to me that the first stage > x86->IR transformation sometimes does so, but rarely enough that it > might be considered a bug; I wouldn't rely on that. The compilation pipeline is designed so that the front ends can make relatively stupid translations into IR and rely on the initial IR "optimisation" pass to tidy up the mess. This makes the front ends easier to write. Although I can't offhand think of any dead assignments to temporaries that the front ends might make, I wouldn't be surprised to find there are some somewhere. > the only case I saw was that cmp operations > do a subtract that's not used. Memcheck's instrumentation adds lots of > dead temps. But the optimization pass that follows both removes them > all (see do_deadcode_BB in iropt.c). Yeh, probably true. J |