RV32 SoC DS UG
High-Perf RV32 SoC DS UG
RV64 SoC DS UG API and Examples
Embedded IDE UG
Loading...
Searching...
No Matches
type.h
Go to the documentation of this file.
1
2// Copyright (C) 2013-2026 Efinix Inc. All rights reserved.
3// Full license header bsp/efinix/EfxSapphireSocRV64/include/LICENSE.MD
5
6#ifndef TYPE_H_
7#define TYPE_H_
8
9
10#include <stdint.h>
11
12#ifdef __cplusplus
13extern "C" {
14#endif
15
16#if __riscv_xlen == 64
17 typedef int64_t slen ;
18 typedef uint64_t ulen ;
19#else
20 typedef int32_t slen ;
21 typedef uint32_t ulen ;
22#endif
23
24typedef uint64_t u64;
25typedef int64_t s64;
26typedef uint32_t u32;
27typedef int32_t s32;
28typedef uint16_t u16;
29typedef int16_t s16;
30typedef uint8_t u8;
31typedef int8_t s8;
32
33#define BIT_0 (1 << 0)
34#define BIT_1 (1 << 1)
35#define BIT_2 (1 << 2)
36#define BIT_3 (1 << 3)
37#define BIT_4 (1 << 4)
38#define BIT_5 (1 << 5)
39#define BIT_6 (1 << 6)
40#define BIT_7 (1 << 7)
41#define BIT_8 (1 << 8)
42#define BIT_9 (1 << 9)
43#define BIT_10 (1 << 10)
44#define BIT_11 (1 << 11)
45#define BIT_12 (1 << 12)
46#define BIT_13 (1 << 13)
47#define BIT_14 (1 << 14)
48#define BIT_15 (1 << 15)
49#define BIT_16 (1 << 16)
50#define BIT_17 (1 << 17)
51#define BIT_18 (1 << 18)
52#define BIT_19 (1 << 19)
53#define BIT_20 (1 << 20)
54#define BIT_21 (1 << 21)
55#define BIT_22 (1 << 22)
56#define BIT_23 (1 << 23)
57#define BIT_24 (1 << 24)
58#define BIT_25 (1 << 25)
59#define BIT_26 (1 << 26)
60#define BIT_27 (1 << 27)
61#define BIT_28 (1 << 28)
62#define BIT_29 (1 << 29)
63#define BIT_30 (1 << 30)
64#define BIT_31 (1 << 31)
65
66#ifdef __cplusplus
67}
68#endif // C_plusplus
69
70#endif //TYPE_H_
uint32_t ulen
Definition type.h:21
int64_t s64
Definition type.h:25
uint64_t u64
Definition type.h:24
uint8_t u8
Definition type.h:30
int8_t s8
Definition type.h:31
int16_t s16
Definition type.h:29
uint16_t u16
Definition type.h:28
int32_t slen
Definition type.h:20
int32_t s32
Definition type.h:27
uint32_t u32
Definition type.h:26