Opened 6 years ago

Last modified 5 years ago

#5482 reopened defect

NF API is slow when visualizing simple block diagrams — at Initial Version

Reported by: Francesco Casella Owned by: Adrian Pop
Priority: blocker Milestone: 2.0.0
Component: NF API Version:
Keywords: Cc:

Description

I tried to open Modelica.Blocks.Examples.PID_Controller with -d=nfAPI. These are the times spent in various operations, in seconds:

old API new API
getIconAnnotation(Modelica.Blocks.Continuous.LimPID) 0.483 0.436
getComponentAnnotations(Modelica.Blocks.Continuous.LimPID) 0.431 0.145
getIconAnnotation(Modelica.Blocks.Continuous.Integrator)0.3330.403
getIconAnnotation(Modelica.Mechanics.Rotational.Interfaces.PartialTorque)0.4780.490
getComponentAnnotations(Modelica.Blocks.Continuous.Integrator)0.4410.083
getIconAnnotation(Modelica.Blocks.Nonlinear.Limiter)0.4440.389
Total 7.8 9.4

Although in some cases the new API is faster than the old one, in many it is comparable or even slower, and the overal time spent displaying the diagram is actually longer with the new API.

That's not what I expected based on the Annual Workshop demo.

Can you please check why the new API is not substantially faster in this case? Note that this is just the first model I tried out, I did not pick it specifically for performance issues.

Change History (0)

Note: See TracTickets for help on using tickets.