From: eihrul Date: Tue, 5 Apr 2011 08:57:38 +0000 (+0000) Subject: workaround for missing _mm_cvtss_f32 on some gcc versionsx X-Git-Tag: xonotic-v0.6.0~163^2~522 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=bd2caa413b94d2804f524b891e66be1aef4f6dcd;p=xonotic%2Fdarkplaces.git workaround for missing _mm_cvtss_f32 on some gcc versionsx git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@11024 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/dpsoftrast.c b/dpsoftrast.c index 4f7fbf34..ae48e8cd 100644 --- a/dpsoftrast.c +++ b/dpsoftrast.c @@ -73,6 +73,10 @@ typedef qboolean bool; #ifdef SSE_POSSIBLE #include +#if defined(__GNUC__) && (__GNUC < 4 || __GNUC_MINOR__ < 6) + #define _mm_cvtss_f32(val) (__builtin_ia32_vec_ext_v4sf ((__v4sf)(val), 0)) +#endif + #define MM_MALLOC(size) _mm_malloc(size, ATOMIC_SIZE) static void *MM_CALLOC(size_t nmemb, size_t size)