<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-size: 12pt; color: rgb(0, 0, 0);"><font face="monospace">I've been using primarily :</font></div>
<div style="font-size: 12pt; color: rgb(0, 0, 0);"><font face="monospace"><br>
</font></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="font-family:monospace"><span style="color:#000000;background-color:#ffffff">aarch64-rtems6-gcc (GCC) 10.3.1 20210409 (RTEMS 6, RSB no-repo, Newlib 0c0f3df)</span><br>
</span><span style="font-family:monospace"><span style="color:#000000;background-color:#ffffff">aarch64-rtems6-g++ (GCC) 10.3.1 20210409 (RTEMS 6, RSB no-repo, Newlib 0c0f3df)</span></span></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="font-family:monospace"><br>
</span></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="font-family:monospace"><span style="color:#000000;background-color:#ffffff"></span>but also tested it with <br>
<br>
</span><span style="font-family:monospace"><span style="color:#000000;background-color:#ffffff"><span style="margin:0px;background-color:rgb(255, 255, 255)">aarch64-rtems6-gcc (GCC) 12.2.1 20220924 (RTEMS 6, RSB cfed1659a297cb0f95a03e053345962097aa02bf, Newlib
01f6251c0)</span><br style="background-color:rgb(255, 255, 255)">
aarch64-rtems6-g++ (GCC) 12.2.1 20220924 (RTEMS 6, RSB cfed1659a297cb0f95a03e053345962097aa02bf, Newlib 01f6251c0)</span><br>
<span><br>
</span>with same result.</span></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="font-family:monospace"><br>
</span></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="font-family:monospace">(I don't know how to remove the disclaimer below, but I'm aware that this is a public email list and intend for the contents of this email to be available to everyone. I'll swap to an email without the confidentiality notice
after this email).<br>
</span><br>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Joel Sherrill <joel@rtems.org><br>
<b>Sent:</b> Wednesday, October 5, 2022 1:43 PM<br>
<b>To:</b> Trip Richert <trip.richert@nta-inc.net><br>
<b>Cc:</b> users@rtems.org <users@rtems.org><br>
<b>Subject:</b> [EX]Re: xilinx_zynqmp_ilp32_zu3eg namespace issue (cmath round not in std)</font>
<div> </div>
</div>
<div>
<div dir="ltr">
<div dir="ltr"><br>
</div>
<br>
<div class="x_gmail_quote">
<div dir="ltr" class="x_gmail_attr">On Wed, Oct 5, 2022 at 1:20 PM Trip Richert <<a href="mailto:trip.richert@nta-inc.net">trip.richert@nta-inc.net</a>> wrote:<br>
</div>
<blockquote class="x_gmail_quote" style="margin:0px 0px 0px 0.8ex; border-left:1px solid rgb(204,204,204); padding-left:1ex">
<div class="x_msg4125583652592345574">
<div dir="ltr"><span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">I'm having an issue compiling using with the ilp32 compiler. Some free functions, which should be in the std namespace, aren't namespaced.</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">Here's an example.</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">#include <cmath></span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">double round_wrapper(double val)</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">{</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline"> return std::round(val);</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">}</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">I get an error message that the round function isn't in the std namespace. Calling return round(val); without the std namespace compiles successfully. </span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">This is the command I used to compile</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">/opt/rtems/6/aarch64/bin/aarch64-rtems6-g++ -std=gnu++11 -D_GNU_SOURCE </span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">-D__RTEMS_MAJOR__=6 -D__rtems__ -fno-strict-aliasing -mcpu=cortex-a53 -mabi=ilp32</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">-isystem /opt/rtems/6/aarch64/bsps/aarch64-rtems6/xilinx_zynqmp_ilp32_zu3eg/lib/include -qrtems -ffunction-sections </span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">-fdata-sections -fPIC -o test.obj -c example.cpp</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">I tried a couple of revisions of rtems, the latest was aarch64-rtems6-g++ (GCC) 12.2.1 20220924 (RTEMS 6, RSB cfed1659a297cb0f95a03e053345962097aa02bf,
Newlib 01f6251c0)</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">if I try to compile the exact same code with similar arguments for arm zedboard, it compiles successfully. So, something is different about the ilp32
compiler</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">/opt/rtems/6/arm/bin/arm-rtems6-g++ -std=gnu++11 -D__RTEMS_MAJOR__=6 -D__rtems__ -fno-strict-aliasing -mthumb -mfpu=neon -mfloat-abi=hard -march=armv7-a
-mtune=cortex-a9 -isystem /opt/rtems/6/arm/bsps/arm-rtems6/xilinx_zynq_zedboard/lib/include -qrtems -ffunction-sections -fdata-sections -fPIC -o test.obj -c example.cpp</span></div>
</div>
</blockquote>
<div><br>
</div>
<div>What gcc version is this? <cmath> is provided by gcc. </div>
<div><br>
</div>
<blockquote class="x_gmail_quote" style="margin:0px 0px 0px 0.8ex; border-left:1px solid rgb(204,204,204); padding-left:1ex">
<div class="x_msg4125583652592345574">
<div dir="ltr"><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">I wasn't sure whether to send this to the bug email list, or to check here first to see if someone noticed something I was messing up first. </span></div>
</div>
</blockquote>
<div><br>
</div>
<div>This is a good enough place to start the discussion.</div>
<div><br>
</div>
<div>--joel </div>
<blockquote class="x_gmail_quote" style="margin:0px 0px 0px 0.8ex; border-left:1px solid rgb(204,204,204); padding-left:1ex">
<div class="x_msg4125583652592345574">
<div dir="ltr"><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">Thanks,</span><br style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255)">
<span style="color:rgb(32,31,30); font-size:14.6667px; background-color:rgb(255,255,255); display:inline">Trip Richert</span>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<br>
<hr>
<p style="font-size:8pt; line-height:10pt; font-family:Arial; color:rgb(255,0,0)">
CONFIDENTIALITY NOTICE: <span style="font-size:8pt; line-height:10pt; font-family:Arial; color:rgb(102,102,102)">
<i>The contents of this e-mail message may be privileged, confidential, proprietary, Controlled Unclassified Information (CUI) or otherwise protected against disclosure or dissemination. This e-mail message and any files transmitted with it are intended solely
for the use of the individual/individuals or entity/entities to whom they are addressed. If you are not the intended recipient of this message, any dissemination, distribution, printing or copying is strictly prohibited. If you have received this message in
error, please e-mail or call the sender (<a href="mailto:trip.richert@nta-inc.net" target="_blank">trip.richert@nta-inc.net</a>, 2563361406) and destroy all copies.
<br>
<br>
</i></span></p>
</div>
_______________________________________________<br>
users mailing list<br>
<a href="mailto:users@rtems.org" target="_blank">users@rtems.org</a><br>
<a href="http://lists.rtems.org/mailman/listinfo/users" rel="noreferrer" target="_blank">http://lists.rtems.org/mailman/listinfo/users</a></div>
</blockquote>
</div>
</div>
<p class="x_MsoNormal"><b><span style="color:black">EXTERNAL SENDER EMAIL WARNING: Do not click links or open attachments unless you recognize the sender and know the content is safe.</span></b></p>
</div>
<br>
<hr>
<p style="font-size:8pt; line-height:10pt; font-family:'Arial'; color:#FF0000">CONFIDENTIALITY NOTICE:
<span style="font-size:8pt; line-height:10pt; font-family:'Arial'; color:#666666">
<i>The contents of this e-mail message may be privileged, confidential, proprietary, Controlled Unclassified Information (CUI) or otherwise protected against disclosure or dissemination. This e-mail message and any files transmitted with it are intended solely
for the use of the individual/individuals or entity/entities to whom they are addressed. If you are not the intended recipient of this message, any dissemination, distribution, printing or copying is strictly prohibited. If you have received this message in
error, please e-mail or call the sender (trip.richert@nta-inc.net, 2563361406) and destroy all copies.
<br>
<br>
</i></span></p>
</body>
</html>