[Gc] Fwd: os_dep.c improvement for Darwin

Ivan Maidanski ivmai at mail.ru
Thu Feb 10 14:33:10 PST 2011


Hi,

Due to the limits of the ML, I've excluded some code realigning from the patch.

Fri, 11 Feb 2011 01:22:09 +0300 Ivan Maidanski <ivmai at mail.ru>:

> Hi,
> 
> This patch:
> 1. adds GC_get_stack_base implementation for Darwin;
> 2. allows to use pthread_get_stack_addr even if GC is single-threaded (useful
> for Android and Darwin there otherwise a hard-code number is used).
> 
> ChangeLog entries:
> * os_dep.c (GC_setpagesize, GC_task_self, PROTECT, UNPROTECT):
> Reorder to remove redundant ifdef for Win32.
> * os_dep.c: Add comment to some endif.
> * os_dep.c: Include pthread.h (for Linux even if single-threaded)
> if USE_GET_STACKBASE_FOR_MAIN; also include it for Darwin.
> * os_dep.c (STACKBOTTOM): Redefine for Darwin (unless prohibited
> for some reason).
> * os_dep.c (GC_get_main_stack_base): Allow
> USE_GET_STACKBASE_FOR_MAIN for Linux even if single-threaded; add
> assertion for the returned result.
> * os_dep.c (GC_get_stack_base): Define for Darwin if
> multi-threaded.
> * os_dep.c (GC_page_was_dirty): Reformat the code.
> * os_dep.c: Reformat some comments.
> * os_dep.c (SIG_OK, CODE_OK): Add comment (for FreeBSD).
> * os_dep.c (ID_STOP, ID_RESUME): Define only if threads.
> * os_dep.c (catch_exception_raise): Remove redundant parentheses;
> refine the documentation.
> 
> PS. the patch is hard to review as it contains numerous code reformatting
> (realigning).
> 
> Regards.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/octet-stream
Size: 21727 bytes
Desc: not available
Url : http://napali.hpl.hp.com/pipermail/gc/attachments/20110211/81b002ec/attachment-0001.obj


More information about the Gc mailing list