llvmpipe: Call util_cpu_detect() from the unit tests.
authorJosé Fonseca <jfonseca@vmware.com>
Thu, 22 Oct 2009 17:10:19 +0000 (18:10 +0100)
committerJosé Fonseca <jfonseca@vmware.com>
Thu, 22 Oct 2009 18:12:13 +0000 (19:12 +0100)
src/gallium/drivers/llvmpipe/lp_test_format.c
src/gallium/drivers/llvmpipe/lp_test_main.c

index ab80c0143f9c4dcdab77f9f12cab59dfa8088956..5dc8297fe90fbec7ccd8bcbb979f1926d2cd77fb 100644 (file)
@@ -35,6 +35,7 @@
 #include <llvm-c/Target.h>
 #include <llvm-c/Transforms/Scalar.h>
 
+#include "util/u_cpu_detect.h"
 #include "util/u_format.h"
 
 #include "lp_bld_format.h"
@@ -263,6 +264,8 @@ int main(int argc, char **argv)
    LLVMInitializeNativeTarget();
 #endif
 
+   util_cpu_detect();
+
    for (i = 0; i < sizeof(test_cases)/sizeof(test_cases[0]); ++i)
       if(!test_format(&test_cases[i]))
         ret = 1;
index f07fa256f16d3d4a199d525a6e699253ff54aaad..d4767ff52ba7e2084523c66b53bbddd9b59a976c 100644 (file)
@@ -34,6 +34,8 @@
  */
 
 
+#include "util/u_cpu_detect.h"
+
 #include "lp_bld_const.h"
 #include "lp_test.h"
 
@@ -370,6 +372,8 @@ int main(int argc, char **argv)
    LLVMInitializeNativeTarget();
 #endif
 
+   util_cpu_detect();
+
    if(fp) {
       /* Warm up the caches */
       test_some(0, NULL, 100);