projects
/
mesa.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
llvmpipe: get rid of barycentric calculation of a0
[mesa.git]
/
src
/
gallium
/
drivers
/
llvmpipe
/
lp_test_main.c
diff --git
a/src/gallium/drivers/llvmpipe/lp_test_main.c
b/src/gallium/drivers/llvmpipe/lp_test_main.c
index 149ee6f1256a4e9dca3c4144d8361fabeab0c8d7..8a896becf5346843e73709adf97eeaad61537460 100644
(file)
--- a/
src/gallium/drivers/llvmpipe/lp_test_main.c
+++ b/
src/gallium/drivers/llvmpipe/lp_test_main.c
@@
-35,24
+35,14
@@
#include "util/u_cpu_detect.h"
#include "util/u_cpu_detect.h"
+#include "util/u_math.h"
#include "gallivm/lp_bld_const.h"
#include "gallivm/lp_bld_init.h"
#include "gallivm/lp_bld_const.h"
#include "gallivm/lp_bld_init.h"
+#include "gallivm/lp_bld_debug.h"
#include "lp_test.h"
#include "lp_test.h"
-#ifdef PIPE_CC_MSVC
-static INLINE double
-round(double x)
-{
- if (x >= 0.0)
- return floor(x + 0.5);
- else
- return ceil(x - 0.5);
-}
-#endif
-
-
void
dump_type(FILE *fp,
struct lp_type type)
void
dump_type(FILE *fp,
struct lp_type type)
@@
-380,7
+370,11
@@
int main(int argc, char **argv)
unsigned i;
boolean success;
boolean single = FALSE;
unsigned i;
boolean success;
boolean single = FALSE;
- struct gallivm_state *gallivm;
+ unsigned fpstate;
+
+ util_cpu_detect();
+ fpstate = util_fpstate_get();
+ util_fpstate_set_denorms_to_zero(fpstate);
for(i = 1; i < argc; ++i) {
if(strcmp(argv[i], "-v") == 0)
for(i = 1; i < argc; ++i) {
if(strcmp(argv[i], "-v") == 0)
@@
-395,23
+389,28
@@
int main(int argc, char **argv)
lp_build_init();
lp_build_init();
- gallivm = gallivm_create();
+#ifdef DEBUG
+ if (verbose >= 2) {
+ gallivm_debug |= GALLIVM_DEBUG_IR;
+ gallivm_debug |= GALLIVM_DEBUG_ASM;
+ }
+#endif
util_cpu_detect();
if(fp) {
/* Warm up the caches */
util_cpu_detect();
if(fp) {
/* Warm up the caches */
- test_some(
gallivm,
0, NULL, 100);
+ test_some(0, NULL, 100);
write_tsv_header(fp);
}
if (single)
write_tsv_header(fp);
}
if (single)
- success = test_single(
gallivm,
verbose, fp);
+ success = test_single(verbose, fp);
else if (n)
else if (n)
- success = test_some(
gallivm,
verbose, fp, n);
+ success = test_some(verbose, fp, n);
else
else
- success = test_all(
gallivm,
verbose, fp);
+ success = test_all(verbose, fp);
if(fp)
fclose(fp);
if(fp)
fclose(fp);