10677 Commits

Author SHA1 Message Date
Koakuma
4687bc2730 stage2: sparc64: Implement airUnionInit 2022-12-10 21:11:14 +07:00
Koakuma
0bc936685b stage2: sparc64: Implement airErrorName 2022-12-10 21:11:14 +07:00
Koakuma
4ddedb3885 stage2: sparc64: Implement get/setUnionTag 2022-12-10 21:11:14 +07:00
Andrew Kelley
7637ac584f
Merge pull request #13821 from Vexu/eliminate-bound-fn
Eliminate `BoundFn` type from the language
2022-12-10 06:14:57 -05:00
Andrew Kelley
02b221051a fix aarch64-windows-gnu libc
We were missing some math functions. After this enhancement I verified
that I was able to cross-compile ninja.exe for aarch64-windows and
produce a viable binary.
2022-12-10 03:06:17 -05:00
Veikka Tuominen
9d93b2ccf1 Eliminate BoundFn type from the language
Closes #9484
2022-12-09 20:37:18 -07:00
Veikka Tuominen
5831b68341 AstGen: add check for missing builtin argument
Closes #13817
2022-12-09 20:37:18 -07:00
Jakub Konka
f7fea080b2 macho+zld: skip atomless synthetic globals in dead_strip
They are implicitly marked live.
2022-12-09 21:12:38 +01:00
Jakub Konka
182751ba27 Revert "coff: specify default base path for relative source paths in pdb" 2022-12-09 14:16:44 +01:00
Jakub Konka
4d640f9bb9 dwarf: resolve all relative paths when generating include_dirs and file_names lists 2022-12-09 14:16:44 +01:00
Jakub Konka
bda5180b2c llvm: resolve all relative paths when creating DIFiles
This will make stack traces and debugging experience more consistent
in the sense that the presence of source lines in stack traces will
not be dependent on the current working directory of the running process.
2022-12-09 14:16:44 +01:00
Jakub Konka
9735953ae2 wasm: implement moving debug_line program when header too big 2022-12-09 09:24:25 +01:00
Jakub Konka
742aa94280 dsym: hint linker when file range copy is not necessary 2022-12-09 09:24:25 +01:00
Jakub Konka
9ade4f6d8c elf: hint linker when file range copy is not necessary 2022-12-09 09:24:25 +01:00
Jakub Konka
d7e42014ca elf: add growAllocSection and growNonAllocSection
Update `Dwarf.zig` to use `growNonAllocSection` for ELF and implement
routine to make space for `.debug_line` header.
2022-12-09 09:24:25 +01:00
Jakub Konka
aa2f48f013 dsym: reuse growSection where possible 2022-12-09 09:24:25 +01:00
Jakub Konka
fa44c73c1e dwarf: move any remaining section growth to dsym 2022-12-09 09:24:25 +01:00
Jakub Konka
b14e580ad8 dwarf: move growing debug_aranges section to dsym 2022-12-09 09:24:25 +01:00
Jakub Konka
136a508027 dsym: finish markDirty helper 2022-12-09 09:24:25 +01:00
Jakub Konka
ecb341a006 dwarf: move growing debug_abbrev section to dsym 2022-12-09 09:24:25 +01:00
Jakub Konka
381abcfb7a dwarf: move another sect growing routine to d_sym 2022-12-09 09:24:25 +01:00
Jakub Konka
4bb66b63ba macho: add helper for getting ptr to DebugSymbols 2022-12-09 09:24:25 +01:00
Jakub Konka
05e221796a dwarf+d_sym: move logic for growing section to d_sym 2022-12-09 09:24:25 +01:00
Jakub Konka
4c38ba7d1b dwarf: move SrcFns if debug_line header exceeded its padding 2022-12-09 09:24:25 +01:00
Jakub Konka
be2b85f670 dwarf: refactor object file format and ptr width switches in writeDbgLineHeader 2022-12-09 09:24:25 +01:00
Jakub Konka
8e71a79e4b dwarf: fix incorrect calc of dir index 2022-12-09 09:24:25 +01:00
Jakub Konka
62145a1b08 dwarf: refactor routine for precalculating size of dbg line header 2022-12-09 09:24:25 +01:00
Jakub Konka
6817219e27 dwarf: generate list of include dirs and file names like LLVM backend 2022-12-09 09:24:25 +01:00
Jakub Konka
6ec34edb9a dwarf: fully resolve each path to each file source 2022-12-09 09:24:25 +01:00
Jakub Konka
f5c764d892 dwarf: track source files via *const Module.File pointers 2022-12-09 09:24:25 +01:00
Jakub Konka
4c4821d993 dwarf: specify all referenced zig source files 2022-12-09 09:24:25 +01:00
Veikka Tuominen
ee9fc54cd0 TypedValue: fix handling of tuples represented as empty_struct_value 2022-12-08 22:21:49 +02:00
Veikka Tuominen
d5ecb318c4 Sema: check for uneeded src loc when using --debug-compile-errors 2022-12-08 11:10:08 +02:00
Veikka Tuominen
f8dcd34775 TypedValue.print: detect string literals
Closes #4281
Closes #13785
2022-12-07 20:32:27 +02:00
Veikka Tuominen
dff32a2cd7 Sema: resolve lazy values in analyzeMinMax
Closes #13797
2022-12-07 14:48:24 +02:00
Veikka Tuominen
ddce76059b Sema: add error for @tagName on empty enum 2022-12-07 14:48:24 +02:00
Veikka Tuominen
d078d08e4f Sema: export function instead of the constant referencing it
Closes #13706
2022-12-07 14:48:24 +02:00
Veikka Tuominen
92f1a29c40 AstGen: make @compileError operand implicitly comptime
This matches the language reference.
2022-12-07 14:48:24 +02:00
Andrew Kelley
53a9ee699a
Merge pull request #13799 from ziglang/close-stage1-issues
close stage1 issues
2022-12-07 03:06:10 -05:00
Casey Banner
8ccb9a6ad3
cache: Fix LockViolation during C compilation paths (#13591)
- C compilation flows didn't hold an exclusive lock on the cache manifest file when writing to it in all cases
- On windows, explicitly unlock the file lock before closing it
2022-12-06 23:15:54 -05:00
Andrew Kelley
50eb7983cd remove most conditional compilation based on stage1
There are still a few occurrences of "stage1" in the standard library
and self-hosted compiler source, however, these instances need a bit
more careful inspection to ensure no breakage.
2022-12-06 20:38:54 -07:00
Andrew Kelley
b7b905d227 add behavior test for while(true) not needing else unreachable
closes #707
2022-12-06 17:57:27 -07:00
Andrew Kelley
e7d28344fa
Merge pull request #13560 from ziglang/wasi-bootstrap
Nuke the C++ implementation of Zig from orbit using WASI
2022-12-06 18:52:39 -05:00
Frank Denis
817cf6a82e
Update wasi-libc to 8b7148f69ae241a2749b3defe4606da8143b72e0 (#13793) 2022-12-06 22:48:35 +00:00
Andrew Kelley
3f693cf5d5 CLI: quality of life enhancement for windows CBE behavior tests
When testing with

```
stage4/bin/zig test ../test/behavior.zig -I../test -ofmt=c -target x86_64-windows
```

previously, one would see this message:

```
error: lld-link: subsystem must be defined
```

Now, `--subsystem console` as well as `-lntdll -lkernel32` are on the
`zig run` line, producing a binary.
2022-12-06 12:46:59 -07:00
Jacob Young
91e489174b CBE: avoid trailing space 2022-12-06 12:27:28 -07:00
Jacob Young
3686787f67 CBE: add windows-specific reserved identifiers 2022-12-06 12:27:28 -07:00
Andrew Kelley
823d1e7087 add std.heap.wasm_allocator 2022-12-06 12:27:28 -07:00
Andrew Kelley
a3fadd2813 stage2: revert change to handling of --color on
This change has been extracted to #13786 and can be solved separately
than this branch.
2022-12-06 12:15:05 -07:00
Andrew Kelley
cb012490ee translate-c: fix wrong logic adjustment
In ea9ad1e85dd5e2ba18e7d55f7a7f9694282159f1, I incorrectly applied
boolean logic to one of the pieces of logic, resulting in a regression
in translate-c.
2022-12-06 12:15:05 -07:00