On Wed, 28 Sep 2011 14:31:12 +0900 Daniel Juyung Seo <seojuyu...@gmail.com>
said:

aaaah the stuff that happens while you're away. sorry guys - i don't like this.
spinning int he ilder EVEN if you limit it to 0.7* frametime.. is bad. idlers
spin already. they just spin OUTSIDE the idler callback. (i.e. they keep
calling the callback in a loop while the app is idle). sp please - don't do
this kind of thing in idlers if you can avoid it (eg if the cost of going in
and out of the idler is high, then sure, do some spins inside, but in this
case, it isn't)...

/me fixes and makes test cases

> In SVN!
> Thanks.
> 
> Daniel Juyung Seo (SeoZ)
> 
> On Tue, Sep 27, 2011 at 4:47 PM, Kim Yunhan <spb...@gmail.com> wrote:
> > Thanks a lot!
> >
> > On Tue, Sep 27, 2011 at 4:29 PM, Cedric BAIL <cedric.b...@free.fr> wrote:
> >
> >> On Tue, Sep 27, 2011 at 8:56 AM, Daniel Juyung Seo <seojuyu...@gmail.com>
> >> wrote:
> >> > No more comments on this patch?
> >>
> >> It's good could get in today.
> >>
> >> > If so, I'll commit this in a day.
> >>
> >> I was lacking network access. Now I am back, I can commit and break
> >> stuff again ! Yeah !
> >>
> >
> > lol ;-)
> >
> >
> >>
> >> > On Thu, Sep 22, 2011 at 10:22 PM, Kim Yunhan <spb...@gmail.com> wrote:
> >> >> Of course, the multiplication won't matter at all. :)
> >> >> I couldn't predict how much time will be taken in ecore main loop.
> >> >> There exists similar code in Ecore_Con_Url and if download is stared, it
> >> >> will be called many times.
> >> >> So I guess that it could be affected with download performance. (though
> >> it
> >> >> will be a little)
> >> >> That was my concern.
> >> >> But I thought it again and UI interaction is more important than
> >> download
> >> >> performance.
> >> >> Therefore I'll send a patch again you suggested.
> >> >>
> >> >> Thank you.
> >> >>
> >> >> Index: ecore/src/lib/ecore_con/ecore_con_url.c
> >> >> ===================================================================
> >> >> --- ecore/src/lib/ecore_con/ecore_con_url.c (revision 63527)
> >> >> +++ ecore/src/lib/ecore_con/ecore_con_url.c (working copy)
> >> >> @@ -1357,15 +1357,21 @@
> >> >>    int fd_max, fd;
> >> >>    int flags, still_running;
> >> >>    int completed_immediately = 0;
> >> >> +   double start;
> >> >>    CURLMcode ret;
> >> >>
> >> >>    _url_con_list = eina_list_append(_url_con_list, url_con);
> >> >>
> >> >>    url_con->active = EINA_TRUE;
> >> >>    curl_multi_add_handle(_curlm, url_con->curl_easy);
> >> >> -   /* This one can't be stopped, or the download never start. */
> >> >> -   while (curl_multi_perform(_curlm, &still_running) ==
> >> >> CURLM_CALL_MULTI_PERFORM) ;
> >> >>
> >> >> +   start = ecore_time_get();
> >> >> +   while (curl_multi_perform(_curlm, &still_running) ==
> >> >> CURLM_CALL_MULTI_PERFORM)
> >> >> +     if ((ecore_time_get() - start) > (0.7 *
> >> >> ecore_animator_frametime_get()))
> >> >> +       {
> >> >> +          break;
> >> >> +       }
> >> >> +
> >> >>    completed_immediately =
> >> _ecore_con_url_process_completed_jobs(url_con);
> >> >>
> >> >>    if (!completed_immediately)
> >> >> @@ -1456,7 +1462,7 @@
> >> >>    start = ecore_time_get();
> >> >>    while (curl_multi_perform(_curlm, &still_running) ==
> >> >> CURLM_CALL_MULTI_PERFORM)
> >> >>      /* make this not more than a frametime to keep interactivity high
> >> */
> >> >> -     if ((ecore_time_get() - start) > ecore_animator_frametime_get())
> >> >> +     if ((ecore_time_get() - start) > (0.7 *
> >> >> ecore_animator_frametime_get()))
> >> >>        {
> >> >>           done = 0;
> >> >>           break;
> >> >>
> >> >>
> >> >> On Thu, Sep 22, 2011 at 9:33 PM, Gustavo Sverzut Barbieri <
> >> >> barbi...@profusion.mobi> wrote:
> >> >>
> >> >>> What will change? The multiplication won't matter and you can move it
> >> >>> outside of the loop. If there is nothing else to be done in the
> >> mainloop it
> >> >>> will do few function calls and get back to work.
> >> >>>
> >> >>> If you allow the full frametime to be used, whenever the user will try
> >> to
> >> >>> do
> >> >>> work the frametime will be gone and skips will happen, even under low
> >> load!
> >> >>>
> >> >>> If someone is considering download speed I strongly recommend doing
> >> >>> splice()
> >> >>> to avoid it coming from kernel to userspace then back to kernel
> >> >>>
> >> >>> Things like servers using ecore don't need frametime at all, thus they
> >> can
> >> >>> make it a few seconds or minutes :-)
> >> >>>
> >> >>> On Thursday, September 22, 2011, Kim Yunhan <spb...@gmail.com> wrote:
> >> >>> > It sounds good. But I'm wonder download performance will be impaired.
> >> >>> :'-(
> >> >>> > It should be tested much more.
> >> >>> >
> >> >>> > On Thu, Sep 22, 2011 at 8:13 PM, Gustavo Sverzut Barbieri <
> >> >>> > barbi...@profusion.mobi> wrote:
> >> >>> >
> >> >>> >> Better to use a percentual if frametime otherwise user will try to
> >> do
> >> >>> some
> >> >>> >> work and it will not have enough time. Something like 0.7 *
> >> >>> >> ecore_animator_frametime_get()
> >> >>> >>
> >> >>> >> On Thursday, September 22, 2011, Cedric BAIL <cedric.b...@free.fr>
> >> >>> wrote:
> >> >>> >> > On Thu, Sep 22, 2011 at 12:51 AM, Kim Yunhan <spb...@gmail.com>
> >> >>> wrote:
> >> >>> >> >> Thank you!
> >> >>> >> >> Ecore_Con_Url already have the solution with
> >> >>> >> _ecore_con_url_idler_handler.
> >> >>> >> >> So I just break the while loop if it takes too long.
> >> >>> >> >>
> >> >>> >> >>
> >> ==================================================================
> >> >>> >> >> --- src/lib/ecore_con/ecore_con_url.c (revision 63520)
> >> >>> >> >> +++ src/lib/ecore_con/ecore_con_url.c (working copy)
> >> >>> >> >> @@ -1357,15 +1357,21 @@
> >> >>> >> >>    int fd_max, fd;
> >> >>> >> >>    int flags, still_running;
> >> >>> >> >>    int completed_immediately = 0;
> >> >>> >> >> +   double start;
> >> >>> >> >>    CURLMcode ret;
> >> >>> >> >>
> >> >>> >> >>    _url_con_list = eina_list_append(_url_con_list, url_con);
> >> >>> >> >>
> >> >>> >> >>    url_con->active = EINA_TRUE;
> >> >>> >> >>    curl_multi_add_handle(_curlm, url_con->curl_easy);
> >> >>> >> >> -   /* This one can't be stopped, or the download never start. */
> >> >>> >> >> -   while (curl_multi_perform(_curlm, &still_running) ==
> >> >>> >> >> CURLM_CALL_MULTI_PERFORM) ;
> >> >>> >> >>
> >> >>> >> >> +   start = ecore_time_get();
> >> >>> >> >> +   while (curl_multi_perform(_curlm, &still_running) ==
> >> >>> >> >> CURLM_CALL_MULTI_PERFORM)
> >> >>> >> >> +     if ((ecore_time_get() - start) >
> >> >>> ecore_animator_frametime_get())
> >> >>> >> >> +       {
> >> >>> >> >> +          break;
> >> >>> >> >> +       }
> >> >>> >> >> +
> >> >>> >> >>    completed_immediately =
> >> >>> >> _ecore_con_url_process_completed_jobs(url_con);
> >> >>> >> >>
> >> >>> >> >>    if (!completed_immediately)
> >> >>> >> >>
> >> >>> >> >>
> >> >>> >> >> It works well for me.
> >> >>> >> >> How about this code?
> >> >>> >> >> Please review again.
> >> >>> >> >
> >> >>> >> > Sounds good to me. If nobody apply, I will in a few hours.
> >> >>> >> >
> >> >>> >> > Thanks,
> >> >>> >> >
> >> >>> >> >> Thank you once again.
> >> >>> >> >>
> >> >>> >> >> On Thu, Sep 22, 2011 at 4:46 AM, Cedric BAIL <
> >> cedric.b...@free.fr>
> >> >>> >> wrote:
> >> >>> >> >>
> >> >>> >> >>> On Wed, Sep 21, 2011 at 6:18 PM, Kim Yunhan <spb...@gmail.com>
> >> >>> wrote:
> >> >>> >> >>> > Thank you for your advice.
> >> >>> >> >>> >
> >> >>> >> >>> > libcurl already supports asynchronous DNS lookup (including
> >> >>> c-ares).
> >> >>> >> >>> > Ecore_Con_Url is integrated with libcurl.
> >> >>> >> >>> > But I think that code in below blocks asynchronous mechanism
> >> of
> >> >>> >> libcurl.
> >> >>> >> >>> > while (curl_multi_perform(_curlm, &still_running)
> >> >>> >> >>> > == CURLM_CALL_MULTI_PERFORM) ;
> >> >>> >> >>> >
> >> >>> >> >>> > I want to fix it simple. :)
> >> >>> >> >>>
> >> >>> >> >>> Agreed, I didn't look to that code since months or years, but
> >> why do
> >> >>> >> >>> we have a 'while' here ? shouldn't we just go back to the main
> >> loop
> >> >>> >> >>> and be magically called again ? did you try that solution ? if
> >> that
> >> >>> >> >>> work, it would be a much better fix in my opinion.
> >> >>> >> >>>
> >> >>> >> >>> > On Thu, Sep 22, 2011 at 12:48 AM, Nicolas Aguirre <
> >> >>> >> >>> aguirre.nico...@gmail.com
> >> >>> >> >>> >> wrote:
> >> >>> >> >>> >
> >> >>> >> >>> >> 2011/9/21 Kim Yunhan <spb...@gmail.com>:
> >> >>> >> >>> >> > Hello!
> >> >>> >> >>> >> >
> >> >>> >> >>> >> > elm_map uses Ecore Con with CURL.
> >> >>> >> >
> >> >>>
> >> >>>
> >> ------------------------------------------------------------------------------
> >> >>> >> All the data continuously generated in your IT infrastructure
> >> contains a
> >> >>> >> definitive record of customers, application performance, security
> >> >>> >> threats, fraudulent activity and more. Splunk takes this data and
> >> makes
> >> >>> >> sense of it. Business sense. IT sense. Common sense.
> >> >>> >> http://p.sf.net/sfu/splunk-d2dcopy1
> >> >>> >> _______________________________________________
> >> >>> >> enlightenment-devel mailing list
> >> >>> >> enlightenment-devel@lists.sourceforge.net
> >> >>> >> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> >> >>> >>
> >> >>> >
> >> >>>
> >> >>>
> >> ------------------------------------------------------------------------------
> >> >>> > All the data continuously generated in your IT infrastructure
> >> contains a
> >> >>> > definitive record of customers, application performance, security
> >> >>> > threats, fraudulent activity and more. Splunk takes this data and
> >> makes
> >> >>> > sense of it. Business sense. IT sense. Common sense.
> >> >>> > http://p.sf.net/sfu/splunk-d2dcopy1
> >> >>> > _______________________________________________
> >> >>> > enlightenment-devel mailing list
> >> >>> > enlightenment-devel@lists.sourceforge.net
> >> >>> > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> >> >>> >
> >> >>>
> >> >>> --
> >> >>> Gustavo Sverzut Barbieri
> >> >>> http://profusion.mobi embedded systems
> >> >>> --------------------------------------
> >> >>> MSN: barbi...@gmail.com
> >> >>> Skype: gsbarbieri
> >> >>> Mobile: +55 (19) 9225-2202
> >> >>>
> >> >>>
> >> ------------------------------------------------------------------------------
> >> >>> All the data continuously generated in your IT infrastructure contains
> >> a
> >> >>> definitive record of customers, application performance, security
> >> >>> threats, fraudulent activity and more. Splunk takes this data and makes
> >> >>> sense of it. Business sense. IT sense. Common sense.
> >> >>> http://p.sf.net/sfu/splunk-d2dcopy1
> >> >>> _______________________________________________
> >> >>> enlightenment-devel mailing list
> >> >>> enlightenment-devel@lists.sourceforge.net
> >> >>> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> >> >>>
> >> >>
> >> >>
> >> ------------------------------------------------------------------------------
> >> >> All the data continuously generated in your IT infrastructure contains a
> >> >> definitive record of customers, application performance, security
> >> >> threats, fraudulent activity and more. Splunk takes this data and makes
> >> >> sense of it. Business sense. IT sense. Common sense.
> >> >> http://p.sf.net/sfu/splunk-d2dcopy1
> >> >> _______________________________________________
> >> >> enlightenment-devel mailing list
> >> >> enlightenment-devel@lists.sourceforge.net
> >> >> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> >> >>
> >> >>
> >> >
> >> >
> >> ------------------------------------------------------------------------------
> >> > All the data continuously generated in your IT infrastructure contains a
> >> > definitive record of customers, application performance, security
> >> > threats, fraudulent activity and more. Splunk takes this data and makes
> >> > sense of it. Business sense. IT sense. Common sense.
> >> > http://p.sf.net/sfu/splunk-d2dcopy1
> >> > _______________________________________________
> >> > enlightenment-devel mailing list
> >> > enlightenment-devel@lists.sourceforge.net
> >> > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> >> >
> >> >
> >>
> >>
> >>
> >> --
> >> Cedric BAIL
> >>
> >>
> >> ------------------------------------------------------------------------------
> >> All the data continuously generated in your IT infrastructure contains a
> >> definitive record of customers, application performance, security
> >> threats, fraudulent activity and more. Splunk takes this data and makes
> >> sense of it. Business sense. IT sense. Common sense.
> >> http://p.sf.net/sfu/splunk-d2dcopy1
> >> _______________________________________________
> >> enlightenment-devel mailing list
> >> enlightenment-devel@lists.sourceforge.net
> >> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> >>
> > ------------------------------------------------------------------------------
> > All the data continuously generated in your IT infrastructure contains a
> > definitive record of customers, application performance, security
> > threats, fraudulent activity and more. Splunk takes this data and makes
> > sense of it. Business sense. IT sense. Common sense.
> > http://p.sf.net/sfu/splunk-d2dcopy1
> > _______________________________________________
> > enlightenment-devel mailing list
> > enlightenment-devel@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> >
> 
> ------------------------------------------------------------------------------
> All the data continuously generated in your IT infrastructure contains a
> definitive record of customers, application performance, security
> threats, fraudulent activity and more. Splunk takes this data and makes
> sense of it. Business sense. IT sense. Common sense.
> http://p.sf.net/sfu/splunk-d2dcopy1
> _______________________________________________
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> 


-- 
------------- Codito, ergo sum - "I code, therefore I am" --------------
The Rasterman (Carsten Haitzler)    ras...@rasterman.com


------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure contains a
definitive record of customers, application performance, security
threats, fraudulent activity and more. Splunk takes this data and makes
sense of it. Business sense. IT sense. Common sense.
http://p.sf.net/sfu/splunk-d2dcopy1
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to