Remove symbol hash table from mrb_state structure.

Use linear search instead. Number of symbols is usually small (<1K), so
we don't need performance boost from hash tables. In our benchmark
measurement, hash tables consumes 790KB for `build/full-debug/mrbtest`.
This commit is contained in:
Yukihiro "Matz" Matsumoto
2019-01-24 17:57:12 +09:00
parent 1076bebde7
commit 02fbb2c211
2 changed files with 24 additions and 46 deletions
-1
View File
@@ -239,7 +239,6 @@ typedef struct mrb_state {
#endif
mrb_sym symidx;
struct kh_n2s *name2sym; /* symbol hash */
struct symbol_name *symtbl; /* symbol table */
size_t symcapa;