Commit graph

1114 commits

Author SHA1 Message Date
Brendan Hansknecht
d74a3c0746
Merge remote-tracking branch 'origin/main' into upgrade-llvm-zig 2024-12-12 13:29:10 -08:00
faldor20
a7308130cf
clippy on everything 2024-12-12 20:54:25 +10:00
Brendan Hansknecht
2475feeb2f
more wasm fixes 2024-12-11 21:47:18 -08:00
Brendan Hansknecht
87537b800e
merge llvm ir optimization locations 2024-12-11 17:33:20 -08:00
Brendan Hansknecht
0a573ca557
Merge remote-tracking branch 'origin/main' into upgrade-llvm-zig 2024-12-11 16:38:34 -08:00
Brendan Hansknecht
37c6330c6f
cleanup when expects are run 2024-12-11 15:15:46 -08:00
Ayaz
793a95264d
Merge branch 'main' into wrapped 2024-12-08 13:54:43 -05:00
shua
def796f146
PR: refac tests, add all int cases for *wrap tests 2024-12-07 16:27:25 +01:00
Asher Frost
61512701b0
Merge branch 'main' into int_overflow 2024-12-04 19:04:53 -05:00
Richard Feldman
bc0c9250f9
Convert unused dbg!()s to eprintln!()s
This makes it nicer to work with dbg! normally,
because grepping the code base for dbg!() reveals
only the usages of it that are currently active.
2024-12-01 23:10:35 -05:00
Asher Frost
c2d06e3658
Made test pass 2024-12-01 16:03:40 -05:00
Asher Frost
7055253564
Merge branch 'main' into int_overflow 2024-12-01 15:32:39 -05:00
Luke Boswell
d7556be7bf
Merge pull request #7264 from shua/saturated
gen-dev: complete Num{Mul,Add,Sub}Saturated impls
2024-12-01 14:01:48 +11:00
shua
8fd2fbc3a1
gen-dev: complete Num{Mul,Add,Sub}Saturated impls
MulSaturated and AddSaturated are now implemented for u128, i128
SubSaturated is now implemented for Dec even if it's a little strange to
saturate at a decimal value:

```
» Num.subSaturated -170_141_183_460_469_231_731dec 1

-170141183460469231731.687303715884105728 : Dec
```

I decided to rm the `build_num_{mul,add}_saturated` methods because
they don't require any asm-specifics. They either call out to bitcode, or
use the non-saturated version for floats.
2024-11-30 23:01:44 +01:00
shua
6dfa458e6c
Num.powInt: panic on overflow 2024-11-30 11:26:42 +01:00
Luke Boswell
656a7bcd87
Merge remote-tracking branch 'remote/main' into upgrade-llvm-zig 2024-11-30 10:18:11 +11:00
wizard7377
7866331f67
Merge branch 'main' into int_overflow 2024-11-28 21:26:38 -05:00
Luke Boswell
fdaaca8c8b
replace cargo deps with workspace in lower_parms, module, mono, parse, problem, roc_target, serialize, solve, solve_problem, specialize_types, test_* 2024-11-29 11:29:04 +11:00
Luke Boswell
1ecb003887
Merge pull request #7250 from shua/fracdec
implement Num.isNaN,isFinite,isInfinite for Dec
2024-11-29 10:16:17 +11:00
Luke Boswell
2feb5d3c2e
Merge remote-tracking branch 'remote/main' into upgrade-llvm-zig 2024-11-29 08:58:47 +11:00
Asher Frost
0eb11932d9
Re-added tests 2024-11-28 10:11:05 -05:00
JRI98
61ca278e31
Fix division of zero by zero for Dec 2024-11-27 23:38:21 +00:00
Agus Zubiaga
1dc9dd0a90
Merge branch 'main' into specialize-exprs 2024-11-27 11:35:14 -03:00
shua
10f04f1d94
implement Num.isNaN,isFinite,isInfinite for Dec 2024-11-27 00:36:54 +01:00
Brendan Hansknecht
e40b3cd6a9
Merge pull request #7235 from shua/devneg
impl Num.neg for Dec,F32,F64 in repl
2024-11-26 13:29:19 -08:00
shua
a98acff0b9
gen-dev: impl Num.neg for Dec,F32,F64
Dec negation was implemented across gen-dev, gen-llvm, gen-wasm as a call
to the compiled zig function `bitcode::DEC_NEGATE`.

f32 and f64 negation were implemented already for gen-llvm, gen-wasm.

for gen-dev x86_64, float negation is implemented by flipping the sign
bit, which means `xorps` for f32, and `xorpd` for f64

for gen-dev aarch64, there is conveniently a `fneg` instruction
2024-11-23 19:17:55 +01:00
Agus Zubiaga
2e96aca0fd
Merge branch 'main' into specialize-exprs 2024-11-23 01:48:51 -03:00
Sam Mohr
f857872903
Properly type constrain all function types 2024-11-21 04:09:47 -08:00
Sam Mohr
7ca305b5dc
Merge branch 'main' into constrain-early-return-functions 2024-11-18 15:04:34 -08:00
Isaac Van Doren
d99c347998
rename Str.split 2024-11-15 21:12:23 -06:00
Luke Boswell
dc3aa06d61
Merge remote-tracking branch 'remote/main' into upgrade-llvm-zig 2024-11-13 09:02:20 +11:00
Isaac Van Doren
ec59acea89
add List.splitOnList 2024-11-10 18:34:34 -06:00
Isaac Van Doren
0a7e98ab65
add List.splitOn 2024-11-10 18:20:31 -06:00
Isaac Van Doren
45b50bd131
add List.splitAt 2024-11-09 17:16:21 -06:00
Sam Mohr
9a2b99c148
Constrain early returns in functions in addition to closures 2024-11-08 00:05:56 -08:00
Sam Mohr
66cc96edbb
Address PR comments from @ayazhafiz 2024-10-29 15:58:35 -07:00
Sam Mohr
c19cfb0a34
Fix test_gen incorrect macro invocations 2024-10-26 18:22:19 -07:00
Sam Mohr
346a2d9467
Simplify tail-call checks 2024-10-26 16:29:14 -07:00
Sam Mohr
8a0cc10c93
Add test_gen tests for early returns 2024-10-24 23:41:53 -07:00
Richard Feldman
44d00e1f13
Updates for making soa no_std 2024-10-21 22:10:43 -04:00
Richard Feldman
98535bfbce
wip 2024-10-20 11:00:58 -04:00
Brendan Hansknecht
5646f829dc
Merge pull request #7146 from HajagosNorbert/hajagosnorbert/neg_int
gen_dev-x86_64 extend Num.neg to all Signed and Unsigned int sizes
2024-10-11 08:57:46 -07:00
Luke Boswell
915097d792
Merge remote-tracking branch 'remote/main' into upgrade-llvm-zig 2024-10-08 18:21:24 +11:00
Brendan Hansknecht
e6a149642d
minor fix 2024-10-07 21:16:30 -07:00
Brendan Hansknecht
a9d1327dd1
Enable multiple functions exposed to the host 2024-10-07 21:16:30 -07:00
Norbert Hajagos
72863daa7e
gen_dev-x86_64 extend Num.neg to all Signed and Unsigned int sizes 2024-10-07 23:43:58 +02:00
Luke Boswell
81f007940c
fix test_gen gen_str tests 2024-09-29 14:43:20 +10:00
Luke Boswell
760af4a04e
Merge remote-tracking branch 'remote/main' into str-dropping 2024-09-29 14:31:04 +10:00
Aurélien Geron
033d87034c
Add a test case for List.dropAt at an index located in the middle of the list 2024-09-19 10:05:48 +12:00
Luke Boswell
99e2bc2038
Merge remote-tracking branch 'remote/main' into upgrade-llvm-zig 2024-09-05 12:11:51 +10:00