flex-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Maurice Amsellem (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (FLEX-33865) ConstraintLayout / LayoutElementHelper are memory inefficient (and slow)
Date Sun, 03 Nov 2013 13:03:18 GMT

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

Maurice Amsellem commented on FLEX-33865:

Sorry, I didn't see that the patch you provided has also replaced the regexp match+replace
with a simple indexOf. 
I thought it was only recycling the Array.
So now I understand the improvement.

The problem with your optimization is that it is not stricly equivalent to the origina code:
The original code accepts and trims spaces before the colon.
Yours doesn't.
Try for example  
LayoutElementHelper.parseConstraintExp("col1 :10").

So of course, we could argue that nobody puts spaces before the colon in practice, but that's
 a change in the function design, so I cannot accept it without prior discussion with the

> 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,
> 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

View raw message