2013/11/2 Joseph S. Myers <jos...@codesourcery.com>: > On Thu, 31 Oct 2013, Ilya Enkovich wrote: > >> This patch adds support Pointer Bounds Checker into c-family and LTO >> front-ends. The main purpose of changes in front-end is to register all >> statically initialized objects for checker. We also need to register >> such objects created by compiler. > > What happens with statically initialized TLS objects? It would seem that > you need something like how the C++ front end handles static constructors > for C++11 thread-local objects, but I don't see anything obvious for that > here.
This patch takes care of pointers initialized by linker. TLS objects are dynamically allocated for each thread and should have some constructor to perform initialization. And if there is such constructors then it should be instrumented by Pointer Bounds Checker. Therefore it should not require additional changes in front-end, right? The only problem I now see for TLS objects is that in my constructors initialize bounds for an actual TLS object, not for object in .tdata. How can I refer to .tdata objects in GIMPLE to get correct bounds initialization for .tdata section? Thanks, Ilya > > -- > Joseph S. Myers > jos...@codesourcery.com