V4 IR: add def statements to the worklist when removing uses.

When removing a phi node, add the def statement for the (previously)
used temps to the worklist. These statements might now be eligible for
further optimizations (specifically removal when there are no uses
left).

Change-Id: I05d7c7bc0a243d328b5f9d1c2dcc53a10bd7491d
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
V4 IR: Store positions for life-time intervals outside the statement.

The statement ids are now stable, so the life-time interval calculation
can re-use information calculated by the optimizer. This re-use will
be done in a separate patch.

It also allows for changes to the numbering in a non-intrusive way. This
will also come in a later patch.

Change-Id: Ie3a2e1d9e3537cc8070ff3e3007f3a5e8ca0579a
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>