# HG changeset patch # User Paul Boddie # Date 1220740503 -7200 # Node ID bd6baced90abb0cbce59aa18cb0c569c0283344a # Parent a36ce78d98d4a194293af34ec7d17e51e6544d01 Added a summary of current optimisations. diff -r a36ce78d98d4 -r bd6baced90ab docs/optimisations.txt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/docs/optimisations.txt Sun Sep 07 00:35:03 2008 +0200 @@ -0,0 +1,45 @@ +Optimisation Prerequisites and Effect +------------ ------------------------ + +constant_storage value instruction references a constant; + storage instruction references a constant; + remove both instructions (currently a single merged instruction) + +source_storage source instruction is a simple input operation; + source instruction is the last instruction; + remove the source instruction + +known_target value instruction references a constant; + target and context are provided (no instructions removed) + +self_access value instruction references "self" in a method; + specified attribute name always has the same position; + appropriate instruction generated + +temp_storage value instruction is a simple input operation; + value instruction is the last instruction; + remove the value instruction, provide the value + instruction in place of a temporary storage + reference + +load_operations value instruction is a simple input operation; + value instruction is the last instruction; + current instruction uses simple input; + remove the value instruction, make the value + instruction the input to the current instruction + +no_operations input to the current instruction loads from the + destination of the current instruction; + omit the current instruction + +unused_results value instruction is a simple input operation; + value instruction is the final instruction of a + discarded expression; + remove the value instruction + +superfluous_temp_operations source instruction writes to temporary storage; + current instruction reads from the same storage; + source instruction is the last instruction; + remove the source instruction, make the current + instruction use the input of the source + instruction