<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/121142>121142</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
Can't specify a physical register in inline assembly issue
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
LuoYuanke
</td>
</tr>
</table>
<pre>
It seems below inline assembly fails to be compiled with clang, but can be successful compiled with GCC. It can be duplicated in https://godbolt.org/z/xhrq6YEvT
```
void foo() {
int src = 1;
int dst, dst2;
asm("movl %1, %0\n\t"
"addl $1, %0"
: "=eax"(dst)
: "i"(1));
}
```
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJxckk-PmzwQxj_NcBltZA8QwoFDNnl5tVKPvezR2ENwazDFJrvpp6_MRk0VNBJont_8Q48KwV4m5gbKVyjPmVrj4Jfm2-rfVzX95Kzz5ta8RQzMY8COnf9AOzk7MaoQeOzcDXtlXcDosWPUfpytY4MfNg6onZouQCfs1ohaTYkIq9YcQr-6J_j_02mHb385s87OahXZoJ1wiHEOkB-BWqD24k3nXdz55QLU_gZqP4fl1_79v-t3EMcUe3EPcbx6a7D3HugAVCNUryCOiHaKGBaNkJ9RQv5ImhDTyiZE-kpvigrj1oBGf3UIVMoEAZUCytME5SkC0UamB4iUMYkrHty_en5MDORnVp_pgw7b2PqZsF-iTBLV932q89OJII6ZaXJT57XKuJFVXsq6FqXIhqbsK53vDXNRqN4cqFRKdFpwVVOhRU6ZbUhQIYn2oioKKXayrFjIg6wKPhy6nqEQPCrrds5dx_TPMxvCyo0kKQvKnOrYhc1BRBN_4KamvctztjSp6KVbLwEK4WyI4dEm2ui4OakJqIoYZta2v6HCebgFq5XDhS82RF6SA55dt03J1sU1T96wcVi7nfYjUJtG3V8v8-J_sI5A7VYagNr7BdeG_gQAAP__gDzm3A">