I'm having an issue compiling using with the ilp32 compiler.  Some free 
functions, which should be in the std namespace, aren't namespaced.

Here's an example.

#include <cmath>
double round_wrapper(double val)
{
   return std::round(val);
}

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.

This is the command I used to compile

/opt/rtems/6/aarch64/bin/aarch64-rtems6-g++ -std=gnu++11 -D_GNU_SOURCE
-D__RTEMS_MAJOR__=6 -D__rtems__ -fno-strict-aliasing -mcpu=cortex-a53 
-mabi=ilp32
-isystem 
/opt/rtems/6/aarch64/bsps/aarch64-rtems6/xilinx_zynqmp_ilp32_zu3eg/lib/include 
-qrtems -ffunction-sections
-fdata-sections -fPIC -o test.obj -c example.cpp

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)

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

/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

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.

Thanks,
Trip Richert


________________________________

CONFIDENTIALITY NOTICE: 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.rich...@nta-inc.net, 2563361406) and destroy all copies.

_______________________________________________
users mailing list
users@rtems.org
http://lists.rtems.org/mailman/listinfo/users

Reply via email to