<html>
    <head>
      <base href="https://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 --- - [AArch64] Lots of redundant 'adrp' instructions"
   href="https://llvm.org/bugs/show_bug.cgi?id=26245">26245</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>[AArch64] Lots of redundant 'adrp' instructions
          </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>Windows NT
          </td>
        </tr>

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

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

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

        <tr>
          <th>Component</th>
          <td>Backend: AArch64
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>mcrosier@codeaurora.org
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>bmakam@codeaurora.org, gberry@codeaurora.org, haicheng@codeaurora.org, junbuml@codeaurora.org, llvm-bugs@lists.llvm.org, mcrosier@codeaurora.org, mssimpso@codeaurora.org
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>I see lots of cases were we have redundant 'adrp' instructions.  For example, I
just ran into something like the following:

 adrp x8, 541000
 str d1, [sp,#40]
 ldr d1, [x8,#2392]
 adrp x9, 541000     // Redundant
 adrp x21, 5d3000
 str d1, [sp,#32]
 ldr d1, [x9,#2800]
 mov x19, x0
 str wzr, [x19,#16]
 stp xzr, xzr, [x19]
 str wzr, [sp,#20]
 fmov s15, wzr
 mov v4.16b, v15.16b
 mov v5.16b, v15.16b
 mov v6.16b, v15.16b
 mov v7.16b, v15.16b
 mov v16.16b, v15.16b
 mov v13.16b, v15.16b
 mov v14.16b, v15.16b
 fmov d8, #-5.000000000000e-01
 adrp x23, 5d3000    // Potentially redundant
 mov w22, wzr
 add x23, x23, #0xfc0
 adrp x24, 5d0000
 str d1, [sp,#24]
 ldp d9, d12, [sp,#24]
 adrp x26, 5d0000   // Redundant
 add x26, x26, #0x9c8

I'll see if I can't reduce a test case shortly.</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>