Commit Graph

8611 Commits (afa24ccd993e38b56407c83160da567bc2b0ae8a)

Author SHA1 Message Date
Andrew Kelley afa24ccd99 fix the build on Windows
Workaround for issue #2668

Zig std lib currently does not allow forward slashes in Windows path
names.
2020-04-06 18:35:49 -04:00
LemonBoy a59d31bd28 ir: Support tuple multiplication 2020-04-06 14:03:43 -04:00
Andrew Kelley e4eb817f79
libc_installation.zig: don't special-case based on C ABI
Whether the C ABI is mingw-w64 or msvc, detection of native libc paths
should be the same. In the future we may want to allow passing a C ABI
parameter to detectNativeCPaths() but for now we have the same behavior
regardless.
2020-04-06 13:33:32 -04:00
Andrew Kelley 96ed544665
build.zig supports specifying config.h location explicitly
also it does not try to run llvm-config executable when -Dlib-files-only

This fixes cross-compiling using the bootstrap repository.
2020-04-06 13:07:19 -04:00
LemonBoy a0b73c9f02 compiler-rt: Separate max size allowed for load/store and CAS
The v6m ISA has no way to express a CAS loop natively without turning
off the interrupts or using the kernel cmpxchg harness.

On such a platform the user has to provide a few __sync_* builtins to
satisfy the linker.
2020-04-06 12:52:53 -04:00
Vexu c5ced0d74a
Merge pull request #4939 from SuperAuguste/master
translate-c: Properly translate C multicharacter literals
2020-04-06 10:31:17 +03:00
Andrew Kelley 701c03d083 zig uses mingw-w64 to provide -lpsapi 2020-04-05 23:06:47 -04:00
Andrew Kelley 28d9696617 use mingw-w64 to provide -luuid if requested 2020-04-05 23:06:47 -04:00
SuperAuguste 6106cf4419 fixes 2020-04-05 19:06:43 -04:00
Benjamin Feng cb98984ae6 Generate clearer size mismatch error message 2020-04-05 18:38:19 -04:00
Andrew Kelley 05b587fcde
Merge branch 'LemonBoy-vec-div'
closes #4737
2020-04-05 18:34:47 -04:00
Andrew Kelley e84b9b70ff
annotate disabled tests with github issue links 2020-04-05 18:34:32 -04:00
Andrew Kelley 5597b11a52
add runtime safety tests for SIMD integer division 2020-04-05 18:34:31 -04:00
LemonBoy f6cdc94a50
ir: Fix error checking for vector ops
The extra logic that's needed was lost during a refactoring, now it
should be fine.
2020-04-05 18:34:31 -04:00
LemonBoy 0f964e1910
I'm getting tired of this shit LLVM 2020-04-05 18:34:31 -04:00
LemonBoy 91a8e3b47b
tests: Chop away some flaky tests 2020-04-05 18:34:31 -04:00
LemonBoy fe77c38247
ir: Remove unused and commented out code 2020-04-05 18:34:31 -04:00
LemonBoy eff7555d5d
std: Delete a hack in the feature set code
Now that bitwise not works on vectors we can simplify the code.
2020-04-05 18:34:31 -04:00
LemonBoy d2d97e55cc
ir: Support shift left/right on vectors 2020-04-05 18:34:31 -04:00
LemonBoy 2485f30046
ir: Support bitwise not on vectors 2020-04-05 18:34:31 -04:00
LemonBoy 54ffcf95a8
ir: Support div/mod/rem on vector types
Closes #4050
2020-04-05 18:34:31 -04:00
Andrew Kelley e2dc63644a
type_has_one_possible_value takes comptime struct fields into account
Before, type_has_one_possible_value would return false for the value
`.{1}`. But actually, that type is a tuple with a single comptime field.
Such a type, in fact, has one possible value.

This plus the corresponding adjustment to get_the_one_possible_value
solves #3878.
2020-04-05 17:09:01 -04:00
Vexu 6ef15fc8d0
Merge pull request #4901 from phase/feature/translate-c-remassign
translate-c: RemAssign and DivAssign
2020-04-05 21:05:18 +03:00
Andrew Kelley 607b2661a0
Merge pull request #4942 from daurnimator/tidy-atomics
Tidy up compiler_rt/atomics
2020-04-05 11:13:31 -04:00
daurnimator 4daec63aea .gitattributes: deps/SoftFloat-3e/*.txt lines are crlf terminated 2020-04-05 11:03:31 -04:00
daurnimator d4d2180148 Convert .gitattributes to use unix line endings 2020-04-05 11:03:31 -04:00
Michaël Larouche c4a5f519f2 Do not parse native_libc.txt anymore when linking on native target, always run detection of libc.
Fixes #4772
2020-04-05 11:01:35 -04:00
Jadon Fowler ae376e0758 translate-c: remove unneeded semicolon
Signed-off-by: Jadon Fowler <j@jadon.io>
2020-04-05 10:44:42 -04:00
daurnimator e9e43ed0d3
compiler_rt/atomics: be consistent with `const value` 2020-04-05 14:08:25 +10:00
daurnimator f947444362
Tidy up compiler_rt/atomics 2020-04-05 14:06:12 +10:00
SuperAuguste 027e2a1673 fix multichar literals in translate_c 2020-04-04 17:56:25 -04:00
xackus cd20e0cc67 rename mem.separate to mem.split 2020-04-04 17:37:51 -04:00
Andrew Kelley e5d479b06e detect an endless loop when trying to detect native libc installation
closes #4810
2020-04-04 15:03:22 -04:00
Andrew Kelley 52db13738b
zig cc looks for native include directories unless -nostdinc
closes #4938
2020-04-04 14:58:24 -04:00
Andrew Kelley d02838b71a
add libutil to zig's glibc support 2020-04-04 14:43:51 -04:00
Andrew Kelley dc7e8b2fdc
build.zig: better detection of using outside zig executable
As pointed out by gereeter, dirname("/") successfully returns "/" again.
So checking for null is not sufficient.
2020-04-04 14:05:49 -04:00
Felix (xq) Queißner 12cdea4525 Adds some documentation to std.atomic.Queue. 2020-04-04 13:47:07 -04:00
Andrew Kelley cf8728aabd
Merge pull request #4935 from LemonBoy/stage1-eb
Big-endian fixes for stage1
2020-04-04 13:45:49 -04:00
Andrew Kelley d73808f3ff
remove `zig BUILD_INFO` hack
Rather than stuffing configuration information into the Zig binary, the
build script reads it from config.h. This solves a problem for package
maintainers and improves the use case of deterministic builds.

closes #3758
2020-04-04 11:57:28 -04:00
LemonBoy ad2ebc87f2 stage1: Byteswap floats when serializing them 2020-04-04 16:55:24 +02:00
LemonBoy 084c62f5d1 stage1: Fix serialization of ZigValue on BE machines 2020-04-04 14:06:32 +02:00
Jadon Fowler 391ee996a5 translate-c: account for signedness when translating div & mod
Signed-off-by: Jadon Fowler <j@jadon.io>
2020-04-04 02:16:30 -04:00
Andrew Kelley e89c42655c
Merge pull request #4868 from xackus/new-arraylist-api
new ArrayList API
2020-04-03 22:31:15 -04:00
Michael Dusan 1568470c44
Merge pull request #4891 from mikdusan/issue4207
add compiler-error test: coerce
2020-04-03 21:04:22 -04:00
Michael Dusan 8b6a06eefe
add compiler-error test: coerce
Issue fixed by an unknown commit.

closes #4207
2020-04-03 19:11:51 -04:00
Michael Dusan db4c06ce60 stage1: add compile errors for sentinel slicing
closes #3963
2020-04-03 19:05:30 -04:00
Andrew Kelley f1425fd9da
gitattributes: note that libcxxabi is vendored 2020-04-03 18:36:42 -04:00
Andrew Kelley a2cad9a3d9
add issue links to disabled test cases 2020-04-03 18:36:13 -04:00
Andrew Kelley 7beea47178
Merge branch 'LemonBoy-compiler-rt-atomics'
closes #4924
2020-04-03 16:08:52 -04:00
Andrew Kelley e03cbb117e
compiler-rt: don't forget to export these functions 2020-04-03 16:07:32 -04:00