From 9cc101327450f5871749ecd797361f5b254100e5 Mon Sep 17 00:00:00 2001 From: Alasdair Armstrong Date: Wed, 6 Jun 2018 20:52:35 +0100 Subject: Factor utility functions for IR into separate file and struct update optimizations. Move the utility functions for graph generation and pretty printing of intermediate representation instructions into a separate file, bytecode_util.ml, by analogy with ast_util.ml. Add an optimization pass that searches for specific patterns of struct updates and removes uncessary copying of the structs involved. With this optimisation pass the time taken for u-boot to run approx 57,000,000 instructions goes down from about 11-12 minutes to 8 minutes (about 120,000 IPS). --- language/bytecode.ott | 1 + 1 file changed, 1 insertion(+) (limited to 'language') diff --git a/language/bytecode.ott b/language/bytecode.ott index be2bd4a4..704bda83 100644 --- a/language/bytecode.ott +++ b/language/bytecode.ott @@ -105,6 +105,7 @@ clexp :: 'CL_' ::= | id :: :: id | id . string :: :: field | * id :: :: addr + | id -> string :: :: addr_field | current_exception :: :: current_exception | have_exception :: :: have_exception -- cgit v1.2.3