jakubtomsu
e15230c194
remove force_inline from vector_dot
2026-04-10 17:21:03 +02:00
jakubtomsu
d5e4e61c1c
implement floor, ceil and trunc with SIMD
2026-04-10 17:10:24 +02:00
jakubtomsu
47371791b3
faster vector_dot and vector_cross3
2026-04-10 17:08:40 +02:00
gingerBill
7e9c14e6f3
Remove deprecated procedure
2026-03-25 11:38:38 +00:00
gingerBill
8f4b720e90
Add contextless to appropriate procedures in core:math/fixed
2026-03-25 11:38:14 +00:00
Yawning Angel
a171746a15
core/math/rand: Disable LLVM vectorization of xoshiro on Intel
...
LLVM tries really hard to vectorize this when it is a terrible idea,
when `-microarch:native` is specified on modern processors. Not doing
so is a 2.5->3x performance gain.
2026-03-19 19:25:23 +09:00
Jeroen van Rijn
f82fbc9405
-vet-tabs
2026-03-15 11:06:22 +01:00
mlgudi
76da2c3233
mul_high: fix aliasing bug when dest overlaps input
2026-03-15 02:47:26 +00:00
mlgudi
84b38810f1
powmod: fix Montgomery branch calling Barrett implementation
2026-03-15 02:46:30 +00:00
jakubtomsu
e8aac50f8b
math/rand math/bits dependency
2026-02-17 18:34:37 +01:00
gingerBill
a7ed7ccd0c
Merge pull request #6259 from odin-lang/bill/range-init
...
`for init; x in y {}` style loops (proof of concept)
2026-02-17 11:11:56 +00:00
gingerBill
6da4a6746f
Add linalg.to_f16
2026-02-17 09:41:22 +00:00
Jeroen van Rijn
a7bf06eb5f
Fix cast.
2026-02-15 17:15:48 +01:00
Jeroen van Rijn
5c95a48bc7
Clean up core:math/big
...
- Deprecate the u64/u32 implementation so we can use fewer nails and have an easier time of maintaining and optimizing the package going forward. The remaining implementation still works on 32-bit targets, it's just a smidge less efficient.
- Use only 1 nail instead of 4. The tests now run 3.5% faster as a result.
Future optimizations may including using fully packed backing (no nails) using `intrinsics.overflow_*` to handle borrow and carry safely.
2026-02-15 17:00:53 +01:00
Jeroen van Rijn
d8f2eb2717
Remove core:mem import from core:math/big.
2026-02-12 14:37:28 +01:00
Jeroen van Rijn
71f343bc85
Remove core:mem import from core:math/big.
2026-02-12 13:56:05 +01:00
Jeroen van Rijn
b82512b4cf
Restrict math.wrap to floats.
2026-02-11 22:15:15 +01:00
gingerBill
355b8a8c83
Merge pull request #6245 from odin-lang/new_os
...
`core:os/os2` -> `core:os` integration
2026-02-11 17:53:16 +00:00
jakubtomsu
d492122bd4
import cleanup
2026-02-09 20:08:22 +01:00
Jeroen van Rijn
e7dbabf668
core:os -> core:os/old && core:os/os2 -> core:os
2026-02-09 15:50:21 +01:00
Jeroen van Rijn
8ed264680b
Remove all core:os imports from JS targets
...
Fix `local_tz_name` on FreeBSD.
2026-02-09 15:07:27 +01:00
Jeroen van Rijn
9c1a9c80f8
core:os -> core:os/os for core:math/big
2026-02-08 12:42:28 +01:00
Xotchkass
edb70a8d75
optimized slice filling in xoshiro/pcg_random_generator_proc ( #6001 )
2026-01-13 21:11:01 +01:00
Wrath
7062f89bcd
core:math/rand small documentation fix
2025-12-22 16:10:51 -05:00
gingerBill
6922ab15fb
Merge pull request #5864 from Skyress-s/master
...
fix: linalg.quaternion_from_forward_and_up()
2025-12-01 12:31:55 +00:00
Andreas Stenmark
ad11d3bea0
Fix #5978 : choice_bit_set respects bit_set domain
2025-11-30 21:46:26 +01:00
Yawning Angel
ea1f1e275d
base/runtime: Add chacha8rand as the default RNG
2025-11-29 16:16:52 +09:00
Yawning Angel
f74f93154a
math/rand: Add xoshiro256**
...
This is extracted from the previos PR as an improved non-cryptographic
PRNG option.
2025-11-29 10:45:53 +09:00
Yawning Angel
110d869cd7
math/rand: Add a copy of the existing PCG PRNG
...
The switch to the new RNG will be a breaking change as the outputted
sequence will change for a given seed. This is intended for backward
compatibility purposes only.
2025-11-29 10:45:53 +09:00
Jeroen van Rijn
cbf9f59da0
Fix core:math/ease
2025-11-28 23:18:28 +01:00
Jeroen van Rijn
976bb52af7
Always use new itoa method when MATH_BIG_FORCE_32_BIT
2025-11-28 23:08:17 +01:00
Xotchkass
b8f8e6a8df
changed panic to assert
2025-11-28 14:11:37 +02:00
Xotchkass
a234f25fa5
Add range-based random number generation functions
2025-11-28 13:40:30 +02:00
Jeroen van Rijn
be38ba58b3
Another little bit faster.
2025-11-27 18:27:55 +01:00
Jeroen van Rijn
a6820020c7
Merge pull request #5968 from Xotchkass/rand_u_max
...
Add `uint32_max`, `uint64_max`, `uint128_max` and `uint_max` procs to `core:math/rand`
2025-11-27 16:12:09 +00:00
Jeroen van Rijn
3cdaf06fc8
Switch between old and new itoa method based on optimization level + digit size
2025-11-27 16:10:32 +01:00
Jeroen van Rijn
1ea5990be2
Speed up big.itoa
...
Extract 18 (64-bit) or 8 (32-bit) digits per big division.
This gives a 2.5x speedup for a 1024-bit bigint.
2025-11-27 15:35:05 +01:00
gingerBill
78d8059ebe
Use @(rodata) where possible
2025-11-27 10:24:22 +00:00
gingerBill
0d16ab2783
Add alias Okay = None
2025-11-27 09:14:39 +00:00
gingerBill
c63fa3f663
Use < 0 instead of == -1 for comparisons
2025-11-27 09:13:21 +00:00
gingerBill
53876907c6
Handle Allocator_Error correctly in core:math/big
2025-11-27 09:10:03 +00:00
Xotchkass
0ed24953bb
add uint32_max, uint64_max, uint128_max and uint_max procs to math/rand
2025-11-26 23:06:19 +02:00
Phil Homan
342a7dd112
rerrange math.sign and math.sign_bit overloads
2025-11-23 11:03:37 -08:00
Phil Homan
9131bca7ba
add math.sign and math.sign_bit overloads for int types
2025-11-22 13:32:21 -08:00
Jeroen van Rijn
56aab55d82
Fix #5931
...
Fix #5931 and add test case for it.
2025-11-18 15:37:57 +01:00
gingerBill
e5153a937b
Merge pull request #5859 from odin-lang/bill/change-license
...
Change Odin's LICENSE to zlib from BSD 3-clause
2025-11-04 13:53:13 +00:00
NicknEma
7317704fd0
Fix docs on int*_max
2025-11-04 13:11:48 +01:00
thetarnav
c63ad8b1cf
Cleanup ease_inverse
2025-11-01 21:22:06 +01:00
thetarnav
78f9f8bbce
Add ease inverse procedures
2025-11-01 21:11:32 +01:00
Mathias Mohn Mørch
9a321befd4
Fixed issue where the linalg.quaternion_from_forward_and_up could return incorrect values in certain scenarioes
2025-10-30 20:35:35 +01:00