Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

How to speedup timeBackend

How to speedup timeBackend

Hello.

I made a model to solve the stress distribution that represented by a two dimensional array.

timeBackend of the model that has 40*70 array took about 20-30 minutes.
It'a too late for me...

I found following some tickets.
https://trac.openmodelica.org/OpenModelica/ticket/3695
https://trac.openmodelica.org/OpenModelica/ticket/2647

I applied --removeSimpleEquations=new which is writen in the #3695 but it was same timeBackend.
And I would to try to compile simplify2 but I didn't know how to compile it.

Do someone know how to speedup the timeBackend?

Version : OM 1.11.0(OM 1.12Dev is same timeBackend)
OS        :  Windows7
CPU      :  Core i7-4810MQ 2.8GHz
memory : 32Gbyte


Following are mistake.
Version : OM 1.9.6(OM 1.12Dev is same timeBackend)
OS        :  Windows7
CPU      :  Core i5-6300U 2.4GHz
memory : 12Gbyte

Edited by: Ueda - Apr-12-17 04:55:25

Re: How to speedup timeBackend

Hello,

you can further debug the timings with "-d=execstat", this enabled debug flag execstat, that dumps the time spend in each module.
Based on that analysis it's probably possible to change the configuration, so that the compiler performs better.

so long.
Willi

Re: How to speedup timeBackend

Thanks you

I tried to -d=execstat for the model.
And then following is result of high percentage commands.


Commandtime[sec]percentage[%]
matching and sorting (n=18156)271.413.1
analyzeInitialSystem (initialization)252.912.2
prepare postOptimizeDAE:271.413.1
postOpt tearingSystem (initialization)318.715.4
postOpt removeSimpleEquations (simulation)271.013.1
postOpt tearingSystem (simulation)317.115.3
ostOpt detectJacobianSparsePattern (simulation)269.013.0
total1971.595.3

*The model doesn't have pre() and is nonliear equation.

I want to study to reduce these time.
But, If someone know how to speedup these performance
could you tell me it, please?

Re: How to speedup timeBackend

If it's large nonlinear equations, performance should be expected to be slow in the backend. It means many equations are related to each other, which means any sort of dependency analysis or change in an equation will affect many other equations. What can sometimes improve performance is if common subexpression elimination can move parts of the nonlinear system outside of the algebraic loop. You can try it with some of: --preOptModules+=introduceDerAlias --postOptModules+=wrapFunctionCalls.

Otherwise, sending the model to us via a ticket (or openmodelica@ida.liu.se, or directly to a developer encrypted if it's sensitive information) and we could perform a more detailed profiling of the model and see if any support function can be improved to get better performance for some detail in the model.

Re: How to speedup timeBackend

Thanks sjoelund.se

I tried options  for the model in OMShell.

Code:


setCommandLineOptions("--preOptModules+=introduceDerAlias")
setCommandLineOptions("--postOptModules+=wrapFunctionCalls")

And following is Result.


Commandtime[sec]percentage[%]
matching and sorting (n=18156)270.313.7
analyzeInitialSystem (initialization)164.18.3
prepare postOptimizeDAE:271.413.8
postOpt tearingSystem (initialization)317.716.1
postOpt removeSimpleEquations (simulation)270.513.7
postOpt tearingSystem (simulation)315.116.0
ostOpt detectJacobianSparsePattern (simulation)268.813.6
total1877.995.2


I got about 100sec reduction about analyzeInitialSystem, but it's not enough.

I would like to send a mail for openmodelica@ida.liu.se.

Also, if you know how to try Simplify2 could you tell me it please.

Thanks for your help.

Edited by: Ueda - Apr-13-17 08:24:56
There are 0 guests and 0 other users also viewing this topic
You are here: