Running command: "" <> buildModelFMU(Modelica.StateGraph.Examples.FirstExample_Variant2,fileNamePrefix="Modelica_3_2_2_cpp_Modelica_StateGraph_Examples_FirstExample_Variant2",fmuType="me",version="2.0",platforms={"static"}) Notification: Performance of loadModel(Modelica): time 2.168/2.168, allocations: 194.9 MB / 208.4 MB, free: 3.25 MB / 170.7 MB Notification: Performance of FrontEnd - loaded program: time 3.637e-05/3.621e-05, allocations: 4 kB / 255.4 MB, free: 3.105 MB / 202.7 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1029/0.103, allocations: 44.5 MB / 299.9 MB, free: 6.539 MB / 250.7 MB Notification: Performance of FrontEnd - scodeFlatten: time 0.4373/0.5403, allocations: 71.42 MB / 371.4 MB, free: 21.39 MB / 314.7 MB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0003/0.5406, allocations: 64.84 kB / 371.4 MB, free: 21.39 MB / 314.7 MB Notification: Performance of FrontEnd - DAE generated: time 0.01311/0.5538, allocations: 2.941 MB / 374.4 MB, free: 20.9 MB / 314.7 MB Notification: Performance of FrontEnd: time 2.405e-06/0.5538, allocations: 0 / 374.4 MB, free: 20.9 MB / 314.7 MB Notification: Performance of Transformations before backend: time 2.049e-05/0.5539, allocations: 8.875 kB / 374.4 MB, free: 20.9 MB / 314.7 MB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 58 * Number of variables: 58 Notification: Performance of Generate backend data structure: time 0.0006669/0.5545, allocations: 453.4 kB / 374.8 MB, free: 20.51 MB / 314.7 MB Notification: Performance of prepare preOptimizeDAE: time 5.013e-05/0.5546, allocations: 9.906 kB / 374.8 MB, free: 20.51 MB / 314.7 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 8.138e-05/0.5547, allocations: 60.02 kB / 374.9 MB, free: 20.47 MB / 314.7 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 7.483e-05/0.5548, allocations: 19.94 kB / 374.9 MB, free: 20.46 MB / 314.7 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0002764/0.5551, allocations: 223.5 kB / 375.1 MB, free: 20.25 MB / 314.7 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 4.165e-05/0.5551, allocations: 28.83 kB / 375.2 MB, free: 20.25 MB / 314.7 MB Notification: Performance of preOpt expandDerOperator (simulation): time 5.405e-05/0.5552, allocations: 25.84 kB / 375.2 MB, free: 20.25 MB / 314.7 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0005758/0.5558, allocations: 261.5 kB / 375.4 MB, free: 20.16 MB / 314.7 MB Notification: Performance of preOpt findStateOrder (simulation): time 1.594e-05/0.5558, allocations: 3.984 kB / 375.4 MB, free: 20.16 MB / 314.7 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 3.309e-05/0.5558, allocations: 8.625 kB / 375.5 MB, free: 20.16 MB / 314.7 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 1.34e-05/0.5559, allocations: 6.719 kB / 375.5 MB, free: 20.16 MB / 314.7 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0004621/0.5563, allocations: 159 kB / 375.6 MB, free: 20.16 MB / 314.7 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.001506/0.5579, allocations: 0.9469 MB / 376.6 MB, free: 19.51 MB / 314.7 MB Notification: Performance of preOpt comSubExp (simulation): time 0.0003826/0.5583, allocations: 149.1 kB / 376.7 MB, free: 19.48 MB / 314.7 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0001752/0.5585, allocations: 75.05 kB / 376.8 MB, free: 19.47 MB / 314.7 MB Notification: Performance of preOpt evalFunc (simulation): time 3.246e-05/0.5585, allocations: 4.203 kB / 376.8 MB, free: 19.47 MB / 314.7 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0002604/0.5588, allocations: 112.6 kB / 376.9 MB, free: 19.41 MB / 314.7 MB Notification: Performance of pre-optimization done (n=23): time 2.996e-06/0.5588, allocations: 1.219 kB / 376.9 MB, free: 19.41 MB / 314.7 MB Notification: Performance of matching and sorting (n=23): time 0.0004808/0.5593, allocations: 159.4 kB / 377.1 MB, free: 19.37 MB / 314.7 MB Notification: Performance of inlineWhenForInitialization (initialization): time 4.277e-05/0.5594, allocations: 58.25 kB / 377.1 MB, free: 19.31 MB / 314.7 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0001678/0.5595, allocations: 146.1 kB / 377.3 MB, free: 19.21 MB / 314.7 MB Notification: Performance of collectPreVariables (initialization): time 4.085e-05/0.5596, allocations: 35.41 kB / 377.3 MB, free: 19.18 MB / 314.7 MB Notification: Performance of collectInitialEqns (initialization): time 0.0001002/0.5597, allocations: 210.7 kB / 377.5 MB, free: 19 MB / 314.7 MB Notification: Performance of collectInitialBindings (initialization): time 6.114e-05/0.5598, allocations: 59.22 kB / 377.6 MB, free: 18.97 MB / 314.7 MB Notification: Performance of simplifyInitialFunctions (initialization): time 2e-05/0.5598, allocations: 8.875 kB / 377.6 MB, free: 18.97 MB / 314.7 MB Notification: Performance of setup shared object (initialization): time 7.089e-05/0.5599, allocations: 324.9 kB / 377.9 MB, free: 18.65 MB / 314.7 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0001789/0.5601, allocations: 65.61 kB / 377.9 MB, free: 18.64 MB / 314.7 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0002243/0.5603, allocations: 126.7 kB / 378.1 MB, free: 18.57 MB / 314.7 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.0001971/0.5605, allocations: 69.98 kB / 378.1 MB, free: 18.56 MB / 314.7 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 3.868e-06/0.5605, allocations: 0 / 378.1 MB, free: 18.56 MB / 314.7 MB Notification: Performance of matching and sorting (n=40) (initialization): time 0.00059/0.5611, allocations: 241.7 kB / 378.4 MB, free: 18.5 MB / 314.7 MB Notification: Performance of prepare postOptimizeDAE: time 2.873e-05/0.5612, allocations: 6.781 kB / 378.4 MB, free: 18.5 MB / 314.7 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.059e-05/0.5612, allocations: 2.062 kB / 378.4 MB, free: 18.5 MB / 314.7 MB Notification: Performance of postOpt tearingSystem (initialization): time 2.591e-05/0.5612, allocations: 5.219 kB / 378.4 MB, free: 18.5 MB / 314.7 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0002568/0.5615, allocations: 38.86 kB / 378.4 MB, free: 18.49 MB / 314.7 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.708e-05/0.5615, allocations: 5.609 kB / 378.4 MB, free: 18.49 MB / 314.7 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0001773/0.5617, allocations: 16.66 kB / 378.4 MB, free: 18.48 MB / 314.7 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 4.626e-05/0.5618, allocations: 19.39 kB / 378.5 MB, free: 18.48 MB / 314.7 MB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 10 * Number of states: 0 () * Number of discrete variables: 30 ($PRE.transition1.enableFire,$PRE.transition2.enableFire,$whenCondition2,$whenCondition1,$PRE.initialStep.localActive,initialStep.localActive,$PRE.initialStep.newActive,initialStep.newActive,$PRE.initialStep.oldActive,initialStep.oldActive,initialStep.active,transition1.enableFire,transition1.fire,$PRE.transition1.t_start,transition1.t_start,$PRE.step.localActive,step.localActive,$PRE.step.newActive,step.newActive,$PRE.step.oldActive,step.oldActive,step.active,transition2.enableFire,$PRE.timer.entryTime,timer.entryTime,greaterEqual.y,stateGraphRoot.activeSteps,stateGraphRoot.resume,stateGraphRoot.suspend,transition1.condition) * Number of discrete states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (40): * Single equations (assignments): 40 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of prepare postOptimizeDAE: time 0.0001186/0.5619, allocations: 131.9 kB / 378.6 MB, free: 18.37 MB / 314.7 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 4.401e-05/0.562, allocations: 17.7 kB / 378.6 MB, free: 18.36 MB / 314.7 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0004909/0.5625, allocations: 193 kB / 378.8 MB, free: 18.31 MB / 314.7 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 7.854e-06/0.5625, allocations: 2.5 kB / 378.8 MB, free: 18.31 MB / 314.7 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 5.32e-06/0.5625, allocations: 3.938 kB / 378.8 MB, free: 18.3 MB / 314.7 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 5.57e-06/0.5625, allocations: 1.25 kB / 378.8 MB, free: 18.3 MB / 314.7 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.001032/0.5636, allocations: 0.5809 MB / 379.4 MB, free: 17.96 MB / 314.7 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 4.288e-06/0.5636, allocations: 0 / 379.4 MB, free: 17.96 MB / 314.7 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0001367/0.5638, allocations: 17.5 kB / 379.4 MB, free: 17.96 MB / 314.7 MB Notification: Performance of postOpt tearingSystem (simulation): time 8.396e-06/0.5638, allocations: 1.188 kB / 379.4 MB, free: 17.96 MB / 314.7 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.307e-05/0.5638, allocations: 4.844 kB / 379.4 MB, free: 17.96 MB / 314.7 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 5.601e-06/0.5638, allocations: 5.297 kB / 379.4 MB, free: 17.96 MB / 314.7 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 2.384e-06/0.5638, allocations: 0 / 379.4 MB, free: 17.96 MB / 314.7 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0004189/0.5643, allocations: 277.4 kB / 379.7 MB, free: 17.8 MB / 314.7 MB Notification: Performance of postOpt removeConstants (simulation): time 4.44e-05/0.5643, allocations: 84.92 kB / 379.8 MB, free: 17.7 MB / 314.7 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 3.735e-05/0.5644, allocations: 6.469 kB / 379.8 MB, free: 17.7 MB / 314.7 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001456/0.5645, allocations: 10.53 kB / 379.8 MB, free: 17.7 MB / 314.7 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.000121/0.5647, allocations: 18.48 kB / 379.8 MB, free: 17.7 MB / 314.7 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 2.808e-05/0.5647, allocations: 9.719 kB / 379.8 MB, free: 17.7 MB / 314.7 MB Notification: Performance of sorting global known variables: time 7.786e-05/0.5648, allocations: 102.4 kB / 379.9 MB, free: 17.62 MB / 314.7 MB Notification: Performance of sort global known variables: time 1.473e-06/0.5648, allocations: 4 kB / 379.9 MB, free: 17.62 MB / 314.7 MB Notification: Performance of remove unused functions: time 0.000494/0.5653, allocations: 48.06 kB / 380 MB, free: 17.61 MB / 314.7 MB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 1 * Number of states: 0 () * Number of discrete variables: 19 (step.active,step.localActive,transition1.enableFire,initialStep.localActive,$cse1,$cse2,$whenCondition2,$whenCondition1,initialStep.newActive,initialStep.oldActive,initialStep.active,transition1.fire,transition1.t_start,step.newActive,step.oldActive,transition2.enableFire,timer.entryTime,greaterEqual.y,stateGraphRoot.activeSteps) * Number of discrete states: 2 (initialStep.newActive,step.newActive) * Top-level inputs: 0 Notification: Strong component statistics for simulation (25): * Single equations (assignments): 21 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 4 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of Backend phase and start with SimCode phase: time 0.0007134/0.566, allocations: 0.8127 MB / 380.8 MB, free: 16.94 MB / 314.7 MB Notification: Performance of simCode: created initialization part: time 0.0005038/0.5666, allocations: 168 kB / 380.9 MB, free: 16.93 MB / 314.7 MB Notification: Performance of simCode: created event and clocks part: time 3.016e-06/0.5666, allocations: 4.188 kB / 380.9 MB, free: 16.92 MB / 314.7 MB Notification: Performance of simCode: created simulation system equations: time 0.0001953/0.5668, allocations: 78.36 kB / 381 MB, free: 16.92 MB / 314.7 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0003102/0.5671, allocations: 15.2 kB / 381 MB, free: 16.92 MB / 314.7 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.001032/0.5681, allocations: 319 kB / 381.3 MB, free: 16.74 MB / 314.7 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0008906/0.5691, allocations: 0.7401 MB / 382.1 MB, free: 32.04 MB / 330.7 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0001744/0.5693, allocations: 61.31 kB / 382.1 MB, free: 32.03 MB / 330.7 MB Notification: Performance of SimCode: time 2.574e-06/0.5693, allocations: 0 / 382.1 MB, free: 32.03 MB / 330.7 MB Notification: Performance of buildModelFMU: Generate C++ for platform static: time 2.587/3.156, allocations: 3.042 MB / 385.2 MB, free: 31.74 MB / 330.7 MB TODO: How the !@#!# did the simulation report success but simulation result Modelica_3.2.2_cpp_Modelica.StateGraph.Examples.FirstExample_Variant2_res.mat does not exist to compare? outputFormat=mat