r600g: disable handling of DISCARD_RANGE
[mesa.git] / src / gallium / drivers / r600 / r700_asm.c
index a7f2f54736e9f39d25cacfe5b86de421d2e39de5..ffa179fbf828216b79c1885cec70c3a58cff272e 100644 (file)
  * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
  * USE OR OTHER DEALINGS IN THE SOFTWARE.
  */
-#include <stdio.h>
-#include "util/u_memory.h"
-#include "r600_pipe.h"
 #include "r600_asm.h"
 #include "r700_sq.h"
 
+void r700_bytecode_cf_vtx_build(uint32_t *bytecode, const struct r600_bytecode_cf *cf)
+{
+       unsigned count = (cf->ndw / 4) - 1;
+       *bytecode++ = S_SQ_CF_WORD0_ADDR(cf->addr >> 1);
+       *bytecode++ = cf->inst |
+                       S_SQ_CF_WORD1_BARRIER(1) |
+                       S_SQ_CF_WORD1_COUNT(count) |
+                       S_SQ_CF_WORD1_COUNT_3(count >> 3);
+}
 
-int r700_bc_alu_build(struct r600_bc *bc, struct r600_bc_alu *alu, unsigned id)
+int r700_bytecode_alu_build(struct r600_bytecode *bc, struct r600_bytecode_alu *alu, unsigned id)
 {
        bc->bytecode[id++] = S_SQ_ALU_WORD0_SRC0_SEL(alu->src[0].sel) |
                S_SQ_ALU_WORD0_SRC0_REL(alu->src[0].rel) |