26 Commits

Author SHA1 Message Date
Robin Voetter
073289d0da
spirv: disable new behavior tests that do not pass
Some new behavior tests have recently been added, and not all of these
pass with the SPIR-V backend.
2023-07-01 19:45:09 +02:00
Jacob Young
9343c31c38 Sema: fix @min/@max type resolution with all runtime args
Closes #16229
2023-06-26 18:46:25 -07:00
mlugg
c4cc796695 Sema: consider type bounds when refining result type of @min/@max
I achieved this through a major refactor of the logic of analyzeMinMax.
This change should be compatible with vectors of comptime_int, which
Andrew said are supposed to work (but which currently do not).
2023-06-16 13:33:31 -07:00
Eric Joldasov
d884d7050e
all: replace comptime try with try comptime
Signed-off-by: Eric Joldasov <bratishkaerik@getgoogleoff.me>
2023-06-13 23:46:58 +06:00
Jacob Young
0c438ab616 x86_64: hotfix for crash during in-memory coercion of large type
Unblocks #15768
Closes #15904
2023-05-29 22:03:27 -04:00
mlugg
e2837fd224 Sema: return comptime_int if all args to @min/@max are comptime_int
Resolves: #15776
2023-05-29 11:32:13 -07:00
Robin Voetter
37aa343079
spirv: more passing tests 2023-05-20 17:30:22 +02:00
Jacob Young
403c2d91be x86_64: fix float min/max behavior 2023-05-18 20:42:38 -04:00
Andrew Kelley
958fba0eb7
Merge pull request #15713 from alichraghi/ali-spirv
spirv: get more behavior tests passing
2023-05-16 16:09:22 -07:00
Jacob Young
2cbd442a9d x86_64: implement integer vector movement 2023-05-15 03:07:51 -04:00
Ali Chraghi
9c550721e4 spirv: lower float_to_int and int_to_float 2023-05-15 03:04:17 +03:30
Ali Chraghi
ccc490ef68
setup spirv backend in behavior tests 2023-05-11 20:31:52 +02:00
Jacob Young
c5b96c7447 llvm: fix @max/@min of unsupported float types
Closes #15611
2023-05-10 15:16:50 -04:00
Jacob Young
36a39267b8 x86_64: fix feature confusion 2023-05-03 04:25:14 -04:00
mlugg
152c7b1885 Implement multi-argument @min/@max and notice bounds
Resolves: #14039
2023-05-02 16:46:27 -07:00
Jacob Young
6de457211f behavior: update affected tests for the x86_64 backend 2023-05-01 19:22:52 -04:00
Jacob Young
30e1daa746 x86_64: implement basic float ops 2023-03-21 08:49:54 +01:00
Jacob Young
c478c7609e CBE: implement vector operations
Also, bigint add and sub which is all I was actually trying to do.
2023-03-05 02:59:02 -05:00
Koakuma
f9e9ba784f stage2: sparc64: Skip unimplemented tests 2022-12-10 21:51:46 +07:00
Veikka Tuominen
dff32a2cd7 Sema: resolve lazy values in analyzeMinMax
Closes #13797
2022-12-07 14:48:24 +02:00
Jacob Young
6a4266d62a cbe: fix infinite recursion on recursive types 2022-10-25 05:11:28 -04:00
Ali Chraghi
ca27055cda all: rename @maximum to @max and @minimum to @min 2022-10-18 14:15:16 +03:00
Luuk de Gram
a0a587ff85 wasm: Enable passing behavior tests
This shuffles some tests do ensure the new instructions are tested for the wasm backend,
by moving vectors into their own tests as well as move the f16 test cases as those require
special operating also.
2022-04-02 21:54:01 +02:00
Andrew Kelley
ad5770eba4 organize behavior tests
* Identify the ones that are passing and stop skipping them.
 * Flatten out the main behavior.zig file and have each individual test
   disable itself if it is not passing.
2022-03-18 15:02:52 -07:00
Andrew Kelley
55eea3b045 stage2: implement @minimum and @maximum, including vectors
* std.os: take advantage of `@minimum`. It's probably time to
   deprecate `std.min` and `std.max`.
 * New AIR instructions: min and max
 * Introduce SIMD vector support to stage2
 * Add `@Type` support for vectors
 * Sema: add `checkSimdBinOp` which can be re-used for other arithmatic
   operators that want to support vectors.
 * Implement coercion from vectors to arrays.
   - In backends this is handled with bitcast for vector to array,
     however maybe we want to reduce the amount of branching by
     introducing an explicit AIR instruction for it in the future.
 * LLVM backend: implement lowering vector types
 * Sema: Implement `slice.ptr` at comptime
 * Value: improve `numberMin` and `numberMax` to support floats in
   addition to integers, and make them behave properly in the presence
   of NaN.
2021-10-14 21:17:30 -07:00
Robin Voetter
cdeea3b094 minimum/maximum builtins 2021-07-26 20:41:00 -04:00