Building volk in MinGW

I try to build volk in MinGW and find the following issues:

  1. config.sub and config.guess are corrupt. They seems to be corrupted
    symlinks. This can be corrected by copying from top level directory.
  2. The following files lead to compile error with undeclared clock_t
    etc.
    qa_32f_add_aligned16.cc
    qa_32f_divide_aligned16.cc
    qa_32f_multiply_aligned16.cc
    qa_32f_sqrt_aligned16.cc
    qa_16sc_magnitude_32f_aligned16.cc
    This can be fixed by #include

After these changes, make succeeded.
make check does nothing, so I have not checked the functionality.
I think I will study the usage of the volk library later.

Kyle

On Thu, Dec 16, 2010 at 7:14 PM, Kyle Z. [email protected] wrote:

After these changes, make succeeded.
make check does nothing, so I have not checked the functionality.
I think I will study the usage of the volk library later.

Kyle

Thanks, Kyle, that’s helpful. I’ll make the ctime fix now and look
into the config.sub and config.guess issues.

If you want to run a test, in volk/lib/test_all. This is what is
normally run by make check, but I have disabled it for speed. The
checks take a while to complete.

Tom

On Thu, Dec 16, 2010 at 9:21 PM, Kyle Z. [email protected] wrote:

qa_32f_multiply_aligned16.cc
Thanks, Kyle, that’s helpful. I’ll make the ctime fix now and look
/usr/share/automake-1.11/config.sub/guess
But obviously those do not exist in MinGW.
That is why in ubuntu there is no problem. But failed in MinGW.

You’re right. That was a silly thing to do.

I just pushed an update to next with all of these fixed. Please let me
know if you run across anything else.

.sse not available… no test performed
Kyle
Don’t know what to say about this one yet. Just more evidence that I
really need to get a Windows and OSX machine to test with.

Thanks again.

Tom

On 17/12/2010 1:01 PM, Tom R. wrote:

This can be fixed by #include
If you want to run a test, in volk/lib/test_all. This is what is
normally run by make check, but I have disabled it for speed. The
checks take a while to complete.

Tom

I found config.sub and config.guess are symlink to
/usr/share/automake-1.11/config.sub/guess
But obviously those do not exist in MinGW.
That is why in ubuntu there is no problem. But failed in MinGW.

I run test_all but without success.
What I got is:

.sse2 not available… no test performed
.sse3 not available… no test performed
.sse3 not available… no test performed
.sse3 not available… no test performed
.sse3 not available… no test performed
.sse3 not available… no test performed
.sse not available… no test performed
.sse not available… no test performed
.sse2 not available… no test performed
.ssse3 not available… no test performed
.ssse3 not available… no test performed
.ssse3 not available… no test performed
.sse2 not available… no test performed
.32f_add_aligned

after that a Windows popup message is up asking if report problem to MS.
It seems to be some exception raised.
I have no experience in cppunit so really no idea what is happening.
Kyle

.sse not available… no test performed
Kyle

Don’t know what to say about this one yet. Just more evidence that I
really need to get a Windows and OSX machine to test with.

Thanks again.

Tom

After some looking into the codes, I have the following findings.

all qa_* code include <volk/volk.h>, which in turn includes
<volk/volk_config.h>
However, volk_config.h has the following:

#undef LV_HAVE_GENERIC
#undef LV_HAVE_ALTIVEC
#undef LV_HAVE_32
#undef LV_HAVE_64
#undef LV_HAVE_3DNOW
#undef LV_HAVE_ABM
#undef LV_HAVE_POPCOUNT
#undef LV_HAVE_MMX
#undef LV_HAVE_SSE
#undef LV_HAVE_SSE2
#undef LV_HAVE_SSE3
#undef LV_HAVE_SSSE3
#undef LV_HAVE_SSE4_A
#undef LV_HAVE_SSE4_1
#undef LV_HAVE_SSE4_2
#undef LV_HAVE_AVX

So everything is undefined.
This means configure does not change anything to volk_config.h.in

However, I have a look at config.h, which shows correct settings

/* 32 flag set */
#define LV_HAVE_32 1

/* 3dnow flag set /
/
#undef LV_HAVE_3DNOW */

/* 64 flag set /
/
#undef LV_HAVE_64 */

/* abm flag set /
/
#undef LV_HAVE_ABM */

/* altivec flag set /
/
#undef LV_HAVE_ALTIVEC */

/* avx flag set /
/
#undef LV_HAVE_AVX */

/* generic flag set */
#define LV_HAVE_GENERIC 1

/* mmx flag set */
#define LV_HAVE_MMX 1

/* popcount flag set /
/
#undef LV_HAVE_POPCOUNT */

/* sse flag set */
#define LV_HAVE_SSE 1

/* sse2 flag set */
#define LV_HAVE_SSE2 1

/* sse3 flag set */
#define LV_HAVE_SSE3 1

/* sse4_1 flag set /
/
#undef LV_HAVE_SSE4_1 */

/* sse4_2 flag set /
/
#undef LV_HAVE_SSE4_2 */

/* sse4_a flag set /
/
#undef LV_HAVE_SSE4_A */

/* ssse3 flag set */
#define LV_HAVE_SSSE3 1

This is strange since configure has done correct testing on SSE support
but just does not produce volk_config.h correctly.

Kyle