Skip to content

Doesn't build on no_std with no features or alloc enabled only #34

@MuntasirSZN

Description

@MuntasirSZN

I tested no_std with x86_64-unknown-linux-gnu and x86_64-unknown-uefi.

error[E0425]: cannot find function `mm_extract_epi64` in this scope
   --> /home/muntasir/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/crc-fast-1.8.0/src/crc32/fusion/x86/iscsi/sse_pclmulqdq.rs:138:22
    |
138 |         let x0_low = mm_extract_epi64(x0, 0);
    |                      ^^^^^^^^^^^^^^^^
    |
   ::: /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse41.rs:16:1
    |
 16 | pub fn _mm_extract_epi64<const IMM1: i32>(a: __m128i) -> i64 {
    | ------------------------------------------------------------ similarly named function `_mm_extract_epi64` defined here
    |
help: the leading underscore in `_mm_extract_epi64` marks it as unused, consider renaming it to `mm_extract_epi64`
   --> /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse41.rs:16:8
    |
 16 - pub fn _mm_extract_epi64<const IMM1: i32>(a: __m128i) -> i64 {
 16 + pub fn mm_extract_epi64<const IMM1: i32>(a: __m128i) -> i64 {
    |
help: consider importing this function
    |
 11 + use crate::crc32::fusion::x86::mm_extract_epi64;
    |

error[E0425]: cannot find function `mm_extract_epi64` in this scope
   --> /home/muntasir/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/crc-fast-1.8.0/src/crc32/fusion/x86/iscsi/sse_pclmulqdq.rs:139:23
    |
139 |         let x0_high = mm_extract_epi64(x0, 1);
    |                       ^^^^^^^^^^^^^^^^
    |
   ::: /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse41.rs:16:1
    |
 16 | pub fn _mm_extract_epi64<const IMM1: i32>(a: __m128i) -> i64 {
    | ------------------------------------------------------------ similarly named function `_mm_extract_epi64` defined here
    |
help: the leading underscore in `_mm_extract_epi64` marks it as unused, consider renaming it to `mm_extract_epi64`
   --> /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse41.rs:16:8
    |
 16 - pub fn _mm_extract_epi64<const IMM1: i32>(a: __m128i) -> i64 {
 16 + pub fn mm_extract_epi64<const IMM1: i32>(a: __m128i) -> i64 {
    |
help: consider importing this function
    |
 11 + use crate::crc32::fusion::x86::mm_extract_epi64;
    |

error[E0425]: cannot find function `mm_extract_epi64` in this scope
   --> /home/muntasir/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/crc-fast-1.8.0/src/crc32/fusion/x86/iscsi/sse_pclmulqdq.rs:140:27
    |
140 |         let x0_combined = mm_extract_epi64(
    |                           ^^^^^^^^^^^^^^^^
    |
   ::: /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse41.rs:16:1
    |
 16 | pub fn _mm_extract_epi64<const IMM1: i32>(a: __m128i) -> i64 {
    | ------------------------------------------------------------ similarly named function `_mm_extract_epi64` defined here
    |
help: the leading underscore in `_mm_extract_epi64` marks it as unused, consider renaming it to `mm_extract_epi64`
   --> /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse41.rs:16:8
    |
 16 - pub fn _mm_extract_epi64<const IMM1: i32>(a: __m128i) -> i64 {
 16 + pub fn mm_extract_epi64<const IMM1: i32>(a: __m128i) -> i64 {
    |
help: consider importing this function
    |
 11 + use crate::crc32::fusion::x86::mm_extract_epi64;
    |

error[E0425]: cannot find function `crc_shift_iscsi_sse` in this scope
   --> /home/muntasir/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/crc-fast-1.8.0/src/crc32/fusion/x86/iscsi/sse_pclmulqdq.rs:141:13
    |
141 |             crc_shift_iscsi_sse(mm_crc32_u64(mm_crc32_u64(0, x0_low), x0_high), klen * 3 + 8),
    |             ^^^^^^^^^^^^^^^^^^^ not found in this scope
    |
help: consider importing this function
    |
 11 + use crate::crc32::fusion::x86::crc_shift_iscsi_sse;
    |

error[E0425]: cannot find function `mm_crc32_u64` in this scope
   --> /home/muntasir/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/crc-fast-1.8.0/src/crc32/fusion/x86/iscsi/sse_pclmulqdq.rs:141:33
    |
141 |             crc_shift_iscsi_sse(mm_crc32_u64(mm_crc32_u64(0, x0_low), x0_high), klen * 3 + 8),
    |                                 ^^^^^^^^^^^^
    |
   ::: /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse42.rs:20:1
    |
 20 | pub fn _mm_crc32_u64(crc: u64, v: u64) -> u64 {
    | --------------------------------------------- similarly named function `_mm_crc32_u64` defined here
    |
help: the leading underscore in `_mm_crc32_u64` marks it as unused, consider renaming it to `mm_crc32_u64`
   --> /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse42.rs:20:8
    |
 20 - pub fn _mm_crc32_u64(crc: u64, v: u64) -> u64 {
 20 + pub fn mm_crc32_u64(crc: u64, v: u64) -> u64 {
    |
help: consider importing this function
    |
 11 + use crate::crc32::fusion::x86::mm_crc32_u64;
    |

error[E0425]: cannot find function `mm_crc32_u64` in this scope
   --> /home/muntasir/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/crc-fast-1.8.0/src/crc32/fusion/x86/iscsi/sse_pclmulqdq.rs:141:46
    |
141 |             crc_shift_iscsi_sse(mm_crc32_u64(mm_crc32_u64(0, x0_low), x0_high), klen * 3 + 8),
    |                                              ^^^^^^^^^^^^
    |
   ::: /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse42.rs:20:1
    |
 20 | pub fn _mm_crc32_u64(crc: u64, v: u64) -> u64 {
    | --------------------------------------------- similarly named function `_mm_crc32_u64` defined here
    |
help: the leading underscore in `_mm_crc32_u64` marks it as unused, consider renaming it to `mm_crc32_u64`
   --> /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse42.rs:20:8
    |
 20 - pub fn _mm_crc32_u64(crc: u64, v: u64) -> u64 {
 20 + pub fn mm_crc32_u64(crc: u64, v: u64) -> u64 {
    |
help: consider importing this function
    |
 11 + use crate::crc32::fusion::x86::mm_crc32_u64;
    |

error[E0425]: cannot find function `mm_crc32_u64` in this scope
   --> /home/muntasir/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/crc-fast-1.8.0/src/crc32/fusion/x86/iscsi/sse_pclmulqdq.rs:149:16
    |
149 |         crc0 = mm_crc32_u64(crc0, *(buf as *const u64) ^ vc);
    |                ^^^^^^^^^^^^
    |
   ::: /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse42.rs:20:1
    |
 20 | pub fn _mm_crc32_u64(crc: u64, v: u64) -> u64 {
    | --------------------------------------------- similarly named function `_mm_crc32_u64` defined here
    |
help: the leading underscore in `_mm_crc32_u64` marks it as unused, consider renaming it to `mm_crc32_u64`
   --> /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse42.rs:20:8
    |
 20 - pub fn _mm_crc32_u64(crc: u64, v: u64) -> u64 {
 20 + pub fn mm_crc32_u64(crc: u64, v: u64) -> u64 {
    |
help: consider importing this function
    |
 11 + use crate::crc32::fusion::x86::mm_crc32_u64;
    |

error[E0425]: cannot find function `mm_crc32_u64` in this scope
   --> /home/muntasir/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/crc-fast-1.8.0/src/crc32/fusion/x86/iscsi/sse_pclmulqdq.rs:156:16
    |
156 |         crc0 = mm_crc32_u64(crc0, *(buf as *const u64));
    |                ^^^^^^^^^^^^
    |
   ::: /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse42.rs:20:1
    |
 20 | pub fn _mm_crc32_u64(crc: u64, v: u64) -> u64 {
    | --------------------------------------------- similarly named function `_mm_crc32_u64` defined here
    |
help: the leading underscore in `_mm_crc32_u64` marks it as unused, consider renaming it to `mm_crc32_u64`
   --> /home/muntasir/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/../../stdarch/crates/core_arch/src/x86_64/sse42.rs:20:8
    |
 20 - pub fn _mm_crc32_u64(crc: u64, v: u64) -> u64 {
 20 + pub fn mm_crc32_u64(crc: u64, v: u64) -> u64 {
    |
help: consider importing this function
    |
 11 + use crate::crc32::fusion::x86::mm_crc32_u64;
    |

error: `#[panic_handler]` function required, but not found

error: unwinding panics are not supported without std
  |
  = help: using nightly cargo, use -Zbuild-std with panic="abort" to avoid unwinding
  = note: since the core library is usually precompiled with panic="unwind", rebuilding your crate with panic="abort" may not be enough to fix the problem

Some errors have detailed explanations: E0412, E0425, E0433.
For more information about an error, try `rustc --explain E0412`.
error: could not compile `crc-fast` (lib) due to 211 previous errors

There are a lot more.

Rust version is 1.91.1.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions