Transcript Slide 1

WW TSS-03
ArchestrA Graphics: Design
Guidelines for Top Performance
Mirko Canel
October, 2012
© 2012 Invensys. All Rights Reserved. The names, logos, and taglines identifying the products and services of Invensys are proprietary marks of
Invensys or its subsidiaries. All third party trademarks and service marks are the proprietary marks of their respective owners.
Slide 3
Agenda
We will discuss design considerations to achieve the best performance
from Wonderware ArchestrA Graphics. Key topics covered:
1. Improve the performance of graphics to reduce the total time to
show updated values
2. CPU Utilization Considerations
3. Memory Utilization Considerations
4. Bottleneck Investigation
5. ArchestrA IDE Performance Considerations
Slide 5
Introduction
ArchestrA Graphics overview of the technology
1. .NET considerations on memory utilization: Garbage Collector (the
typical saw tooth in the memory utilization)
2. Vector graphics overview of the concepts
3. GDI+ and CPU rendering
Slide 6
Introduction GDI, GDI+
GDI
Obj_line GDI+
Fn1(x)
Fn2(x)
Obj_rect
Fn4(x)
Fn3(x)
Obj_bmp
Obj_Transparency
Obj_ Antialiasing
Obj_ Translucency
Obj_Gradients
Slide 7
ArchestrA Graphics Call-Up time base
concepts
Retrieve Definition
Graphic Call-up Time
Bind Data
Static CPU Load
Render
Memory Utilization
Continuous Updates
Close
Call-Up Time
Retrieve
Slide 8
Bind
Render
Continuous
Close
Call Up Time: The contributors
Simplified overview on the main contributors to the time consumption
when showing an ArchestrA Graphic
• Retrieve Definition: Size and complexity of the ArchestrA Graphics
• Binding Data: Number of custom properties and references
• Rendering Time: Total number of simple and complex graphic
elements, runtime graphical effects
• Waiting Data: Engine scan cycle, I/O speed, communication strategy
• Expression Evaluation: Total number, complexity, code efficiency
• Delta Rendering: Number of data changes + Total number of simple
and complex graphic elements, runtime graphical effects
Retrieve Bind
Slide 9
Render
Waiting Data…
Expression
Evaluation
Render Close
Call-Up Time Advanced concepts:
ActiveOnDemand DDE SuiteLink
GoodQuality / Initializing:2012 New Feature
Behavior introduced by the Engine, always
consistent across the next examples.
L00115867: InitializingQualityOnSuspend=1
Call-Up Time
Delta Expressions
Evaluation
Cached data
Delta Expressions
Evaluation
ArchestrAGraphic
Retrieve
Bind
Render
IO / AppServer
Waiting Data…
1 Sec.
Default values and
placeholders shown
Expressions
Evaluation
Close
Continuous
1 Sec.
1 Sec.
1 Sec.
IO Scan Cycle possible
inter-Engines latencies
Subscription/Activation
possible inter-Engines
latencies
OPERATOR REQUEST
NEW VALUES
BEHAVIOR FOR IOSERVER AND DASERVERS THAT DOES NOT IMPLEMENT SUBSCRIPTION MESSAGES.
Retrieve Bind
Slide 10
Render
Waiting Data…
Expression
Evaluation
Render Close
t
Call-Up Time Advanced concepts:
ActiveOnDemand DDE SuiteLink
Call-Up Time
Delta Expressions
Evaluation
Waiting Data…
Delta Expressions
Evaluation
ArchestrAGraphic
Retrieve
Bind
Render
Expressions
Evaluation
DDESL Client
1 Sec.
Default values and
placeholders shown
DAS
Expressions
Evaluation
A
C
T
1 Sec.
X
1 Sec.
Subscription/Activation
possible inter-Engines
latencies
1 Sec.
Close
Continuous
1 Sec.
1 Sec.
IO Scan Cycle possible
inter-Engines latencies
1 Sec.
1 Sec.
1 Sec.
InitialUpDate
Control Layer
OPERATOR REQUEST
NEW VALUES
BEHAVIOR FOR DASERVERS THAT DOES IMPLEMENT SUBSCRIPTION MESSAGES.
Slide 11
t
Call-Up Time Advanced concepts:
ActiveOnDemand OPC Client
Call-Up Time
Delta Expressions
Evaluation
Waiting Data…
Delta Expressions
Evaluation
ArchestrAGraphic
Retrieve
Bind
Render
X
OPC Client
A R
C E
T A
D
Default values and
placeholders shown
OPCServer
Expressions
Evaluation
1 Sec.
Expressions
Evaluation
1 Sec.
1 Sec.
Subscription/Activation
possible inter-Engines
latencies
1 Sec.
1 Sec.
Close
Continuous
1 Sec.
1 Sec.
IO Scan Cycle possible
inter-Engines latencies
1 Sec.
1 Sec.
InitialUpDate
Control Layer
OPERATOR REQUEST
Slide 12
NEW VALUES
t
Call-Up Time Advanced concepts:
ActiveAll:OPC & SL
Call-Up Time
Delta Expressions
Evaluation
Delta Expressions
Evaluation
ArchestrAGraphic
Retrieve
IO / AppServer
Bind
Render
1 Sec.
Expressions
Evaluation
1 Sec.
Delta Expressions
Evaluation
Close
Continuous
1 Sec.
1 Sec.
1 Sec.
IO Scan Cycle possible
inter-Engines latencies
Default values and
placeholders shown
OPERATOR REQUEST
Retrieve Bind
Slide 13
Render
NEW VALUES
Waiting Data…
ActiveOnDemand
Expression
Evaluation
Render Close
t
Call Up Time: Retrieval InTouch
Glass
Objects
Initialization
Bolts
Polygon6
Polygon5
View.exe
Polygon4
Polygon3
ArchestrA
Graphic
Library
Arrow
.
.
.
.
.
.
=
Deserialization
DefinitionFiles
Disk I/O
Retrieve Bind
Slide 14
Render
Waiting Data…
Expression
Evaluation
Render Close
Arc1
Call Up Time: Retrieval InTouch
Glass
• Graphic element information
Bolts
Polygon6
Polygon5
• Animations Initialization
Polygon4
Polygon3
• Scripting Interface Initialization
Arrow
=
.
.
.
.
• Communication Interface Initialization
Arc1
Retrieve Bind
Slide 15
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Retrieval InTouch
Glass
• Graphic element information
Bolts
Polygon6
Polygon5
• Animations Initialization
Polygon4
Polygon3
• Scripting Interface Initialization
Arrow
.
.
.
.
• Communication Interface Initialization
Arc1
Retrieve Bind
Slide 16
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Retrieval InTouch
Glass
• Graphic element information
Bolts
Polygon6
Polygon5
• Animations Initialization
Polygon4
Polygon3
• Scripting Interface Initialization
Arrow
=
.
.
.
.
• Communication Interface Initialization
Arc1
Retrieve Bind
Slide 17
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Retrieval InTouch
Glass
• Graphic element information
Bolts
Polygon6
Objects
Initialization
• Animations Initialization
Polygon5
Polygon4
Polygon3
• Scripting Interface Initialization
Arrow
.
.
.
.
• Communication Interface Initialization
Arc1
Retrieve Bind
Slide 18
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Retrieval InTouch
=
Line
A simple ArchestrA Graphic Element is not just a representation on the
screen, it is part and able to interact dynamically with the entire
ArchestrA framework:
• Graphic Definition
• Animations
• Scripting
• Communication
Retrieve Bind
Slide 19
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Retrieval ArchestrA
The Simplest mitigation method for addressing slow retrieval of
ArchestrA graphic shown using the new API ShowGraphic or the
ShowSymbol animation is to use the fastest disk IO available.
• SSD vs. traditional Drives
Retrieve Bind
Slide 20
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Retrieval InTouch
The Simplest mitigation method for addressing slow InTouch Windows
call up times is to “uncheck” load windows from disk (pre 2012)
• This does not change the initial draw times but all subsequent draw
times are faster.
• This method has had limitations that have been more commonly
reached when using ArchestrA graphics
– Memory limitations are reached
– When limitations are reached in WindowViewer, new opened windows can
result in lower performance.
Retrieve Bind
Slide 21
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Retrieval 2012
Slide 22
In-Memory Window Caching
InTouch 2012 Enhancements
• The total amount of memory accessible to WindowViewer has been
extended to the maximums by default.
– 2 Gb on 32 bit OS; 3 Gb on 64 bit OS
• The memory cache will remove oldest windows from the cache to
make room for new windows being opened.
– First in/First out and time based aging
• Windows that are a high priority for fast access can be designated
which will result in them being always considered recent.
• ArchestrA Graphics memory footprint has been reduced by 15%
Slide 23
Call Up Time: Data Binding
Data binding is affected first of all by the total number of references
present in your ArchestrA graphics.
• Use a clever organization of the information: 1 integer custom
property instead of 16 Boolean custom properties when designing a
symbol that will be used across all the graphics of your application
(icons, alarm states)
• Try to avoid redundant information by reusing Custom Properties for
the embedded symbols. Clever use of Private/Public
• Use of Owning Object/SetCustomProperty/ShowGraphic
Retrieve Bind
Slide 24
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Data Binding
ShowSymbol/ShowGraphic vs. InTouch
InTouch tags show the last known value immediately, while ArchestrA
communications will identify initializing data. Once the graphic has
been fully rendered, the data required by the window must be
initialized and this can result in a slow operator experience.
Retrieve Bind
Slide 25
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Data Binding
• How to improve the binding time?
– “Round robin” considerations
• GR or not GR ?
• MyContainer / myArea / myEngine Vs Static References
– For top performance uses Static References. (me.attribute is considered
static reference)
– Intouch:MemoryTags
– Redirection using OwningObject (improved reference binding algorithm)
– SetCustomPropertyValue (script execution time reduced by 80%)
– SHOW GRAPHIC IMPROVEMENTS “INTRO”
Retrieve Bind
Slide 26
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Hitting GR Node
From the OPC DI manual:
The item syntax for array elements is
<sg>.Attribute(<item>)[<index>]
DI objects are special Objects with Dynamic arrays and properties.
The Attribute() keyword is used to identify which references are IO
properties of the DI objects from internal dynamic properties.
ALWAYS use the Attribute keyword in your references.
L00119964 : Doc Enhancement request
L00118912 : Investigation
Retrieve Bind
Slide 27
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Hitting GR Node
Possible Scenarios:
•
Turning off many PLCS will cause a lot of references to go bad and
will hit the GR node causing poor performance to the GR node.
•
DI Objects undeploy
•
Massive use of relative references
The importance of monitor binding counts:
Logger: wwpackageserver ReferenceBinding
ObjectViewer: GRNodePlatform.GR.BindCnt
Retrieve Bind
Slide 28
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Hitting GR Node
Example of an
OPC DI object
Undeploy and
Deploy
Retrieve Bind
Slide 29
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Data Binding
• How to improve the binding time?
– Redirection using OwningObject property (improved reference binding
algorithm)
– Redirection using SetCustomPropertyValue function (script execution time
reduced by 80%)
– Redirection using Show Graphic
Retrieve Bind
Slide 30
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Data Binding
The new “ShowGraphic” function extends the flexibility of the product
and improves the concept of OwningObject and Dynamic
References: everything is now embedded parameter of the main
function and natively resolved.
Retrieve Bind
Slide 31
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: ShowGraphic
Dim graphicInfo as aaGraphic.GraphicInfo;
Dim cpValues [2] as aaGraphic.CustomPropertyValuePair;
cpValues[1] = new aaGraphic.CustomPropertyValuePair("CP1", 20, true);
cpValues[2] = new aaGraphic.CustomPropertyValuePair("CP2", "Pump.PV.TagName", false);
graphicInfo.Identity = "i1";
graphicInfo.GraphicName = "S1";
graphicInfo.OwningObject = "UserDefined_001";
graphicInfo.WindowTitle = "ShowGraphic";
graphicInfo.Resizable = false;
graphicInfo.CustomProperties=cpValues;
ShowGraphic( graphicInfo );
Retrieve Bind
Slide 32
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Rendering
The rendering time is impacted by the high number of primitive
invokes: each single line, circle, textbox we are drawing has a cost.
• Extremely high definition of small details can impact the rendering
performance
• Reusing multiple times an extremely hi detailed small icon symbol
can reduce the rendering performance of the entire application
• Gradients, transparencies, graphical effects that need runtime
calculation can impact rendering performance (CPU vs. GPU: GDI+
vs. GDI)
Retrieve Bind
Slide 33
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Rendering
The Urban Legend
Is it more efficient to include 1000
ArchestrA Graphics in one InTouch window,
or to have 1 ArchestrA Graphic containing
1000 embedded ArchestrA graphics?
• 1 ArchestrA Graphic with 1000 graphics:
as mentioned before, each invoke has a
cost. 1000 InTouch calls to the ArchestrA
graphic library vs.. only 1.
• 2 You are ready for the future! ArchestrA
Graphics are ready to evolve taking
advantage of the next evolutions of the
.NET framework.
Retrieve Bind
Slide 34
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Rendering Gradients
The definition of gradients are the colors and the type of gradients.
• All of the individual colors are calculated at runtime when initially
rendered and any time an animation changes the gradient.
– When large numbers of graphic elements (1000’s) using gradients are used
the impact can be severe.
• This information consumes more memory than a solid fill.
• Be careful of a larger number of small graphic elements using
gradients. The effect may be minimal visually but severe in terms of
performance.
• Transparencies have a similar performance impact.
Retrieve Bind
Slide 35
Render
Waiting Data…
Expression
Evaluation
Render Close
Call Up Time: Rendering Gradients
Same Embedded Symbol (just
resized)
• Same Detail
• Same Calculations
• Same Cost
• Different Visual Value
• A simple PNG image, is this case
perform much better.
Retrieve Bind
Slide 36
Render
Waiting Data…
Expression
Evaluation
Render Close
Symbol Embedding Pitfall Example
Status Symbol is created.
This will be used on every
piece of equipment.
There may be hundreds on
the window.
It is made of many large
detailed elements.
Slide 37
Static CPU Utilization
Once a window has been rendered on the screen there are factors that
can result in a greater CPU utilization.
When this occurs there can be other impacts:
• System becomes unresponsive
• Fewer Terminal Server Sessions can be run on the server as other
sessions become unresponsive.
• There are many contributing factors
Retrieve Bind
Slide 38
Render
Waiting Data…
Expression
Evaluation
Render Close
Bitmaps
ArchestrA Graphics support multiple formats (BMP, GIF, JPG, TIF, PNG,
ICO, EMF). Bitmaps are the most expensive but also most common.
Format
Typical Compression
Ratios
Description
GIF
4:1 - 10:1
Lossless for images <=256 colors. Works best for flat color, sharpedged art. Horizontally oriented bands of color compress better than
vertically oriented bands.
JPEG (High)
10:1 - 20:1
High quality - has little or no loss in image quality with continuous
tone originals. Worse results for flat color and sharp-edge art.
JPEG
(Medium)
30:1 - 50:1
Moderate quality - usually the best choice for the Web.
JPEG (Low)
60:1 - 100:1
Poor quality - suitable for thumbnails and previews. Visible blockiness
(pixelation).
PNG
10-30% smaller than GIFs
PNG's behave similarly to GIFs only better; they work best with flatcolor, sharp-edged art. PNGs compress both horizontally and
vertically, so solid blocks of color generally compress best.
Retrieve Bind
Slide 39
Render
Waiting Data…
Expression
Evaluation
Render Close
Bitmap Common Pitfalls
• Embed a large picture and resize to
a small one
• Both take the same size on disk
• Retake image at smaller size and
save as compressed format
10 Mbytes picture
Retrieve Bind
Slide 40
Render
Waiting Data…
Expression
Evaluation
Render Close
Custom Property Density
Custom Properties have been greatly optimized in InTouch 2012 which
has resulted in better performance.
Some customers have ended up with 20,000 plus custom properties on
a symbol.
Typically an impact of embedding many symbols at many levels.
Should consider necessity of the variables and consider if they should
reside server side.
• Is it needed for graphic presentation?
• Is the value specific to only this workstation?
Retrieve Bind
Slide 41
Render
Waiting Data…
Expression
Evaluation
Render Close
Multi-Variable Expressions
Each variable must be subscribed, bound and published individually.
• Can the calculation be done server side?
• Is the value specific to this specific workstation?
Expressions are ad-hoc scripts and require execution.
• The AppEngine is better suited to executing volumes of scripts and
should be used to handle load where possible.
Slide 42
Expressions: code efficiency
Avoid high number of Expressions with string operations like:
•
Concatenations “+”
•
String find
•
String replace
If you cannot avoid, use the .NET system.string class functions.
ArchestrA strings functions are designed for automation and are
general purpose, the built in functions are not Top Performance
functions.
System.String.Concat
System.String.Contains
System.String.IndexOf
Retrieve Bind
Slide 43
Render
Waiting Data…
Expression
Evaluation
Render Close
Script Utilization
ArchestrA Graphics are extremely flexible in their ability to execute
scripts (On Show, While Showing, On Close, Data Change,
Condition). Carefully plan the usage of scripts that will cyclically
execute.
• If you are setting a script to run every 50ms, why?
• Is every execution needed? Is the same result calculated over and
over?
• How many scripts are in the symbol?
• How many instances of the symbol will be used?
• Can the script be server side?
Retrieve Bind
Slide 44
Render
Waiting Data…
Expression
Evaluation
Render Close
Symbol Embedding
The implications of embedding symbols are often not considered.
• When embedding several layers of symbols, remember that the final
symbol will have every custom property, script, and graphic element
from all of the individual symbols.
• Layering/stacking and then resizing symbols is very easy to do but
comes at a cost.
• Are there details on the symbols that are not visible at the size it is
embedded?
Retrieve Bind
Slide 45
Render
Waiting Data…
Expression
Evaluation
Render Close
Symbol Embedding
Symbol 1
Symbol 2
Symbol 3
Name,X,Y,Width,Height,angle,
absoluteorigin,transparency,loc
ked,dynamicsizechange,ancho
rpoint
Name,X,Y,Width,Height,angle,
absoluteorigin,transparency,loc
ked,dynamicsizechange,ancho
rpoint
Name,X,Y,Width,Height,angle,
absoluteorigin,transparency,loc
ked,dynamicsizechange,ancho
rpoint
Symbol
2
Symbol3
Name,X,Y,Width,Height,an
gle,absoluteorigin,transpar
ency,locked,dynamicsizech
ange,anchorpoint
Nameicsizechan
ge,anchorpoint
Sym
Nameicsiz
bol3
echange,a
Graphic Element
nchorpoint
Graphic Element
Graphic Element
Retrieve Bind
Slide 46
Render
Waiting Data…
Expression
Evaluation
Render Close
Symbol Embedding
Symbol 1
Symbol 2
Symbol 3
Name,X,Y,Width,Height,angle,
absoluteorigin,transparency,loc
ked,dynamicsizechange,ancho
rpoint
Name,X,Y,Width,Height,angle,
absoluteorigin,transparency,loc
ked,dynamicsizechange,ancho
rpoint
Name,X,Y,Width,Height,angle,
absoluteorigin,transparency,loc
ked,dynamicsizechange,ancho
rpoint
Symbol
2
Symbol3
Name,X,Y,Width,Height,an
gle,absoluteorigin,transpar
ency,locked,dynamicsizech
ange,anchorpoint
Nameicsizechan
ge,anchorpoint
Sym
Nameicsiz
bol3
echange,a
Graphic Element
nchorpoint
Graphic Element
Graphic Element
Definition of the Symbol cost 430 bytes
Retrieve Bind
Slide 47
Render
Waiting Data…
Expression
Evaluation
Render Close
Symbol Embedding
430 BYTES !!!
Common reaction
in the
3rd millennium.
Retrieve Bind
Slide 48
Render
Waiting Data…
Expression
Evaluation
Render Close
Symbol Embedding example
430 bytes.
Final Valve Symbol
Name,X,Y,Width,Height,angle,
absoluteorigin,transparency,loc
ked,dynamicsizechange,ancho
rpoint
####
####
Graphic Elements
Intermediate Symbols
14 Intermediate Symbols, for the base valve symbol.
Retrieve Bind
Slide 49
Render
Waiting Data…
Expression
Evaluation
Render Close
Symbol Embedding
Impact on a huge Applications
430 bytes
* 15 Embeds levels
* 200 graphics
*337 windows/popups
=
434’730’000 bytes
Alias 434 MegaBytes
Alias 0.434 GigaBytes
Retrieve Bind
Slide 50
Render
Waiting Data…
Expression
Evaluation
Render Close
Element Grouping
When using the Grouping mechanism in graphics there is an
optimization done for groups with no animation. The group is
handled as an image.
The Tank on the left
opens in half the time
with half the static CPU
load of the tank on the
right.
Top Performance
Configuration:
• 1 Base Group
Animations
• 1 Base Group Static
elements.
Retrieve Bind
Slide 51
Render
Waiting Data…
Expression
Evaluation
Render Close
Hardware Choices
What hardware choices can be made to give best results?
1. Fast CPU Clock – (WindowViewer only uses one processor/core, so a
faster dual core is preferred over a slower quad core).
2. Available RAM – Have 3Gb available for each WindowViewer session
3. Fast Hard Drive – Solid State
4. FAST GPU
Retrieve Bind
Slide 52
Render
Waiting Data…
Expression
Evaluation
Render Close
Do Graphics Have to be Simple to
Perform?
Call up time is under 1 sec
and static CPU load is
~1%.
DO SIMPLE GRAPHICS
ALWAYS PERFORM ?
Slide 53
Development Performance
Considerations
Performance impact on IDE using ArchestrA Graphics:
CustomProperty1/ Reference1
.
.
.
$Template1.Graphic1
Slide 54
CustomPropertyN/ ReferenceN
Development Performance
Considerations
Performance impact on IDE using ArchestrA Graphics:
CustomProperty1/ Reference1
Instance1.Graphic1
$Template1.Graphic1
Slide 55
.
.
.
CustomPropertyN/ ReferenceN
Development Performance
Considerations
Performance impact on IDE using ArchestrA Graphics:
Instance5.Graphic1
Instance4.Graphic1
Instance3.Graphic1
Instance2.Graphic1
Instance1.Graphic1
$Template1.Graphic1
Slide 56
Development Performance
Considerations
Performance impact on IDE using ArchestrA Graphics:
Instance4.Graphic1
Instance3.Graphic1
Instance2.Graphic1
THIS IS NOT A BUG !
Instance1.Graphic1
IT IS JUST A SPIDER
$Template1.Graphic1
$Template1.Graphic2
Instance1.Graphic2
Slide 57
Instance2.Graphic2
Development Performance
Considerations
• Do not define 100 graphics in the base valve template if you
are planning to have 5000 instances of the specific valve,
propagation of a small change will take hours.
• ArchestrA System Platform 2012 has a lot of improvements to address
IDE performance.
• Invensys development is still working to improve in future versions
IDE performance.
Slide 58
Development Performance
Considerations
1. Development Performance vs.. Runtime Performance
1.Never use the Development experience to evaluate the performance of your
ArchestrA Graphic application. Short overview and description on the
ArchestrA Graphics SQL storage layer and architecture.
Retrieve Bind
Slide 59
Render
Waiting Data…
Expression
Evaluation
Render Close
Bottleneck investigation
How to understand where the time is wasted; Parameters to monitor
• Measure the performance of a generic InTouch window with
ArchestrA Graphics
• Measure the performance of a specific ArchestrA Graphic
– Example using ShowGraphic and log flags
• Log Flags for InTouch vs.. ArchestrA Graphics
• External tools: Process explorer
Slide 60
Bottleneck investigation [Case Studies]
Dim graphicInfo as aaGraphic.GraphicInfo;
Dim cpValues [2] as aaGraphic.CustomPropertyValuePair;
cpValues[1] = new aaGraphic.CustomPropertyValuePair("CP1", 20, true);
cpValues[2] =
new aaGraphic.CustomPropertyValuePair("CP2", "Pump.PV.TagName", false);
graphicInfo.Identity = "i1";
graphicInfo.GraphicName = "S1";
graphicInfo.OwningObject = "UserDefined_001";
graphicInfo.WindowTitle = "ShowGraphic";
graphicInfo.Resizable = false;
graphicInfo.CustomProperties=cpValues;
LogMessage(“ShowGraphic Start:”);
ShowGraphic( graphicInfo );
LogMessage(“ShowGraphic Stop:”);
Retrieve Bind
Slide 61
Render
Waiting Data…
Expression
Evaluation
Render Close
Bottleneck investigation [Case Studies]
Slide 62
Bottleneck investigation [Case Studies]
Simple AAPKG to
exercise all or a limited
subset of the galaxy
ArchestrA Graphics and
log the loading time.
Slide 63
Bottleneck investigation [Case Studies]
How to create the list of
symbols to exercise:
SELECT visual_element_name
FROM
[dbo].[internal_visual_element_description_view]
where [hierarchical_visual_element_name]
Save the query result as a txt file with the
same name of the instance
Slide 64
Bottleneck investigation [Case Studies]
Configuration:
CreateLog: log an entry for
each graphic slower than
‘CreateLog’ ms.
ExecutionRate: delay in
seconds to open and close the
graphic
FileLocation: File Path for the
Symbols list and log file.
Slide 65
Visualization Stability Enhancements in
InTouch 2012
Problems
InTouch 2012 Approach
• Windows based on A2 Graphics
• Refactored various internal
– Render slow compared to native
InTouch
– Consume more memory than
comparable native InTouch
• InTouch runs on CPU-0 regardless of
the number of cores
components of A2 Graphics to
reduce memory footprint in runtime
(Removed design time data from
runtime environment)
• Refactored Custom Property code
and SetCustomPropertyValue
function for improved data binding
performance
• Support binding to any core in the
computer (still runs in a single core)
Slide 66
References
Tech Note 628
Advanced Communication Management for Application Server
Tech Note 644
Improving Application Performance with ArchestrA Graphics
Slide 67
Contributors
Slide 68
•
Marilou Aguinaldo, Invensys Senior Technical Support Engineer
•
John Krajewski, Invensys Director, Product Management, HMI/SCADA
•
Ryan Van Slooten, Invensys ArchestrA Application Specialist
•
Ken Cook, Invensys ArchestrA Applications Consultant
•
Bruce Schultz, Invensys Principal Software Development Engineer
•
TopoGigia
Questions?
THANK YOU
Slide 69