Commit Graph

142 Commits

Author SHA1 Message Date
Vincent Torri b20f37ef58 Ecore: fix seg fault in ecore_thread on Windows
PHS() was returning a wrong value. Thanks to Cedric for the help

SVN revision: 75720
2012-08-27 06:04:16 +00:00
Cedric BAIL 83872cb113 ecore: fix shutdown to use a different mutex for the list of running thread.
SVN revision: 74953
2012-08-07 03:47:14 +00:00
Mike Blumenkrantz 020bf40113 don't return value in void functions
SVN revision: 71742
2012-06-06 10:52:45 +00:00
Cedric BAIL 6d2b2f366f ecore: force pthread_join even when main loop isn't running.
pthread_create can fail if to much pthread are pending. As pthread_join
is only called when the main loop can flush the async call list, there was
a possibility for edje_cc to run out of thread due to that. We know
force the flush of the async call list and so call pthread_join when
pthread_create fail.


SVN revision: 71555
2012-05-30 12:14:34 +00:00
Cedric BAIL 3f662e32a7 ecore: fix count of objects in the Ecore_Thread trash.
SVN revision: 71550
2012-05-30 10:25:44 +00:00
Cedric BAIL a5f658a4b2 ecore: cancel all pending thread at shutdown.
Hopefully this will fix bug #961.


SVN revision: 71526
2012-05-30 03:10:30 +00:00
Carsten Haitzler 55bdb51962 ok ok - doesnt make a difference.. but only limit if MORE than 16xcpu
count



SVN revision: 71409
2012-05-24 10:13:30 +00:00
Carsten Haitzler 4bf005eede fix ecore-thread scheduler starvation issue.
SVN revision: 71404
2012-05-24 09:51:17 +00:00
Cedric BAIL 302141e873 ecore: reduce likely race condition on Ecore_Thread shutdown.
SVN revision: 71311
2012-05-22 10:13:14 +00:00
Carsten Haitzler b4757bca71 fix valgrind bitch about uniittied mem!
SVN revision: 70461
2012-04-25 09:16:43 +00:00
Carsten Haitzler 74f07c6893 try fix to refactor of ecore where thread_count went negative as it
was --'d when a no_queue thread finished too.



SVN revision: 69741
2012-03-29 11:05:59 +00:00
Carsten Haitzler f0792f360f remvoe unused func too
SVN revision: 69733
2012-03-29 09:25:48 +00:00
Carsten Haitzler edc6198ece main loop checks for all of ecore -> back. (removed by cedric last year)
SVN revision: 69727
2012-03-29 08:52:25 +00:00
Cedric BAIL ce754d6a12 ecore: fix Ecore_Thread memory leak.
SVN revision: 69343
2012-03-14 17:51:38 +00:00
Cedric BAIL 77b6473314 ecore: fix Ecore_Thread double free and update ChangeLog/NEWS.
SVN revision: 69172
2012-03-10 12:47:54 +00:00
Carsten Haitzler 531ea0831d hey cedric - i left this commented out, but this 2nd queue is wrong as
the first handles cleaning up the direct worker.



SVN revision: 69098
2012-03-09 12:49:30 +00:00
Mike Blumenkrantz 96211b171a #if 0 out an unused function
SVN revision: 68437
2012-02-25 08:30:51 +00:00
Cedric BAIL 22ed9fcfab ecore: fix ecore build without thread support and mmap.
SVN revision: 68418
2012-02-24 15:14:10 +00:00
Cedric BAIL 6ca64e9c3c ecore: cleanup thread destruction.
SVN revision: 68288
2012-02-22 21:38:39 +00:00
Cedric BAIL 6152601e1f ecore: rewrite of Ecore_Thread internal to use Eina_Lock and ecore_main_loop_thread_safe_call_async.
NOTES: It is now safer and faster. I doubt I will have more time before the release to finish
ecore_thread_message_run, nor to make the shutdown nicer.


SVN revision: 68164
2012-02-20 15:57:18 +00:00
Cedric BAIL c6894cee94 ecore: move self to the right position.
SVN revision: 67130
2012-01-12 09:06:28 +00:00
Cedric BAIL 81b3cddb13 ecore: fix Ecore_Thread.
SVN revision: 67082
2012-01-11 13:45:34 +00:00
Daniel Juyung Seo 19de4626ab ecore: applied eina_array_count_get -> eina_array_count api change.
SVN revision: 67022
2012-01-10 15:34:52 +00:00
Cedric BAIL 38567fbf32 ecore: include stdlib.h when required.
SVN revision: 65964
2011-12-06 16:09:05 +00:00
Cedric BAIL 61f1be3463 ecore: remove some warning.
SVN revision: 65445
2011-11-20 14:44:05 +00:00
Vincent Torri 9faf53f4e5 Ecore: warning: implicit declaration of functions 'getpid' and 'usleep' on OpenBSD
Patch by Fabien Romano from OpenBSD



SVN revision: 65211
2011-11-14 22:29:46 +00:00
Carsten Haitzler 58cbf16625 ran ecrustify on ecore. some manual fixing too.
SVN revision: 64238
2011-10-21 05:40:39 +00:00
Youness Alaoui b2392e422c Ecore: _ecore_thread_handler must not be defined if threads aren't supported
SVN revision: 63251
2011-09-07 06:58:10 +00:00
Mike McCormack bfffcce2fe ecore: Create a lockless ecore_event_handler_del
Signed-off-by: Mike McCormack <mj.mccormack@samsung.com>

SVN revision: 62375
2011-08-12 05:22:16 +00:00
Mike McCormack a541e19c16 ecore: Use eina locks for _ecore_lock()
Always count lock calls too.

Signed-off-by: Mike McCormack <mj.mccormack@samsung.com>

SVN revision: 62372
2011-08-12 05:21:49 +00:00
Mike McCormack 5c8256e337 ecore: Add main loop thread safety
Thread safety is disabled by default.
Enable it with --enable-thread-safety

Should cover timers, events, animators, idlers and fd handlers.

Tested with Enlightenment and elementary_test.

Signed-off-by: Mike McCormack <mj.mccormack@samsung.com>

SVN revision: 61851
2011-07-28 12:01:16 +00:00
Iván Briano 4da2c481b5 Fix some double frees. The hash frees the data itself.
SVN revision: 61292
2011-07-12 13:36:19 +00:00
Iván Briano a5b1673a70 Little errors no one cares about, but make thread-less case work as expected
SVN revision: 61129
2011-07-07 18:39:25 +00:00
Mike McCormack 18193e9918 ecore: Fix thread check for quicklaunch
Signed-off-by: Mike McCormack <mj.mccormack@samsung.com>

SVN revision: 61109
2011-07-07 10:11:13 +00:00
Iván Briano 693af50513 Expand Ecore_Thread docs.
Thanks cedric for technical advice.
Thanks discomfitor for helping when English vanished.
Thanks myself for keeping both of them busy so they don't break SVN *too* much.


SVN revision: 61095
2011-07-06 18:08:21 +00:00
Mike McCormack f7ec79e13e ecore: Add function to check we're the main loop thread
Rearrange the the order of startup to avoid triggering
the thread checks in ecore_event_type_new().

Signed-off-by: Mike McCormack <mj.mccormack@samsung.com>

SVN revision: 61040
2011-07-05 11:13:20 +00:00
Cedric BAIL 94718fa484 ecore: forgotten eina_threads_init/shutdown.
SVN revision: 60801
2011-06-29 08:24:13 +00:00
Iván Briano 0365a18df7 It doesn't look like this matters, so let's fix the build.
And if it does matter, I hope it breaks something from cedric. One femur, for example. Or both.


SVN revision: 60789
2011-06-29 02:32:37 +00:00
Cedric BAIL 5d473313b0 ecore: do count threads only in the main loop.
NOTE: for an unknow reason I always get the wrong number
of threads when doing the computation from the thread.
Even if I use volatile and mutex. So to avoid that move
that stuff in the main loop. It increase the complexity
of the code, but at least it work.


SVN revision: 60767
2011-06-28 15:53:19 +00:00
Cedric BAIL edfeab7295 ecore: actually limit the number of pipe in the cache.
SVN revision: 60763
2011-06-28 14:53:34 +00:00
Vincent Torri d9e7ffbf87 Ecore: ecore_thread : free resources, spotted by Ulrich Eckhardt
SVN revision: 60057
2011-06-07 22:21:25 +00:00
Christopher Michael 61ec1408bd Ecore: Fix shadow declaration of variable 'time'.
SVN revision: 59720
2011-05-27 02:06:26 +00:00
Vincent Torri 223bcd6866 Ecore : ecore_thread: use Sleep() on Windows, instead of usleep()
usleep() does not exists on Windows. Use Sleep() instead. But the
resolution timers are not good on Windows. the sleep will be around
50ms at best.


SVN revision: 59466
2011-05-17 07:17:53 +00:00
Daniel Juyung Seo 6ef3841a37 Ecore: Removed trailing whitespaces.
SVN revision: 58753
2011-04-20 14:15:33 +00:00
Cedric BAIL ab3150b53e ecore: add ecore_thread_reschedule.
SVN revision: 57797
2011-03-16 13:16:14 +00:00
Christopher Michael c0096e92ad Ecore_Thread: Fix yet another doxy typo.
SVN revision: 57326
2011-02-25 18:42:44 +00:00
Christopher Michael 4ba275a120 Ecore_Thread: Fix doxy typo.
SVN revision: 57325
2011-02-25 18:41:37 +00:00
Vincent Torri a3ffd27636 remove win7 code and fix other minor problems
SVN revision: 55023
2010-11-26 18:41:43 +00:00
Vincent Torri 95f36c0e18 more fixes, but needs to remove Windows 7 code, now...
SVN revision: 55019
2010-11-26 15:34:30 +00:00
Vincent Torri 6b4b7bc42d add native win32 thread support in ecore_thread. Not tested a lot at all.
SVN revision: 55014
2010-11-26 13:50:31 +00:00