Performance issue

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Performance issue

cbeler
Hi all :)

Recently, I saw a mail from Avi saying that the widestring conversion
lead to performace problem.

I'm using 3.9g and I feel request takes too much time.
For instance, a single refresh (local server) takes 5 seconds and the
processor is having at leat 50% usage.
I have a pentium 3Ghz and linux. VM is 3.7-7. I also use WAEncodedKom39
but changing to WAKom doesn't really change the performance hit.

Actually, I don't know if it's a problem in my image or a more general
problem due to widestring for instance. So if you have any suggestions,
advices, please let me know...

Thanks

Cédrick
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Performance issue

Philippe Marschall
2006/8/31, Cédrick Béler <[hidden email]>:

> Hi all :)
>
> Recently, I saw a mail from Avi saying that the widestring conversion
> lead to performace problem.
>
> I'm using 3.9g and I feel request takes too much time.
> For instance, a single refresh (local server) takes 5 seconds and the
> processor is having at leat 50% usage.
> I have a pentium 3Ghz and linux. VM is 3.7-7. I also use WAEncodedKom39
> but changing to WAKom doesn't really change the performance hit.
>
> Actually, I don't know if it's a problem in my image or a more general
> problem due to widestring for instance. So if you have any suggestions,
> advices, please let me know...

Profile it so you know where the bottlneck is.

And WAKom works on 3.9 only for ASCII characters. I someone inputs a
non-ascii character you get an exception.

Philippe
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Performance issue

cbeler

>
> Profile it so you know where the bottlneck is.
ok...  so directly from seaside ?

do we have to add all times

91.5% {45ms} SUPSession(WASession)>>incomingRequest:
  |91.5% {45ms} SUPSession(WASession)>>responseForRequest:
  |  91.5% {45ms} SUPSession(WASession)>>performRequest:
  |    91.5% {45ms} SUPSession(WASession)>>start:
  |      91.5% {45ms} WARenderLoopMain>>start:
  |        91.5% {45ms} WARenderLoop>>run
  |          91.5% {45ms} WARender>>go

-> 45 + 45 +45 + ...?

47 tallies, 49 msec.

but it's more 4900msec for me ;)

I joined the result I add, if you can have a look and tell me important
points because it doesn't really mean somrthing to me...

Thanks

Cédrick


47 tallies, 49 msec.

**Tree**
91.5% {45ms} SUPSession(WASession)>>incomingRequest:
  |91.5% {45ms} SUPSession(WASession)>>responseForRequest:
  |  91.5% {45ms} SUPSession(WASession)>>performRequest:
  |    91.5% {45ms} SUPSession(WASession)>>start:
  |      91.5% {45ms} WARenderLoopMain>>start:
  |        91.5% {45ms} WARenderLoop>>run
  |          91.5% {45ms} WARender>>go
  |            91.5% {45ms} WARender>>render
  |              91.5% {45ms} WARender>>buildResponse
  |                91.5% {45ms} WADelegation(WAPresenter)>>renderWithContext:
  |                  91.5% {45ms} WADelegation(WAPresenter)>>renderContentOn:
  |                    91.5% {45ms} WAWindowDecoration(WAPresenter)>>renderWithContext:
  |                      91.5% {45ms} WAWindowDecoration>>renderContentOn:
  |                        91.5% {45ms} WAWindowDecoration(WADecoration)>>renderOwnerOn:
  |                          91.5% {45ms} WAAnswerHandler(WAPresenter)>>renderWithContext:
  |                            91.5% {45ms} WAAnswerHandler(WAPresenter)>>renderContentOn:
  |                              91.5% {45ms} WADelegation(WAPresenter)>>renderWithContext:
  |                                91.5% {45ms} WADelegation(WAPresenter)>>renderContentOn:
  |                                  91.5% {45ms} WAAnswerHandler(WAPresenter)>>renderWithContext:
  |                                    91.5% {45ms} WAAnswerHandler(WAPresenter)>>renderContentOn:
  |                                      91.5% {45ms} WAProfiler(WAPresenter)>>renderWithContext:
  |                                        91.5% {45ms} WAProfiler>>renderContentOn:
  |                                          91.5% {45ms} WAHtmlRenderer(WAAbstractHtmlBuilder)>>render:
  |                                            91.5% {45ms} SUPMain(WAComponent)>>renderOn:
  |                                              91.5% {45ms} SUPMain(WAPresenter)>>renderWithContext:
  |                                                91.5% {45ms} SUPMain>>renderContentOn:
  |                                                  76.6% {38ms} WARenderCanvas>>render:
  |                                                    |76.6% {38ms} SUPExperienceEditorTask2(WAComponent)>>renderOn:
  |                                                    |  76.6% {38ms} WADelegation(WAPresenter)>>renderWithContext:
  |                                                    |    76.6% {38ms} WADelegation(WAPresenter)>>renderContentOn:
  |                                                    |      76.6% {38ms} WAAnswerHandler(WAPresenter)>>renderWithContext:
  |                                                    |        76.6% {38ms} WAAnswerHandler(WAPresenter)>>renderContentOn:
  |                                                    |          76.6% {38ms} WAMessageDecoration(WAPresenter)>>renderWithContext:
  |                                                    |            76.6% {38ms} WAMessageDecoration>>renderContentOn:
  |                                                    |              76.6% {38ms} WAMessageDecoration(WADecoration)>>renderOwnerOn:
  |                                                    |                76.6% {38ms} SUPEventEditor(WAPresenter)>>renderWithContext:
  |                                                    |                  76.6% {38ms} SUPEventEditor(EFFormComponent)>>renderContentOn:
  |                                                    |                    76.6% {38ms} SUPEventEditor(EFFormComponent)>>renderDialogOn:
  |                                                    |                      76.6% {38ms} SUPEventEditor(EFFormComponent)>>renderRowForSelector:on:
[66.0% {32ms} SUPEventEditor(EFFormComponent)>>renderFieldForSelector:on:
[  |25.5% {12ms} SUPEventEditor>>renderEventOn:
[  |  |25.5% {12ms} WARenderCanvas>>render:
[  |  |  25.5% {12ms} SUPEventChooser2(WAComponent)>>renderOn:
[  |  |    25.5% {12ms} SUPEventChooser2(WAPresenter)>>renderWithContext:
[  |  |      12.8% {6ms} WARenderingContext>>callbacksFor:
[  |  |        |12.8% {6ms} WACallbackRegistry class>>context:owner:
[  |  |        |  12.8% {6ms} WACallbackRegistry>>initializeWithContext:owner:
[  |  |      12.8% {6ms} SUPEventChooser2>>renderContentOn:
[  |  |        12.8% {6ms} SUPEventChooser2>>renderMainOn:
[  |  |          12.8% {6ms} WADivTag(WATagBrush)>>with:
[  |  |            12.8% {6ms} WADivTag(WABrush)>>with:
[  |  |              12.8% {6ms} WARenderCanvas(WACanvas)>>nest:
[  |  |                12.8% {6ms} WARenderCanvas(WACanvas)>>flush
[  |  |                  12.8% {6ms} WASelectTag(WABrush)>>close
[  |  |                    12.8% {6ms} WASelectTag>>with:
[  |  |                      12.8% {6ms} WASelectTag>>optionsOn:
[  |  |                        12.8% {6ms} WAOptionTag(WATagBrush)>>with:
[  |  |                          12.8% {6ms} WAOptionTag(WATagBrush)>>openTag
[  |  |                            12.8% {6ms} WAHtmlStreamDocument>>openTag:attributes:
[  |  |                              12.8% {6ms} WAHtmlStreamDocument>>writeOpenTag:attributes:on:
[  |  |                                12.8% {6ms} WAHtmlAttributes>>writeOn:
[  |  |                                  12.8% {6ms} WAHtmlAttributes>>writeKey:value:on:
[  |  |                                    12.8% {6ms} WAAbstractHtmlBuilder class>>encode:to:
[  |  |                                      12.8% {6ms} RWBinaryOrTextStream>>nextPut:
[  |  |                                        12.8% {6ms} RWBinaryOrTextStream(WriteStream)>>nextPut:
[  |  |                                          12.8% {6ms} Character>>isOctetCharacter
[  |25.5% {12ms} SUPEventEditor>>renderTimeOn:
[  |  |25.5% {12ms} WARenderCanvas>>render:
[  |  |  25.5% {12ms} WACanvasTimeSelector(WAComponent)>>renderOn:
[  |  |    25.5% {12ms} WACanvasTimeSelector(WAPresenter)>>renderWithContext:
[  |  |      25.5% {12ms} WACanvasTimeSelector>>renderContentOn:
[  |  |        14.9% {7ms} WASelectTag(WATagBrush)>>autosubmited
[  |  |          |14.9% {7ms} WASelectTag(WATagBrush)>>id:
[  |  |          |  14.9% {7ms} WASelectTag(WATagBrush)>>attributeAt:put:
[  |  |          |    14.9% {7ms} WAHtmlAttributes>>at:put:
[  |  |          |      14.9% {7ms} Dictionary>>at:put:
[  |  |          |        14.9% {7ms} Association class>>key:value:
[  |  |          |          14.9% {7ms} Association class(LookupKey class)>>key:
[  |  |          |            14.9% {7ms} Association(LookupKey)>>key:
[  |  |        10.6% {5ms} WADivTag(WATagBrush)>>with:
[  |  |          10.6% {5ms} WADivTag(WABrush)>>with:
[  |  |            10.6% {5ms} WARenderCanvas(WACanvas)>>nest:
[  |  |              10.6% {5ms} WARenderCanvas(WACanvas)>>flush
[  |  |                10.6% {5ms} WASelectTag(WABrush)>>close
[  |  |                  10.6% {5ms} WASelectTag>>with:
[  |  |                    10.6% {5ms} WASelectTag>>optionsOn:
[  |  |                      10.6% {5ms} WAOptionTag(WATagBrush)>>with:
[  |  |                        10.6% {5ms} WAOptionTag(WATagBrush)>>within:
[  |  |                          10.6% {5ms} SmallInteger(Object)>>renderOn:
[  |  |                            10.6% {5ms} WARenderCanvas(WAHtmlCanvas)>>text:
[  |  |                              10.6% {5ms} WARenderCanvas(WAHtmlCanvas)>>html:
[  |14.9% {7ms} SUPEventEditor>>renderGravityOn:
[  |  14.9% {7ms} WADivTag(WATagBrush)>>class:
[  |    14.9% {7ms} WAHtmlAttributes>>addClass:
[  |      14.9% {7ms} WAHtmlAttributes>>at:append:
[  |        14.9% {7ms} WAHtmlAttributes>>at:append:separator:
[  |          14.9% {7ms} String class(SequenceableCollection class)>>streamContents:
[  |            14.9% {7ms} WriteStream class(PositionableStream class)>>on:
[10.6% {5ms} WAGenericTag(WATagBrush)>>with:
[  10.6% {5ms} WAGenericTag(WABrush)>>with:
[    10.6% {5ms} WARenderCanvas(WACanvas)>>nest:
[      10.6% {5ms} WARenderCanvas(WACanvas)>>flush
[        10.6% {5ms} EFLiveDateInput(WABrush)>>close
[          10.6% {5ms} EFLiveDateInput>>with:
[            10.6% {5ms} WATextInputTag(WABrush)>>close
[              10.6% {5ms} WATextInputTag(WAFormInputTag)>>with:
[                10.6% {5ms} WATextInputTag(WATagBrush)>>with:
[                  10.6% {5ms} WATextInputTag(WATagBrush)>>openTag
[                    10.6% {5ms} WAHtmlStreamDocument>>openTag:attributes:
[                      10.6% {5ms} WAHtmlStreamDocument>>writeOpenTag:attributes:on:
[                        10.6% {5ms} WAHtmlAttributes>>writeOn:
[                          10.6% {5ms} WAHtmlAttributes>>writeKey:value:on:
[                            10.6% {5ms} WAAbstractHtmlBuilder class>>encode:to:
[                              10.6% {5ms} Array(SequenceableCollection)>>at:ifAbsent:
  |                                                  14.9% {7ms} SUPMain>>renderMenuOn:
  |                                                    14.9% {7ms} WARenderCanvas(WAHtmlCanvas)>>tableData:
  |                                                      14.9% {7ms} WARenderCanvas(WAHtmlCanvas)>>tableData
  |                                                        14.9% {7ms} WARenderCanvas(WACanvas)>>brush:
8.5% {4ms} MessageTally>>spyEvery:on:
  8.5% {4ms} BlockContext>>ensure:
    8.5% {4ms} MethodContext>>tempAt:put:

**Leaves**
14.9% {7ms} WriteStream class(PositionableStream class)>>on:
14.9% {7ms} WARenderCanvas(WACanvas)>>brush:
14.9% {7ms} Association(LookupKey)>>key:
12.8% {6ms} WACallbackRegistry>>initializeWithContext:owner:
12.8% {6ms} Character>>isOctetCharacter
10.6% {5ms} WARenderCanvas(WAHtmlCanvas)>>html:
10.6% {5ms} Array(SequenceableCollection)>>at:ifAbsent:
8.5% {4ms} MethodContext>>tempAt:put:

**Memory**
        old +0 bytes
        young +73,592 bytes
        used +73,592 bytes
        free -73,592 bytes

**GCs**
        full 0 totalling 0ms (0.0% uptime)
        incr 8 totalling 4ms (8.0% uptime), avg 1.0ms
        tenures 0
        root table 0 overflows

_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Performance issue

Philippe Marschall
2006/8/31, Cédrick Béler <[hidden email]>:

>
> >
> > Profile it so you know where the bottlneck is.
> ok...  so directly from seaside ?
>
> do we have to add all times
>
> 91.5% {45ms} SUPSession(WASession)>>incomingRequest:
>   |91.5% {45ms} SUPSession(WASession)>>responseForRequest:
>   |  91.5% {45ms} SUPSession(WASession)>>performRequest:
>   |    91.5% {45ms} SUPSession(WASession)>>start:
>   |      91.5% {45ms} WARenderLoopMain>>start:
>   |        91.5% {45ms} WARenderLoop>>run
>   |          91.5% {45ms} WARender>>go
>
> -> 45 + 45 +45 + ...?
>
> 47 tallies, 49 msec.

No, that's 45 ms total rendering time!
75% or 38ms are spent in EFFormComponent>>#renderRowForSelector:on:

So rendering speed is not your problem. It's either the callbacks or
the network latency. The 3.9 Unix VM is said to have a greatly reduced
network latency. You can try it but I doubt it's that extreme.

I'd say invesitgate your callbacks.

Philippe
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Performance issue

cbeler

>
> No, that's 45 ms total rendering time!
ok ;)
> 75% or 38ms are spent in EFFormComponent>>#renderRowForSelector:on:
>
> So rendering speed is not your problem. It's either the callbacks or
> the network latency. The 3.9 Unix VM is said to have a greatly reduced
> network latency. You can try it but I doubt it's that extreme.
I'm using localhost so network shouldn't be my problem
>
> I'd say invesitgate your callbacks.
I don't really know how to investigate callbacks...

Event with WACounter I have to wait around 2 seconds to update the
display ... ?  is it normal ?



Cédrick
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Performance issue

Philippe Marschall
2006/8/31, Cédrick Béler <[hidden email]>:

>
> >
> > No, that's 45 ms total rendering time!
> ok ;)
> > 75% or 38ms are spent in EFFormComponent>>#renderRowForSelector:on:
> >
> > So rendering speed is not your problem. It's either the callbacks or
> > the network latency. The 3.9 Unix VM is said to have a greatly reduced
> > network latency. You can try it but I doubt it's that extreme.
> I'm using localhost so network shouldn't be my problem

I meant socket latency.

> >
> > I'd say invesitgate your callbacks.
> I don't really know how to investigate callbacks...
>
> Event with WACounter I have to wait around 2 seconds to update the
> display ... ?  is it normal ?

No not at all. Can you try and see if the 3.9 vm makes any difference?
If you were on windows I asked if you had some kind of personal
firewall on.

Philippe
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Performance issue

cbeler

>
> I meant socket latency.
ok :)
I think it's ok. With scriptaculous, submits and update are nearly
instantaneous

>
>> >
>> > I'd say invesitgate your callbacks.
>> I don't really know how to investigate callbacks...
>>
>> Event with WACounter I have to wait around 2 seconds to update the
>> display ... ?  is it normal ?
>
> No not at all. Can you try and see if the 3.9 vm makes any difference?
> If you were on windows I asked if you had some kind of personal
> firewall on.
>
oh maybe, I've found a reason... I had a Transcript opened, just
collapsing it improved the response time as Seaside writes a lot on it !!!

so now the counter works better (less than 1 second, I'll say half od
one) and my app too (around 2 seconds which is ok for now)...

Are there any way of improving the performance when releasing an app ?
- closing Transcript is one of them ...

Cédrick

_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside