From 2cd5fff635d7b7954a220cf474172b4c0955cb55 Mon Sep 17 00:00:00 2001 From: dos-reis Date: Sat, 26 Feb 2011 12:55:47 +0000 Subject: * interp/g-opt.boot (canInlineVarDefinition): Observe order of evaluation. --- src/ChangeLog | 5 +++++ src/interp/g-opt.boot | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/ChangeLog b/src/ChangeLog index 18878936..90e2b934 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2011-02-26 Gabriel Dos Reis + + * interp/g-opt.boot (canInlineVarDefinition): Observe order of + evaluation. + 2011-02-25 Gabriel Dos Reis * interp/g-opt.boot (optNot): Push %not inside conditionals. diff --git a/src/interp/g-opt.boot b/src/interp/g-opt.boot index b119ce5f..e6e8b934 100644 --- a/src/interp/g-opt.boot +++ b/src/interp/g-opt.boot @@ -540,7 +540,7 @@ canInlineVarDefinition(var,expr,body) == -- side-effected latter, it is alos a no no. or/[varIsAssigned(x,body) for x in dependentVars expr] => false -- Conversatively preserve order of inialization - body is ['%bind,:.] => false + cons? body and body.op in '(%bind LET %loop %collect) => false -- Linearly used internal temporaries should be replaced, and -- so should side-effet free initializers for linear variables. usageCount := numOfOccurencesOf(var,body) -- cgit v1.2.3