aboutsummaryrefslogtreecommitdiff
path: root/src/Compilation.zig
AgeCommit message (Collapse)Author
2025-11-20update deprecated ArrayListUnmanaged usage (#25958)Benjamin Jurk
2025-11-20update Aro and translate-c to latestVeikka Tuominen
2025-11-19compiler: fix crash if file contents change during updateMatthew Lugg
When reporting a compile error, we would load the new file, but assume we could apply old AST/token indices (etc) to it, potentially causing crashes. Instead, if the file stat has changed since it was loaded, just emit an error that the file was modified mid-update.
2025-11-14represent Mac Catalyst as aarch64-maccatalyst-none rather than ↵Alex Rønne Petersen
aarch64-ios-macabi Apple's own headers and tbd files prefer to think of Mac Catalyst as a distinct OS target. Earlier, when DriverKit support was added to LLVM, it was represented a distinct OS. So why Apple decided to only represent Mac Catalyst as an ABI in the target triple is beyond me. But this isn't the first time they've ignored established target triple norms (see: armv7k and aarch64_32) and it probably won't be the last. While doing this, I also audited all Darwin OS prongs throughout the codebase and made sure they cover all the tags.
2025-11-07Move/coalesce RcIncludes enum to `std.zig.RcIncludes`Ryan Liptak
2025-11-07Move/coalesce CompressDebugSections enum to `std.zig.CompressDebugSections`Ryan Liptak
2025-11-05Move `std.Target.SubSystem` to `std.zig.Subsystem`Carl Åstholm
Also updates the field names to conform with the rest of std.
2025-10-30Merge pull request #25558 from jacobly0/elfv2-load-objJacob Young
Elf2: start implementing input object loading
2025-10-30std.debug.lockStderrWriter: also return ttyconfMatthew Lugg
`std.Io.tty.Config.detect` may be an expensive check (e.g. involving syscalls), and doing it every time we need to print isn't really necessary; under normal usage, we can compute the value once and cache it for the whole program's execution. Since anyone outputting to stderr may reasonably want this information (in fact they are very likely to), it makes sense to cache it and return it from `lockStderrWriter`. Call sites who do not need it will experience no significant overhead, and can just ignore the TTY config with a `const w, _` destructure.
2025-10-29Elf2: load archivesJacob Young
2025-10-29Elf2: load relocations from input objectsJacob Young
2025-10-29Elf2: start implementing input object loadingJacob Young
2025-10-29compiler: update for introduction of std.IoAndrew Kelley
only thing remaining is using libc dns resolution when linking libc
2025-10-29progress towards compiler building againAndrew Kelley
2025-10-26Compilation: define __illumos__ for C/C++ when targeting illumosAlex Rønne Petersen
Per the illumos GCC fork.
2025-10-10Coff: implement threadlocal variablesJacob Young
2025-10-09- Output error messages for fatal translate-c errorskcbanner
2025-10-09- aroDiagnosticsToErrorBundle: fixup not clearing notes after flushing the ↵kcbanner
current error - Compilation: renameTmpIntoCache doesn't need to be pub after the `translateC` change
2025-10-09- Rework common translate-c and cImport logic into `Compilation.translateC`kcbanner
- Add std.zig.Server.allocErrorBundle, replace duplicates
2025-10-09- Rework translate-c to integrate with the build system (by outputing error ↵kcbanner
bundles on stdout) via --zig-integration - Revive some of the removed cache integration logic in `cmdTranslateC` now that `translate-c` can return error bundles - Fixup inconsistent path separators (on Windows) when building the aro include path - Move some error bundle logic from resinator into aro.Diagnostics - Add `ErrorBundle.addRootErrorMessageWithNotes` (extracted from resinator)
2025-10-06Elf2: implement virtual allocationJacob Young
This allows segments to be moved around in the output file without needing to reapply relocations until virtual address space is exhaused.
2025-10-05InternPool: use sequential string indices instead of byte offsetsJacob Young
This allows more bytes to be referenced by a smaller index range. Closes #22867 Closes #25297 Closes #25339
2025-10-03Merge pull request #25430 from jacobly0/x86_64-winJacob Young
Coff2: create a new linker from scratch
2025-10-03compiler: control the s390x backchain feature through the frame pointer optionAlex Rønne Petersen
This is a little different from how C/C++ compilers do this, but I think it's justified because it's what users actually *mean* when the use frame pointer options. This is another one of those LLVM "CPU" features that have nothing to do with CPU at all and should really be a TargetMachine option or something. One day we'll figure out a better way of dealing with these...
2025-10-02Coff: deleteJacob Young
2025-10-02Coff2: create a new linker from scratchJacob Young
2025-09-26Merge pull request #25342 from ziglang/fuzz-limitAndrew Kelley
fuzzing: implement limited fuzzing
2025-09-25Compilation: --debug-rt always DebugAndrew Kelley
--debug-rt previously would make rt libs match the root module. Now they are always debug when --debug-rt is passed. This includes compiler-rt, fuzzer lib, and others.
2025-09-24aro does not have -mmacos version flags or -Wno-overriding-optionAndrew Kelley
2025-09-24aro does not have a pragma-pack warningAndrew Kelley
2025-09-24`@cImport`: don't pass args to Aro it doesn't understandAndrew Kelley
2025-09-24Compilation: use renameTmpIntoCacheAndrew Kelley
solves several problems with this pattern
2025-09-24Compilation: re-implement cImportAndrew Kelley
2025-09-24fix rebase conflictsAndrew Kelley
2025-09-24Compilation: avoid passing Clang specific options to AroVeikka Tuominen
2025-09-24add translate-c CLI argsAndrew Kelley
2025-09-24compiler: update aro and translate-c to latest; delete clang translate-cAndrew Kelley
2025-09-21Elf2: create a new linker from scratchJacob Young
This iteration already has significantly better incremental support. Closes #24110
2025-09-10Merge pull request #24968 from ifreund/dequeAndrew Kelley
std: add a Deque data structure
2025-09-06Compilation: fix buildGlibcSharedObjects error handlingAndrew Kelley
Oops, this was supposed to be only a temporary troubleshooting patch.
2025-08-31std.fmt: delete deprecated APIsAndrew Kelley
std.fmt.Formatter -> std.fmt.Alt std.fmt.format -> std.Io.Writer.print
2025-08-30Merge pull request #25077 from ziglang/GenericReaderAndrew Kelley
std.Io: delete GenericReader, AnyReader, FixedBufferStream; and related API breakage
2025-08-30rework std.Io.Writer.Allocating to support runtime-known alignmentAndrew Kelley
Also, breaking API changes to: * std.fs.Dir.readFileAlloc * std.fs.Dir.readFileAllocOptions
2025-08-30zig cc: pass -mthumb to the assembler as necessaryAlex Rønne Petersen
2025-08-30zig cc: pass CPU features to Clang using the new -Xclangas when assemblingAlex Rønne Petersen
Unfortunately, we cannot yet remove the special-casing for RISC-V CPU features, so that code stays. Closes #10411.
2025-08-29std.Io: delete GenericReaderAndrew Kelley
and delete deprecated alias std.io
2025-08-28fix not discarding delimiterAndrew Kelley
perhaps these APIs have the defaults backwards, eh?
2025-08-27delete some vestigal dead codeAndrew Kelley
2025-08-26Compilation: use std.DequeIsaac Freund
And delete DeprecatedLinearFifo from the source tree.
2025-08-26std.Target: add vita osMaciej 'vesim' Kuliński
Co-authored-by: Alex Rønne Petersen <alex@alexrp.com>