This repository is an educational companion to the book 'Programming with 64-Bit ARM Assembly Language', adapted for Apple Silicon (ARM64 macOS, iOS, watchOS, tvOS). It contains 16 chapters of progressively complex assembly examples, covering system calls, memory addressing, functions, floating-point, NEON, and optimization. The code demonstrates key differences between Linux and Darwin (Apple) ABIs, such as syscall numbers, addressing modes (ADRP/ADD vs LDR =symbol), and variadic function calling conventions. It includes reusable debug macros (printReg, printStr) for register inspection, file I/O macros, and a toupper function callable from C, Python, and Swift. The project also features an Xcode SwiftUI app that integrates assembly code across multiple Apple platforms. The repository is well-maintained and actively used as a reference for Apple Silicon assembly development.
This is a Swift-based command-line tool and library (Injection framework) for manipulating Mach-O binaries. It can inject, remove, or alter load commands (LC_LOAD_DYLIB, LC_LOAD_WEAK_DYLIB, etc.) into executables, dylibs, and IPA archives. The tool also supports stripping code signatures, disabling ASLR, converting binaries for iOS simulator, and handling fat binaries. The code directly parses Mach-O headers and performs byte-level binary patching. It is built with the Swift Argument Parser and is available as both a CLI and a framework for integration into other macOS/iOS projects. The code demonstrates solid understanding of the Mach-O format and low-level binary manipulation, though there is some code duplication between the CLI and framework targets.