Skip to content

Commit

Permalink
flambda-backend: Parse zero_alloc attributes into the typed tree (o…
Browse files Browse the repository at this point in the history
…caml-flambda#2400)

Check for [@zero_alloc] earlier, record it in the typed tree
  • Loading branch information
ccasin authored Apr 12, 2024
1 parent dd9c221 commit 337d4a0
Show file tree
Hide file tree
Showing 36 changed files with 1,038 additions and 1,559 deletions.
51 changes: 25 additions & 26 deletions .depend
Original file line number Diff line number Diff line change
Expand Up @@ -400,6 +400,7 @@ parsing/attr_helper.cmi : \
parsing/location.cmi \
parsing/asttypes.cmi
parsing/builtin_attributes.cmo : \
utils/zero_alloc_utils.cmi \
utils/warnings.cmi \
parsing/parsetree.cmi \
utils/misc.cmi \
Expand All @@ -412,6 +413,7 @@ parsing/builtin_attributes.cmo : \
parsing/ast_helper.cmi \
parsing/builtin_attributes.cmi
parsing/builtin_attributes.cmx : \
utils/zero_alloc_utils.cmx \
utils/warnings.cmx \
parsing/parsetree.cmi \
utils/misc.cmx \
Expand All @@ -424,6 +426,7 @@ parsing/builtin_attributes.cmx : \
parsing/ast_helper.cmx \
parsing/builtin_attributes.cmi
parsing/builtin_attributes.cmi : \
utils/zero_alloc_utils.cmi \
parsing/parsetree.cmi \
utils/misc.cmi \
parsing/location.cmi
Expand Down Expand Up @@ -1452,6 +1455,7 @@ typing/printtyp.cmi : \
typing/env.cmi \
parsing/asttypes.cmi
typing/printtyped.cmo : \
utils/zero_alloc_utils.cmi \
typing/types.cmi \
typing/typedtree.cmi \
parsing/printast.cmi \
Expand All @@ -1468,6 +1472,7 @@ typing/printtyped.cmo : \
parsing/asttypes.cmi \
typing/printtyped.cmi
typing/printtyped.cmx : \
utils/zero_alloc_utils.cmx \
typing/types.cmx \
typing/typedtree.cmx \
parsing/printast.cmx \
Expand Down Expand Up @@ -1731,6 +1736,7 @@ typing/typeclass.cmi : \
typing/ctype.cmi \
parsing/asttypes.cmi
typing/typecore.cmo : \
utils/zero_alloc_utils.cmi \
utils/warnings.cmi \
typing/untypeast.cmi \
typing/uniqueness_analysis.cmi \
Expand Down Expand Up @@ -1773,6 +1779,7 @@ typing/typecore.cmo : \
parsing/ast_helper.cmi \
typing/typecore.cmi
typing/typecore.cmx : \
utils/zero_alloc_utils.cmx \
utils/warnings.cmx \
typing/untypeast.cmx \
typing/uniqueness_analysis.cmx \
Expand Down Expand Up @@ -1994,6 +2001,7 @@ typing/typedecl_variance.cmi : \
typing/env.cmi \
parsing/asttypes.cmi
typing/typedtree.cmo : \
utils/zero_alloc_utils.cmi \
typing/types.cmi \
typing/shape.cmi \
typing/primitive.cmi \
Expand All @@ -2007,9 +2015,11 @@ typing/typedtree.cmo : \
parsing/jane_asttypes.cmi \
typing/ident.cmi \
typing/env.cmi \
parsing/builtin_attributes.cmi \
parsing/asttypes.cmi \
typing/typedtree.cmi
typing/typedtree.cmx : \
utils/zero_alloc_utils.cmx \
typing/types.cmx \
typing/shape.cmx \
typing/primitive.cmx \
Expand All @@ -2023,9 +2033,11 @@ typing/typedtree.cmx : \
parsing/jane_asttypes.cmx \
typing/ident.cmx \
typing/env.cmx \
parsing/builtin_attributes.cmx \
parsing/asttypes.cmi \
typing/typedtree.cmi
typing/typedtree.cmi : \
utils/zero_alloc_utils.cmi \
typing/types.cmi \
typing/shape.cmi \
typing/primitive.cmi \
Expand All @@ -2039,6 +2051,7 @@ typing/typedtree.cmi : \
parsing/jane_asttypes.cmi \
typing/ident.cmi \
typing/env.cmi \
parsing/builtin_attributes.cmi \
parsing/asttypes.cmi
typing/typemod.cmo : \
utils/warnings.cmi \
Expand Down Expand Up @@ -3958,36 +3971,28 @@ middle_end/variable.cmi : \
utils/identifiable.cmi \
typing/ident.cmi \
utils/compilation_unit.cmi
lambda/assume_info.cmo : \
utils/zero_alloc_utils.cmi \
lambda/assume_info.cmi
lambda/assume_info.cmx : \
utils/zero_alloc_utils.cmx \
lambda/assume_info.cmi
lambda/assume_info.cmi : \
utils/zero_alloc_utils.cmi
lambda/debuginfo.cmo : \
utils/zero_alloc_utils.cmi \
parsing/location.cmi \
utils/int_replace_polymorphic_compare.cmi \
typing/ident.cmi \
utils/compilation_unit.cmi \
parsing/asttypes.cmi \
lambda/assume_info.cmi \
lambda/debuginfo.cmi
lambda/debuginfo.cmx : \
utils/zero_alloc_utils.cmx \
parsing/location.cmx \
utils/int_replace_polymorphic_compare.cmx \
typing/ident.cmx \
utils/compilation_unit.cmx \
parsing/asttypes.cmi \
lambda/assume_info.cmx \
lambda/debuginfo.cmi
lambda/debuginfo.cmi : \
utils/zero_alloc_utils.cmi \
parsing/location.cmi \
typing/ident.cmi \
utils/compilation_unit.cmi \
parsing/asttypes.cmi \
lambda/assume_info.cmi
parsing/asttypes.cmi
lambda/lambda.cmo : \
typing/types.cmi \
typing/typedtree.cmi \
Expand All @@ -4003,6 +4008,7 @@ lambda/lambda.cmo : \
utils/config.cmi \
utils/compilation_unit.cmi \
utils/clflags.cmi \
parsing/builtin_attributes.cmi \
parsing/asttypes.cmi \
lambda/lambda.cmi
lambda/lambda.cmx : \
Expand All @@ -4020,6 +4026,7 @@ lambda/lambda.cmx : \
utils/config.cmx \
utils/compilation_unit.cmx \
utils/clflags.cmx \
parsing/builtin_attributes.cmx \
parsing/asttypes.cmi \
lambda/lambda.cmi
lambda/lambda.cmi : \
Expand All @@ -4034,6 +4041,7 @@ lambda/lambda.cmi : \
typing/env.cmi \
lambda/debuginfo.cmi \
utils/compilation_unit.cmi \
parsing/builtin_attributes.cmi \
parsing/asttypes.cmi
lambda/matching.cmo : \
typing/types.cmi \
Expand Down Expand Up @@ -4249,36 +4257,25 @@ lambda/translattribute.cmo : \
utils/warnings.cmi \
typing/typedtree.cmi \
parsing/parsetree.cmi \
utils/misc.cmi \
parsing/longident.cmi \
parsing/location.cmi \
lambda/lambda.cmi \
utils/config.cmi \
utils/clflags.cmi \
parsing/builtin_attributes.cmi \
parsing/asttypes.cmi \
lambda/assume_info.cmi \
lambda/translattribute.cmi
lambda/translattribute.cmx : \
utils/warnings.cmx \
typing/typedtree.cmx \
parsing/parsetree.cmi \
utils/misc.cmx \
parsing/longident.cmx \
parsing/location.cmx \
lambda/lambda.cmx \
utils/config.cmx \
utils/clflags.cmx \
parsing/builtin_attributes.cmx \
parsing/asttypes.cmi \
lambda/assume_info.cmx \
lambda/translattribute.cmi
lambda/translattribute.cmi : \
typing/typedtree.cmi \
parsing/parsetree.cmi \
parsing/location.cmi \
lambda/lambda.cmi \
lambda/assume_info.cmi
lambda/lambda.cmi
lambda/translclass.cmo : \
typing/types.cmi \
typing/typeopt.cmi \
Expand Down Expand Up @@ -4323,6 +4320,7 @@ lambda/translclass.cmi : \
lambda/debuginfo.cmi \
parsing/asttypes.cmi
lambda/translcore.cmo : \
utils/zero_alloc_utils.cmi \
typing/types.cmi \
typing/typeopt.cmi \
typing/typedtree.cmi \
Expand Down Expand Up @@ -4352,11 +4350,12 @@ lambda/translcore.cmo : \
typing/ctype.cmi \
utils/config.cmi \
utils/clflags.cmi \
parsing/builtin_attributes.cmi \
typing/btype.cmi \
parsing/asttypes.cmi \
lambda/assume_info.cmi \
lambda/translcore.cmi
lambda/translcore.cmx : \
utils/zero_alloc_utils.cmx \
typing/types.cmx \
typing/typeopt.cmx \
typing/typedtree.cmx \
Expand Down Expand Up @@ -4386,9 +4385,9 @@ lambda/translcore.cmx : \
typing/ctype.cmx \
utils/config.cmx \
utils/clflags.cmx \
parsing/builtin_attributes.cmx \
typing/btype.cmx \
parsing/asttypes.cmi \
lambda/assume_info.cmx \
lambda/translcore.cmi
lambda/translcore.cmi : \
typing/types.cmi \
Expand Down
Binary file modified boot/ocamlc
Binary file not shown.
1 change: 0 additions & 1 deletion compilerlibs/Makefile.compilerlibs
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,6 @@ TYPING = \
typing/typedecl_properties.cmo \
typing/typedecl_variance.cmo \
typing/typedecl_separability.cmo \
lambda/assume_info.cmo \
lambda/debuginfo.cmo lambda/lambda.cmo \
typing/typedecl.cmo \
typing/typeopt.cmo \
Expand Down
3 changes: 1 addition & 2 deletions dune
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@
annot outcometree

;; lambda/
assume_info debuginfo lambda matching printlambda runtimedef runtimetags tmc simplif switch
debuginfo lambda matching printlambda runtimedef runtimetags tmc simplif switch
translmode
transl_comprehension_utils
transl_array_comprehension transl_list_comprehension
Expand Down Expand Up @@ -330,7 +330,6 @@
(annot.mli as compiler-libs/annot.mli)
(outcometree.mli as compiler-libs/outcometree.mli)
(debuginfo.mli as compiler-libs/debuginfo.mli)
(assume_info.mli as compiler-libs/assume_info.mli)
(lambda.mli as compiler-libs/lambda.mli)
(matching.mli as compiler-libs/matching.mli)
(printlambda.mli as compiler-libs/printlambda.mli)
Expand Down
91 changes: 0 additions & 91 deletions lambda/assume_info.ml

This file was deleted.

37 changes: 0 additions & 37 deletions lambda/assume_info.mli

This file was deleted.

Loading

0 comments on commit 337d4a0

Please sign in to comment.