Andrew Kelley
dae7aeb337
llvm: add valgrind client request integration for x86_64
...
closes #12500
2022-08-22 16:04:07 -07:00
Andrew Kelley
ecdd4a9fe8
build system: add flag for -fstack-protector
2022-08-22 15:11:34 -07:00
Andrew Kelley
c955379504
Revert "test_runner: workaround #1923 , isolating error traces in tests"
...
This reverts commit 1a32f2a7f40328799537cc94240a57054a1275bc.
Sorry, this workaround is not welcome. Instead, please solve the actual
issue by doing the accepted behavior in the compiler itself:
> in a catch or else (handling a returned error), if the block does not
> try or return error.xyz, set the index to 0
This also applies to if statements, such as the one that test runner is
doing just above this hack.
2022-08-22 11:46:54 -07:00
Techcable
1a32f2a7f4
test_runner: workaround #1923 , isolating error traces in tests
...
Essentially #1923 means "caught" errors still show up in error return traces.
The correct fix would require the compiler to fix this, but that could affect performance.
For now, simply workaround this issue by clearing the return traces
between tests.
This means that "caught" errors in one test will not show up in the
error traces of other tests.
2022-08-22 14:38:03 +03:00
Veikka Tuominen
8667d6d61e
Merge pull request #12563 from Vexu/stage2-fixes
...
Stage2 fixes
2022-08-22 14:32:31 +03:00
Veikka Tuominen
5404dcdfd8
Sema: fix fieldCallBind on tuples and anon structs
...
Closes #12573
2022-08-22 14:31:58 +03:00
InKryption
f1999712b0
std.io.Reader: bounded array functions
...
* Add readIntoBoundedBytes
* Add readBoundedBytes
2022-08-22 14:07:22 +03:00
Shane Kennedy
cd5a9ba1f4
lagnref: add signed integer repr documentation
...
Closes #11103
2022-08-22 13:57:51 +03:00
Justas Zabulionis
24d718e7eb
std.valgrind.callgrind: fix string type
...
Fixes the error when using std.vallgrind.callgrind:
error: expected type '[2]u8', found '*const [2:0]u8'
2022-08-22 13:55:00 +03:00
Veikka Tuominen
560baf67ce
Sema: fix implicit cast from extern fn to fn ptr
...
Closes #12570
2022-08-22 11:16:36 +03:00
Veikka Tuominen
b0bcd4add2
Sema: allow optional pointers in packed structs
...
Closes #12572
2022-08-22 11:16:36 +03:00
Veikka Tuominen
74c7782c60
Sema: make orelse with C pointers behave like stage1 for now
...
Closes #12537
2022-08-22 11:16:36 +03:00
Veikka Tuominen
c1afe57d70
Sema: resolve lazy values in resolveMaybeUndefValIntable
...
Closes #12512
Closes #12513
2022-08-22 11:16:36 +03:00
Veikka Tuominen
b55a5007fa
Sema: fix parameter of type 'T' must be comptime error
...
Closes #12519
Closes #12505
2022-08-22 11:16:36 +03:00
Veikka Tuominen
b2f02a820f
Sema: check for astgen failures in semaStructFields
...
The struct might be a top level struct in which case it might not have Zir.
Closes #12548
2022-08-22 11:16:36 +03:00
Jakub Konka
6c020cdb76
Merge pull request #12557 from Luukdegram/wasm-archive
...
wasm-linker: Improve archive linking
2022-08-22 08:38:41 +02:00
John Schmidt
9cf667a21b
Enable unexpectedErrno error tracing for stage2 LLVM
...
Stage2 seems to be able to handle this now.
2022-08-21 23:41:01 +03:00
Luuk de Gram
d4c56804df
std: fix EmulatableRunStep
...
Fixes a compilation error when using the `EmulatableRunStep`
that is being generated from a step directly using `runEmulatable`.
2022-08-21 16:42:11 +02:00
Veikka Tuominen
02070ae26b
Merge pull request #12499 from Vexu/explain-why-called-at-comptime
...
stage2: add note about function call being comptime because of comptime only return type
2022-08-21 17:27:52 +03:00
Veikka Tuominen
20d0018d79
Sema: ignore dbg_block instructions when checking for comptimeness
...
Closes #12514
2022-08-21 12:53:19 +03:00
Veikka Tuominen
d48af541c7
Sema: handle union and enum field order being different
...
Closes #12543
2022-08-21 12:51:40 +03:00
Veikka Tuominen
e8102d8738
Sema: add note about function call being comptime because of comptime only return type
2022-08-21 12:24:48 +03:00
Jakub Konka
4a98385b0a
macho: do not leave file descriptors open if unused
...
This manifested in different `AccessDenied` errors on Windows when
trying to do an atomic file copying in the compiler/linker.
2022-08-20 19:41:23 +02:00
Luuk de Gram
7fe2a3d104
test/link: add wasm linker-test for archives
...
Adds a test case that will pull-in compiler-rt symbols,
and therefore link with the compiler-rt archive file.
2022-08-20 15:46:39 +02:00
Luuk de Gram
1544625df3
wasm/Object: parse using the correct file size
...
When an object file is being parsed from within an archive
file, we provide the object file size to ensure we do not
read past the object file. This is because follow up object
files can exist there, as well as an LF character to notate
the end of the file was reached. Such a character is invalid
within the object file.
This also fixes a bug in getting the function/global type
for defined globals/functions from object files as it was missing
the substraction with the import count of the respective type.
2022-08-20 14:50:11 +02:00
Luuk de Gram
aca911ca18
wasm/archive: correctly parse long file names
...
Wasm archive files are encoded the same way as GNU.
This means that the header notates the character index within
the long file name list rather than the length of the name.
The entire name is then delimited by an LF character (0x0a).
This also makes a cosmetic update to remove the `self` name,
and rather label it as `archive` instead.
2022-08-20 14:50:08 +02:00
Andrew Kelley
e5e6eb9831
Merge pull request #12368 from ziglang/stage3-default
...
make self-hosted the default compiler
2022-08-19 20:26:46 -04:00
Andrew Kelley
b75eeae595
CI: x86_64-linux: avoid cmake ZIG_EXECUTABLE hack
...
empirically this avoids a segfault on the CI.
2022-08-19 17:24:23 -07:00
Andrew Kelley
e78e9f33c0
CI: update x86_64-linux tarball
2022-08-19 16:45:16 -07:00
Andrew Kelley
3ce8060818
CI: update windows tarball
2022-08-19 16:45:16 -07:00
Andrew Kelley
4a27d2aac6
std.os.linux.bpf: fix compile error
2022-08-19 16:45:16 -07:00
Andrew Kelley
a85f41ec2c
test-stack-traces: relax parsing rules
...
* accept forward and backward slashes in file paths
* strip multiple extensions; e.g. if the basename is "test.exe.obj"
then it strips to "test".
2022-08-19 16:45:16 -07:00
Jakub Konka
10b95d89f8
coff: change improperly used packed struct into extern struct
2022-08-19 16:45:16 -07:00
Andrew Kelley
437311756d
LLVM: add DLL export attribute
...
This was present in stage1 but missing from self-hosted.
2022-08-19 16:45:16 -07:00
Andrew Kelley
35f62bc7ae
CI: windows: don't create build directory
...
Simplify the script by not creating an unnecessary build directory and
then changing directories to and from it.
2022-08-19 16:45:16 -07:00
Andrew Kelley
c4466496ff
build: hook up -Dskip-stage2-tests and remove test-toolchain
2022-08-19 16:45:16 -07:00
Andrew Kelley
5be2e8f941
CI: update windows tarball
...
This includes a few recent bug fixes which may solve the Windows CI
failure.
2022-08-19 16:45:16 -07:00
Andrew Kelley
445b33cfc0
fix std.os.windows.PathSpace.span
...
it was returning a pointer to a parameter.
2022-08-19 16:45:16 -07:00
Andrew Kelley
28e95b3240
CI: drone: simplify
...
Instead of a switch in a bash file we just properly name
the pipeline steps.
Also use zig build to produce the release artifact.
2022-08-19 16:45:15 -07:00
Andrew Kelley
5b486b1851
CI: use zig build to produce release artifact
...
For both macOS and FreeBSD.
2022-08-19 16:45:15 -07:00
Andrew Kelley
a8f86291d2
CI: update freebsd tarball
...
This updates to a stage3 freebsd tarball.
2022-08-19 16:45:15 -07:00
Andrew Kelley
7cf6930e24
CI: macos: set release mode for zig and simplify
2022-08-19 16:45:15 -07:00
Andrew Kelley
9f43ebd6ef
CI: windows: build stage3 directly from dev kit
2022-08-19 16:45:15 -07:00
Andrew Kelley
d75d40dfdf
build: make docs a separate step than test
2022-08-19 16:45:15 -07:00
Andrew Kelley
7346600517
CI: avoid concurrent jobs tripping over each other
2022-08-19 16:45:15 -07:00
Andrew Kelley
e3ccea70dd
CI: isolate zig-cache for parallel debug/release builds
2022-08-19 16:45:15 -07:00
Andrew Kelley
09ec9b0315
langref: update to new error message
2022-08-19 16:45:15 -07:00
Andrew Kelley
a73b3a0d70
CI: simplify x86 linux test instructions
2022-08-19 16:45:15 -07:00
Andrew Kelley
06c42a0c68
CI: test both stage3-debug and stage3-release on x86-linux
2022-08-19 16:45:15 -07:00
Andrew Kelley
507aae4a1a
make self-hosted the default compiler
...
stage1 is available behind the -fstage1 flag.
closes #89
2022-08-19 16:45:15 -07:00