summaryrefslogtreecommitdiff
path: root/lisp
Commit message (Collapse)AuthorAgeFilesLines
* * Fix limple-mode for new type and range limple semanticAndrea Corallo2020-11-121-1/+11
| | | | | | * lisp/emacs-lisp/comp.el (comp-limple-branches, comp-limple-ops): New variables. (comp-limple-lock-keywords): Update value.
* Add initial nativecomp typeset and range propagation supportAndrea Corallo2020-11-122-82/+271
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit add an initial support for a better type propagation and integer range propagation. Each mvar can be now characterized by a set of types, a set of values and an integral range. * lisp/emacs-lisp/comp.el (comp-known-ret-types): Store into typeset and remove fixnum. (comp-known-ret-ranges, comp-type-predicates): New variables. (comp-ctxt): Remove supertype-memoize slot and add union-typesets-mem. (comp-mvar): Remove const-vld, constant, type slots. Add typeset, valset, range slots. (comp-mvar-value-vld-p, comp-mvar-value, comp-mvar-fixnum-p) (comp-mvar-symbol-p, comp-mvar-cons-p) (comp-mvar-type-hint-match-p, comp-func-ret-typeset) (comp-func-ret-range): New functions. (make-comp-mvar, make-comp-ssa-mvar): Update logic. (comp--typeof-types): New variable. (comp-supertypes, comp-common-supertype): Logic update. (comp-subtype-p, comp-union-typesets, comp-range-1+) (comp-range-1-, comp-range-<, comp-range-union) (comp-range-intersection): New functions. (comp-fwprop-prologue, comp-mvar-propagate) (comp-function-foldable-p, comp-function-call-maybe-fold) (comp-fwprop-insn, comp-call-optim-func, comp-finalize-relocs): Logic update. * src/comp.c (emit_mvar_rval, emit_call_with_type_hint) (emit_call2_with_type_hint): Logic update. * lisp/emacs-lisp/cl-preloaded.el (cl--typeof-types): Undo the add of fixnum and bignum as unnecessary. * test/src/comp-tests.el (comp-tests-mentioned-p-1, comp-tests-cond-rw-checker-val) (comp-tests-cond-rw-checker-type, cond-rw-1, cond-rw-2) (cond-rw-3, cond-rw-4, cond-rw-5): Update for new type interface. (range-simple-union, range-simple-intersection): New integer range tests. (union-types): New union type test.
* * Rename two nativecomp functionsAndrea Corallo2020-11-121-5/+5
| | | | | | | * lisp/emacs-lisp/comp.el (comp-function-foldable-p): Rename from comp-function-optimizable-p. (comp-function-call-maybe-fold): Same from comp-function-call-maybe-fold.
* * lisp/emacs-lisp/comp.el (comp-fwprop-insn): Fix phi function.Andrea Corallo2020-11-081-13/+14
|
* * lisp/emacs-lisp/comp.el (comp-common-supertype-2): Fix null intersectionAndrea Corallo2020-11-071-8/+7
|
* Merge remote-tracking branch 'savannah/master' into HEADAndrea Corallo2020-11-07