<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On 14 January 2016 at 10:38, Weiming Zhao via cfe-commits <span dir="ltr"><<a href="mailto:cfe-commits@lists.llvm.org" target="_blank">cfe-commits@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">weimingz added a comment.<br>
<br>
Hi Nick,<br>
<br>
Below is a reduced code:<br>
t.c:<br>
<br>
  static long double acoshl (long double __x) __asm__ ("" "acosh") ;  // this is from <gcc4.9>/arm-linux-gnueabi/libc/usr/include/bits/mathcalls.h<br>
  extern long double acoshl (long double) __asm__ ("" "__acoshl_finite") ; // this is from existing code<br>
<br>
GCC gives warning like:<br>
/tmp/t.c:2:1: warning: asm declaration ignored due to conflict with previous rename [-Wpragmas]<br>
 extern long double acoshl (long double) __asm__ ("" "__acoshl_finite") ;<br></blockquote><div><br></div><div><div>That's the same case as in this testcase:</div><div><br></div><div>  void foo() __asm__("one");</div><div>  void foo() __asm__("two");<br></div><div>  void test() { foo(); }<br></div><div><br></div><div>GCC emits a call to 'one' while Clang emits a call to 'two'. This is a real bug. Please don't downgrade this to a warning.</div><div><br></div><div>As an alternative, I would accept a patch which changes how clang generates code so that it also produces a call to 'one', with a warning. It looks like what we need to do is drop subsequent asm label declarations on functions that already have one.</div><div><br></div><div>Nick</div></div></div></div></div>