<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - NewGVN: We could eliminate about 200 lines of code from eliminateInstructions"
   href="https://bugs.llvm.org/show_bug.cgi?id=33282">33282</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>NewGVN: We could eliminate about 200 lines of code from eliminateInstructions
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>libraries
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Scalar Optimizations
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>dberlin@dberlin.org
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Bryant Wong, besides pointing out a bug in ValueDFS (which ends up not
affecting anything but is still wrong :P), pointed out to me that including all
the uses in the vectors is pointless.

Every time we see a def dominate another def, we can replace all the uses, so
we are just wasting time by including them and sorting them.

I have a prototype that does this, and it saves about 200 lines of code in
eliminateinstructions.

i haven't measured any speed change (not surprising, we walk the uses either
way and the sort is fast).

Right now, my prototype doesn't do as good at dead code elimination as we do,
and we would have to move how we handle replacing predicatienfo arguments (but
it would still be simple, we just have to record whether we ended up killing
them during the stack walk or not).

But it may be worth getting back to at some point.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>