Has anybody tested native-building with GCC version 9.0 or 10.0 for TARGET of arm64, such as NEOVERSEN1 or TSV110?

48 views
Skip to first unread message

Guodong Xu

unread,
May 25, 2020, 4:37:36 AM5/25/20
to OpenBLAS-users
Hi, all

There is a definition in Makefile.system about GCCVERSIONSGTEQ9 
There are references to this macro in Makefile.arm64

However, when I start a build using these commands on an arm64 server machine where GCC 10.0 is installed: (so, I am doing arm64 native build)
 $ make clean
 $ make TARGET=TSV110

The GCCVERSIONSGTEQ9 is still null. (It's expected to be '1'). This makes the optimization C flags CCOMMON_OPT are not updated at all.

I am not expert in the build system. From what I see, looks like Makefile.system is not executed. I am not sure.

Attached is my full build log. Captured by "$ make  TARGET=TSV110 V=1 2>&1 | tee build.log". I added debugging information into Makefiles.?? to help to show the issue. See attched patch.

PS: make TARGET=NEOVERSEN1 has the same issue. I guess something common. 

Thanks.
-Guodong Xu


build.log
makefile.debugging.patch

Guodong Xu

unread,
May 25, 2020, 5:57:07 AM5/25/20
to OpenBLAS-users
Ok, with more debugging, I found the problem. 'GCCVERSIONGTEQ9' is defined only if OSNAME = WINNT 
However, In my case, I am building on a linux machine. 

Markfile.arm64 doesn't check OSNAME at all (well, it should not I think), that makes the problem. I don't understand why GCC version checking is wrapped inside of 'WINNT'. Somebody can shine light on me?

I will submit a patch to fix that.

-Guodong

martin-frbg

unread,
May 25, 2020, 6:37:47 AM5/25/20
to OpenBLAS-users
Nice catch, thanks.
You are right this does not make sense at all - probably all the gcc version checks somehow flocked to the "logical" location where there already was one,
and none of us noticed that it was actually inside an ifdef for a totally unrelated operating system. (All actual testing will likely have happened locally before
the final code cleanup for submitting a PR, and in either case the code still compiles with the misplaced checks, unless one happens to use some
particularly old compiler. So little chance for our automated CI tests to flag this, and relatively rare systems meaning few users to spot the defect )

Guodong Xu

unread,
May 25, 2020, 7:06:26 AM5/25/20
to OpenBLAS-users
I submitted this patch. :) Please help check. I only have Linux OS and Arm64 server, and I verified on that.
For x86, it's not easy for me to run the tests on x86.

The 'git log' told me the GCC version was originally added for MSVC ABI. I support that stands for Microsoft VC, so it's WINNT relevant.
But in codes submitted after that, surely people were adding non-WINNT related stuff into that. So, as you said, a fix should be required.

-Guodong 
Reply all
Reply to author
Forward
0 new messages