<div dir="ltr">Thanks for your advise.<div><br></div><div>Regards,</div><div>Luis</div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-04-22 0:05 GMT+02:00 Jonathan Roelofs <span dir="ltr"><<a href="mailto:jonathan@codesourcery.com" target="_blank">jonathan@codesourcery.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
<br>
On 4/21/15 7:54 AM, LUIS MIGUEL SANCHEZ GARCIA wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
llvm::APInt V = L->getValue();<br>
unsigned int rint = std::atoi(V.toString(10,false).c_str());<br>
</blockquote>
<br></span>
FYI, APInt has getters that sidestep the need to roundtrip through a string. Look for getZExtValue() and getSExtValue().<br>
<br>
<br>
Cheers,<br>
<br>
Jon<span class="HOEnZb"><font color="#888888"><br>
<br>
-- <br>
Jon Roelofs<br>
<a href="mailto:jonathan@codesourcery.com" target="_blank">jonathan@codesourcery.com</a><br>
CodeSourcery / Mentor Embedded<br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div><span style="font-size:small;font-family:arial">-- </span><br style="font-size:small;font-family:arial"><span style="font-size:small;font-family:arial">-- </span><br style="font-size:small;font-family:arial"><span style="font-size:small;font-family:arial">--------------------------------------------------</span><br style="font-size:small;font-family:arial"><span style="font-size:small;font-family:arial">Luis Miguel Sánchez García</span><br style="font-size:small;font-family:arial"><span style="font-size:small;font-family:arial;border-collapse:collapse">Computer Architecture and Technology Area.</span><div style="font-size:small;font-family:arial">Office 2.2.B08<br><div>Computer Science Department. UNIVERSIDAD CARLOS III DE MADRID<br>Universidad Carlos III de Madrid<br>Avda. de la Universidad, 30<br>28911 Leganés - Madrid - Spain<br>e-mail: <a href="mailto:lmsan@arcos.inf.uc3m.es" style="color:rgb(17,85,204)" target="_blank">lmsan@arcos.inf.uc3m.es</a><br>        <a href="mailto:luismiguel.sanchez@uc3m.es" style="color:rgb(17,85,204)" target="_blank">luismiguel.sanchez@uc3m.es</a><br><br></div><div>Phone: (+34) 91 624 5951<br><div> <br>Linked-In: <a href="http://es.linkedin.com/in/lmsan" style="color:rgb(17,85,204)" target="_blank">http://es.linkedin.com/in/lmsan</a><br>Twitter: <a href="http://twitter.com/lmsanchezgarcia" style="color:rgb(17,85,204)" target="_blank">http://twitter.com/lmsanchezgarcia</a><br>--------------------------------------------------</div></div></div></div></div></div>
</div>