aboutsummaryrefslogtreecommitdiff
path: root/src/arch/aarch64/Mir.zig
AgeCommit message (Collapse)Author
2025-07-02compiler: delete aarch64 backendAndrew Kelley
this backend was abandoned before it was completed, and it is not worth salvaging.
2025-06-12x86_64: remove air references from mirJacob Young
2025-06-12compiler: get most backends compiling againmlugg
As of this commit, every backend other than self-hosted Wasm and self-hosted SPIR-V compiles and (at least somewhat) functions again. Those two backends are currently disabled with panics. Note that `Zcu.Feature.separate_thread` is *not* enabled for the fixed backends. Avoiding linker references from codegen is a non-trivial task, and can be done after this branch.
2024-10-10arch/aarch64/Mir: fix spelling (pseudo instead of psuedo)Samuel Fiedler
2024-03-01compiler: audit debug mode checksJacob Young
* Introduce `-Ddebug-extensions` for enabling compiler debug helpers * Replace safety mode checks with `std.debug.runtime_safety` * Replace debugger helper checks with `!builtin.strip_debug_info` Sometimes, you just have to debug optimized compilers...
2023-06-24all: migrate code to new cast builtin syntaxmlugg
Most of this migration was performed automatically with `zig fmt`. There were a few exceptions which I had to manually fix: * `@alignCast` and `@addrSpaceCast` cannot be automatically rewritten * `@truncate`'s fixup is incorrect for vectors * Test cases are not formatted, and their error locations change
2022-12-17std.builtin: rename Type.UnionField and Type.StructField's field_type to typer00ster91
2022-11-05coff: compile and link simple exit program on arm64Jakub Konka
* make image base target dependent * fix relocs to imports
2022-11-01stage2 AArch64: implement min/maxjoachimschmidt557
2022-10-20stage2 AArch64: introduce ldr_ptr_stack Mir instructionjoachimschmidt557
2022-10-20stage2 AArch64: simplify allocMemjoachimschmidt557
2022-09-13stage2: support being built in ReleaseSafe modeAndrew Kelley
2022-08-05stage2 AArch64: implement basic integer rem/modjoachimschmidt557
2022-08-05stage2 AArch64: implement basic integer divisionjoachimschmidt557
2022-08-05stage2 AArch64: all arguments passed via stack from now onjoachimschmidt557
Only in the Undefined calling convention, not in other calling conventions
2022-08-05stage2 AArch64: introduce MCValue.stack_argument_offsetjoachimschmidt557
This new MCValue union member shares the same semantics as the MCValue type of the same name in the ARM backend.
2022-07-22macho: improve logs for dyld infoJakub Konka
2022-07-22macho: rework symbol handling to match zld/ELFJakub Konka
Now, each object file will store a mutable table of symbols that it defines. Upon symbol resolution between object files, the symbol will be updated with a globally allocated section ordinal and address in virtual memory. If the object defines a globally available symbol, its location only (comprising of the symbol index and object index) will be stored in the globals map for easy access when relocating, etc. This approach cleans up the symbol management significantly, and matches the status quo used in zld/ELF. Additionally, this makes scoping symbol stabs easier too as they are now naturally contained within each object file.
2022-05-05aarch64: fix mul_with_overflow for ints <= 32bitsJakub Konka
2022-05-05aarch64: implement mul_with_overflow for ints in range 33-64 bits inclJakub Konka
2022-05-05aarch64: implement mul_with_overflow for <= 32bit intsJakub Konka
Add emitters for `smull`, `umull` and `tst (immediate)` instructions.
2022-05-05stage2 AArch64: implement {add,sub}_with_overflow for all ints < 64joachimschmidt557
2022-04-19stage2 AArch64: Add ldrsb, ldrsh instructionsjoachimschmidt557
2022-04-19stage2 AArch64: Implement basic truncate functionalityjoachimschmidt557
2022-03-25stage2 AArch64: lower cmp to binOpjoachimschmidt557
2022-03-13stage2 AArch64: Implement bit shifting with immediate operandsjoachimschmidt557
2022-03-13stage2 AArch64: implement bit shifts with register operandsjoachimschmidt557
2022-03-05stage2 AArch64: implement bitwise binary operationsjoachimschmidt557
for integers with bit sizes <= 64
2022-03-05stage2 AArch64: introduce logical immediate instructionsjoachimschmidt557
2022-02-23stage2 AArch64: more support for MCValue.got_load and direct_loadjoachimschmidt557
2022-02-23stage2 AArch64: remove MIR load_memory instructionjoachimschmidt557
This instruction now just represents loading from a hard-coded adrress after extracting the other use cases for load_memory into load_got and load_direct.
2022-02-15aarch64: introduce MCValue.got_load and MCValue.direct_loadJakub Konka
This matches the current design in x86_64 backend and significantly simplifies handling of PIE targets in aarch64 backend.
2022-02-14stage2 AArch64: Implement not for booleansjoachimschmidt557
2022-02-14stage2 AArch64: implement cond_br for other MCValuesjoachimschmidt557
2022-02-14stage2 AArch64: Implement binOp for add, subjoachimschmidt557
2022-02-14stage2 AArch64: minor refactors in Mir + Emitjoachimschmidt557
2022-02-14stage2 AArch64: implement slice_len and slice_elem_valjoachimschmidt557
2022-02-14stage2 AArch64: implement loading from registerjoachimschmidt557
2022-02-11macho: correctly lower slices incl reloc and rebase trackingJakub Konka
Match changes required to `Elf` linker, which enable lowering of const slices on `MachO` targets. Expand `Mir` instructions requiring the knowledge of the containing atom - pass the symbol index into the linker's table from codegen via mir to emitter, to then utilise it in the linker.
2022-01-14stage2 AArch64: split ldr/str into {ldr,str}_register and _immediatejoachimschmidt557
2021-12-19stage2 AArch64: Implement saving callee-saved registersjoachimschmidt557
2021-11-30allocgate: std Allocator interface refactorLee Cannon
2021-11-12stage2 AArch64: add new load/store from/to stack MIR instructionsjoachimschmidt557
2021-11-10stage2 AArch64: implement airCondBrjoachimschmidt557
2021-11-10stage2 AArch64: implement genSetReg for condition flagsjoachimschmidt557
2021-11-10stage2 AArch64: implement airCmpjoachimschmidt557
2021-10-31stage2 AArch64: implement emit debug line infojoachimschmidt557
2021-10-31stage2 AArch64 Emit: implement call_extern and load_memoryjoachimschmidt557
2021-10-31stage2 AArch64: begin transition to MIRjoachimschmidt557
This commit includes the transitions for the following instructions: - add_immediate - b - bl - blr - brk - ldp - ldr - ldrb - ldrh - mov_to_from_sp - mov_register - movk - movz - nop - ret - stp - str - strb - strh - sub_immediate - svc