commit_hash stringlengths 40 40 | author stringlengths 1 57 | date timestamp[s]date 2010-07-26 04:45:09 2026-04-14 18:21:10 | message stringlengths 8 1.39M | diff stringlengths 68 51.2k | files_changed int64 1 136 | insertions int64 0 2.35k | deletions int64 0 1.9k |
|---|---|---|---|---|---|---|---|
0dde2f126b4ecfc0bf6a06c6272032ce73d78361 | Kristof Roomp | 2024-05-25T21:32:57 | add u16x16 and tests (#155)
* add u16x16 and tests
* fix shr
* fix saturating
* dont add simpleneg | diff --git a/src/lib.rs b/src/lib.rs
index 9e7fc3c..b895c82 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -252,6 +252,9 @@ pub use u8x16_::*;
mod u16x8_;
pub use u16x8_::*;
+mod u16x16_;
+pub use u16x16_::*;
+
mod u32x4_;
pub use u32x4_::*;
@@ -313,7 +316,7 @@ union ConstUnionHack256bit {
i32x8: i32x8,
i64... | 4 | 729 | 31 |
d420e240f04cfb6f31bb24cb4a034d3a59d61b4f | Lokathor | 2024-05-20T18:35:48 | chore: Release wide version 0.7.20 | diff --git a/Cargo.toml b/Cargo.toml
index e9bc7cd..bbeec07 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.19"
+version = "0.7.20"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"... | 1 | 1 | 1 |
e719fdc00625516e9ebf5db0cb12ad95e1c5fe21 | Kristof Roomp | 2024-05-20T18:35:24 | improve perf of reduce_min,reduce_max,reduce_add and add unsigned upcast from u16x8 (#154)
* improve perf of reduce_min,reduce_max,reduce_add and add unsigned upcast from u16x8 to i32x8
* fix scalar paths
* add comment
* add comment | diff --git a/src/i16x8_.rs b/src/i16x8_.rs
index 8b01d0b..f8a8a76 100644
--- a/src/i16x8_.rs
+++ b/src/i16x8_.rs
@@ -654,32 +654,94 @@ impl i16x8 {
#[inline]
#[must_use]
pub fn reduce_add(self) -> i16 {
- let arr: [i16; 8] = cast(self);
+ pick! {
+ if #[cfg(target_feature="sse2")] {
+ // ther... | 3 | 126 | 19 |
264b4668034fed16104ae4c1a12048e047230362 | Lokathor | 2024-05-13T16:42:31 | chore: Release wide version 0.7.19 | diff --git a/Cargo.toml b/Cargo.toml
index dc21800..e9bc7cd 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.18"
+version = "0.7.19"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"... | 1 | 1 | 1 |
86cb2a06682a8f533966813e8bf48f08515b356e | Kristof Roomp | 2024-05-13T16:17:59 | Added i16 widening mul since this is implemented badly on some platforms (#153)
* add reduce min/max along with tests. Also optimize i16 abs for sse2
* mulwiden
* better mulwiden
* better mulwiden
* fix test
* add must_sue and inline
* fix spacing
* remove unnecessary paren | diff --git a/src/i16x8_.rs b/src/i16x8_.rs
index 43404d2..8b01d0b 100644
--- a/src/i16x8_.rs
+++ b/src/i16x8_.rs
@@ -933,6 +933,50 @@ impl i16x8 {
}
}
+ /// multiplies two i16x8 and returns the result as a widened i32x8
+ #[inline]
+ #[must_use]
+ pub fn mul_widen(self, rhs: Self) -> i32x8 {
+ pick! {
... | 2 | 62 | 0 |
4b7b5f219a773fe3fd966ec3d2efe6caba6f8b5c | Lokathor | 2024-05-12T16:55:34 | chore: Release wide version 0.7.18 | diff --git a/Cargo.toml b/Cargo.toml
index a37619b..dc21800 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.17"
+version = "0.7.18"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"... | 1 | 1 | 1 |
445451e68bff8355ab5c3a1b81fbd5c8da68f3c7 | Kristof Roomp | 2024-05-12T16:53:54 | Add unsigned_abs to i8,i16,i32,i64 to provide well defined behavior for abs (#152)
* add unsigned version of abs for clearer code when handling corner cases
* fix typo
* fixed wasm typo
* fix neon cast
* add pub(crate) to unsigned types
* fixed i8x16
* x86 doesnt have abs i64
* typo
* fix 64 bi... | diff --git a/src/i16x8_.rs b/src/i16x8_.rs
index 66e72e4..43404d2 100644
--- a/src/i16x8_.rs
+++ b/src/i16x8_.rs
@@ -696,10 +696,52 @@ impl i16x8 {
} else if #[cfg(all(target_feature="neon",target_arch="aarch64"))]{
unsafe {Self { neon: vabsq_s16(self.neon) }}
} else {
- self.is_negative()... | 18 | 318 | 18 |
4875c143371c60bf825a8b4ca4fd47ed4c26e171 | Lokathor | 2024-04-29T18:56:05 | chore: Release wide version 0.7.17 | diff --git a/Cargo.toml b/Cargo.toml
index 9692d0f..a37619b 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.16"
+version = "0.7.17"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"... | 1 | 1 | 1 |
9f2f87813536d5f7222cf29b46eb002a342cae1d | Kristof Roomp | 2024-04-29T18:54:00 | simplify i16x16::move_mask (#151) | diff --git a/src/i16x16_.rs b/src/i16x16_.rs
index 21b3ece..2ce5f51 100644
--- a/src/i16x16_.rs
+++ b/src/i16x16_.rs
@@ -294,9 +294,10 @@ impl i16x16 {
#[must_use]
pub fn move_mask(self) -> i32 {
pick! {
- if #[cfg(target_feature="avx2")] {
- (move_mask_i8_m256i(pack_i16_to_i8_m256i(self.avx2,shu... | 1 | 4 | 3 |
c735a28d504b7bd0d7cdac1dcf52bc57d2d8b317 | Lokathor | 2024-04-15T17:21:22 | chore: Release wide version 0.7.16 | diff --git a/Cargo.toml b/Cargo.toml
index 2aff04b..9692d0f 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.15"
+version = "0.7.16"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"... | 1 | 1 | 1 |
9dea4738a79e829f1ea94354b9d89c86b653068d | Alex Yusiuk | 2024-04-15T17:19:27 | feat: add i16x8::mul_keep_high (#149)
* feat: add i16x8::mul_keep_high
* feat: add WASM SIMD version of mul_keep_high | diff --git a/src/i16x8_.rs b/src/i16x8_.rs
index 625bee5..66e72e4 100644
--- a/src/i16x8_.rs
+++ b/src/i16x8_.rs
@@ -853,6 +853,44 @@ impl i16x8 {
}
}
+ /// Multiples two i16x8 and return the high part of intermediate i32x8
+ #[inline]
+ #[must_use]
+ pub fn mul_keep_high(lhs: Self, rhs: Self) -> Self {
+... | 2 | 46 | 0 |
44c08be2dbe572680edf1976f8845e1b83eb5921 | Lokathor | 2024-01-29T21:29:26 | chore: Release wide version 0.7.15 | diff --git a/Cargo.toml b/Cargo.toml
index a7f5e45..2aff04b 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.14"
+version = "0.7.15"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"... | 1 | 1 | 1 |
bd6850c9af234b107588bcb090adbcfed8c8e36f | Alex Yusiuk | 2024-01-29T21:25:14 | feat: add u8x16::narrow_i16x8 (#148)
* feat: add u8x16::narrow_i16x8
* style: run cargo fmt and fix clippy warnings | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index ae9aa6d..8b5cd62 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -1575,7 +1575,7 @@ impl f32x4 {
}
#[inline]
- pub fn as_array_mut(&mut self) -> &mut[f32; 4] {
+ pub fn as_array_mut(&mut self) -> &mut [f32; 4] {
cast_mut(self)
}
}
diff --git a/src/f6... | 17 | 88 | 20 |
a0485076986375425319f94cc786d4508f9d39a1 | Lokathor | 2024-01-21T18:10:03 | chore: Release wide version 0.7.14 | diff --git a/Cargo.toml b/Cargo.toml
index 264aa36..a7f5e45 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.13"
+version = "0.7.14"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"... | 1 | 1 | 1 |
6ad5b3d93d7752bce78feb3840648a7cf8e76bac | Alex Yusiuk | 2024-01-19T20:31:11 | feat: add u8x16::unpack_low/high (#147)
This commit adds u8x16::unpack_low and u8x16::unpack_high which is basically SSE2's unpack_low_i8_m128i and unpack_high_i8_m128i, but also allows SIMD128 and NEON backends. | diff --git a/src/u8x16_.rs b/src/u8x16_.rs
index 2cbd767..3c2156e 100644
--- a/src/u8x16_.rs
+++ b/src/u8x16_.rs
@@ -459,6 +459,62 @@ impl u8x16 {
}
}
+ /// Unpack and interleave low lanes of two u8x16
+ pub fn unpack_low(lhs: u8x16, rhs: u8x16) -> u8x16 {
+ pick! {
+ if #[cfg(target_feature = "ss... | 2 | 72 | 0 |
86ff930908641ad049110ebd7e526c7686303813 | Lokathor | 2023-10-17T06:20:55 | chore: Release wide version 0.7.13 | diff --git a/Cargo.toml b/Cargo.toml
index fa61297..264aa36 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.12"
+version = "0.7.13"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"... | 1 | 1 | 1 |
fe73f078cdc3f33f1fc06422d1ead12f754982d9 | tower120 | 2023-10-17T04:04:28 | as_array_mut added to all simd types. (#142) | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index f93162e..ae9aa6d 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -1573,4 +1573,9 @@ impl f32x4 {
pub fn as_array_ref(&self) -> &[f32; 4] {
cast_ref(self)
}
+
+ #[inline]
+ pub fn as_array_mut(&mut self) -> &mut[f32; 4] {
+ cast_mut(self)
+ }
}
diff --... | 18 | 90 | 0 |
aba67bf2f4a3c13c343b5b26aa3818f9cd7f0cbc | Kristof Roomp | 2023-10-01T19:43:51 | Add dot product for i16. (#136)
* add reduce_add
* fix unit test
* added comments to reduce_add
* add i16 dot product instructions
* fix comment
* fix comment
* fix other cpus
* fix avx
* temporarily disable nightly MIPS tests and record issue
* fix test from merge | diff --git a/src/i16x16_.rs b/src/i16x16_.rs
index 54126bc..f582ce4 100644
--- a/src/i16x16_.rs
+++ b/src/i16x16_.rs
@@ -485,6 +485,21 @@ impl i16x16 {
}
}
+ /// Calculates partial dot product.
+ /// Multiplies packed signed 16-bit integers, producing intermediate signed 32-bit integers. Horizontally add ad... | 4 | 78 | 0 |
1fd7657a52f83c675c0cd08cbe92c6bceaf0280e | Lokathor | 2023-10-01T03:28:41 | chore: Release wide version 0.7.12 | diff --git a/Cargo.toml b/Cargo.toml
index 20b26ad..fa61297 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.11"
+version = "0.7.12"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"... | 1 | 1 | 1 |
6270f8dfe22720a8131179ec02942cdaea85ad8d | Kristof Roomp | 2023-09-26T16:32:16 | add reduce min/max along with tests. Also optimize i16 abs for sse2 (#138) | diff --git a/src/i16x16_.rs b/src/i16x16_.rs
index 510ebef..54126bc 100644
--- a/src/i16x16_.rs
+++ b/src/i16x16_.rs
@@ -390,8 +390,27 @@ impl i16x16 {
#[inline]
#[must_use]
pub fn reduce_add(self) -> i16 {
- let arr: [i16; 16] = cast(self);
- arr.iter().sum()
+ let arr: [i16x8; 2] = cast(self);
+
+ ... | 8 | 178 | 8 |
81cfcab42ae95b153ca780975ef0d44d81bb4436 | Kristof Roomp | 2023-09-13T13:02:16 | add reduce_add to integer (#135)
* add reduce_add
* fix unit test
* added comments to reduce_add | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index b35284a..f93162e 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -1379,7 +1379,10 @@ impl f32x4 {
let t2 = t1 >> 31;
!cast::<_, f32x4>(t2).cmp_eq(f32x4::ZERO)
}
+
+ /// horizontal add of all the elements of the vector
#[inline]
+ #[must_use]
pub fn... | 12 | 73 | 0 |
75971f165e19ea773e5652621363fd5f8ed4d8a8 | Lokathor | 2023-07-11T20:50:29 | chore: Release wide version 0.7.11 | diff --git a/Cargo.toml b/Cargo.toml
index e62ad8a..20b26ad 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.10"
+version = "0.7.11"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"... | 1 | 1 | 1 |
27efc4a49059da79f8e400dd001253b7b77ae4fe | Lokathor | 2023-07-11T20:46:25 | re apply inline and must_use | diff --git a/src/i8x16_.rs b/src/i8x16_.rs
index f548ac9..175ef24 100644
--- a/src/i8x16_.rs
+++ b/src/i8x16_.rs
@@ -577,8 +577,8 @@ impl i8x16 {
}
}
- //#[inline]
- //#[must_use]
+ #[inline]
+ #[must_use]
pub fn move_mask(self) -> i32 {
pick! {
if #[cfg(target_feature="sse2")] { | 1 | 2 | 2 |
3e3d23209cd7c93dd4202542bbda45a110dc5864 | UnrealInReal | 2023-07-11T20:44:44 | Add the miss impl of `Eq` for `u8x16` and `u16x8` (#134)
Co-authored-by: liuxiaonan <xiaonan.liu@motphys.com> | diff --git a/src/u16x8_.rs b/src/u16x8_.rs
index 8ed95f4..a0b28e5 100644
--- a/src/u16x8_.rs
+++ b/src/u16x8_.rs
@@ -46,6 +46,8 @@ pick! {
unsafe { vminvq_u16(vceqq_u16(self.neon, other.neon))==u16::MAX }
}
}
+
+ impl Eq for u16x8 { }
} else {
#[derive(Default, Clone, Copy, Parti... | 2 | 4 | 0 |
7ede2b4aca803a4274115d7e801dcdab46676518 | Lokathor | 2023-06-06T17:03:59 | chore: Release wide version 0.7.10 | diff --git a/Cargo.toml b/Cargo.toml
index 5cfaf40..e62ad8a 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.9"
+version = "0.7.10"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"
... | 1 | 1 | 1 |
d01c1999b4106ea6164062b4ec67e21ce8b6f2db | Lokathor | 2023-05-19T16:18:03 | chore: Release wide version 0.7.9 | diff --git a/Cargo.toml b/Cargo.toml
index 7398c95..c50c2bd 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.8"
+version = "0.7.9"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"
... | 1 | 1 | 1 |
981fd5793bdff383439e8342109a0f636c188019 | Kristof Roomp | 2023-05-19T16:16:27 | add narrow and widen operations to convert 8 to 16 to 32 bits (#130)
* add narrow and widen operations to convert 8 to 16 to 32 bits
* fixed comment and pack_to_i8_truncate
* fix i16x16
* fix i16x16 again
* fix native avx2 16x8
* fix arm for nonstd
* fix aarch64
* add simd128 versions of pack
*... | diff --git a/src/i16x16_.rs b/src/i16x16_.rs
index 9800abe..b3539c4 100644
--- a/src/i16x16_.rs
+++ b/src/i16x16_.rs
@@ -4,11 +4,11 @@ pick! {
if #[cfg(target_feature="avx2")] {
#[derive(Default, Clone, Copy, PartialEq, Eq)]
#[repr(C, align(32))]
- pub struct i16x16 { avx2: m256i }
+ pub struct i16x1... | 9 | 361 | 23 |
a1c00734293ff90cd1e3ffe67fc9e1ff6cdf1b72 | Lokathor | 2023-04-07T18:05:51 | more i16 stuff | diff --git a/src/i16x8_.rs b/src/i16x8_.rs
index e4e49e5..5515a8b 100644
--- a/src/i16x8_.rs
+++ b/src/i16x8_.rs
@@ -444,6 +444,27 @@ impl i16x8 {
pub fn new(array: [i16; 8]) -> Self {
Self::from(array)
}
+ /// Unpack the lower half of the input and expand it to `i16` values.
+ #[inline]
+ pub fn from_u8x... | 3 | 38 | 13 |
a6496d1b88344362bc26ff86f694719bcc1feae8 | Lokathor | 2023-02-26T15:58:44 | chore: Release wide version 0.7.8 | diff --git a/Cargo.toml b/Cargo.toml
index cc3407b..7398c95 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.7"
+version = "0.7.8"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"
... | 1 | 1 | 1 |
d75ba31cb7154704e61ca1991ad3ce1548e78e1c | Lokathor | 2023-02-24T16:16:45 | chore: Release wide version 0.7.7 | diff --git a/Cargo.toml b/Cargo.toml
index d2058d6..cc3407b 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.6"
+version = "0.7.7"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"
... | 1 | 1 | 1 |
d45924953bebdd33eab54f43f62d8df2079f3b87 | Kristof Roomp | 2023-02-23T19:35:11 | Provide matrix transpose for 8x8 types (#128)
* add i16x8 transpose
* added 32 bit
* added i32 transpose
* added f32 transpose
* fix f32
* fix comment
* better version of neon, swapped order of 16 and 32 bit swaps
* add DCT impl to example tests
* clean up i32 dct
* cleaned up examples a bit... | diff --git a/src/f32x8_.rs b/src/f32x8_.rs
index a2b3284..c597aad 100644
--- a/src/f32x8_.rs
+++ b/src/f32x8_.rs
@@ -1327,6 +1327,80 @@ impl f32x8 {
Self::pow_f32x8(self, f32x8::splat(y))
}
+ /// Transpose matrix of 8x8 f32 matrix. Currently only accelerated on AVX.
+ #[must_use]
+ #[inline]
+ pub fn tran... | 7 | 661 | 0 |
bbcdb8f54a63f520fd38ff2b803911f7a183c49a | Kristof Roomp | 2023-02-21T04:26:58 | made MulScaleRound a trait (#127)
* made MulScaleRound a trait
* made MulScaleRound a trait for i16x16 as well
* typo
* made mul_scale_round_n methods instead of traits
* remove accidentally added file | diff --git a/src/i16x16_.rs b/src/i16x16_.rs
index ff2c3ba..9800abe 100644
--- a/src/i16x16_.rs
+++ b/src/i16x16_.rs
@@ -397,6 +397,28 @@ impl i16x16 {
}
}
+ /// Multiply and scale equivilent to ((self * rhs) + 0x4000) >> 15 on each
+ /// lane, effectively multiplying by a 16 bit fixed point number between ... | 4 | 90 | 1 |
6e822b3a9b0f83df17ccdb31cc6adfe45313ec87 | Kristof Roomp | 2023-02-13T19:06:36 | add saturating add/sub i16 and multiply and scale (#123)
* add saturating add/sub i16 and multiply and scale
* made sure that we work even with sse2 turned off
* fixed formatting
* added saturating add/sub to i8,u8,u16
* fix error in wasm i16x16
* fixed name of intrisic
* added ssse3 codepath for mul... | diff --git a/src/f64x2_.rs b/src/f64x2_.rs
index 356e46c..9374b8f 100644
--- a/src/f64x2_.rs
+++ b/src/f64x2_.rs
@@ -438,7 +438,7 @@ impl f64x2 {
#[must_use]
pub fn fast_max(self, rhs: Self) -> Self {
pick! {
- if #[cfg(target_feature="sse")] {
+ if #[cfg(target_feature="sse2")] {
Self { s... | 14 | 777 | 3 |
a4fcad93647ed13a380b10e7f8c985ea5402f5bb | Lokathor | 2023-02-02T15:56:31 | chore: Release wide version 0.7.6 | diff --git a/Cargo.toml b/Cargo.toml
index cf78af2..d2058d6 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.5"
+version = "0.7.6"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"
... | 1 | 1 | 1 |
efb05d37c58820cae5e17e376b228e040918d007 | Lokathor | 2022-10-07T06:16:00 | (cargo-release) version 0.7.5 | diff --git a/Cargo.toml b/Cargo.toml
index a58e030..cf78af2 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.4"
+version = "0.7.5"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"
... | 1 | 1 | 1 |
ae1be208794d6e0300d8b3059837a528a200b182 | Lokathor | 2022-10-07T06:14:09 | much more inline! | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index ad1ad7c..52a13ee 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -806,6 +806,7 @@ impl f32x4 {
}
#[allow(non_upper_case_globals)]
+ #[inline]
pub fn asin_acos(self) -> (Self, Self) {
// Based on the Agner Fog "vector class library":
// https://git... | 9 | 157 | 111 |
7d586f967d0fa5a69a93c904a052d05907891a35 | Lokathor | 2022-10-07T06:13:08 | join all tests into a single test binary. this makes them run *much* faster | diff --git a/tests/all_tests/main.rs b/tests/all_tests/main.rs
new file mode 100644
index 0000000..c422741
--- /dev/null
+++ b/tests/all_tests/main.rs
@@ -0,0 +1,23 @@
+#![allow(clippy::approx_constant)]
+#![allow(clippy::unnecessary_cast)]
+#![allow(clippy::assertions_on_constants)]
+
+mod t_f32x4;
+mod t_f32x8;
+mod ... | 20 | 23 | 0 |
9d1c40bcf0f259e782b406d22628377a178fcb5c | Lokathor | 2022-10-07T05:49:37 | adjust comments for clarity. | diff --git a/src/lib.rs b/src/lib.rs
index 2f901cd..36f26bd 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -19,14 +19,13 @@
// Note(Lokathor): Due to standard library magic, the std-only methods for f32
// and f64 will automatically be available simply by declaring this.
+#[cfg(feature = "std")]
+extern crate std;
... | 1 | 2 | 3 |
2e722ae10904a9abea7517c0daa10537dd97fee1 | Josh Holmer | 2022-10-06T16:33:00 | Add inline attribute to array casts (#116)
I found that the Rust compiler was not inlining the methods
`to_array` and `as_array_ref`, which are extremely thin wrappers
around cast functions and should in theory always be inlined.
The lack of inlining was also preventing certain code optimizations
that the compiler... | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index fe6f1f5..ad1ad7c 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -1470,10 +1470,12 @@ impl f32x4 {
Self::pow_f32x4(self, f32x4::splat(y))
}
+ #[inline]
pub fn to_array(self) -> [f32; 4] {
cast(self)
}
+ #[inline]
pub fn as_array_ref(&self) -... | 18 | 36 | 0 |
5c79ff5f150b23d6e8d393223ce98984129e732e | Lokathor | 2022-01-23T05:46:50 | (cargo-release) version 0.7.4 | diff --git a/Cargo.toml b/Cargo.toml
index 7ccddba..a58e030 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.3"
+version = "0.7.4"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"
... | 1 | 1 | 1 |
1086a608893ffec5e73982f101e1bd918643461c | Lokathor | 2022-01-23T05:46:19 | Add a `new` method for each type that accepts an appropriate array. | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 7162bbf..fe6f1f5 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -424,6 +424,12 @@ impl CmpLt for f32x4 {
}
impl f32x4 {
+ #[inline]
+ #[must_use]
+ pub fn new(array: [f32; 4]) -> Self {
+ Self::from(array)
+ }
+
#[inline]
#[must_use]
pub fn blend(s... | 18 | 91 | 0 |
ff58177bdd59129fb6dee837a10a7fe416c31500 | Lokathor | 2021-12-12T22:34:32 | (cargo-release) version 0.7.3 | diff --git a/Cargo.toml b/Cargo.toml
index abd20ba..7ccddba 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.2"
+version = "0.7.3"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor/wide"
... | 1 | 1 | 1 |
0db49455ac01fd85a0016046d8c88a36d858b089 | Lokathor | 2021-12-12T22:33:20 | software_sqrt fix (#113)
* Update lib.rs
* Update lib.rs | diff --git a/src/lib.rs b/src/lib.rs
index db77b8c..2f901cd 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -750,6 +750,9 @@ fn software_sqrt(x: f64) -> f64 {
}
// inf and nan
{
+ if x.is_nan() {
+ return f64::NAN;
+ }
if ix0 & 0x7ff00000 == 0x7ff00000 {
return x * x + x;
} | 1 | 3 | 0 |
7bf2d87a6aecc76c9f674aeafa2ba17316cda84a | Lokathor | 2021-12-12T20:54:53 | (cargo-release) version 0.7.2 | diff --git a/Cargo.toml b/Cargo.toml
index 544e423..abd20ba 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.2-alpha.0"
+version = "0.7.2"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
82a93fe5070b12a22c73fb9e7a80449ac297db38 | TÖRÖK Attila | 2021-12-12T20:52:47 | Add as_array_ref to all types, similar to to_array (#112) | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 8f475d7..7162bbf 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -1467,4 +1467,8 @@ impl f32x4 {
pub fn to_array(self) -> [f32; 4] {
cast(self)
}
+
+ pub fn as_array_ref(&self) -> &[f32; 4] {
+ cast_ref(self)
+ }
}
diff --git a/src/f32x8_.rs b/src/f32x... | 18 | 72 | 0 |
25c3985f9cda57f7ff63673e41b769654955151b | Lokathor | 2021-09-16T12:55:40 | (cargo-release) start next development iteration 0.7.2-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index 2c55a26..544e423 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.1"
+version = "0.7.2-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
4c81cf5e21f031cb2d6b0d8602f701c839667e59 | Lokathor | 2021-09-16T12:55:06 | (cargo-release) version 0.7.1 | diff --git a/Cargo.toml b/Cargo.toml
index a1ec4d9..2c55a26 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.1-alpha.0"
+version = "0.7.1"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
9352715533e863b44ec54a435f08894669200444 | Jonas Schievink | 2021-08-11T18:33:35 | Fix typo in crate docs (#107) | diff --git a/src/lib.rs b/src/lib.rs
index 78f0d83..db77b8c 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -6,8 +6,8 @@
//! This crate provides SIMD-compatible data types.
//!
//! When possible, explicit SIMD is used with all the math operations here. As a
-//! fallback, the fact the fact that all the lengths of a fixe... | 1 | 2 | 2 |
265afbbbe6ecc571df830b505db3f80305634ae4 | Uriel | 2021-08-05T07:13:01 | add slice methods (#105)
* as_slice
* rename to to_array | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 3659aa3..88d716a 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -1463,4 +1463,8 @@ impl f32x4 {
pub fn powf(self, y: f32) -> Self {
Self::pow_f32x4(self, f32x4::splat(y))
}
+
+ pub fn to_array(self) -> [f32; 4] {
+ cast(self)
+ }
}
diff --git a/src/f3... | 18 | 72 | 0 |
29a615de57e117b4b2a2ac16a776ea88c1d6fee8 | Christopher Serr | 2021-08-04T22:37:31 | Fix `i16x16::blend` when `avx2` is not available (#104)
There's two SSE vectors when AVX2 is not available, so both need to be
blended. | diff --git a/src/i16x16_.rs b/src/i16x16_.rs
index 0646bbc..6018840 100644
--- a/src/i16x16_.rs
+++ b/src/i16x16_.rs
@@ -567,7 +567,10 @@ impl i16x16 {
if #[cfg(target_feature="avx2")] {
Self { avx2: blend_varying_i8_m256i(f.avx2, t.avx2, self.avx2) }
} else if #[cfg(target_feature="sse4.1")] {
-... | 1 | 4 | 1 |
95300068c10e6af162cca3b0f88a19f0f0c4050e | Uriel | 2021-08-04T21:31:00 | Implement multiplication in most vectors that dont have it (#103)
* add mult for 64s and splats
* implement tests
* add left-side splat
* impl mul to more vectors
* add more tests
* run cargo fmt | diff --git a/src/i16x16_.rs b/src/i16x16_.rs
index 4bd7132..0646bbc 100644
--- a/src/i16x16_.rs
+++ b/src/i16x16_.rs
@@ -163,6 +163,60 @@ impl Mul for i16x16 {
}
}
+impl Add<i16> for i16x16 {
+ type Output = Self;
+ #[inline]
+ #[must_use]
+ fn add(self, rhs: i16) -> Self::Output {
+ self.add(Self::splat(r... | 22 | 1,077 | 42 |
83144597253fb45a175782a05b3bfe4fbf7f97fc | Lokathor | 2021-08-04T02:17:21 | (cargo-release) start next development iteration 0.7.1-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index cdd8c2b..a1ec4d9 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.7.0"
+version = "0.7.1-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
4be592638cc2b423f4d7fbe26b0a182499b08143 | Lokathor | 2021-08-04T02:16:34 | (cargo-release) version 0.7.0 | diff --git a/Cargo.toml b/Cargo.toml
index 82294f5..cdd8c2b 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.6.6-alpha.0"
+version = "0.7.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
b2cfe07d7ef059b5f3e4535b3f0fbd428c3ff1c5 | Christopher Serr | 2021-07-29T16:34:29 | Use the `TAU` constant (#93)
The minimal Rust version of this crate is `1.52.0` and this constant got
stabilized in `1.47.0`. | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index e602937..c416830 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -41,7 +41,7 @@ impl f32x4 {
const_f32_as_f32x4!(LOG2_10, core::f32::consts::LOG2_10);
const_f32_as_f32x4!(PI, core::f32::consts::PI);
const_f32_as_f32x4!(SQRT_2, core::f32::consts::SQRT_2);
- co... | 4 | 4 | 4 |
475616aad910deed3eb4e6a7d740be5989a88566 | Christopher Serr | 2021-07-29T16:34:19 | Fix `Sub` and `Add` for `i32x8` (#94)
Clippy considered those implementations to be kinda sus. ඞ
 | diff --git a/src/i32x8_.rs b/src/i32x8_.rs
index 35e9a58..dbeda80 100644
--- a/src/i32x8_.rs
+++ b/src/i32x8_.rs
@@ -133,7 +133,7 @@ impl Add<i32x8> for i32 {
#[inline]
#[must_use]
fn add(self, rhs: i32x8) -> Self::Output {
- i32x8::splat(self) * rhs
+ i32x8::splat(self) + rhs
}
}
@@ -142,7 +142,7 ... | 1 | 3 | 3 |
3e58eb8e7a5cc4bcca6a0ba6dcffd89f52ec38a5 | Christopher Serr | 2021-07-29T16:34:09 | Fix some `Not` implementations (#95)
Some are inelegant and others are just plain wrong. | diff --git a/src/f32x8_.rs b/src/f32x8_.rs
index ff3e588..d2ed4b1 100644
--- a/src/f32x8_.rs
+++ b/src/f32x8_.rs
@@ -1441,14 +1441,14 @@ impl Not for f32x8 {
Self { sse0: self.sse0.not() , sse1: self.sse1.not() }
} else {
Self { arr: [
- f32::from_bits(self.arr[0].to_bits() ^ u32::MAX)... | 4 | 18 | 19 |
a9f8fb455bc6d9aa71ca48fd49f7809e21c70e86 | Lokathor | 2021-07-20T03:18:53 | fix move_mask | diff --git a/src/i32x8_.rs b/src/i32x8_.rs
index d0ba198..35e9a58 100644
--- a/src/i32x8_.rs
+++ b/src/i32x8_.rs
@@ -478,7 +478,13 @@ impl i32x8 {
move_mask_i8_m128i(self.sse0) << 16 | move_mask_i8_m128i(self.sse1)
}
else {
- unsafe { core::mem::transmute::<_, i8x32>(self) }.move_mask();
+... | 1 | 7 | 1 |
8ebc75392ff92018007940a57e4af40e255927eb | Lokathor | 2021-07-20T03:10:14 | fix safe_arch breaks | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 2c3f416..e602937 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -469,7 +469,7 @@ impl f32x4 {
pub fn round(self) -> Self {
pick! {
if #[cfg(target_feature="sse4.1")] {
- Self { sse: round_m128!(self.sse, Nearest) }
+ Self { sse: round_m128... | 5 | 28 | 36 |
5febaa5d2ee7e19f30af9507b6c6370e445bc02b | Nick Whitney | 2021-07-20T02:29:47 | Add the constants to i16x16 (#91) | diff --git a/src/i16x16_.rs b/src/i16x16_.rs
index 1fb4639..288aa15 100644
--- a/src/i16x16_.rs
+++ b/src/i16x16_.rs
@@ -16,6 +16,8 @@ pick! {
}
}
+int_uint_consts!(i16, 16, i16x16, i16x16, i16a16, const_i16_as_i16x16, 256);
+
unsafe impl Zeroable for i16x16 {}
unsafe impl Pod for i16x16 {}
diff --git a/src/l... | 2 | 3 | 1 |
9b2c84dcfcda6dd64f8c1febe463aadde8c84a18 | Lokathor | 2021-07-20T02:29:18 | fix no-feautres declaration. | diff --git a/src/i16x16_.rs b/src/i16x16_.rs
index e2f22c8..1fb4639 100644
--- a/src/i16x16_.rs
+++ b/src/i16x16_.rs
@@ -11,7 +11,7 @@ pick! {
pub struct i16x16 { pub(crate) sse0: m128i, pub(crate) sse1: m128i }
} else {
#[derive(Default, Clone, Copy, PartialEq, Eq)]
- #[repr(C, align(16))]
+ #[repr(... | 1 | 1 | 1 |
7837c2fbf7678eb1243d62e313350808d0658e35 | Squirrel | 2021-07-19T22:09:29 | i16x16 (#86)
* i16x16
* blend seems to use i8 regardless
* Bugfix for i32x8
(+ additional test to stop it coming back)
* Fixing mistake picked up by tests. | diff --git a/src/i16x16_.rs b/src/i16x16_.rs
new file mode 100644
index 0000000..e2f22c8
--- /dev/null
+++ b/src/i16x16_.rs
@@ -0,0 +1,503 @@
+use super::*;
+
+pick! {
+ if #[cfg(target_feature="avx2")] {
+ #[derive(Default, Clone, Copy, PartialEq, Eq)]
+ #[repr(C, align(32))]
+ pub struct i16x16 { avx2: m256... | 14 | 762 | 33 |
c5c1633fc0665ad4fa85581143211cd21b573c7b | Nick Whitney | 2021-07-19T22:06:06 | Implement constants for signed and unsigned integer types (#89)
* Expand the ConstUnionHack
Added additional fields to the 128bit version, and added the 256bit version.
The following types are commented out in the 256bit union because they haven't been implemented yet:
- i16x16
- u8x32
- u16x16
* Implement... | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 2944a87..2c3f416 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -15,7 +15,7 @@ pick! {
macro_rules! const_f32_as_f32x4 {
($i:ident, $f:expr) => {
pub const $i: f32x4 =
- unsafe { ConstUnionHack128bit { f32a4: [$f, $f, $f, $f] }.f32x4 };
+ unsafe { C... | 21 | 124 | 17 |
0ef14095cc77e3f0370af4f9a7585c91ed9a2825 | Lokathor | 2021-06-07T02:58:51 | (cargo-release) start next development iteration 0.6.6-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index fc9ce90..d21bf99 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.6.5"
+version = "0.6.6-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
566ae33d6d6fd53278fd1e06b80d941c3cacb9c2 | Lokathor | 2021-06-07T02:58:16 | (cargo-release) version 0.6.5 | diff --git a/Cargo.toml b/Cargo.toml
index 77585b3..fc9ce90 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.6.5-alpha.0"
+version = "0.6.5"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
cb91288ded8f2c2101cd23f2a64bede67240f4e3 | Wewe Lads | 2020-12-02T22:17:10 | Fix out of bounds index. (#84) | diff --git a/src/lib.rs b/src/lib.rs
index 94dc9bc..2d5f65c 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -592,7 +592,7 @@ macro_rules! from_array {
5 => $dst_wide::from([src[0] as $dst, src[1] as $dst, src[2] as $dst, src[3] as $dst, src[4] as $dst,0 as $dst,0 as $dst,0 as $dst,0 as $dst,0 as $dst,0 as $dst,0... | 1 | 1 | 1 |
aa2d4f943e6f4798b28219bb8b93e111574dfe73 | Lokathor | 2020-11-16T21:34:40 | (cargo-release) start next development iteration 0.6.5-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index eb32ecd..77585b3 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.6.4"
+version = "0.6.5-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
0bd3b2b91763b72b275d0678a7a02b1a6a1f114d | Lokathor | 2020-11-16T21:33:52 | (cargo-release) version 0.6.4 | diff --git a/Cargo.toml b/Cargo.toml
index c1f3ad5..eb32ecd 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.6.4-alpha.0"
+version = "0.6.4"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
a85d9fe42e6910f7c9106aa32388c73834d9e072 | Austin | 2020-11-16T21:29:30 | Implement {float}::copysign() (#83)
* Add {f64x4, f64x2, f32x8, f32x4}::copysign functions
* Add tests for copysign | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 2c55f11..2944a87 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -603,6 +603,13 @@ impl f32x4 {
self ^ (signs & Self::from(-0.0))
}
+ #[inline]
+ #[must_use]
+ pub fn copysign(self, sign: Self) -> Self {
+ let magnitude_mask = Self::from(f32::from_bits(... | 8 | 70 | 0 |
5fbfb55f75830909201faa7cd2043ebcd7563412 | Lokathor | 2020-11-08T18:06:54 | (cargo-release) start next development iteration 0.6.4-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index 44339ae..c1f3ad5 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.6.3"
+version = "0.6.4-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
bd7b7175e613943aafadeb6412f0ed8d73e9c38b | Lokathor | 2020-11-08T18:06:19 | (cargo-release) version 0.6.3 | diff --git a/Cargo.toml b/Cargo.toml
index e68a2a9..44339ae 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.6.3-alpha.0"
+version = "0.6.3"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
ce3d2b6c335fafe614933b2a6053ad8bb6b91de2 | Austin | 2020-11-08T17:56:43 | Implement {float}::atan(), and {float}::atan2() (#56) (#82)
* Add {f64x4, f64x2, f32x8, f32x4}::{atan, atan2} functions
* Add tests for atan and atan2
* Add polynomial_3 macro
* Remove extraneous argument in polynomial_5n macro | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 67db870..2c55f11 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -454,6 +454,15 @@ impl f32x4 {
let out = !(shift_u & shifted_exp_mask).cmp_eq(shifted_exp_mask);
cast(out)
}
+ #[inline]
+ #[must_use]
+ pub fn is_inf(self) -> Self {
+ let shifted_inf ... | 9 | 810 | 3 |
6a70a6f307701e394a94ccb080c9c47f6e59d783 | Lokathor | 2020-10-26T20:26:22 | (cargo-release) start next development iteration 0.6.3-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index c94dc1b..e68a2a9 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.6.2"
+version = "0.6.3-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
19c286c0908814be0342f331a07dca7ee7e6c4ce | Lokathor | 2020-10-26T20:25:20 | (cargo-release) version 0.6.2 | diff --git a/Cargo.toml b/Cargo.toml
index 33680d8..c94dc1b 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.6.2-alpha.0"
+version = "0.6.2"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
cee7b6f6cd7008a01a000f93f6710120c97162d5 | Evgeniy Reizner | 2020-10-17T17:11:54 | Lower i32x8/u32x8 SSE requirements from SSSE3 down to SSE2. (#80) | diff --git a/src/f32x8_.rs b/src/f32x8_.rs
index 9f8c12d..ebffc7b 100644
--- a/src/f32x8_.rs
+++ b/src/f32x8_.rs
@@ -9,8 +9,7 @@ pick! {
#[derive(Default, Clone, Copy, PartialEq)]
#[repr(C, align(32))]
pub struct f32x8 { sse0: m128, sse1: m128 }
- }
- else {
+ } else {
#[derive(Default, Clone, Co... | 3 | 117 | 139 |
fb7c9d4ce0254fc990818b00041057dbb7400620 | Lokathor | 2020-10-15T18:37:57 | (cargo-release) start next development iteration 0.6.2-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index b2335a9..33680d8 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.6.1"
+version = "0.6.2-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
6d7c364ade36b584bc7a74e0b28a415667403b82 | Lokathor | 2020-10-15T18:37:29 | (cargo-release) version 0.6.1 | diff --git a/Cargo.toml b/Cargo.toml
index ef2256a..b2335a9 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.6.1-alpha.0"
+version = "0.6.1"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
cf21c1510d7f298148d3f350668788f40744c265 | Evgeniy Reizner | 2020-10-15T18:32:50 | Add f32xN::recip and f32xN::recip_sqrt (#71)
Closes #69 | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index cc9eae6..67db870 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -789,6 +789,45 @@ impl f32x4 {
}
#[inline]
#[must_use]
+ pub fn recip(self) -> Self {
+ pick! {
+ if #[cfg(target_feature="sse")] {
+ Self { sse: reciprocal_m128(self.sse) }
+ ... | 4 | 228 | 0 |
e95d8f5131b98193fc3d9d48c574dacb47a9a721 | Evgeniy Reizner | 2020-10-12T18:45:01 | Remove unnecessary rounding from f32xN::trunc. (#74) | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 15a19a9..cc9eae6 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -518,17 +518,7 @@ impl f32x4 {
}
}
}
- // On i586, `f32::trunc` in the standard library will give wrong results.
- #[cfg(any(
- all(
- any(target_arch = "x86", target_arch = "x86_... | 4 | 22 | 54 |
9b9d5ee4c174999124b5163fabfaa23b2973fa19 | Lokathor | 2020-10-12T16:28:31 | Fix semver break (#73)
* (cargo-release) version 0.6.0
* (cargo-release) start next development iteration 0.6.1-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index 9f5249d..ef2256a 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.5.7-alpha.0"
+version = "0.6.1-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/... | 1 | 1 | 1 |
a931c1157ae9a07f7b3a03ad3a9be4be65b27592 | Lokathor | 2020-10-11T21:06:28 | (cargo-release) start next development iteration 0.5.7-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index bc671a1..9f5249d 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.5.6"
+version = "0.5.7-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
7b63ef1f18a8898b8097515d92ca7bdca5e2ddc2 | Lokathor | 2020-10-11T21:05:39 | (cargo-release) version 0.5.6 | diff --git a/Cargo.toml b/Cargo.toml
index 5604e18..bc671a1 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.5.6-alpha.0"
+version = "0.5.6"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
b8e96a8a0e41d915b993d1e2505e79c517f23939 | Lokathor | 2020-10-11T20:59:11 | fixups for next release. | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 9024e33..15a19a9 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -985,9 +985,9 @@ impl f32x4 {
if !mask.any() {
res
} else {
- let iszero = self.is_zero_or_subnormal();
+ let is_zero = self.is_zero_or_subnormal();
let res = underflow.b... | 4 | 46 | 39 |
b70df8af26c1bc9e0624311ef973a970d11ec4b8 | Lokathor | 2020-10-11T20:53:21 | adjust the cfg to allow sse+std at the same time. | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 3a8ee8c..9024e33 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -518,11 +518,16 @@ impl f32x4 {
}
}
}
- // Allow only for x86 with SSE and for other architectures when the `std` feature is enabled.
- // This is done to exclude i586, which retuns inval... | 3 | 19 | 8 |
cff702ae32bab589423e06ef74907320188dd8b2 | Evgeniy Reizner | 2020-10-11T20:41:24 | Add f32x4::trunc (#67)
Closes #66 | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index d552020..3a8ee8c 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -518,6 +518,33 @@ impl f32x4 {
}
}
}
+ // Allow only for x86 with SSE and for other architectures when the `std` feature is enabled.
+ // This is done to exclude i586, which retuns invali... | 4 | 102 | 0 |
f27a303211ea08e1ad189107dcb41bd394e668eb | Lokathor | 2020-09-13T16:50:59 | (cargo-release) start next development iteration 0.5.6-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index 9f7a0c7..5604e18 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.5.5"
+version = "0.5.6-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
0ca39772a8078f9d9699ff316bb9b457f480c50a | Lokathor | 2020-09-13T16:50:17 | (cargo-release) version 0.5.5 | diff --git a/Cargo.toml b/Cargo.toml
index 694e3b3..9f7a0c7 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.5.5-alpha.0"
+version = "0.5.5"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
3b1b4c16cae2044d04c990c50b86ef0c52dffcb3 | MindSpunk | 2020-09-13T15:09:54 | Fix invalid member name on blend sse4.1 variant (#63) | diff --git a/src/i8x32_.rs b/src/i8x32_.rs
index ea3f19d..b82a720 100644
--- a/src/i8x32_.rs
+++ b/src/i8x32_.rs
@@ -415,7 +415,7 @@ impl i8x32 {
if #[cfg(target_feature="avx2")] {
Self { avx: blend_varying_i8_m256i(f.avx, t.avx, self.avx) }
} else if #[cfg(target_feature="sse4.1")] {
- ... | 1 | 1 | 1 |
00de1af88cced28b9fb64fbe393261f203573c96 | Lokathor | 2020-09-07T17:51:17 | (cargo-release) start next development iteration 0.5.5-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index 72a187a..694e3b3 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.5.4"
+version = "0.5.5-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
811aae76aa66b92dce34486d037a490fb4a8263b | Lokathor | 2020-09-07T17:50:48 | (cargo-release) version 0.5.4 | diff --git a/Cargo.toml b/Cargo.toml
index b339d26..72a187a 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.5.4-alpha.0"
+version = "0.5.4"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
14ea4d4aa9450aa413c60860ac287d2e82834725 | ronniec95 | 2020-09-07T17:49:25 | Ops with base types (#53)
* Added tests for powf
* Initial merge and commit with asin* functions
* Fixed tests for ln so it works with i586 (no sse)
powf added for f32x4/f32x8/f64x2/f64x8
Had to disable impl_f32x8_asin_acos and impl_f32x4_asin_acos for i586 failure
* Most importantly added a powf that tak... | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 24f1001..42c9126 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -127,6 +127,78 @@ impl Div for f32x4 {
}
}
+impl Add<f32> for f32x4 {
+ type Output = Self;
+ #[inline]
+ #[must_use]
+ fn add(self, rhs: f32) -> Self::Output {
+ self.add(Self::splat(rhs))
+... | 11 | 459 | 0 |
831ee3c431d57ae92cf0ba4e0cf2dc2c16d0e79a | Lokathor | 2020-08-31T13:47:50 | (cargo-release) start next development iteration 0.5.4-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index a3187e5..b339d26 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.5.3"
+version = "0.5.4-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
9ecb82ad39931c5bf22e38a0ce41e23c55e79550 | Lokathor | 2020-08-31T13:47:27 | (cargo-release) version 0.5.3 | diff --git a/Cargo.toml b/Cargo.toml
index 96209e6..a3187e5 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.5.3-alpha.0"
+version = "0.5.3"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
9a5fc4f80ba8a5b52fb290cff86f329e747b8eae | ronniec95 | 2020-08-30T23:35:05 | Add powf (#50)
* Added tests for powf
* Initial merge and commit with asin* functions
* Fixed tests for ln so it works with i586 (no sse)
powf added for f32x4/f32x8/f64x2/f64x8
Had to disable impl_f32x8_asin_acos and impl_f32x4_asin_acos for i586 failure
* Most importantly added a powf that takes a f64x4/... | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 614c6ea..db13ae5 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -811,17 +811,13 @@ impl f32x4 {
pub fn reduce_add(self) -> f32 {
pick! {
- if #[cfg(target_feature="sse3")] {
- let a = add_horizontal_m128(self.sse, self.sse);
- let b = add_... | 3 | 9 | 14 |
ba508652abb2e302bf580767b0e6b8137f4e618c | Lokathor | 2020-08-28T03:44:17 | (cargo-release) start next development iteration 0.5.3-alpha.0 | diff --git a/Cargo.toml b/Cargo.toml
index bbb4c45..96209e6 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.5.2"
+version = "0.5.3-alpha.0"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
bfa623a51da2c10ecd81af14adf2436540f51bba | Lokathor | 2020-08-28T03:44:05 | (cargo-release) version 0.5.2 | diff --git a/Cargo.toml b/Cargo.toml
index 28d860d..bbb4c45 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,7 +1,7 @@
[package]
name = "wide"
description = "A crate to help you go wide."
-version = "0.5.2-alpha.0"
+version = "0.5.2"
authors = ["Lokathor <zefria@gmail.com>"]
repository = "https://github.com/Lokathor... | 1 | 1 | 1 |
55b870c6bde25531163c59ff9890710bcf94365c | Gray Olson | 2020-08-28T03:14:44 | Implement {float}::asin_acos(), {float}::asin(), and {float}::acos() (#48)
* f64x2::asin_acos, f64x2::asin, f64x2::acos
* f32x4::asin_acos, f32x4::asin, f32x4::acos
* tests for asin and acos
* fix polynomial_4, make test thresholds tighter
* impl asin_acos, asin, acos for avx/256bit types | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 06e56f9..39beac5 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -448,6 +448,119 @@ impl f32x4 {
self ^ (signs & Self::from(-0.0))
}
+ #[inline]
+ #[must_use]
+ #[allow(non_upper_case_globals)]
+ pub fn asin_acos(self) -> (Self, Self) {
+ // Based on t... | 8 | 1,081 | 0 |
d3c67d8f8fd4c3b85065b201bab0a53f23286e3c | ronniec95 | 2020-08-20T15:51:33 | Ln/log10/log2 added to f32x4 and f64x2 (#45)
* Added natural log (ln(e)) log10 log2 for f32x4 and f64x2
Added polynomial5n and 8 to lib.rs
* Refactoring to use some of the constants already defined
* updated the tests to check difference from std for ln(). +/-1*e-11 compared to std
* Change the exponent func... | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index a15f1ac..06e56f9 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -622,4 +622,72 @@ impl f32x4 {
let in_range = in_range & self.is_finite();
in_range.blend(z, Self::ZERO)
}
+
+ #[inline]
+ #[allow(non_upper_case_globals)]
+ fn exponent(self) -> f32x4 {
+... | 5 | 191 | 0 |
893be22607199750d429ccd499464e7ba924a2c8 | Lokathor | 2020-08-20T00:43:26 | Closes https://github.com/Lokathor/wide/issues/41 | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index ddc123f..a15f1ac 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -568,6 +568,22 @@ impl f32x4 {
}
}
}
+ #[inline]
+ #[must_use]
+ pub fn any(self) -> bool {
+ self.move_mask() != 0
+ }
+ #[inline]
+ #[must_use]
+ pub fn all(self) -> bool {
+ ... | 4 | 86 | 0 |
f6cd078be400e57c90c2bbc1a9791cd6336dd930 | Lokathor | 2020-08-20T00:34:30 | Change `exp` tests to assert minimal difference from the libstd `exp` function. | diff --git a/tests/t_f32x4.rs b/tests/t_f32x4.rs
index 7337a39..b0e8e3d 100644
--- a/tests/t_f32x4.rs
+++ b/tests/t_f32x4.rs
@@ -348,21 +348,12 @@ fn impl_f32x4_sqrt() {
#[test]
fn impl_f32x4_exp() {
- for (f, e) in [
- (-2.0, 0.13533528),
- (-1.0, 0.36787945),
- (0.0, 1.0),
- (1.0, 2.7182817),
- (1... | 2 | 8 | 26 |
a6d72c78ea546a6926d5e14e8234d64e2b1c026e | Lokathor | 2020-08-20T00:25:07 | float macros up, use the associated consts where possible. | diff --git a/src/f32x4_.rs b/src/f32x4_.rs
index 5f8da39..ddc123f 100644
--- a/src/f32x4_.rs
+++ b/src/f32x4_.rs
@@ -19,25 +19,9 @@ macro_rules! const_f32_as_f32x4 {
};
}
-macro_rules! polynomial_2 {
- ($x:expr, $c0:expr, $c1:expr, $c2:expr $(,)?) => {{
- let x = $x;
- let x2 = x * x;
- x2.mul_add($c2, ... | 3 | 54 | 64 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.