Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ jobs:
- name: Install dependencies
if: matrix.install_deps
run: ${{ matrix.install_deps }}
- name: Cargo deps locks
if: ${{ matrix.rust == '1.41.1' }}
run:
cargo update -p either --precise 1.13.0
- name: Tests
run: |
rustc -C target-cpu=native --print cfg
Expand Down Expand Up @@ -138,11 +142,7 @@ jobs:
profile: minimal
targets: ${{ matrix.target }}
- name: Cache cargo plugins
id: cache
uses: actions/cache@v1
with:
path: ~/.cargo/bin/
key: ${{ runner.os }}-cargo-plugins
uses: Swatinem/rust-cache@v2
- name: Install cross
if: steps.cache.outputs.cache-hit != 'true'
run: cargo install cross
Expand Down
3 changes: 0 additions & 3 deletions examples/usegemm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,23 +21,20 @@ use core::fmt::{Display, Debug};

trait Float : Copy + Display + Debug + PartialEq {
fn zero() -> Self;
fn one() -> Self;
fn from(x: i64) -> Self;
fn nan() -> Self;
fn is_nan(self) -> bool;
}

impl Float for f32 {
fn zero() -> Self { 0. }
fn one() -> Self { 1. }
fn from(x: i64) -> Self { x as Self }
fn nan() -> Self { 0./0. }
fn is_nan(self) -> bool { self.is_nan() }
}

impl Float for f64 {
fn zero() -> Self { 0. }
fn one() -> Self { 1. }
fn from(x: i64) -> Self { x as Self }
fn nan() -> Self { 0./0. }
fn is_nan(self) -> bool { self.is_nan() }
Expand Down
4 changes: 2 additions & 2 deletions src/debugmacros.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ macro_rules! dprint {
}
}

#[cfg(feature = "use_debug")]
/*
macro_rules! debug {
($e:expr) => {
$e;
}
}
*/

#[cfg(not(feature = "use_debug"))]
macro_rules! debug {
($e:expr) => {
}
Expand Down
1 change: 1 addition & 0 deletions src/kernel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ pub(crate) trait GemmKernel {
pub(crate) trait Element : Copy + Send + Sync {
fn zero() -> Self;
fn one() -> Self;
#[cfg_attr(not(test), allow(unused))]
fn test_value() -> Self;
fn is_zero(&self) -> bool;
fn add_assign(&mut self, rhs: Self);
Expand Down
Loading