gallium: Drop unused X2D opcode.
[mesa.git] / src / gallium / auxiliary / gallivm / lp_bld_tgsi.c
index 495940caf804b48c91db2efe0d987d3b92a7ceea..c5d36793b21b7fcc41d8353c9e11d48034fd2cc8 100644 (file)
@@ -3,7 +3,7 @@
  * Copyright 2011-2012 Advanced Micro Devices, Inc.
  * Copyright 2010 VMware, Inc.
  * Copyright 2009 VMware, Inc.
- * Copyright 2007-2008 Tungsten Graphics, Inc., Cedar Park, Texas.
+ * Copyright 2007-2008 VMware, Inc.
  * All Rights Reserved.
  *
  * Permission is hereby granted, free of charge, to any person obtaining a
@@ -54,7 +54,7 @@ unsigned lp_bld_tgsi_list_init(struct lp_build_tgsi_context * bld_base)
 
 unsigned lp_bld_tgsi_add_instruction(
    struct lp_build_tgsi_context * bld_base,
-   struct tgsi_full_instruction *inst_to_add)
+   const struct tgsi_full_instruction *inst_to_add)
 {
 
    if (bld_base->num_instructions == bld_base->max_instructions) {
@@ -200,16 +200,17 @@ lp_build_tgsi_inst_llvm(
 
    bld_base->pc++;
 
+   if (bld_base->emit_debug) {
+      bld_base->emit_debug(bld_base, inst, info);
+   }
+
    /* Ignore deprecated instructions */
    switch (inst->Instruction.Opcode) {
 
-   case TGSI_OPCODE_RCC:
    case TGSI_OPCODE_UP2H:
    case TGSI_OPCODE_UP2US:
    case TGSI_OPCODE_UP4B:
    case TGSI_OPCODE_UP4UB:
-   case TGSI_OPCODE_X2D:
-   case TGSI_OPCODE_ARA:
    case TGSI_OPCODE_BRA:
    case TGSI_OPCODE_PUSHA:
    case TGSI_OPCODE_POPA:
@@ -465,8 +466,8 @@ lp_build_tgsi_llvm(
    }
 
    while (bld_base->pc != -1) {
-      struct tgsi_full_instruction *instr = bld_base->instructions +
-                                                       bld_base->pc;
+      const struct tgsi_full_instruction *instr =
+         bld_base->instructions + bld_base->pc;
       const struct tgsi_opcode_info *opcode_info =
          tgsi_get_opcode_info(instr->Instruction.Opcode);
       if (!lp_build_tgsi_inst_llvm(bld_base, instr)) {