joachimschmidt557
fbda9991f4
stage2 codegen: Fix silent bug in reuseOperand
2021-04-17 20:57:26 -04:00
Isaac Freund
4081e0a475
zig fmt: bypass auto indentation for // zig fmt: on
...
Currently an indented `// zig fmt: on` will be indented an additional
time on every run of zig fmt.
2021-04-17 20:10:20 -04:00
Isaac Freund
8e6865c8ee
std/build: fix linker_allow_shlib_undefined
...
The relevant flags were renamed in 01a1365 but updating std.build
was overlooked.
2021-04-17 15:17:54 +02:00
Frank Denis
9f6b56ab4b
Merge pull request #8555 from chivay/pidfd
...
std: Add pidfd wrappers
2021-04-17 15:03:25 +02:00
jacob gw
afb9f695b1
stage2: add support for zig cc assembler -mcpu option
2021-04-17 02:00:07 -04:00
Hubert Jasudowicz
5134fb72ef
std: Add pidfd wrappers
2021-04-17 01:13:16 +02:00
Isaac Freund
01a1365857
Rename --(no-)allow-shilb-undefined to -f(no-)allow-shilb-undefined
...
This breaks with GNU ld but is consistent with our naming convention for
all the rest of the flags.
2021-04-17 00:03:35 +02:00
daurnimator
99e7ba24b1
Add LibExeObjStep.linker_allow_shlib_undefined field to set --allow-shlib-undefined
2021-04-16 22:51:51 +02:00
daurnimator
0e687d125b
Add --(no-)allow-shlib-undefined to supported zig linking flags
2021-04-16 22:51:51 +02:00
Andrew Kelley
140d9df99b
Merge pull request #8506 from LemonBoy/test-c-file
...
build: Test the c.zig file too
2021-04-16 13:03:52 -04:00
joachimschmidt557
5edabb3990
stage2 register manager: Add functions for allocating multiple registers
2021-04-16 13:03:10 -04:00
Manuel Floruß
2cd49d20e8
Fix std.os.windows.user32.messageBoxW
...
Arguments to `selectSymbol` were passed in the wrong order.
2021-04-16 13:01:25 -04:00
Andrew Kelley
235aa8c078
ci: drone: don't skip stage2 tests
...
the stalls seem to be happening for a different reason
2021-04-16 09:57:31 -07:00
Mahdi Khanalizadeh
d1a41feddc
linux: fix number of arguments for tgkill syscall
2021-04-16 17:09:15 +02:00
Evan Haas
d4d21dd46d
translate-c: better handling of int -> enum casts
...
In std.meta.cast when casting to an enum type from an integer type, first
do a C-style cast from the source value to the tag type of the enum.
This ensures that we don't get an error due to the source value not being
representable by the enum.
In transCCast() use std.meta.cast instead of directly emitting the cast
operation since the enum's underlying type may not be known at translation
time due to an MSVC bug, see https://github.com/ziglang/zig/issues/8003
Fixes #6011
2021-04-15 22:46:22 -04:00
Andrew Kelley
ccdf55310b
stage2: properly model miscellaneous failed tasks
...
with error messages that go away after updates
2021-04-15 19:01:55 -07:00
Andrew Kelley
2b2920f599
ci: drone: disable stage2 tests
...
See #8545
2021-04-15 16:20:43 -07:00
Andrew Kelley
c795e82cbc
ci: windows: update to llvm 12 msvc tarball
2021-04-15 12:40:22 -07:00
Andrew Kelley
c49fe52cb1
ci: update macos tarball to llvm 12
2021-04-15 11:27:02 -07:00
Andrew Kelley
68e69aae2b
build.zig: omit LLVMTableGen from llvm libs
2021-04-15 10:58:53 -07:00
Andrew Kelley
2a6ec2e155
build.zig: update llvm libs
2021-04-15 10:43:39 -07:00
Andrew Kelley
a38042e3ac
ci: windows: proper flags to zig build
2021-04-15 02:02:36 -07:00
Andrew Kelley
fa633a658f
ci: windows: try the dev kit strategy
2021-04-15 01:44:17 -07:00
Andrew Kelley
4a1d3465cc
ci: windows: ranlib take 2
2021-04-15 01:22:42 -07:00
Andrew Kelley
3266f326de
ci: windows: better -DCMAKE_RANLIB option
2021-04-15 01:14:33 -07:00
Andrew Kelley
04b8354702
freebsd: disable failing test
...
See #8538
2021-04-15 00:59:40 -07:00
Andrew Kelley
996193c228
ci: freebsd: don't try to compile with zig cc
2021-04-15 00:51:26 -07:00
Andrew Kelley
a680c7ba98
ci: windows: use llvm-ar.exe from the tarball
2021-04-15 00:41:30 -07:00
Andrew Kelley
c59241bda0
ci: better handle of -mcpu
2021-04-15 00:18:21 -07:00
Andrew Kelley
553fbeba82
ci: better target triple and mcpu cmake args
2021-04-14 23:49:16 -07:00
Andrew Kelley
85755c51d5
ci: freebsd: set the target triple
2021-04-14 23:35:51 -07:00
Andrew Kelley
df319db058
ci: windows: install git
2021-04-14 23:18:03 -07:00
Andrew Kelley
3967823f3a
ci: freebsd: pass -DZIG_USE_LLVM_CONFIG=OFF
2021-04-14 23:17:08 -07:00
Andrew Kelley
ee42178b43
ci: aarch64-linux: disable run-translated-c tests
...
See #8537
2021-04-14 23:10:51 -07:00
Andrew Kelley
45eb9554c4
ci: windows: try using zig-bootstrap to build zig
2021-04-14 23:03:16 -07:00
Andrew Kelley
406353103a
ci: freebsd: update to llvm 12
2021-04-14 22:59:34 -07:00
Andrew Kelley
1438c324a4
ci: update drone CI to llvm 12
2021-04-14 21:18:23 -07:00
Andrew Kelley
391a40d601
ci: update linux to llvm12 tarball
2021-04-14 20:35:33 -07:00
Michael Dusan
6a7f21d1b8
ci: macos-aarch64 update dep tarballs for llvm12
2021-04-14 19:43:17 -07:00
lithdew
81adcd533e
os/posix: handle ECONNRESET for write/writev
2021-04-14 16:40:06 -07:00
Andrew Kelley
5a3ea9bece
Merge remote-tracking branch 'origin/llvm12'
...
Happy LLVM 12 Release Day.
Please note that the llvm 12 tag does not include the latest commit in
the release/12.x branch, which is in fact a bug fix for a regression
that is causing a failure in Zig's test suite.
Zig master branch is tracking release/12.x, and will be enabling the
test that is fixed by that commit.
2021-04-14 14:41:57 -07:00
LemonBoy
2ebd6bd706
std: Fix sqrt for u0/u1 input types
2021-04-14 17:53:27 +02:00
LemonBoy
ebf97627fd
build: Test the c.zig file too
...
* Add some more tests for the sqrt/sqrtf implementations.
The idea is to cross-check the software impl with the HW one whenever
possible.
* Fix a broken test, oops.
2021-04-14 17:53:26 +02:00
Frank Denis
1fada37466
Merge pull request #8518 from akvadrako/doc-field-align
...
Update doc for struct field alignment.
2021-04-14 10:56:37 +02:00
Evan Haas
e761e0ac18
translate-c: wrap switch statements in a while (true) loop
...
This allows `break` statements to be directly translated from the original C.
Add a break statement as the last statement of the while loop to ensure we
don't have an infinite loop if no breaks / returns are hit in the switch.
Fixes #8387
2021-04-13 11:45:03 -07:00
Jakub Konka
36a33c99e3
Merge pull request #8517 from ziglang/zld-archive-fix
...
zld: fix symbol resolution from interdependent static archives
2021-04-13 17:12:26 +02:00
Devin Bayer
ca3aa02206
Update doc for struct field alignment.
2021-04-13 14:53:44 +02:00
Jakub Konka
461543a5fd
zld: fix symbol resolution from interdep archives
...
Fixes symbol resolution if an archive occurring later in the linker
line depends on a object embedded within the archive that occurred
before.
2021-04-13 13:36:08 +02:00
Jakub Konka
65e4725aba
Add standalone test for interdep C archives
...
Tests a scenario where the linker line has the following:
```
main.o libA.a libB.a
```
where `main.o` pulls a symbol from `libB.a`, which in turn is
dependent on a symbol from `libA.a`.
2021-04-13 13:32:59 +02:00
Jakub Konka
a5bbc66f10
zld: cleanup redundant changes
2021-04-13 10:56:03 +02:00