Opened 8 years ago
Last modified 4 years ago
#4138 closed task
New FrontEnd — at Version 25
Reported by: | Per Östlund | Owned by: | Per Östlund |
---|---|---|---|
Priority: | blocker | Milestone: | 1.17.0 |
Component: | New Instantiation | Version: | |
Keywords: | Cc: | Mahder Alemseged Gebremedhin, Adrian Pop |
Description (last modified by )
This ticket is tracking the progress on the the new frontend. Some documentation on the new frontend development is available on wiki:NewFrontEnd.
The current status is:
- Instantiation (Per, Adrian) 80%
- Instantiation of long and short class definitions are implemented. Still missing are overloaded functions and partial derivative functions. Partial support for class extends. The handling of equations, algorithms and expressions needs to be expanded.
- Extends (Per) 90%
- Support for extends is implemented. More error checking is needed though, e.g. for duplicate elements and illegal class types.
- Lookup (Per) 90%
- Basic lookup is implemented, both for class names and crefs. Very little error checking is done beyond "name could not be found" though. Some more lookup functions will likely be needed for e.g. inner/outer.
- Modifiers (Per) 80%
- Support of modifiers on components, extends clauses and class modifiers is implemented, more testing is needed.
- Redeclare (Per) 60%
- Only very basic redeclare of components is implemented, more work is needed for redeclare of classes, merging of modifiers, constraining type, etc. Preliminary support for redeclare-as-elements was implemented.
- Imports (Per) 25%
- Basic support for qualified imports is implemented, unqualified imports still remains. It's also only possible to import classes at the moment, and not components. Some way of marking elements as imported is also needed, currently they are just inserted into the importing class as they are.
- Conditional Components (Lennart)
- No support for conditional components implemented. This needs support from constant/function evaluation and expression simplification. It can be implemented after typing together with handling of component bindings.
- Inner/Outer (Adrian)
- No support for Inner/Outer is implemented at all so far, but the new instance tree structure should make this fairly straightforward. The inner outer can be implemented via addition of alias equations, is a matter of lookup of the inner component and prefixing.
- Functions (Per, Adrian, Peter, Mahder) 40%
- Partial support for functions. Instantiation and typing of functions is implemented. Positional arguments and named arguments are supported. Vectorization support has been be implemented. Support for reductions needs to be implemented. Per is working now on a way of storing functions during the instantiation is needed so that they end up in the DAE (we can probably use the component tree directly for this).
- Records (Mahder) 50%
- Support for records and for record constructors in the works.
- Builtin (Per, Peter) 30%
- So far only support for the basic types and time is implemented. Support for all the builtin functions and other builtin things (e.g. StateSelect, ExternalObject, etc.) needs to be implemented. As much as possible should be implemented via ModelicaBuiltin.
- Typing (Mahder, Peter) 70%
- Quite a lot of typing is already implemented, but it needs to be expanded to handle all kinds of expressions and so on.
- Type Checking (Mahder, Peter) 60%
- Some parts of the type checking module from the "old new frontend" is being used to type check binary expressions at the moment. Everything in NFTypeCheck that's not used is commented out since some of it doesn't compile any more. We need to investigate if more of the old code can be reused, and implement missing/nonreusable parts.
- Flattening (Per) 40%
- Expansion of array bindings is currently broken and need to be fixed. Subscripting needs to be improved, and the module in general needs to be expanded to keep up with the phases before it.
- Connection Handling (Adrian) 50%
- Handling of connect equations using the DAE and the instance tree.
- Unit checking (Arun) 100%
- Ported the backend unit checking to the new frontend. Added tests. Based on the DAE intermediate form.
- Operator Overloading (Mahder & Martin) 1%
- The support for operator overloading from the current front-end (or the previous implementation of the new front-end) should be ported to the new front-end.
- Constant Evaluation (Lennart) 30%
- Constant evaluate structural parameters (minimal) or any other constant/parameter bindings (not by default). Per implemented a new type of DAE component reference that contains links to the instantiated component tree on which one can do evaluation of bindings. Partial support for evaluating component references has been implemented, needs extending to support all types of expressions. We should ONLY evaluate what we need and nothing more.
- Function Evaluation (Lennart) 1%
- Sometimes to evaluate structural parameters one needs to evaluate functions. This will port the function interpretation from the current front-end to the new front-end.
- Expression Simplification (Lennart) %
- Expression simplification is needed together with constant/function evaluation to evaluate structural parameters. This needs to be a separate package so that can be reused in some other parts of the compiler. The current implementation is rather slow, should be improved up if possible.
- Local balance checking (Mahder)
- This will check the balance checking for each model so that errors can be detected sooner. We had no such support in the current front-end.
- Synchronous Features (BernhardT)
- The handling of the synchronous features (Clocks, etc) and state machines should be ported from the current front-end to the new front-end. This functionality needs function, builtin and inner/outer support.
Change History (26)
comment:1 by , 8 years ago
Cc: | added |
---|
comment:2 by , 8 years ago
Description: | modified (diff) |
---|
comment:3 by , 8 years ago
Description: | modified (diff) |
---|
follow-ups: 5 9 comment:4 by , 8 years ago
follow-up: 6 comment:5 by , 8 years ago
Replying to casella:
Still some problems with component modifiers.
I am well aware of that, and have already fixed this particular issue locally a while ago. At the moment I'm not really interested in bug reports though, the new instantiation is not ready for public testing yet.
follow-up: 7 comment:6 by , 8 years ago
Replying to perost:
At the moment I'm not really interested in bug reports though, the new instantiation is not ready for public testing yet.
Q1: Can you give a reasonable estimate of when this will be possible?
Q2: Is the interface towards the other tasks of Phase 2 already stabilized? If not, when will it reasonably be?
comment:7 by , 8 years ago
Replying to casella:
Q1: Can you give a reasonable estimate of when this will be possible?
No
Q2: Is the interface towards the other tasks of Phase 2 already stabilized? If not, when will it reasonably be?
Maybe
follow-up: 11 comment:10 by , 8 years ago
However, instantiating P.S in the attached test case still fails
by , 8 years ago
follow-up: 12 comment:11 by , 8 years ago
Replying to casella:
However, instantiating P.S in the attached test case still fails
It works fine for me, are you using the latest nightly build?
comment:12 by , 8 years ago
comment:13 by , 8 years ago
Description: | modified (diff) |
---|
comment:14 by , 8 years ago
Description: | modified (diff) |
---|
comment:15 by , 8 years ago
Component: | *unknown* → NF - New FrontEnd |
---|---|
Description: | modified (diff) |
comment:16 by , 8 years ago
Description: | modified (diff) |
---|
comment:17 by , 8 years ago
Description: | modified (diff) |
---|
comment:18 by , 8 years ago
Description: | modified (diff) |
---|---|
Summary: | NF core → New FrontEnd |
comment:19 by , 8 years ago
Milestone: | Future → 2.0.0 |
---|---|
Priority: | high → blocker |
Type: | defect → task |
comment:20 by , 8 years ago
Description: | modified (diff) |
---|
comment:21 by , 8 years ago
Description: | modified (diff) |
---|
Initial support for enumerations is now implemented.
comment:24 by , 8 years ago
Description: | modified (diff) |
---|
comment:25 by , 8 years ago
Description: | modified (diff) |
---|
Still some problems with component modifiers. Running the following test script
returns
so for some reason model C is not instantiated at all.