Opened 15 years ago
Closed 12 years ago
#1128 closed discussion (wontfix)
Improve instantation speed
Reported by: | Jan Brugård | Owned by: | Jan Brugård |
---|---|---|---|
Priority: | critical | Milestone: | Red October |
Component: | Backend | Version: | |
Keywords: | Cc: | Jan Brugård |
Description
There are several problems with slow instantation, i.e. that models takes long time to check. Below is a quite Technical list of things that can be improved:
- Change the DAE representation from a list data structure to something more intelligent (since the instantiation code does lookup in this and backpatching, etc. it should be low cost to find and replace elements). There is a separate ticket for this (#1478)
- Lookup in environment involves instantiation, and no reuse of already instantiated classes is done. New frames in the Enviroment are created on the fly, and thrown away afterwards. The Enviroment (Env) should be redesigned to allow:
Some way of caching DAE, so instantiation to produce dae could be reused (beware of how to handle modifiers!)
Some way of caching frames so once a frame has been created it should not be created again. This means going from a list structure to a tree structure with an additional "pointer" to indicate the current scope.
Contain instance hierarchy to also find inner/outer components and classes.
Still keep efficient lookup of variables and classes.
- More optimizations like lazy evaluation of parameter expressions (today parameter expressions are always evaluated even if it means evaluating function calls, etc), stripping binding expressions from partial instantiation (today the binding expression of a constant is evaluated to find its type)
Change History (3)
comment:1 by , 15 years ago
comment:3 by , 12 years ago
Cc: | brugard, → brugard |
---|---|
Component: | → Backend |
Resolution: | → wontfix |
Status: | new → closed |
The new instantation will fix the remaining issues. Performance was improved for the deadline.
http://intranet/trac/mathmodelica/ticket/2468