================
@@ -1769,6 +1775,39 @@ void AArch64AsmPrinter::emitPtrauthAuthResign(const 
MachineInstr *MI) {
     OutStreamer->emitLabel(EndSym);
 }
 
+void AArch64AsmPrinter::emitPtrauthBranch(const MachineInstr *MI) {
+  unsigned InstsEmitted = 0;
+
+  unsigned BrTarget = MI->getOperand(0).getReg();
+  auto Key = (AArch64PACKey::ID)MI->getOperand(1).getImm();
----------------
kovdan01 wrote:

There is an assertion against `Disc` that it fits 16 bits, we probably want to 
have an assertion against `Key` as well. For example, in 
`AArch64AsmPrinter::emitInstruction` below this approach is already used - we 
first store the `Key` as `uint64_t` and then check that it's value is valid.

https://github.com/llvm/llvm-project/pull/85736
_______________________________________________
llvm-branch-commits mailing list
llvm-branch-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

Reply via email to