![]() When used for 64-bit, they’re named X0 to X30, and for 32-bit they’re W0 to W30. There are 31 general-purpose registers, each of which can be used for 64- or 32-bit values. When calling and running routines like this, you’re most concerned with the first two, which are explained in detail in ARM’s Procedure Call Standard (references below), and Apple’s platform-specific document (references). ![]() The processor has three main types of register: general-purpose, floating point (including SIMD) and special. For any of that to make sense, you first need to understand the register architecture of the ARM64 processor. Stepping through the lines of assembly, that first saves a set of registers, performs the floating point operation I want, restores the registers, and returns. In that first article, I glibly produced a C wrapper ofĮxtern double multadd(double, double, double) This article starts to explain the mechanics of writing your own routines, by explaining the register architecture of ARM64 processors. In that, I provided a short and simple demonstration of calling an assembly routine and getting its result. ![]() In the first article in this series on developing for Apple Silicon Macs using assembly language, I built a simple framework AsmAttic to use as the basis for developing ARM assembly language routines. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |