dmd Arm64 - first function compile!
Brad Roberts
braddr at puremagic.com
Mon Jun 3 20:40:43 UTC 2024
On 6/3/2024 11:38 AM, Walter Bright via Digitalmars-d wrote:
> On 6/3/2024 9:41 AM, Ben Jones wrote:
>> On Sunday, 2 June 2024 at 06:30:18 UTC, Walter Bright wrote:
>>>
>>
>> What stuff can other contributors be helping with on this?
>>
>
> 1. add floating point instructions, SIMD, SVE and SME instructions to
> the disasmarm.d. It only currently does the Base Instructions.
>
> http://www.scs.stanford.edu/~zyedidia/arm64/index.html
>
>
> 2. using the Gnu assembler, `as`, write an example of every instruction.
> Collect the binary hex emitted, and add them as unit tests to the
> disassembler.
>
>
> 3. write an inline assembler. Much like the arm disassembler, this will
> be totally different from the way the x86 assembler works. I suggest
> making it work analogously to the way disasmarm.d works. The list of
> instructions written for (2) can be reused as the test suite for it.
>
>
> With the disassembler verified against `as`, and the inline assembler
> verified against the disassembler, then the instructions generated by
> the compiler can be much more easily verified.
You mean something like:
https://github.com/braddr/dmd/blob/arm/test/compilable/arm_iasm.d
https://github.com/braddr/dmd/blob/arm/src/iasm_arm.c
They only cover a subset of the instructions based on an older version
of the instruction set, but that still covers probably 90% of both
assembly and tests. It doesn't cover disassembly, as I just used
objdump from the standard gnu dev tool set.
More information about the Digitalmars-d
mailing list