Skip to content

Calls to ___chkstk_darwin result in HLIL statements with no apparent side effects #7343

Description

@withzombies

Version and Platform (required):

  • Binary Ninja Version: 5.2.8313-dev
  • Edition: Commercial
  • OS: macOS
  • OS Version: 15.6.1
  • CPU Architecture: ARM64

Bug Description:

100005874    int64_t sub_100005874(int64_t arg1, int64_t arg2, int64_t arg3 @ x20)

100005884        int64_t var_20 = arg3
100005898        int64_t var_c0 = arg1
1000058a0        void* x0 = _$s8Dispatch0A13WorkItemFlagsVMa(0)
1000058a8        void* x8 = *(x0 - 8)
1000058b0        *(x8 + 0x40)

^-- what is this?

1000058d0        void* x21 = &var_c0 - ((___chkstk_darwin() + 0xf) & 0xfffffffffffffff0)
1000058dc        void* x0_1 = _$s8Dispatch0A3QoSVMa(0)
1000058e0        void* x8_5 = *(x0_1 - 8)
1000058e8        *(x8_5 + 0x40)

^-- what is this?

100005908        void* x23 = x21 - ((___chkstk_darwin() + 0xf) & 0xfffffffffffffff0)
100005914        void* x0_2 = _$s8Dispatch0A4TimeVMa(0)
10000591c        void* x27 = *(x0_2 - 8)
100005920        *(x27 + 0x40)

^-- what is this?

100005940        void* x22 = x23 - ((___chkstk_darwin() + 0xf) & 0xfffffffffffffff0)
10000595c        void* x25 = x22 - ___chkstk_darwin()

Steps To Reproduce:
Open the Rectangle.app binary as ARM64 and browse to 0x100005874.

Expected Behavior:
Statements that have side effects.

Screenshots/Video Recording:
If applicable, please add screenshots/video recording here to help explain your problem.

Binary:

Rectangle.bndb.zip

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions