Skip to content

Commit

Permalink
Reformat and address minor comments
Browse files Browse the repository at this point in the history
  • Loading branch information
GlassOfWhiskey committed Dec 3, 2023
1 parent bb4e9d5 commit 1c03839
Show file tree
Hide file tree
Showing 7 changed files with 338 additions and 364 deletions.
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ IF(CPUINFO_SUPPORTED_PLATFORM)
LIST(APPEND CPUINFO_SRCS
src/arm/android/properties.c)
ENDIF()
ELSEIF (CPUINFO_TARGET_PROCESSOR MATCHES "^(riscv(32|64)?)$")
ELSEIF(CPUINFO_TARGET_PROCESSOR MATCHES "^(riscv(32|64))$")
LIST(APPEND CPUINFO_SRCS
src/riscv/cache.c
src/riscv/uarch.c)
Expand All @@ -221,7 +221,7 @@ IF(CPUINFO_SUPPORTED_PLATFORM)
src/riscv/linux/init.c
src/riscv/linux/riscv-hw.c
src/riscv/linux/riscv-isa.c)
ENDIF ()
ENDIF()
ENDIF()

IF(CMAKE_SYSTEM_NAME STREQUAL "Emscripten")
Expand Down
8 changes: 0 additions & 8 deletions include/cpuinfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -78,14 +78,6 @@
#define CPUINFO_ARCH_PPC64 0
#endif

#ifndef CPUINFO_ARCH_RISCV32
#define CPUINFO_ARCH_RISCV32 0
#endif

#ifndef CPUINFO_ARCH_RISCV64
#define CPUINFO_ARCH_RISCV64 0
#endif

#ifndef CPUINFO_ARCH_ASMJS
#define CPUINFO_ARCH_ASMJS 0
#endif
Expand Down
8 changes: 4 additions & 4 deletions src/riscv/linux/api.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@

#if CPUINFO_ARCH_RISCV32 || CPUINFO_ARCH_RISCV64
/* arch/riscv/include/uapi/asm/hwcap.h */
#define CPUINFO_RISCV_LINUX_FEATURE_A UINT32_C(0x00000001)
#define CPUINFO_RISCV_LINUX_FEATURE_C UINT32_C(0x00000004)
#define CPUINFO_RISCV_LINUX_FEATURE_D UINT32_C(0x00000008)
#define CPUINFO_RISCV_LINUX_FEATURE_F UINT32_C(0x00000020)
#define CPUINFO_RISCV_LINUX_FEATURE_I UINT32_C(0x00000100)
#define CPUINFO_RISCV_LINUX_FEATURE_M UINT32_C(0x00001000)
#define CPUINFO_RISCV_LINUX_FEATURE_A UINT32_C(0x00000001)
#define CPUINFO_RISCV_LINUX_FEATURE_F UINT32_C(0x00000020)
#define CPUINFO_RISCV_LINUX_FEATURE_D UINT32_C(0x00000008)
#define CPUINFO_RISCV_LINUX_FEATURE_C UINT32_C(0x00000004)
#define CPUINFO_RISCV_LINUX_FEATURE_V UINT32_C(0x00200000)
#endif

Expand Down
Loading

0 comments on commit 1c03839

Please sign in to comment.