OSDN Git Service

Subzero: Control whether deleted instructions are retained.
authorJim Stichnoth <stichnot@chromium.org>
Mon, 14 Mar 2016 15:37:52 +0000 (08:37 -0700)
committerJim Stichnoth <stichnot@chromium.org>
Mon, 14 Mar 2016 15:37:52 +0000 (08:37 -0700)
commit76719b4aab9bdc44a9d37004aba64471790ab574
treeb9230d82f6a1ac7daeb0fb056708995d96a03c50
parent999a22f0bbd828c9fc711b6100194f0678d1a08c
Subzero: Control whether deleted instructions are retained.

Normally, deleted instructions are preserved in the Cfg, and printed as part of dump output.  This helps debugging by partially explaining the provenance of new instructions that originated from the deleted instructions.

However, these instructions slow down iteration over the instruction list, and checking their deleted status may pollute the cache.

As such, in a non-DUMP enabled build, we repurpose the renumberInstructions() pass to also unlink deleted instructions as needed.

A flag is provided to override this behavior, in case we have to debug a situation where a bug only manifests in a DUMP build and not a non-DUMP build, or vice versa.

BUG= https://bugs.chromium.org/p/nativeclient/issues/detail?id=4360
R=eholk@chromium.org, jpp@chromium.org

Review URL: https://codereview.chromium.org/1790063003 .
src/IceCfg.h
src/IceCfgNode.cpp
src/IceClFlags.cpp
src/IceClFlags.h
src/IceDefs.h