<div dir="ltr">Hi,<div><br></div><div>I think we should change one of our patches to not use &#39;static register&#39; as comment in this link <a href="http://www.lemoda.net/c/keywords/register.html">http://www.lemoda.net/c/keywords/register.html</a> and this one <a href="http://stackoverflow.com/questions/8674236/is-typedef-a-storage-class-specifier">http://stackoverflow.com/questions/8674236/is-typedef-a-storage-class-specifier</a>. </div>
<div><br></div><div><div>/*                                                                              </div><div> * how to get the current stack pointer in C                                    </div><div> */                                                                             </div>
<div>#if defined(CONFIG_BUILTIN_STACK_POINTER)                                       </div><div>/* compiler has __builtin_stack_pointer support already */                      </div><div>                                                                                </div>
<div>#elif defined(__clang__)                                                        </div><div>#define __builtin_stack_pointer() ({ \                                          </div><div>        unsigned long current_sp; \                                             </div>
<div>        asm (&quot;mov %0, sp&quot; : &quot;=r&quot; (current_sp)); \                               </div><div>        current_sp; \                                                           </div><div>})                                                                              </div>
<div>#define current_stack_pointer __builtin_stack_pointer()                         </div><div>                                                                                </div><div>#else /* gcc */                                                                 </div>
<div>static register unsigned long current_stack_pointer asm (&quot;sp&quot;);              &lt;==================   </div><div>#define __builtin_stack_pointer() current_stack_pointer                         </div><div>#endif   </div>
</div><div><br></div><div>If we do so, we get kernel-gcc back to work on vexpress. What do you think?</div><div><br></div><div>Regards,</div><div>Tinti</div><div><br></div><div>-- <br><div dir="ltr">Simplicity is the ultimate sophistication<br>
</div>
</div></div>