Jakub Konka
d565c5dfcd
macho: fix a sad typo in calculating the address of a TLV pointer
2024-03-15 08:17:10 +01:00
Elaine Gibson
6b38758594
coff: only store PDB basename
2024-03-14 18:56:02 -07:00
Matthew Lugg
39459e78ad
Merge pull request #19273 from mlugg/incremental-some-more
...
compiler: more progress on incremental
2024-03-14 17:45:21 +00:00
Motiejus Jakštys
400145ee3b
reduce garbage for repeated zig cc - calls
...
Context: user provides `-` to read from stdin instead of a file.
Before: it would create a file in $ZIG_LOCAL_CACHE_DIR/tmp/ for each
invocation and leave it there.
After: it hashes the file contents and renames the file to the hash.
Result: repeated invocations of `zig cc` do not cause so much trash to
be created.
2024-03-14 09:32:56 -07:00
mlugg
7c32370194
Zcu: preserve ordering of usingnamespace decls
...
See comment. This slightly regresses a previous fix from this branch. A
proper solution will come soon, with the splitting up of `Decl` into
`Cau` and `Nav`.
2024-03-14 07:40:08 +00:00
mlugg
347196f905
Zcu: perform orphan checks against uncoerced function
2024-03-14 07:40:08 +00:00
mlugg
075c103332
compiler: add func_ies incremental dependencies
...
This was an oversight in my original design. This new form of dependency
is invalidated when the resolved IES for a runtime function changes.
2024-03-14 07:40:08 +00:00
mlugg
1421d329a3
compiler: progress towards incremental
...
Most basic re-analysis logic is now in place. Trivial updates are
hitting linker assertions.
2024-03-14 07:40:07 +00:00
mlugg
7ba8641d19
Zcu: handle updates to file root struct
2024-03-14 07:40:07 +00:00
mlugg
42fedb3f6c
Zcu: handle incremental updates (more) correctly when scanning namespaces
2024-03-14 07:40:06 +00:00
mlugg
d4ce1ec8dd
Zcu: convert Decl.zir_inst_index to a TrackedInst.Index.Optional
...
This makes tracking easier across incremental updates: `scanDecl` can
now tell whether an existing decl in a namespace was mapped to the one
it's analyzing in the new ZIR.
2024-03-14 07:40:06 +00:00
mlugg
7c4793f23c
Zcu: remove old decls after scanning namespace
2024-03-14 07:40:06 +00:00
mlugg
48af67c152
Zcu: rename implicitly-named decls to avoid overriding by explicit decls
2024-03-14 07:40:05 +00:00
mlugg
00969062a9
compiler: detect duplicate test names in AstGen
...
There is no reason to perform this detection during semantic analysis.
In fact, doing so is problematic, because we wish to utilize detection
of existing decls in a namespace in incremental compilation.
2024-03-14 07:40:05 +00:00
Jakub Konka
55c085b893
elf: re-use output buffer for emitting thunks
2024-03-12 13:25:29 +01:00
Jakub Konka
faa4bdb017
elf+aarch64: fix off-by-one in converging on groups interleaved with thunks
2024-03-12 13:16:11 +01:00
Jakub Konka
b1eba5a996
elf+aarch64: actually write out thunks, and add a proper link test
2024-03-12 13:16:11 +01:00
Andrew Kelley
bd24e66379
Merge pull request #19229 from tiehuis/ryu-128
...
std.fmt: add ryu floating-point formatting implementation
2024-03-11 18:46:26 -07:00
Andrew Kelley
0c61466771
Merge pull request #19174 from squeek502/lazy-resinator
...
Lazily compile the `zig rc` subcommand and use it during `zig build-exe`, etc
2024-03-11 17:18:09 -07:00
Andrew Kelley
f60c24c73c
Merge pull request #19155 from ianic/tar_max_file_size
...
std.tar: error on insufficient buffers provided to iterator
2024-03-11 17:03:44 -07:00
Igor Anić
f8f43ca3e1
package: remove git fetch zlib lookahead fix
...
My first zlib implementation broke git fetch because it introduce
[lookahead](https://github.com/ziglang/zig/issues/18967 ). That resulted
in workarounds [1](80f3ef6e14 )
[2](d00faa2407 )
After [fixing](https://github.com/ziglang/zig/pull/19163 ) lookahead in
zlib decompressor this fixes are no longer necessary.
2024-03-11 16:49:21 -07:00
Tristan Ross
6067d39522
std.builtin: make atomic order fields lowercase
2024-03-11 07:09:10 -07:00
Tristan Ross
c260b4c753
std.builtin: make global linkage fields lowercase
2024-03-11 07:09:10 -07:00
Tristan Ross
aab84a3dec
std.builtin: make float mode fields lowercase
2024-03-11 07:09:10 -07:00
Tristan Ross
9d70d614ae
std.builtin: make link mode fields lowercase
2024-03-11 07:09:10 -07:00
Tristan Ross
099f3c4039
std.builtin: make container layout fields lowercase
2024-03-11 07:09:07 -07:00
Ryan Liptak
c32e0d3000
Fix progress when multiple zig rc child processes are building resinator
2024-03-11 05:06:17 -07:00
Ryan Liptak
8799f7466d
Report the progress of lazily building zig rc
...
jitCmd now takes a `server` option that will emit progress/errors via std.zig.Server when enabled.
2024-03-11 05:06:17 -07:00
Ryan Liptak
7c05330287
Integrate resinator errors with Zig using std.zig.Server and ErrorBundle
...
This takes the code that was previously in src/Compilation.zig to turn resinator diagnostics into Zig error bundles and puts it in resinator/main.zig, and then makes resinator emit the resulting error bundles via std.zig.Server (which is used by the build runner, etc). Also adds support for turning Aro diagnostics into ErrorBundles.
2024-03-11 05:06:16 -07:00
Ryan Liptak
52de2802c4
Lazily compile the zig rc subcommand and use it during zig build-exe
...
This moves .rc/.manifest compilation out of the main Zig binary, contributing towards #19063
Also:
- Make resinator use Aro as its preprocessor instead of clang
- Sync resinator with upstream
2024-03-11 05:06:16 -07:00
Igor Anić
0cca7e732e
std.tar: fix broken public interface
2024-03-11 12:25:51 +01:00
Andrew Kelley
1397341540
add missing field to module creation
...
Fixes a merge conflict with one of mlugg's recent branches.
2024-03-10 18:22:53 -07:00
Andrew Kelley
6b8c7540a8
fix 32 bit compilation
2024-03-10 17:51:07 -07:00
Andrew Kelley
8b70e4f2c9
autodocs: fix root name and missing dir close
2024-03-10 17:51:07 -07:00
Andrew Kelley
261094ca85
-femit-docs: create main.wasm artifact
2024-03-10 17:51:07 -07:00
Andrew Kelley
ffd53a459e
-femit-docs: creating sources.tar
...
It's always a good day when you get to use File.writeFileAll 😎
2024-03-10 17:51:07 -07:00
Andrew Kelley
91260459e3
frontend: skeleton for creating autodocs
...
This time, unlike the old implementation, it properly does autodoc
generation during the compilation pipeline, saving time.
2024-03-10 17:51:06 -07:00
Andrew Kelley
33f3443243
add zig std subcommand
2024-03-10 17:51:06 -07:00
Andrew Kelley
356e653f9b
better to use AST than ZIR for doc generation
2024-03-10 17:51:05 -07:00
Jakub Konka
c1bda06c14
Merge pull request #19225 from ziglang/elf-aarch64
...
elf: port aarch64 support from zld
2024-03-10 15:32:58 +01:00
Marc Tiehuis
bb1fe112f1
wasm/codegen: add "and" + "or" impl for big ints
2024-03-10 18:15:15 +13:00
Jakub Konka
2cdbad6f10
elf+aarch64: handle PREL64 reloc
2024-03-09 19:34:34 +01:00
Jakub Konka
229468b7a9
elf+aarch64: fix 32bit build
2024-03-09 18:55:52 +01:00
mlugg
e2cbbd0c26
Sema: perform codegen for anon decl created by @extern
...
This fixes a bug where, at least with the LLVM backend, `@extern` calls
which had the same name as a normal `extern` in the same Zcu would
result in the `@extern` incorrectly suffixing the identifier `.2`.
Usually, the LLVM backend has a system to change the generated globals
to "collapse" them all together, but it only works if `updateDecl` is
called!
2024-03-09 04:52:06 +00:00
Jakub Konka
859f9a22c4
elf+aarch64: implement basic thunk support
2024-03-08 22:46:18 +01:00
Jakub Konka
7c5ddb6ae4
elf+aarch64: handle PREL32 reloc
2024-03-08 22:46:18 +01:00
Jakub Konka
47100bd40a
elf+aarch64: handle TLS GD model
2024-03-08 22:46:18 +01:00
Jakub Konka
b343103567
elf+aarch64: handle gottp and .tls_common
2024-03-08 22:46:18 +01:00
Jakub Konka
7258d143e3
elf+aarch64: fix incorrectly emitted TLSDESC relocs
2024-03-08 22:46:17 +01:00
Jakub Konka
b5642b4f85
elf+aarch64: set _GLOBAL_OFFSET_TABLE_ to .got section
2024-03-08 22:46:17 +01:00