From ccaa4bfbf0f951b08e77edbec8c76cffcd705541 Mon Sep 17 00:00:00 2001 From: Lysann Tranvouez Date: Wed, 1 Oct 2025 22:14:43 +0200 Subject: [PATCH] fixing some comments --- src/arm64/detours_arm64.h | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/arm64/detours_arm64.h b/src/arm64/detours_arm64.h index cfea12f..f031fe7 100644 --- a/src/arm64/detours_arm64.h +++ b/src/arm64/detours_arm64.h @@ -12,12 +12,11 @@ typedef struct detour_trampoline // An ARM64 instruction is 4 bytes long. // // The overwrite is always composed of 3 instructions (12 bytes) which perform an indirect jump - // using _DETOUR_TRAMPOLINE::pbDetour as the address holding the target location. + // using detour_trampoline::ptr_detour as the address holding the target location. // // Copied instructions can expand. // - // The scheme using MovImmediate can cause an instruction - // to grow as much as 6 times. + // The scheme using MovImmediate can cause an instruction to grow as much as 6 times. // That would be Bcc or Tbz with a large address space: // 4 instructions to form immediate // inverted tbz/bcc @@ -27,11 +26,11 @@ typedef struct detour_trampoline // 3 instructions to form immediate // br or brl // - // A theoretical maximum for rbCode is thefore 4*4*6 + 16 = 112 (another 16 for jmp to pbRemain). + // A theoretical maximum for `code` is therefore 4*4*6 + 16 = 112 (another 16 for jmp to ptr_remain). // // With literals, the maximum expansion is 5, including the literals: 4*4*5 + 16 = 96. // - // The number is rounded up to 128. m_rbScratchDst should match this. + // The number is rounded up to 128. // uint8_t code[128]; // target code + jmp to pbRemain uint8_t code_size; // size of moved target code.