Skip to content

Commit 534547d

Browse files
authored
Merge pull request #1011 from bloomberg/ordered_hash_set_map
specialize ordered_hash_map
2 parents 14f1175 + a9d844f commit 534547d

18 files changed

+5208
-5460
lines changed

jscomp/Makefile

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,16 @@ ext/ident_map.ml : ext/map.cppo.ml
6464
# ext/map_poly.ml : ext/map.cppo.ml
6565
# cppo -D TYPE_POLY $< -o $@
6666

67+
ext/ordered_hash_map_make.ml: ext/ordered_hash_map.cppo.ml
68+
cppo -D TYPE_FUNCTOR $< -o $@
69+
ext/ordered_hash_map_local_ident.ml: ext/ordered_hash_map.cppo.ml
70+
cppo -D TYPE_LOCAL_IDENT $< -o $@
71+
72+
ext/ordered_hash_set_make.ml : ext/ordered_hash_set.cppo.ml
73+
cppo -D TYPE_FUNCTOR $< -o $@
74+
75+
ext/ordered_hash_set_string.ml:ext/ordered_hash_set.cppo.ml
76+
cppo -D TYPE_STRING $< -o $@
6777
## Stubs
6878
.c.o:
6979
$(NATIVE) -ccopt -o -ccopt $@ -c $<
@@ -125,10 +135,14 @@ EXT_SRCS = ext_util\
125135
ext_marshal ext_option \
126136
ext_pervasives ext_pp ext_ref ext_sys \
127137
hash_set_gen hash_set string_hash_set int_hash_set \
128-
ordered_hash_set ordered_hash_map union_find \
138+
ordered_hash_set_gen\
139+
ordered_hash_set_string\
140+
ordered_hash_map_gen\
141+
union_find \
129142
ext_ident\
130143
ident_map\
131144
ident_set\
145+
ordered_hash_map_local_ident\
132146
int_map\
133147
literals \
134148
string_map \

jscomp/all.depend

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,18 @@ ext/string_hash_set.cmx : ext/hash_set_gen.cmx ext/ext_string.cmx \
3434
stubs/bs_hash_stubs.cmx ext/string_hash_set.cmi
3535
ext/int_hash_set.cmx : ext/hash_set_gen.cmx ext/ext_int.cmx \
3636
stubs/bs_hash_stubs.cmx ext/int_hash_set.cmi
37-
ext/ordered_hash_set.cmx : ext/ext_util.cmx ext/ordered_hash_set.cmi
38-
ext/ordered_hash_map.cmx : ext/ext_util.cmx ext/ordered_hash_map.cmi
37+
ext/ordered_hash_set_gen.cmx : ext/ext_util.cmx
38+
ext/ordered_hash_set_string.cmx : ext/ordered_hash_set_gen.cmx \
39+
ext/ext_string.cmx stubs/bs_hash_stubs.cmx
40+
ext/ordered_hash_map_gen.cmx : ext/ext_util.cmx
3941
ext/union_find.cmx : ext/union_find.cmi
4042
ext/ext_ident.cmx : ext/string_hashtbl.cmx ext/string_hash_set.cmx \
4143
ext/ext_string.cmx ext/ext_ident.cmi
4244
ext/ident_map.cmx : ext/map_gen.cmx ext/ext_ident.cmx ext/ident_map.cmi
4345
ext/ident_set.cmx : ext/set_gen.cmx ext/ident_set.cmi
46+
ext/ordered_hash_map_local_ident.cmx : ext/ordered_hash_map_gen.cmx \
47+
ext/ext_ident.cmx stubs/bs_hash_stubs.cmx \
48+
ext/ordered_hash_map_local_ident.cmi
4449
ext/int_map.cmx : ext/map_gen.cmx ext/ext_int.cmx ext/int_map.cmi
4550
ext/literals.cmx : ext/literals.cmi
4651
ext/string_map.cmx : ext/map_gen.cmx ext/string_map.cmi
@@ -86,12 +91,11 @@ ext/ext_sys.cmi :
8691
ext/hash_set.cmi : ext/hash_set_gen.cmx
8792
ext/string_hash_set.cmi : ext/hash_set_gen.cmx
8893
ext/int_hash_set.cmi : ext/hash_set_gen.cmx
89-
ext/ordered_hash_set.cmi :
90-
ext/ordered_hash_map.cmi :
9194
ext/union_find.cmi :
9295
ext/ext_ident.cmi :
9396
ext/ident_map.cmi : ext/map_gen.cmx
9497
ext/ident_set.cmi : ext/set_gen.cmx
98+
ext/ordered_hash_map_local_ident.cmi : ext/ordered_hash_map_gen.cmx
9599
ext/int_map.cmi : ext/map_gen.cmx
96100
ext/literals.cmi :
97101
ext/string_map.cmi : ext/map_gen.cmx
@@ -290,9 +294,10 @@ core/bs_conditional_initial.cmx : common/bs_version.cmx \
290294
core/ocaml_options.cmx : common/bs_version.cmx core/ocaml_options.cmi
291295
core/ocaml_parse.cmx : syntax/ppx_entry.cmx common/js_config.cmx \
292296
core/ocaml_parse.cmi
293-
core/lam.cmx : ext/ordered_hash_map.cmx core/ocaml_stdlib_slots.cmx \
294-
ext/literals.cmx common/js_config.cmx ext/int_vec_vec.cmx ext/int_vec.cmx \
295-
ext/ident_set.cmx ext/ext_string.cmx ext/ext_scc.cmx core/lam.cmi
297+
core/lam.cmx : ext/ordered_hash_map_local_ident.cmx \
298+
core/ocaml_stdlib_slots.cmx ext/literals.cmx common/js_config.cmx \
299+
ext/int_vec_vec.cmx ext/int_vec.cmx ext/ident_set.cmx ext/ext_string.cmx \
300+
ext/ext_scc.cmx core/lam.cmi
296301
core/lam_print.cmx : core/lam.cmx core/lam_print.cmi
297302
core/lam_beta_reduce_util.cmx : core/lam.cmx ext/ident_hashtbl.cmx \
298303
core/lam_beta_reduce_util.cmi
@@ -543,7 +548,7 @@ ounit_tests/ounit_hash_stubs_test.cmx : ounit_tests/ounit_tests_util.cmx \
543548
ounit/oUnit.cmx ext/int_hash_set.cmx ext/hash_set_poly.cmx \
544549
stubs/bs_hash_stubs.cmx
545550
ounit_tests/ounit_hash_set_tests.cmx : ext/string_hash_set.cmx \
546-
ext/ordered_hash_set.cmx ounit/oUnit.cmx ext/hash_set_poly.cmx \
551+
ext/ordered_hash_set_string.cmx ounit/oUnit.cmx ext/hash_set_poly.cmx \
547552
ext/hash_set.cmx
548553
ounit_tests/ounit_scc_tests.cmx : ounit/oUnit.cmx ext/int_vec_vec.cmx \
549554
ext/int_vec.cmx ext/ext_string.cmx ext/ext_scc.cmx

jscomp/bin/all_ounit_tests.d

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ bin/all_ounit_tests.ml : ext/hash_set.ml
2626
bin/all_ounit_tests.ml : ext/hash_set.mli
2727
bin/all_ounit_tests.ml : ext/hash_set_poly.ml
2828
bin/all_ounit_tests.ml : ext/hash_set_poly.mli
29-
bin/all_ounit_tests.ml : ext/ordered_hash_set.ml
30-
bin/all_ounit_tests.ml : ext/ordered_hash_set.mli
3129
bin/all_ounit_tests.ml : stubs/bs_hash_stubs.ml
30+
bin/all_ounit_tests.ml : ext/ordered_hash_set_gen.ml
31+
bin/all_ounit_tests.ml : ext/ordered_hash_set_string.ml
3232
bin/all_ounit_tests.ml : ext/string_hash_set.ml
3333
bin/all_ounit_tests.ml : ext/string_hash_set.mli
3434
bin/all_ounit_tests.ml : ounit_tests/ounit_hash_set_tests.ml

0 commit comments

Comments
 (0)