<div dir="ltr">How would you deal with inlining?<div><br></div><div>-eric</div></div><br><div class="gmail_quote"><div dir="ltr">On Tue, Jun 30, 2015 at 12:53 PM Akira Hatanaka <<a href="mailto:ahatanak@gmail.com">ahatanak@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">In <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__reviews.llvm.org_D10832-23197327&d=AwMFaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=mQ4LZ2PUj9hpadE3cDHZnIdEwhEBrbAstXeMaFoB9tg&m=4M4H-n5lZxg0HBcAMEE7j6hz3mNpnShyvrnL0QZg9po&s=HfkrHRkCy58WUQPp_wI8CFttCfrMm6Td6GKs6iySRSI&e=" rel="noreferrer" target="_blank">http://reviews.llvm.org/D10832#197327</a>, @echristo wrote:<br>
<br>
> I think that'll cause problems when we merge translation units at module<br>
>  link time? i.e. we only have one llvm.trap intrinsic.<br>
<br>
<br>
Attaching the attribute to the declaration of llvm.trap would cause problems when linking modules, but attaching it to the call site should be fine. The linked module looks like this:<br>
<br>
declare void @llvm.trap() #2<br>
...<br>
call void @llvm.trap() #4<br>
...<br>
call void @llvm.trap() #5<br>
...<br>
attributes #2 = { noreturn nounwind }<br>
attributes #4 = { noreturn nounwind "trap-func-name"="foo112" }<br>
attributes #5 = { noreturn nounwind "trap-func-name"="foo111" }<br>
<br>
<br>
<a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__reviews.llvm.org_D10832&d=AwMFaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=mQ4LZ2PUj9hpadE3cDHZnIdEwhEBrbAstXeMaFoB9tg&m=4M4H-n5lZxg0HBcAMEE7j6hz3mNpnShyvrnL0QZg9po&s=4fLernD9AtOw-B5kLO2XMnJLm-ZPhi6b1dHohD6Dgcw&e=" rel="noreferrer" target="_blank">http://reviews.llvm.org/D10832</a><br>
<br>
EMAIL PREFERENCES<br>
  <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__reviews.llvm.org_settings_panel_emailpreferences_&d=AwMFaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=mQ4LZ2PUj9hpadE3cDHZnIdEwhEBrbAstXeMaFoB9tg&m=4M4H-n5lZxg0HBcAMEE7j6hz3mNpnShyvrnL0QZg9po&s=EFDAPXV8uzXp7MIRDjctCzRbVICSBBInorzIovCsCaY&e=" rel="noreferrer" target="_blank">http://reviews.llvm.org/settings/panel/emailpreferences/</a><br>
<br>
<br>
</blockquote></div>