Behdad Esfahbod
dbdbfe3d7b
Use nullptr instead of NULL
2017-10-15 12:11:08 +02:00
Konstantin Ritt
3f174cd020
Minor refactoring to the atomics implementation
...
s/atomic_int/atomic_int_impl/ and s/atomic_ptr/atomic_ptr_impl/
to bring it in par with hb_mutex_impl_t, then re-introduce
hb_atomic_int_t as a wrapper around hb_atomic_int_impl_t.
In hb_reference_count_t, make it clear the non-atomic get and set
are intentional due to nature of the cases they are used in
(comparison to -1 and the debug output/tracing).
2015-04-08 13:04:22 -07:00
Behdad Esfahbod
24930d544e
Minor
2015-04-08 12:52:06 -07:00
Behdad Esfahbod
45a8b46f47
Allow implementing atomic and mutex ops in config
...
Motivated by
https://github.com/behdad/harfbuzz/pull/92
2015-04-08 12:49:38 -07:00
Konstantin Ritt
7db326a15b
Fix build on WinRT
...
There is no environment (like WinCE) and the basic version
of InitializeCriticalSection is unsupported.
https://codereview.qt-project.org/#/c/92496/
2015-01-25 08:13:24 +04:00
Behdad Esfahbod
8fd4d70b14
[wince] Two more Windows CE fixes
...
Report has it that it builds (and works) now:
https://codereview.qt-project.org/#/c/92087/
2014-08-12 13:12:31 -04:00
Behdad Esfahbod
db30828048
[win] Consolidate windows.h include tips and tricks
2014-07-19 16:32:04 -04:00
Behdad Esfahbod
a6c1e040e5
Improve check for Windows platforms
...
Instead of checking for compiler, check for platform.
2013-02-12 15:31:58 -05:00
Behdad Esfahbod
b842780138
Minor
2013-02-11 17:02:17 -05:00
Behdad Esfahbod
0e292eb2a2
Remove Glib thread-safety support
...
Now that we have pthread detection in configure, we don't need Glib
anymore. Glib will only be a Unicode data provider.
2012-10-02 15:09:38 -04:00
Behdad Esfahbod
eb56f6ae96
Minor
2012-08-07 21:44:25 -04:00
Behdad Esfahbod
49f8e0cd9a
GStaticMutex is deprecated
2012-06-16 15:40:03 -04:00
Behdad Esfahbod
81a4b9fd4e
Remove unused hb_static_mutex_t
2012-06-05 20:53:00 -04:00
Behdad Esfahbod
04bc1eebe7
Add configure tests for Intel atomic intrinsics
2012-06-05 20:16:56 -04:00
Behdad Esfahbod
cdafe3a7d8
Add gcc intrinsics implementations for atomic and mutex
2012-06-05 16:40:23 -04:00
Behdad Esfahbod
0e253e97af
Add a mutex to object header
...
Removes one more static-initialization. A few more to go.
2012-06-05 15:54:43 -04:00
Behdad Esfahbod
022a05ae90
Minor
2012-05-17 21:53:24 -04:00
Behdad Esfahbod
34961e3198
Prefer native atomic/mutex ops to glib's
2012-05-17 20:50:38 -04:00
Behdad Esfahbod
ec3ba4b96f
Move atomic ops into their own header
2012-05-17 20:30:46 -04:00
Behdad Esfahbod
a1970d9afc
Add support for atomic int and mutex on Apple systems
...
So, apparently there's no atomic int 'get' method on Apple. You have to
add(0) to get. And that's not const-friendly. So switch inert-object
checking to a non-atomic get. This, however, is safe, and a negligible
performance boost too.
2012-02-24 16:19:52 -05:00
Behdad Esfahbod
bd7ff1dec5
Allow disabling multi-threaded support
...
By defining HB_NO_MT.
Also, only warn once per missing MT feature support.
Mozilla Bug 666661 - gfx/harfbuzz/src/hb-prive.h - compiler warnings on mac
2012-02-23 15:06:16 -05:00
Behdad Esfahbod
c605bbbb6d
Remove C++ guards from source files
...
Where causing issues for people with MSVC.
2011-08-04 20:00:53 -04:00
Behdad Esfahbod
f60271c0c2
Add mingw32 support
...
With these changes, on Ubuntu I can do:
./configure --host=i586-mingw32msvc && make
2011-08-02 10:00:55 -04:00
Behdad Esfahbod
389a7c9e67
Remove hb_static_threadsafe_set_t
2011-05-11 22:21:38 -04:00
Behdad Esfahbod
daa446f184
Fix compile with no mutex available
2011-05-11 21:31:25 -04:00
Behdad Esfahbod
1e56c476c1
Free static mutex'es
2011-05-11 21:28:01 -04:00
Behdad Esfahbod
831886a9b4
Streamline mutex stuff
2011-05-11 21:27:52 -04:00
Behdad Esfahbod
438c4eee35
Remove unused hb_mutex_trylock()
2011-05-11 21:14:34 -04:00
Behdad Esfahbod
8c7a100a4d
Fix build without mutex
2011-05-10 19:21:07 -04:00
Behdad Esfahbod
19d3035c40
Remove duplicate atomic_int implementation
2011-05-10 19:18:12 -04:00
Behdad Esfahbod
45bfa99034
Fix set implementation to be truly threadsafe even with destroy() callbacks
...
The test/object test is passing again, instead of deadlocking.
2011-05-10 19:15:49 -04:00
Behdad Esfahbod
08611d5194
Add note re deadlocks
2011-05-06 16:28:10 -04:00
Behdad Esfahbod
d37486d87b
Add hb_threadsafe_set_t
2011-05-05 15:07:54 -04:00
Behdad Esfahbod
b81bd42951
Make hb_mutex_*() macros take a pointer
...
More intuitive.
2011-05-05 00:21:16 -04:00
Behdad Esfahbod
a4b1900913
Add hb_static_mutex_t
2011-05-05 00:17:43 -04:00
Behdad Esfahbod
56eb5ad6f9
Move code around
...
Mutex (and Windows.h by extension) are fairly isolated now.
2011-05-04 19:27:37 -04:00