From afecb9c758f73efe81838752f91477d3206346b6 Mon Sep 17 00:00:00 2001 From: Slava Pestov Date: Fri, 13 Nov 2009 04:32:33 -0600 Subject: [PATCH] Fixing call( inline caching --- .../tree/propagation/call-effect/call-effect.factor | 6 +----- core/compiler/units/units.factor | 2 +- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/basis/compiler/tree/propagation/call-effect/call-effect.factor b/basis/compiler/tree/propagation/call-effect/call-effect.factor index 545d02cf9a..ff4886d1c7 100644 --- a/basis/compiler/tree/propagation/call-effect/call-effect.factor +++ b/basis/compiler/tree/propagation/call-effect/call-effect.factor @@ -24,11 +24,7 @@ IN: compiler.tree.propagation.call-effect TUPLE: inline-cache value counter ; : inline-cache-hit? ( word/quot ic -- ? ) - { - [ nip value>> ] - [ value>> eq? ] - [ nip counter>> effect-counter eq? ] - } 2&& ; inline + { [ value>> eq? ] [ nip counter>> effect-counter eq? ] } 2&& ; inline : update-inline-cache ( word/quot ic -- ) [ effect-counter ] dip diff --git a/core/compiler/units/units.factor b/core/compiler/units/units.factor index 93ed6c4aa1..a46e846b0d 100644 --- a/core/compiler/units/units.factor +++ b/core/compiler/units/units.factor @@ -132,7 +132,7 @@ M: object bump-effect-counter* drop f ; or ; : bump-effect-counter ( -- ) - bump-effect-counter? [ 46 getenv 1 + 46 setenv ] when ; + bump-effect-counter? [ 46 getenv 0 or 1 + 46 setenv ] when ; : notify-observers ( -- ) updated-definitions dup assoc-empty?