<div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Mon, Feb 22, 2016 at 9:18 PM Kit Barton <<a href="mailto:kbarton@ca.ibm.com">kbarton@ca.ibm.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr" style="font-family:Arial;font-size:10.5pt"><div dir="ltr"><span style="font-size:0.857em">Hi Tim,</span></div>
<div dir="ltr"><span style="font-size:0.857em">I'm a little confused about what you're trying to accomplish here.</span></div>
<div dir="ltr"><span style="font-size:0.857em">Are you trying to find a way to access the stack_guard in the TCB provided by glibc?</span></div></div></blockquote><div><br></div><div>Yes.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr" style="font-family:Arial;font-size:10.5pt"><div dir="ltr"><span style="font-size:0.857em"> </span></div>
<div dir="ltr"><span style="font-size:0.857em">If not, can we not just come up with our own definition of __stack_chk_guard and discuss the best way to implement that (perhaps not by putting it in the TCB)?</span></div>
<div dir="ltr"> </div>
<div dir="ltr"><span style="font-size:0.857em">I'm not familiar with the GCC implementation, but I can talk to the GCC folks tomorrow to get some more details. I know that XL implemented this differently, but some specific details are a bit fuzzy. I'll refresh my memory on that tomorrow as well.</span></div></div></blockquote><div><br></div><div>Based on my understanding, GCC simply hardcoded the register number and offset: <a href="https://github.com/gcc-mirror/gcc/blob/master/gcc/config/rs6000/linux64.h#L610">https://github.com/gcc-mirror/gcc/blob/master/gcc/config/rs6000/linux64.h#L610</a>, and I intend to do similar things here, except we may not need/want to hardcode register number.</div><div><br></div><div>It'll be great if you and GCC folks can help. Thank you!</div></div></div>