diff options
| author | Alessandro Gatti <a.gatti@frob.it> | 2024-12-04 22:45:28 +0100 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2024-12-10 12:10:36 +1100 |
| commit | 28b52446669b72f9863902510430bdeeaaa39fa6 (patch) | |
| tree | e672ec9e30fa2495b8665d20f38cb505e31e78cb | |
| parent | 2a8f6047ff5c94bba7ace738a14b572cc8553251 (diff) | |
extmod/modplatform: Distinguish RISC-V 64 from RISC-V 32.
This commit lets the platform module report a more accurate architecture
name when running on a RISC-V 64 bits platform.
Signed-off-by: Alessandro Gatti <a.gatti@frob.it>
| -rw-r--r-- | extmod/modplatform.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/extmod/modplatform.h b/extmod/modplatform.h index 5c9cbffb2..a155f071c 100644 --- a/extmod/modplatform.h +++ b/extmod/modplatform.h @@ -48,7 +48,11 @@ #elif defined(__xtensa__) #define MICROPY_PLATFORM_ARCH "xtensa" #elif defined(__riscv) +#if __riscv_xlen == 64 +#define MICROPY_PLATFORM_ARCH "riscv64" +#else #define MICROPY_PLATFORM_ARCH "riscv" +#endif #else #define MICROPY_PLATFORM_ARCH "" #endif |
