On Sat, 27 Jun 2026 15:01:30 GMT, Yasumasa Suenaga <[email protected]> wrote:
>> I was actually implying moving it for a core file attach also. This just
>> doesn't seem like the proper place for CPU dependent code.
>
> Is the following code appropriate?
> Introduce `attachInternal()` in `LinuxDebuggerLocal` to call `attach0()`,
> then `LinuxAARCH64DebuggerLocal` overrides it to check PAC.
>
>
> @Override
> protected void attachInternal(int pid) throws DebuggerException) {
> super.attachInternal(pid); // call "attach0()" in super class
> (LinuxDebuggerLocal)
> if (pacEnabled()) {
> ((MachineDescriptionAArch64)d.getMachineDescription()).enablePAC();
> }
> }
We have to check PAC after attaching.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/31669#discussion_r3486247179