<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Fri, Jan 17, 2014 at 9:41 AM, Artyom Skrobov <span dir="ltr"><<a href="mailto:Artyom.Skrobov@arm.com" target="_blank">Artyom.Skrobov@arm.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br>
<br>
ARMAsmPrinter::emitAttributes emits AllowDIVExt (2) for Tag_DIV_use whenever<br>
the compilation target has hardware divide in both ARM and Thumb instruction<br>
sets.<br>
According to the ABI, this is incorrect:<br>
<br>
2: This code was permitted to use SDIV and UDIV in the ARM and Thumb ISAs;<br>
the instructions are present as an optional architectural extension above<br>
the base architecture implied by Tag_CPU_arch and Tag_CPU_arch_profile.<br>
Note: Producers must emit value 2 if and only if the permission to use SDIV<br>
and UDIV cannot be conveyed using values 0 and 1.<br>
<br>
In ARMv8, hardware divide is mandatory in both ARM and Thumb instruction<br>
sets, and therefore, Tag_DIV_use should not be emitted, as the default value<br>
AllowDIVIfExists (0) is sufficient to express the permission to use hardware<br>
divide.<br>
<br>
OK to commit?<br></blockquote><div><br></div><div>LGTM.  Minor nit, Id place the usage note above the values for Tag_DIV_use.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Saleem Abdulrasool<br>compnerd (at) compnerd (dot) org
</div></div>