summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r--src/mesa/drivers/dri/common/utils.c30
1 files changed, 27 insertions, 3 deletions
diff --git a/src/mesa/drivers/dri/common/utils.c b/src/mesa/drivers/dri/common/utils.c
index 59401073ece..0e8e54a2028 100644
--- a/src/mesa/drivers/dri/common/utils.c
+++ b/src/mesa/drivers/dri/common/utils.c
@@ -20,11 +20,14 @@
* DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
* OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
* USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/**
+ * \file utils.c
+ * Utility functions for DRI drivers.
*
- * Authors:
- * Ian Romanick <[email protected]>
+ * \author Ian Romanick <[email protected]>
*/
-/* $XFree86:$ */
#include <string.h>
#include <stdlib.h>
@@ -40,6 +43,10 @@
#include "x86/common_x86_asm.h"
#endif
+#if defined(USE_PPC_ASM)
+#include "ppc/common_ppc_features.h"
+#endif
+
unsigned
driParseDebugString( const char * debug,
const struct dri_debug_control * control )
@@ -141,6 +148,23 @@ driGetRendererString( char * buffer, const char * hardware_name,
cpu[0] = " SPARC";
next = 1;
+#elif defined(USE_PPC_ASM)
+ if ( _mesa_ppc_cpu_features ) {
+ cpu[next] = (cpu_has_64) ? " PowerPC 64" : " PowerPC";
+ next++;
+ }
+
+# ifdef USE_VMX_ASM
+ if ( cpu_has_vmx ) {
+ cpu[next] = "/Altivec";
+ next++;
+ }
+# endif
+
+ if ( ! cpu_has_fpu ) {
+ cpu[next] = "/No FPU";
+ next++;
+ }
#endif
for ( i = 0 ; i < next ; i++ ) {