Messages in this thread | | | From | Kirill Korotaev <> | Subject | Re: [announce, patch] 4G/4G split on x86, 64 GB RAM (and more) support | Date | Wed, 9 Jul 2003 19:17:35 +0400 |
| |
> I added a printf for the actual stack
> thread_self=4000 > my stack 0xbffff4df > attr_init stack=00000000, stack_size=001FF000
> That's the output for pthread_attr_init. The manpage says it should fill in > the default values and a 0 base is not that unreasonable for it. 0 is ok, the problem is in get_stackaddr.
> stack rlimit=1ff000 > thread=4000, stack=40035480, stack_size=40035480 > For the main() thread it's wrong.
exactly! For the main thread pthread_get_stackaddr returns a bull shit always :(
But at least java 1.3 has workaround inside and handles this magic value separatly and doesn't crash whis 3/1GB split (this value depends on TASK_SIZE or more preciesly on current stack value aligned to some big boundary (AFAIR, 1GB)).
Anyway it's definietly a bug. I have a fix in a preloading .so library for glibc which overrides pthread_getstack_addr symbol. If you wish I can send it to you.
> my stack 0xbf7ffaab > attr_init stack=00000000, stack_size=001FF000 > stack rlimit=1ff000 > thread=4002, stack=BF800000, stack_size=001FF000 > > For the others everything is correct. true.
[skip]
Kirill
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |