mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
mruby-set: reduce KSET_INITIAL_SIZE to 4
This change optimizes memory consumption by reducing the initial size of the set's internal hash table. Co-authored-by: Gemini <gemini@google.com>
This commit is contained in:
@@ -34,7 +34,7 @@ kset_equal_value(mrb_state *mrb, mrb_value a, mrb_value b)
|
||||
|
||||
KHASH_DEFINE(set_val, mrb_value, char, FALSE, kset_hash_value, kset_equal_value)
|
||||
|
||||
#define KSET_INITIAL_SIZE 8
|
||||
#define KSET_INITIAL_SIZE 4
|
||||
|
||||
/* Compatibility layer and type definitions */
|
||||
typedef kh_set_val_t kset_t;
|
||||
|
||||
Reference in New Issue
Block a user