Changeset 120 in kStuff
- Timestamp:
- Feb 18, 2022 2:00:53 AM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/k/kDefs.h
r116 r120 189 189 /** 64-bit SPARC. */ 190 190 #define K_ARCH_SPARC_64 (12 | K_ARCH_BIT_64 | K_ARCH_END_BI) 191 /** 32-bit RISC-V, little endian. */ 192 #define K_ARCH_RISCV_32 (13 | K_ARCH_BIT_32 | K_ARCH_END_LITTLE) 193 /** 32-bit RISC-V, big endian. */ 194 #define K_ARCH_RISCV_32_BE (13 | K_ARCH_BIT_32 | K_ARCH_END_BIG) 195 /** 64-bit RISC-V, little endian. */ 196 #define K_ARCH_RISCV_64 (13 | K_ARCH_BIT_64 | K_ARCH_END_LITTLE) 197 /** 64-bit RISC-V, big endian. */ 198 #define K_ARCH_RISCV_64_BE (13 | K_ARCH_BIT_64 | K_ARCH_END_BIG) 191 199 /** The end of the valid architecture values (exclusive). */ 192 200 #define K_ARCH_MAX (12+1) … … 225 233 # elif defined(__powerpc__) || defined(__ppc__) || defined(__PPC__) 226 234 # define K_ARCH K_ARCH_POWERPC_32 235 # elif defined(__riscv) 236 # if __BYTE_ORDER__ == WORDS_BIG_ENDIAN 237 # if defined(__riscv32) || __riscv_xlen+0 == 32 238 # define K_ARCH K_ARCH_RISCV_32_BE 239 # else 240 # define K_ARCH K_ARCH_RISCV_64_BE 241 # endif 242 # elif defined(__riscv32) || __riscv_xlen+0 == 32 243 # define K_ARCH K_ARCH_RISCV_32 244 # else 245 # define K_ARCH K_ARCH_RISCV_64 246 # endif 227 247 # elif defined(__sparcv9__) || defined(__sparcv9) 228 248 # define K_ARCH K_ARCH_SPARC_64 … … 235 255 # elif defined(__sh__) 236 256 # if !defined(__SH5__) 237 # define K_ARCH 257 # define K_ARCH K_ARCH_SH_32 238 258 # else 239 259 # if __SH5__ == 64 240 # define K_ARCH 260 # define K_ARCH K_ARCH_SH_64 241 261 # else 242 # define K_ARCH 262 # define K_ARCH K_ARCH_SH_32 243 263 # endif 244 264 # endif
Note:
See TracChangeset
for help on using the changeset viewer.