<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><span class="vcard"><a class="email" href="mailto:nicolasweber@gmx.de" title="Nico Weber <nicolasweber@gmx.de>"> <span class="fn">Nico Weber</span></a>
</span> changed
          <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED FIXED - Clang doesn't support stdcall names in inline asm"
   href="https://bugs.llvm.org/show_bug.cgi?id=19027">bug 19027</a>
          <br>
             <table border="1" cellspacing="0" cellpadding="8">
          <tr>
            <th>What</th>
            <th>Removed</th>
            <th>Added</th>
          </tr>

         <tr>
           <td style="text-align:right;">CC</td>
           <td>
                
           </td>
           <td>nicolasweber@gmx.de
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">Resolution</td>
           <td>---
           </td>
           <td>FIXED
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">Status</td>
           <td>NEW
           </td>
           <td>RESOLVED
           </td>
         </tr></table>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED FIXED - Clang doesn't support stdcall names in inline asm"
   href="https://bugs.llvm.org/show_bug.cgi?id=19027#c7">Comment # 7</a>
              on <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED FIXED - Clang doesn't support stdcall names in inline asm"
   href="https://bugs.llvm.org/show_bug.cgi?id=19027">bug 19027</a>
              from <span class="vcard"><a class="email" href="mailto:nicolasweber@gmx.de" title="Nico Weber <nicolasweber@gmx.de>"> <span class="fn">Nico Weber</span></a>
</span></b>
        <pre>This seems to work now:

$ cat test.c
void __stdcall StdcallFunc() {};

void Test()
{
    asm ("call _StdcallFunc@0\n");
}
$ out/gn/bin/clang-cl -fuse-ld=lld test.c -m32 /LD /link /nodefaultlib /noentry
$ out/gn/bin/llvm-objdump --disassemble test.dll

test.dll:       file format COFF-i386


Disassembly of section .text:

10001000 .text:
10001000: 55                            pushl   %ebp
10001001: 89 e5                         movl    %esp, %ebp
10001003: 5d                            popl    %ebp
10001004: c3                            retl
10001005: 66 2e 0f 1f 84 00 00 00 00 00 nopw    %cs:(%eax,%eax)
1000100f: 90                            nop
10001010: 55                            pushl   %ebp
10001011: 89 e5                         movl    %esp, %ebp
10001013: e8 e8 ff ff ff                calll   -24 <.text>
10001018: 5d                            popl    %ebp
10001019: c3                            retl</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>