<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/152102>152102</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            [BOLT][AArch64] When the --frame-opt=hot option is enabled, AArch64MCPlusBuilder does not implement the getPushSize API
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            BOLT
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          whousemyname
      </td>
    </tr>
</table>

<pre>
    ### Problem description
When using bolt to optimize a shared library file of aarch64, if the option frame-opt=hot is enabled, the release version will crash directly, and the debug version will show not implemented

### The output generated by compilation
```
BOLT-INFO: program-wide dynostats after all optimizations before SCTC and FOP:

         20554242536 : executed forward branches
          1853550662 : taken forward branches
 8456055324 : executed backward branches
          7085108608 : taken backward branches
           752751874 : executed unconditional branches
 1783127868 : all function calls
           528206474 : indirect calls
           190048784 : PLT calls
        200007176370 : executed instructions
         29587649281 : executed load instructions
 0 : executed store instructions
                   0 : taken jump table branches
                   0 : taken unknown indirect branches
 29763049734 : total branches
          9691411144 : taken branches
 20071638590 : non-taken conditional branches
          8938659270 : taken conditional branches
         29010297860 : all conditional branches
 0 : linker-inserted veneer calls

         16753640491 : executed forward branches (-18.5%)
           774667346 : taken forward branches (-58.2%)
         12256657369 : executed backward branches (+44.9%)
          7083218995 : taken backward branches (-0.0%)
 515286541 : executed unconditional branches (-31.5%)
          1783127868 : all function calls (=)
           528206474 : indirect calls (=)
 190048784 : PLT calls (=)
        197898710201 : executed instructions (-1.1%)
         29587649281 : executed load instructions (=)
 0 : executed store instructions (=)
                   0 : taken jump table branches (=)
                   0 : taken unknown indirect branches (=)
         29525584401 : total branches (-0.8%)
          8373172882 : taken branches (-13.6%)
         21152411519 : non-taken conditional branches (+5.4%)
          7857886341 : taken conditional branches (-12.1%)
         29010297860 : all conditional branches (=)
 0 : linker-inserted veneer calls (=)

BOLT-INFO: Finished pass: print dyno-stats after optimizations
BOLT-INFO: Starting pass: simplify-conditional-tail-calls
BOLT-INFO: Finished pass: simplify-conditional-tail-calls
BOLT-INFO: Starting pass: peepholes
BOLT-INFO: Peephole: 114 double jumps patched.
BOLT-INFO: Peephole: 814 tail call traps inserted.
BOLT-INFO: Peephole: 0 useless conditional branches removed.
BOLT-INFO: Finished pass: peepholes
BOLT-INFO: Starting pass: aligner
BOLT-INFO: Finished pass: aligner
BOLT-INFO: Starting pass: reorder-data
BOLT-INFO: Finished pass: reorder-data
BOLT-INFO: Starting pass: adr-relaxation
BOLT-INFO: Finished pass: adr-relaxation
BOLT-INFO: Starting pass: long-jmp
BOLT-INFO: Starting stub-insertion pass
BOLT-INFO: Inserted 30963 stubs in the hot area and 11310 stubs in the cold area. Shared 0 times, iterated 3 times.
BOLT-INFO: Finished pass: long-jmp
BOLT-INFO: Starting pass: finalize-functions
BOLT-INFO: Finished pass: finalize-functions
BOLT-INFO: Starting pass: frame-optimizer
BOLT-INFO: buildCallGraph: 63578 nodes, 341627 callsites (859 recursive), density = 0.000042, 77720 callsites not processed, 10164 callsites with invalid profile, used perf data for 0 stale functions.
not implemented
UNREACHABLE executed at bolt/include/bolt/Core/MCPlusBuilder.h:597!
not implemented
UNREACHABLE executed at bolt/include/bolt/Core/MCPlusBuilder.h:597!
not implemented
UNREACHABLE executed at bolt/include/bolt/Core/MCPlusBuilder.h:597!
[2]    4158564 abort (core dumped)  ./llvm-bolt  -o   --keep-nops --reorder-blocks=ext-tsp --split-functions 
```

### Question
Does bolt support the activation of frame-opt option under the AArch64 architecture?

</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJzcWMty2zoS_Rp6g6IKD4IAF1rI9tVMqjI3nkmmZg2RLRExBLAA0I7z9VMgKVtv-W4vS4uE7nPQOP0gGioEvbEA84zfZ_zxTvWxdX7-2ro-wPbNqi3crVzzNs8oG3_oybuVgS1qINRed1E7m-HF_1qwqA_abtDKmYiiQ66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