summaryrefslogtreecommitdiffstats
path: root/library/stdarch/crates/core_arch/src/mips/msa/macros.rs
blob: de8905840d71e56d0bd136e13bfd661e76446c34 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
//! Utility macros.

macro_rules! static_assert_imm_s5 {
    ($imm:ident) => {
        let _ = $crate::core_arch::macros::ValidateConstImm::<$imm, -16, 15>::VALID;
    };
}

macro_rules! static_assert_imm_s10 {
    ($imm:ident) => {
        let _ = $crate::core_arch::macros::ValidateConstImm::<$imm, -512, 511>::VALID;
    };
}

macro_rules! static_assert_imm_s11 {
    ($imm:ident) => {
        let _ = $crate::core_arch::macros::ValidateConstImm::<$imm, -1024, 1023>::VALID;
    };
}

macro_rules! static_assert_imm_s12 {
    ($imm:ident) => {
        let _ = $crate::core_arch::macros::ValidateConstImm::<$imm, -2048, 2047>::VALID;
    };
}

macro_rules! static_assert_imm_s13 {
    ($imm:ident) => {
        let _ = $crate::core_arch::macros::ValidateConstImm::<$imm, -4096, 4095>::VALID;
    };
}