Commit Graph

142 Commits

Author SHA1 Message Date
Mike Blumenkrantz 4436081e5b add threadsafe global data to threads, allowing for communication between threads and other threads and threads and main loop
SVN revision: 50453
2010-07-23 15:33:22 +00:00
Mike Blumenkrantz 8ed22a2023 rename mutex
SVN revision: 50451
2010-07-23 13:35:14 +00:00
Mike Blumenkrantz 680ec26e8a fix doxy
SVN revision: 50450
2010-07-23 13:12:42 +00:00
Mike Blumenkrantz 9efdf6c9d4 remove unnecessary mutexes, expand pthread self member to short_run threads, make thread pool data work on short_run threads, ecore_thread_pool_data_modify_or_add -> ecore_thread_pool_data_set
SVN revision: 50449
2010-07-23 13:08:38 +00:00
Mike Blumenkrantz c85f521ffa +ecore_thread_pool_data_modify_or_add
SVN revision: 50443
2010-07-23 04:17:41 +00:00
Mike Blumenkrantz 92cd8f2705 api change to ecore_thread_pool_data_add, now has 4th argument "direct" to avoid copying key value if desired
SVN revision: 50442
2010-07-23 03:39:52 +00:00
Mike Blumenkrantz ebd21717c6 +ecore_thread_pool_data_{add,find,del}: start of ecore_thread_pool api. these calls are used from heavy_run to manage data within a thread pool. more to come
SVN revision: 50438
2010-07-22 20:28:34 +00:00
Mike Blumenkrantz 0ffbf90242 should probably make thread functions threadsafe. and compile.
SVN revision: 50411
2010-07-21 08:33:25 +00:00
Mike Blumenkrantz 977be45e37 fix some function variables and a cedric-requested rename
SVN revision: 50409
2010-07-21 07:09:51 +00:00
Mike Blumenkrantz 00023656af man I fail at formatting
SVN revision: 50406
2010-07-21 04:26:57 +00:00
Mike Blumenkrantz 82d7183f47 +ecore_thread_total_get to return total number of pending jobs
SVN revision: 50405
2010-07-21 04:03:40 +00:00
Mike Blumenkrantz 35ca9e3e12 +ecore_thread_max_reset, ecore_thread_avail_get for more thread functionality, also fix formatting
SVN revision: 50399
2010-07-21 02:12:10 +00:00
Mike Blumenkrantz ec1d528178 +ecore_thread_max_{set,get} to return/set the max number of threads ecore will attempt to run simultaneously
SVN revision: 50397
2010-07-21 01:04:28 +00:00
Mike Blumenkrantz 5701a455d1 some variable renames to make this easier to understand
SVN revision: 50376
2010-07-20 09:40:53 +00:00
Mike Blumenkrantz 75d478dfac +ecore_thread_active_get, ecore_thread_pending_get, ecore_thread_pending_long_get to retrieve number of threads present with given status
SVN revision: 50375
2010-07-20 09:40:18 +00:00
Mike Blumenkrantz 952dd2bd44 note: '/*' is not how you begin a doxygen code block
SVN revision: 50372
2010-07-20 05:25:02 +00:00
Cedric BAIL 3015da94da * ecore: fix build without thread.
NOTE: if you build ecore without pthread support, you really should know
	that it is a bad idea. Only people without pthread support on their
	device/C library should disable it.


SVN revision: 50200
2010-07-12 14:39:06 +00:00
Vincent Torri 3e15fef7b8 fix warnings
SVN revision: 50174
2010-07-10 11:09:40 +00:00
Vincent Torri 5ae1fc61e1 fix spaces
SVN revision: 50173
2010-07-10 11:08:20 +00:00
Cedric BAIL f424ca1e1e * ecore: for the 50 000 commits, why not adding some docs ?
SVN revision: 50000
2010-07-02 16:01:21 +00:00
Cedric BAIL 062f4c3920 * ecore: fix long run thread, now that I have a nice user.
SVN revision: 49994
2010-07-02 11:15:20 +00:00
Cedric BAIL d1fcb71f84 * ecore: add ecore_long_run facility with notify to main loop.
SVN revision: 49948
2010-06-30 13:25:28 +00:00
Cedric BAIL fbe9064310 * ecore: Ecore callback really should return Eina_Bool.
SVN revision: 49829
2010-06-24 16:15:56 +00:00
Iván Briano e0dedc5eb9 Release lock before returning
SVN revision: 47980
2010-04-12 21:51:35 +00:00
Hannes Janetzek 5fd3adcc68 make ecore thread cancel work. someone knowing the internals should check this again.
SVN revision: 47866
2010-04-09 04:52:04 +00:00
Cedric BAIL 816974ff0b * ecore: Match what doc when disabling thread support in ecore.
SVN revision: 46467
2010-02-25 15:26:38 +00:00
Sebastian Dransfeld 0a9456ccf7 Remove duplication from ecore headers
Clean up Ecore.h and ecore_private.h

SVN revision: 44664
2009-12-22 21:15:12 +00:00
Cedric BAIL 78fdf79b00 * ecore: Cleanup some warning.
SVN revision: 44631
2009-12-21 16:17:29 +00:00
Cedric BAIL 579f2e5447 * evas_preload, ecore_thread: On memory allocation failure do call the cancel function too.
SVN revision: 44624
2009-12-21 12:25:32 +00:00
Vincent Torri 14513477b9 fix warnings and returned value when no pthread
SVN revision: 44569
2009-12-19 11:43:44 +00:00
Vincent Torri 1b7b929a09 * link correctly ecore against pthread
* use the efl_pthread.m4 macro
 * add configure output for pthread support in ecore


SVN revision: 43627
2009-11-11 23:43:58 +00:00
Vincent Torri a206a8b183 fix compilation when no pthread is available
Cedric: returning false in ecore_thread_cancel is good ?

SVN revision: 43548
2009-11-08 22:16:17 +00:00
Cedric BAIL 6310f0ef55 * ecore_thread: Add possibility to cancel Ecore_Thread.
WARNING: THIS BREAK API AND ABI !!!


SVN revision: 43501
2009-11-06 22:15:04 +00:00
Vincent Torri 43d3c84907 no need for ref count in ecore_thread init/shutdown functions
SVN revision: 42991
2009-10-10 03:24:56 +00:00
Vincent Torri d8acbfc6f6 rename ecore_thread_init and ecore_thread_shutdown to fit usual private function names
SVN revision: 42240
2009-09-04 05:49:54 +00:00
Lars Munch 023b8909af Added missing pthread guard
Patch from Vincent Torri



SVN revision: 42005
2009-08-26 05:59:56 +00:00
Lars Munch 2e7e9169e7 Fix building without pthread support
SVN revision: 41880
2009-08-20 06:09:15 +00:00
Carsten Haitzler 447051bf3c dont use #ifdeffed out calls
SVN revision: 41726
2009-08-13 00:30:59 +00:00
Cedric BAIL 7db27df3c8 * ecore_thread: Fix the remaining comment from Vincent.
SVN revision: 41581
2009-08-04 09:13:49 +00:00
Cedric BAIL 13cea2628b * ecore_thread: Another dead lock spotted by Sachiel.
SVN revision: 41570
2009-08-03 14:09:09 +00:00
Cedric BAIL e7f691a9f2 * ecore_thread: Prevent mutex lock, thanks to Sachiel.
SVN revision: 41564
2009-08-03 08:19:33 +00:00
Cedric BAIL 2bb8e5ad8e * ecore_thread_run: Add a facility to run heavy code in another thread
that still integrate cleanly with the EFL.

	ecore_thread_run need two callbacks :

	* func_heavy is called from another thread and should not use the
	EFL except Eina, but carefully.

	* func_end is called when func_heavy is done, but from inside ecore
	main loop, so you can at this point call every EFL functions without
	fear.

	Note :

	The system automatically detect how many CPU you have and will spread
	the load on all of them.

	You must not assume that the result will come in the same order you
	requested it. Depend on each CPU load and how heavy the function on it
	are.



SVN revision: 41555
2009-07-31 17:06:11 +00:00