V4: Remove more jumps.
authorErik Verbruggen <erik.verbruggen@me.com>
Fri, 4 Oct 2013 09:55:38 +0000 (11:55 +0200)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Thu, 10 Oct 2013 07:54:12 +0000 (09:54 +0200)
commit42aa10adc93068acbcdc503342c8db92c5b5b899
tree06c153615ee85bf476c5e51c12c503b236807098
parente34477bfaf318fe26cd935728eeec144cc1659fa
V4: Remove more jumps.

Do not generate jump instructions when the target immediately follows
the current basic block, even if there are intermediate jumps in between
as long as they jump to the same basic block. In the IR snippet below,
no jumps will be generated at all.


L8:  goto L6;
L12: goto L6;
L6:  goto L4;
L11: goto L4;
L4:  goto L2;
L10: goto L2;
L2:  ….

Before this change, the gotos in L8, L6, and L2 were still generated.

Change-Id: I718ed0d41c603a6905f2279b782cd9e9cafb7d55
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
src/qml/compiler/qv4isel_masm.cpp
src/qml/compiler/qv4isel_masm_p.h
src/qml/compiler/qv4isel_moth.cpp
src/qml/compiler/qv4isel_moth_p.h
src/qml/compiler/qv4ssa.cpp
src/qml/compiler/qv4ssa_p.h