From 709942e69dde948e5f52fe3cfbaac3b9038904ca Mon Sep 17 00:00:00 2001 From: Falco Girgis Date: Tue, 30 Jan 2024 19:40:40 -0600 Subject: [PATCH] test. --- GL/platforms/sh4.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/GL/platforms/sh4.c b/GL/platforms/sh4.c index acaf692..6fa971c 100644 --- a/GL/platforms/sh4.c +++ b/GL/platforms/sh4.c @@ -1,6 +1,8 @@ #include "../platform.h" #include "sh4.h" +#include + #define CLIP_DEBUG 0 @@ -85,14 +87,12 @@ volatile uint32_t *sq = SQ_BASE_ADDRESS; static inline void _glFlushBuffer() { TRACE(); - /* Wait for both store queues to complete */ - sq = (uint32_t*) 0xe0000000; - sq[0] = sq[8] = 0; + sq_wait(); } static inline void _glPushHeaderOrVertex(Vertex* v) { TRACE(); - +#if 0 uint32_t* s = (uint32_t*) v; sq[0] = *(s++); sq[1] = *(s++); @@ -104,6 +104,8 @@ static inline void _glPushHeaderOrVertex(Vertex* v) { sq[7] = *(s++); __asm__("pref @%0" : : "r"(sq)); sq += 8; +#endif + pvr_sq_load(NULL, v, sizeof(Vertex), PVR_TA_INPUT); } static inline void _glClipEdge(const Vertex* const v1, const Vertex* const v2, Vertex* vout) {