php-src/TSRM
Anatol Belski d11734b4b0 reworked the patch, less new stuff but worky
TLS is already used in TSRM, the way exporting the tsrm cache through
a thread local variable is not portable. Additionally, the current
patch suffers from bugs which are hard to find, but prevent it to
be worky with apache. What is done here is mainly uses the idea
from the RFC patch, but

- __thread variable is removed
- offset math and declarations are removed
- extra macros and definitions are removed

What is done merely is

- use an inline function to access the tsrm cache. The function uses
  the portable tsrm_tls_get macro which is cheap
- all the TSRM_* macros are set to placebo. Thus this opens the way
  remove them later

Except that, the logic is old. TSRMLS_FETCH will have to be done once
per thread, then tsrm_get_ls_cache() can be used. Things seeming to be
worky are cli, cli server and apache. I also tried to enable bz2
shared and it has worked out of the box. The change is yet minimal
diffing to the current master bus is a worky start, IMHO. Though will
have to recheck the other previously done SAPIs - embed and cgi.

The offsets can be added to the tsrm_resource_type struct, then
it'll not be needed to declare them in the userspace. Even the
"done" member type can be changed to int16 or smaller, then adding
the offset as int16 will not change the struct size. As well on the
todo might be removing the hashed storage, thread_id != thread_id and
linked list logic in favour of the explicit TLS operations.
2014-09-25 18:48:27 +02:00
..
acinclude.m4 MFB_4_3: Quote macro names in AC_DEFUN() 2004-12-30 07:08:39 +00:00
build.mk Get rid of autoconf warnings 2011-05-16 00:14:47 +00:00
buildconf Add $automake_flags, to allow propagation of --copy 1999-10-05 13:47:16 +00:00
config.w32 initial move on renaming files and fixing includes 2013-10-17 09:43:52 +02:00
configure.in reworked the patch, less new stuff but worky 2014-09-25 18:48:27 +02:00
LICENSE - Update to 2006 2006-01-04 23:55:42 +00:00
Makefile.am initial move on renaming files and fixing includes 2013-10-17 09:43:52 +02:00
readdir.h fix warnings 2008-07-30 17:45:18 +00:00
threads.m4 check should be on host_alias rather than on target_alias, but somehow works on configure generated using autoconf 2.57. 2005-04-27 13:22:18 +00:00
TODO - Add TODO 2000-09-16 19:07:50 +00:00
tsrm_config_common.h fixed macro 2014-02-24 10:12:18 +01:00
tsrm_config.w32.h Fixed bug #66009 Failed compilation of PHP extension with C++ std library using VS 2012 2014-01-04 01:41:27 +01:00
tsrm_nw.c s/PHP 5/PHP 7/ 2014-09-19 18:33:14 +02:00
tsrm_nw.h s/PHP 5/PHP 7/ 2014-09-19 18:33:14 +02:00
tsrm_strtok_r.c - Testing 1 2 3 2000-09-11 15:15:29 +00:00
tsrm_strtok_r.h - Move virtual cwd to TSRM. 2000-09-03 18:18:13 +00:00
tsrm_win32.c reworked the patch, less new stuff but worky 2014-09-25 18:48:27 +02:00
tsrm_win32.h reworked the patch, less new stuff but worky 2014-09-25 18:48:27 +02:00
TSRM.c reworked the patch, less new stuff but worky 2014-09-25 18:48:27 +02:00
TSRM.dsp fix *.dsp files related to bug #50333 2014-01-28 13:09:29 +01:00
TSRM.h reworked the patch, less new stuff but worky 2014-09-25 18:48:27 +02:00
tsrm.m4 reworked the patch, less new stuff but worky 2014-09-25 18:48:27 +02:00