On Mon, 14 Oct 2013 12:18:26 -0300 Gustavo Sverzut Barbieri
<barbi...@gmail.com> said:

> On Fri, Oct 11, 2013 at 10:20 PM, Carsten Haitzler <ras...@rasterman.com>
> wrote:
> > On Fri, 11 Oct 2013 11:53:40 -0300 Gustavo Sverzut Barbieri
> > <barbi...@gmail.com> said:
> >
> >> On Fri, Oct 11, 2013 at 4:50 AM, Carsten Haitzler <ras...@rasterman.com>
> >> wrote:
> >> > raster pushed a commit to branch master.
> >> >
> >> > http://git.enlightenment.org/core/efl.git/commit/?id=69e27abdc37f222183ce27f4ce0e3fe2a45ca590
> >> >
> >> > commit 69e27abdc37f222183ce27f4ce0e3fe2a45ca590
> >> > Author: Carsten Haitzler (Rasterman) <ras...@rasterman.com>
> >> > Date:   Fri Oct 11 16:49:13 2013 +0900
> >> >
> >> >     eina - and e3fl in general - stop using eina_error_get/set - useless
> >> > really
> >>
> >> while it's not the best thing to use and many places forget to set the
> >> error, knowing which error happened may be useful  -- in the same
> >> lines when you get an EINTR/EAGAIN from syscalls. By just not getting
> >> the results we want we fail to provide context on why it failed :-(
> >
> > i know. problem is that our current usage is broken anyway. i\eina has lots
> > of locks etc. to be threadsafe... but the eina_error system simply isn't
> > and pretty much cannot be, so it's already broken when you use eina from >
> > 1 thread. so i just made it "always not working". at least it's
> > consistently broken. :)
> 
> Ugh? Just make it a thread-local value, as errno.

i considered that, but:

http://gcc.gnu.org/onlinedocs/gcc-4.8.1/gcc/Thread_002dLocal.html#Thread_002dLocal

or more specifically what bothers me is "It requires significant support from
the linker (ld), dynamic linker (ld.so), and system libraries (libc.so and
libpthread.so), so it is not available everywhere."

i can see how it is majorly problematic to have thread local storage
implemented at all, as you now need pthread on create or join to magically
allocate and then deallocate all the tls vars.

btw... you need to count the number of eina_error_get()'s in efl... (as the
MOST common use for an eina error would be checking allocation failure on list
append, hash add etc.). it's basically not used. that's a core major issue with
it. while technically correct to have, it is practically useless and unused
because of the insane amount of code needed to handle such errors everywhere
and unwind etc. :( if we fail to allocate a list node entry... or a hash
entry... we're in DEEEEEEEEEEEEEEEP trouble memory-wise. we can't recover
basically. anything we do to recover invariably may aqllocate some of this
memory in the process of recovery... and repeat.

> 
> -- 
> Gustavo Sverzut Barbieri
> --------------------------------------
> Mobile: +55 (19) 9225-2202
> Contact: http://www.gustavobarbieri.com.br/contact
> 
> ------------------------------------------------------------------------------
> October Webinars: Code for Performance
> Free Intel webinars can help you accelerate application performance.
> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
> the latest Intel processors and coprocessors. See abstracts and register >
> http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk
> _______________________________________________
> 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


------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60135031&iu=/4140/ostg.clktrk
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to