Hi,

I recently stumbled on an issue where dvec.h gets included from intrin.h
and triggers around 140 different "not declared in this scope" errors.

Basically, there is an #include <dvec.h> (which is a C++-only header)
near the top of intrin.h and the function declarations for non-SSE2
bulds come later on (I guess that if SSE2 is used, the compiler already
has declarations for them?). Since dvec.h uses functions which are
declared later on, compilation errors out.


Jacek told me over IRC that dvec/fvec/ivec .h probably shouldn't be
included from intrin.h. I've tried remove them and my build issues went
away.
Should that change be commited? Should it also be backported to the
stable branch?

Jacek was also concerned about breakage of current code. I believe the
change is safe because there are probably few C++ codes around which
rely on the automatic inclusion of dvec (which would not work in many
cases anyway). I also believe that the authors of code which use these
headers will also prefer that we don't add a possibly ugly workaround
which would have to remain forever.


Also, I had tried something to fix the issue: move the #include <dvec.h>
to the bottom of intrin.h and, while fairly ugly, this fixed most of the
errors. The remaining errors[1] are because the declarations have been
commented-out in intrin.h but their use in dvec.h hasn't.
I can see two solutions:
- comment them out too in dvec.h, but then there should also be a way to
  test at compile-time for when these functions are available or not.
- uncomment the in intrin.h but if I've understood correctly, there's a
  concern they're not correct currently.


[1] _mm_shuffle_pd, _mm_slli_epi16, _mm_slli_epi32, _mm_slli_epi64,
_mm_srai_epi16, _mm_srai_epi32, _mm_srli_epi16, _mm_srli_epi32,
_mm_srli_epi64

PS: I will be away for a few days and will not be able to read or write
mails.

-- 
Adrien Nader

------------------------------------------------------------------------------
Android apps run on BlackBerry 10
Introducing the new BlackBerry 10.2.1 Runtime for Android apps.
Now with support for Jelly Bean, Bluetooth, Mapview and more.
Get your Android app in front of a whole new audience.  Start now.
http://pubads.g.doubleclick.net/gampad/clk?id=124407151&iu=/4140/ostg.clktrk
_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to