You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flex.apache.org by "Maurice Amsellem (JIRA)" <ji...@apache.org> on 2013/11/02 21:59:17 UTC

[jira] [Comment Edited] (FLEX-33865) ConstraintLayout / LayoutElementHelper are memory inefficient (and slow)

    [ https://issues.apache.org/jira/browse/FLEX-33865?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13812165#comment-13812165 ] 

Maurice Amsellem edited comment on FLEX-33865 at 11/2/13 8:57 PM:
------------------------------------------------------------------

Hi Benoit,

the first optimization (_constraintColumns instead of constraintColumns) is fine. It avoids an uncessary slice().

I have a few questions regarding the second optimization ( passing an Array to avoid creation of an Array):
1)  you say the method is slow.  Is it faster with your optimization? Can you provider before/after timing
2) There are other places where the method is called without the second parameter (eg. parseConstraintValue above).  In this case, the second unused argument and the addtional tests may actually *slow down* the call.
3) there are three cases in the parseConstraintExp method: Number, null, and constraint string.  Which one are you using ?
4) Can you provide a test application that shows where your optimization is effective




was (Author: mamsellem):
Hi Benoit,

the first optimization (_constraintColumns instead of constraintColumns) is fine. It avoids an uncessary slice().

I have a few questions regarding the second optimization ( passing an Array to avoid creation of an Array):
1)  you say the method is slow.  Is it faster with your optimization? Can you provider before/after timing
2) There are other places where the method is called without the second parameter (eg. parseConstraintValue above).  In this case, the second unused argument and the addtional tests may actually *slow down* the call.
3) Can you provide a test application that shows where your optimization is effective



> ConstraintLayout / LayoutElementHelper are memory inefficient (and slow)
> ------------------------------------------------------------------------
>
>                 Key: FLEX-33865
>                 URL: https://issues.apache.org/jira/browse/FLEX-33865
>             Project: Apache Flex
>          Issue Type: Improvement
>          Components: Mobile: Performance, Spark: Layout
>    Affects Versions: Apache Flex 4.11.0
>         Environment: mobile desktop
>            Reporter: Benoit Wiart
>            Assignee: Maurice Amsellem
>              Labels: mobile, performance
>         Attachments: 0001-ConstraintLayout-optimizations.patch, layout-1-desktop-memory.png, layout-2-desktop-memory.png
>
>
> ConstraintLayout / LayoutElementHelper are doing too many memory allocation.
> it's really bad on mobile
> the attached screenshots were taken on desktop



--
This message was sent by Atlassian JIRA
(v6.1#6144)