Skip to content

Commit 2e0a0b5

Browse files
committed
bricks/_common/mpconfigport.h: set MICROPY_QSTR_BYTES_IN_HASH 0 on small hubs
To save some flash memory, we can set MICROPY_QSTR_BYTES_IN_HASH to 0 on small hubs. On big hubs, setting it to 2 can improve performance.
1 parent 65d5196 commit 2e0a0b5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bricks/_common/mpconfigport.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
X(ETIMEDOUT) \
3737
X(ECANCELED) \
3838

39-
#define MICROPY_QSTR_BYTES_IN_HASH (1)
39+
#define MICROPY_QSTR_BYTES_IN_HASH (PYBRICKS_OPT_EXTRA_LEVEL2 ? 2 : 0)
4040
#define MICROPY_ALLOC_PATH_MAX (256)
4141
#define MICROPY_ALLOC_PARSE_CHUNK_INIT (16)
4242
#define MICROPY_EMIT_X64 (PYBRICKS_OPT_NATIVE_MOD && __x86_64__)

0 commit comments

Comments
 (0)