<html>
    <head>
      <base href="http://llvm.org/bugs/" />
    </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 --- - FileCheck full support for logical operators"
   href="http://llvm.org/bugs/show_bug.cgi?id=16870">16870</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>FileCheck full support for logical operators
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>new-bugs
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>unspecified
          </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>new bugs
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>renato.golin@linaro.org
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvmbugs@cs.uiuc.edu
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>FileCheck already support NOT and AND (Next), but it doesn't yet support OR.

A common use case is:

; CHECK: add r0, r1, r2
; CHECK-OR: add r0, r2, r1

So, a block of CHECK-ORs would be executed on the same block, and the cursor
advances by the length of the smaller pattern matched:

; CHECK: add r0, [[reg1]], [[reg2]]
; CHECK-OR: add r0, [[reg1]], [[reg3]]
; CHECK-OR: add r0, [[reg2]], [[reg1]]
; CHECK-OR: add r0, [[reg2]], [[reg3]]
; CHECK-OR: add r0, [[reg3]], [[reg1]]
; CHECK-OR: add r0, [[reg3]], [[reg2]]

If the text is "add r4", the cursor would advance to "4".

The pattern is broken by any other non-OR checks:

; CHECK: mul r0, ...

Maybe, AND could be an alias to NEXT, but I don't think that's critical.

There's no way to intermix AND/OR for now, since there is no concept of
grouping CHECKs, but it's something to consider for the future if we ever get
that far.</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>