use of undeclared identifier '$rdi'

I am on M1 (Xcode Version 15.4 (15F31d), MacOS 14.5 (23F79), Simulator IOS 17.4) and as far as I remember printing common usage register was possible. I am not sure why it stopped to work rid, rsi and etc (arg1 arg2 seems like still working).

rdi and rsi are register names defined by the x86_64 architecture, but the arm64 architecture of Apple silicon doesn't use the same nomenclature. arm64 numerically identifies the registers as x1, x2, etc.

— Ed Ford,  DTS Engineer

@DTS Engineer

Thanks for you answer (I was pretty sure that was the reason but just wanted a confirmation.) If possible I would like to ask a follow up question. Some time arg1, arg2 doesnt work correctly for some frames: So for instance I have the following frame:

frame #0: 0x000000010587ef98 Pendo`-[PNDScreenManager mymethod:arg1:arg2:](self=0x000060000176b300, _cmd="PNDScreenManager mymethod:arg1:arg2:", dict=0 key/value pairs, window=0x000000010370a400, rootViewController=0x000000010450b350) at PNDScreenManager.m:313:9

and those are the registers:

register read
General Purpose Registers:
        x0 = 0x0000000000000002
        x1 = 0x000000000000000d
        x2 = 0x000060000029ed80
        x3 = 0x0000000000000000
        x4 = 0x000000010450b350
        x5 = 0x0000000000000000
        x6 = 0x0000000000000000
        x7 = 0x0000000000000000
        x8 = 0x0000000105b5b4df  "PNDScreenManager mymethod:arg1:arg2:"
        x9 = 0x0abc76522d81005b
       x10 = 0x000000010371f948
       x11 = 0x000000000000001f
       x12 = 0x000000010371f940
       x13 = 0x0000000000000000
      ...

arg1 , and arg2 will print x0 and x1 as u suggested BUT not self and SEL and so on with rest of the parameters(as I would like). (only x4 the last parameter can be spotted). My question is: What will be the accurate and easy alternative for arg1, arg2 and etc (as it seems like x1,x2 are not consistent in that sense )

Thanks
(if you could share any documentation about arm64 registers and how to work/debug with them will be appreciated )

use of undeclared identifier '$rdi'
 
 
Q