mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 00:58:05 +02:00
Move COPY_FLOAT() macro down into glide driver.
Rewrite COPY_4FV() macro to not use COPY_FLOAT(), and use integer moves as originally intended.
This commit is contained in:
parent
5374e4ba7e
commit
8850a7e20f
3 changed files with 16 additions and 16 deletions
|
|
@ -60,6 +60,8 @@
|
|||
#include "math/m_vector.h"
|
||||
|
||||
|
||||
#define COPY_FLOAT(dst, src) (dst) = (src)
|
||||
|
||||
/* Define some shorter names for these things.
|
||||
*/
|
||||
#define XCOORD GR_VERTEX_X_OFFSET
|
||||
|
|
|
|||
|
|
@ -494,12 +494,6 @@ static INLINE int iceil(float f)
|
|||
#endif
|
||||
|
||||
|
||||
/***
|
||||
*** COPY_FLOAT: copy a float from src to dest.
|
||||
***/
|
||||
#define COPY_FLOAT( dst, src ) (dst) = (src)
|
||||
|
||||
|
||||
/***
|
||||
*** START_FAST_MATH: Set x86 FPU to faster, 32-bit precision mode (and save
|
||||
*** original mode to a temporary).
|
||||
|
|
|
|||
|
|
@ -5,9 +5,9 @@
|
|||
|
||||
/*
|
||||
* Mesa 3-D graphics library
|
||||
* Version: 6.0
|
||||
* Version: 6.5
|
||||
*
|
||||
* Copyright (C) 1999-2004 Brian Paul All Rights Reserved.
|
||||
* Copyright (C) 1999-2005 Brian Paul All Rights Reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and associated documentation files (the "Software"),
|
||||
|
|
@ -176,16 +176,20 @@ do { \
|
|||
} while (0)
|
||||
#endif
|
||||
|
||||
/** Copy a 4-element float vector (Use COPY_FLOAT to avoid loading FPU) */
|
||||
#define COPY_4FV( DST, SRC ) \
|
||||
do { \
|
||||
COPY_FLOAT((DST)[0], (SRC)[0]); \
|
||||
COPY_FLOAT((DST)[1], (SRC)[1]); \
|
||||
COPY_FLOAT((DST)[2], (SRC)[2]); \
|
||||
COPY_FLOAT((DST)[3], (SRC)[3]); \
|
||||
/**
|
||||
* Copy a 4-element float vector (avoid using FPU registers)
|
||||
* XXX Could use two 64-bit moves on 64-bit systems
|
||||
*/
|
||||
#define COPY_4FV( DST, SRC ) \
|
||||
do { \
|
||||
const GLuint *_s = (const GLuint *) (SRC); \
|
||||
GLuint *_d = (GLuint *) (DST); \
|
||||
_d[0] = _s[0]; \
|
||||
_d[1] = _s[1]; \
|
||||
_d[2] = _s[2]; \
|
||||
_d[3] = _s[3]; \
|
||||
} while (0)
|
||||
|
||||
|
||||
/** Copy \p SZ elements into a 4-element vector */
|
||||
#define COPY_SZ_4V(DST, SZ, SRC) \
|
||||
do { \
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue