Re: Thread stack size issue related to glibc TLS bug

2019-06-03 Thread David Holmes
Hi Jiangli, On 31/05/2019 1:23 am, Jiangli Zhou wrote: Hi David, This is a link to __pthread_get_minstack that I find in the public domain: https://code.woboq.org/userspace/glibc/nptl/nptl-init.c.html. It has copyright of 2002-2019, so it's probably the latest version. size_t __pthread_get_min

Re: Thread stack size issue related to glibc TLS bug

2019-05-29 Thread David Holmes
Hi Florian, On 25/05/2019 6:50 am, Florian Weimer wrote: * Jiangli Zhou: Hi Florian, On Fri, May 24, 2019 at 2:46 AM Florian Weimer wrote: * Jiangli Zhou: [3] change: http://cr.openjdk.java.net/~jiangli/tls_size/webrev/ (contributed by Jeremy Manson) _dl_get_tls_static_info is an inter

Re: Thread stack size issue related to glibc TLS bug

2019-05-29 Thread David Holmes
Hi Florian, On 24/05/2019 8:13 pm, Florian Weimer wrote: * David Holmes: My thoughts haven't really changed since 2015 - and sadly neither has there been any change in glibc in that time. Nor, to my recollection, have there been any other reported issues with this. The issue gets occasionall

Re: Thread stack size issue related to glibc TLS bug

2019-05-28 Thread Martin Buchholz
On Mon, May 27, 2019 at 2:07 AM Florian Weimer wrote: > * Martin Buchholz: > > > Very big picture - if we want to banish stack overflows forever, we would > > need to migrate the industry to split runtime stacks, which would add a > bit > > of runtime overhead to every native function call. No o

Re: Thread stack size issue related to glibc TLS bug

2019-05-27 Thread Florian Weimer
* Martin Buchholz: > Very big picture - if we want to banish stack overflows forever, we would > need to migrate the industry to split runtime stacks, which would add a bit > of runtime overhead to every native function call. No one is heroic enough > to make progress towards that. Maybe develop

Re: Thread stack size issue related to glibc TLS bug

2019-05-25 Thread Martin Buchholz
Very big picture - if we want to banish stack overflows forever, we would need to migrate the industry to split runtime stacks, which would add a bit of runtime overhead to every native function call. No one is heroic enough to make progress towards that. Maybe developers of new OSes need to read

Re: Thread stack size issue related to glibc TLS bug

2019-05-24 Thread Florian Weimer
* Jiangli Zhou: > Hi Florian, > > On Fri, May 24, 2019 at 2:46 AM Florian Weimer wrote: >> >> * Jiangli Zhou: >> >> > [3] change: http://cr.openjdk.java.net/~jiangli/tls_size/webrev/ >> > (contributed by Jeremy Manson) >> >> _dl_get_tls_static_info is an internal symbol (it carries a >> GLIBC_PRI

Re: Thread stack size issue related to glibc TLS bug

2019-05-24 Thread Jiangli Zhou
Hi Florian, On Fri, May 24, 2019 at 2:46 AM Florian Weimer wrote: > > * Jiangli Zhou: > > > [3] change: http://cr.openjdk.java.net/~jiangli/tls_size/webrev/ > > (contributed by Jeremy Manson) > > _dl_get_tls_static_info is an internal symbol (it carries a > GLIBC_PRIVATE symbol version). Its imp

Re: Thread stack size issue related to glibc TLS bug

2019-05-24 Thread Florian Weimer
* Jiangli Zhou: > Hi Florian, > > Thanks for the feedback! > > On Fri, May 24, 2019 at 3:13 AM Florian Weimer wrote: >> >> * David Holmes: >> >> > My thoughts haven't really changed since 2015 - and sadly neither has >> > there been any change in glibc in that time. Nor, to my recollection, >> >

Re: Thread stack size issue related to glibc TLS bug

2019-05-24 Thread Florian Weimer
* David Holmes: > My thoughts haven't really changed since 2015 - and sadly neither has > there been any change in glibc in that time. Nor, to my recollection, > have there been any other reported issues with this. The issue gets occasionally reported by people who use small stacks with large ini

Re: Thread stack size issue related to glibc TLS bug

2019-05-24 Thread Florian Weimer
* Jiangli Zhou: > [3] change: http://cr.openjdk.java.net/~jiangli/tls_size/webrev/ > (contributed by Jeremy Manson) _dl_get_tls_static_info is an internal symbol (it carries a GLIBC_PRIVATE symbol version). Its implementation can change at any time. Please do not do this. Thanks, Florian

Re: Thread stack size issue related to glibc TLS bug

2019-05-23 Thread David Holmes
Hi Jiangli, On 24/05/2019 9:21 am, Jiangli Zhou wrote: Hi David (and others), There was a discussion [1] (between you, Jeremy, Martin and others) back in 2015 regarding a stack size issue caused by a glibc bug related to TLS (Thread local storage) [2]. The issue was manifested as a StackOverflo