treewide: s/comparitor/comparator/
authorIlia Mirkin <imirkin@alum.mit.edu>
Mon, 12 Dec 2016 13:32:38 +0000 (08:32 -0500)
committerIlia Mirkin <imirkin@alum.mit.edu>
Tue, 13 Dec 2016 03:13:07 +0000 (22:13 -0500)
git grep -l comparitor | xargs sed -i 's/comparitor/comparator/g'

Just happened to notice this in a patch that was sent and included one
of the tokens in question.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Acked-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
31 files changed:
src/amd/common/ac_nir_to_llvm.c
src/compiler/glsl/builtin_functions.cpp
src/compiler/glsl/glsl_to_nir.cpp
src/compiler/glsl/ir.h
src/compiler/glsl/ir_clone.cpp
src/compiler/glsl/ir_equals.cpp
src/compiler/glsl/ir_hv_accept.cpp
src/compiler/glsl/ir_print_visitor.cpp
src/compiler/glsl/ir_reader.cpp
src/compiler/glsl/ir_rvalue_visitor.cpp
src/compiler/glsl/lower_texture_projection.cpp
src/compiler/glsl/opt_tree_grafting.cpp
src/compiler/glsl_types.h
src/compiler/nir/nir.h
src/compiler/nir/nir_lower_tex.c
src/compiler/nir/nir_print.c
src/compiler/spirv/spirv_to_nir.c
src/gallium/auxiliary/nir/tgsi_to_nir.c
src/gallium/drivers/freedreno/ir3/ir3_compiler_nir.c
src/gallium/drivers/vc4/vc4_program.c
src/mesa/drivers/dri/i965/brw_defines.h
src/mesa/drivers/dri/i965/brw_fs.cpp
src/mesa/drivers/dri/i965/brw_fs_nir.cpp
src/mesa/drivers/dri/i965/brw_lower_texture_gradients.cpp
src/mesa/drivers/dri/i965/brw_vec4.h
src/mesa/drivers/dri/i965/brw_vec4_nir.cpp
src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
src/mesa/main/ff_fragment_shader.cpp
src/mesa/program/ir_to_mesa.cpp
src/mesa/program/prog_to_nir.c
src/mesa/state_tracker/st_glsl_to_tgsi.cpp

index 398db6ace37e37c01230107b398db66ed85cef50..d66fefbe954bebda267a68c03fe8f29845a95dea 100644 (file)
@@ -3418,7 +3418,7 @@ static void visit_tex(struct nir_to_llvm_context *ctx, nir_tex_instr *instr)
        unsigned dmask = 0xf;
        LLVMValueRef address[16];
        LLVMValueRef coords[5];
-       LLVMValueRef coord = NULL, lod = NULL, comparitor = NULL;
+       LLVMValueRef coord = NULL, lod = NULL, comparator = NULL;
        LLVMValueRef bias = NULL, offsets = NULL;
        LLVMValueRef res_ptr, samp_ptr, fmask_ptr = NULL, sample_index = NULL;
        LLVMValueRef ddx = NULL, ddy = NULL;
@@ -3435,8 +3435,8 @@ static void visit_tex(struct nir_to_llvm_context *ctx, nir_tex_instr *instr)
                        break;
                case nir_tex_src_projector:
                        break;
-               case nir_tex_src_comparitor:
-                       comparitor = get_src(ctx, instr->src[i].src);
+               case nir_tex_src_comparator:
+                       comparator = get_src(ctx, instr->src[i].src);
                        break;
                case nir_tex_src_offset:
                        offsets = get_src(ctx, instr->src[i].src);
@@ -3521,8 +3521,8 @@ static void visit_tex(struct nir_to_llvm_context *ctx, nir_tex_instr *instr)
        }
 
        /* Pack depth comparison value */
-       if (instr->is_shadow && comparitor) {
-               address[count++] = llvm_extract_elem(ctx, comparitor, 0);
+       if (instr->is_shadow && comparator) {
+               address[count++] = llvm_extract_elem(ctx, comparator, 0);
        }
 
        /* pack derivatives */
index 17f03a3fa27551a895d7abdc87b343e116f0925e..797af08b6c6bfe51997315a4bfe2023c136542c1 100644 (file)
@@ -1697,7 +1697,7 @@ builtin_builder::create_builtins()
                 _texture(ir_tex, v130, glsl_type::float_type, glsl_type::sampler1DArrayShadow_type, glsl_type::vec3_type),
                 _texture(ir_tex, v130, glsl_type::float_type, glsl_type::sampler2DArrayShadow_type, glsl_type::vec4_type),
                 /* samplerCubeArrayShadow is special; it has an extra parameter
-                 * for the shadow comparitor since there is no vec5 type.
+                 * for the shadow comparator since there is no vec5 type.
                  */
                 _textureCubeArrayShadow(),
 
@@ -4659,7 +4659,7 @@ builtin_builder::_texture(ir_texture_opcode opcode,
    if (coord_size == coord_type->vector_elements) {
       tex->coordinate = var_ref(P);
    } else {
-      /* The incoming coordinate also has the projector or shadow comparitor,
+      /* The incoming coordinate also has the projector or shadow comparator,
        * so we need to swizzle those away.
        */
       tex->coordinate = swizzle_for_size(P, coord_size);
@@ -4676,12 +4676,12 @@ builtin_builder::_texture(ir_texture_opcode opcode,
           */
          ir_variable *refz = in_var(glsl_type::float_type, "refz");
          sig->parameters.push_tail(refz);
-         tex->shadow_comparitor = var_ref(refz);
+         tex->shadow_comparator = var_ref(refz);
       } else {
-         /* The shadow comparitor is normally in the Z component, but a few types
+         /* The shadow comparator is normally in the Z component, but a few types
           * have sufficiently large coordinates that it's in W.
           */
-         tex->shadow_comparitor = swizzle(P, MAX2(coord_size, SWIZZLE_Z), 1);
+         tex->shadow_comparator = swizzle(P, MAX2(coord_size, SWIZZLE_Z), 1);
       }
    }
 
@@ -4754,7 +4754,7 @@ builtin_builder::_textureCubeArrayShadow()
    tex->set_sampler(var_ref(s), glsl_type::float_type);
 
    tex->coordinate = var_ref(P);
-   tex->shadow_comparitor = var_ref(compare);
+   tex->shadow_comparator = var_ref(compare);
 
    body.emit(ret(tex));
 
index 18a53b607e6e76d996fe30c37bb08e9fda65d944..fcaca9f8b6c006d32afb0141b3b8da8e4184873d 100644 (file)
@@ -1898,7 +1898,7 @@ nir_visitor::visit(ir_texture *ir)
 
    if (ir->projector != NULL)
       num_srcs++;
-   if (ir->shadow_comparitor != NULL)
+   if (ir->shadow_comparator != NULL)
       num_srcs++;
    if (ir->offset != NULL)
       num_srcs++;
@@ -1946,10 +1946,10 @@ nir_visitor::visit(ir_texture *ir)
       src_number++;
    }
 
-   if (ir->shadow_comparitor != NULL) {
+   if (ir->shadow_comparator != NULL) {
       instr->src[src_number].src =
-         nir_src_for_ssa(evaluate_rvalue(ir->shadow_comparitor));
-      instr->src[src_number].src_type = nir_tex_src_comparitor;
+         nir_src_for_ssa(evaluate_rvalue(ir->shadow_comparator));
+      instr->src[src_number].src_type = nir_tex_src_comparator;
       src_number++;
    }
 
index df3ccfd883f4861058c25858027910f2d37b13a3..a11dccd2e9bf94476c1d3cea652bf30d93c59d8b 100644 (file)
@@ -1787,7 +1787,7 @@ enum ir_texture_opcode {
  *
  *                                    Texel offset (0 or an expression)
  *                                    | Projection divisor
- *                                    | |  Shadow comparitor
+ *                                    | |  Shadow comparator
  *                                    | |  |
  *                                    v v  v
  * (tex <type> <sampler> <coordinate> 0 1 ( ))
@@ -1808,7 +1808,7 @@ public:
    ir_texture(enum ir_texture_opcode op)
       : ir_rvalue(ir_type_texture),
         op(op), sampler(NULL), coordinate(NULL), projector(NULL),
-        shadow_comparitor(NULL), offset(NULL)
+        shadow_comparator(NULL), offset(NULL)
    {
       memset(&lod_info, 0, sizeof(lod_info));
    }
@@ -1863,7 +1863,7 @@ public:
     * If there is no shadow comparison, this will be \c NULL.  For the
     * \c ir_txf opcode, this *must* be \c NULL.
     */
-   ir_rvalue *shadow_comparitor;
+   ir_rvalue *shadow_comparator;
 
    /** Texel offset. */
    ir_rvalue *offset;
index 0e50084d6173cc9bd11410fe38e528db91c4f881..062ea23a830ef1dc60b29b1c743e2bd8fb28ec65 100644 (file)
@@ -209,8 +209,8 @@ ir_texture::clone(void *mem_ctx, struct hash_table *ht) const
       new_tex->coordinate = this->coordinate->clone(mem_ctx, ht);
    if (this->projector)
       new_tex->projector = this->projector->clone(mem_ctx, ht);
-   if (this->shadow_comparitor) {
-      new_tex->shadow_comparitor = this->shadow_comparitor->clone(mem_ctx, ht);
+   if (this->shadow_comparator) {
+      new_tex->shadow_comparator = this->shadow_comparator->clone(mem_ctx, ht);
    }
 
    if (this->offset != NULL)
index b86f4ea16bb1545b08df585aff0ebf1accfad8e2..58b08d445b99a2a16f38238fcceb6a68b7d108e6 100644 (file)
@@ -143,7 +143,7 @@ ir_texture::equals(const ir_instruction *ir, enum ir_node_type ignore) const
    if (!possibly_null_equals(projector, other->projector, ignore))
       return false;
 
-   if (!possibly_null_equals(shadow_comparitor, other->shadow_comparitor, ignore))
+   if (!possibly_null_equals(shadow_comparator, other->shadow_comparator, ignore))
       return false;
 
    if (!possibly_null_equals(offset, other->offset, ignore))
index 5cc6a346fa4ad35cf63867a5c3f59835ebc545c3..7bbc2163d30cf76d96a116833704590c1b23f36c 100644 (file)
@@ -178,8 +178,8 @@ ir_texture::accept(ir_hierarchical_visitor *v)
         return (s == visit_continue_with_parent) ? visit_continue : s;
    }
 
-   if (this->shadow_comparitor) {
-      s = this->shadow_comparitor->accept(v);
+   if (this->shadow_comparator) {
+      s = this->shadow_comparator->accept(v);
       if (s != visit_continue)
         return (s == visit_continue_with_parent) ? visit_continue : s;
    }
index d4014265ef3810d28be7f30cafae2633f7db346e..7d367038c4c7ceb2263fd47ef87fbc042c268634 100644 (file)
@@ -324,9 +324,9 @@ void ir_print_visitor::visit(ir_texture *ir)
       else
         fprintf(f, "1");
 
-      if (ir->shadow_comparitor) {
+      if (ir->shadow_comparator) {
         fprintf(f, " ");
-        ir->shadow_comparitor->accept(this);
+        ir->shadow_comparator->accept(this);
       } else {
         fprintf(f, " ()");
       }
index d67d1436a4e8a7bd25d9b2910ece2dc47cfe1eae..6d3d04817797926d3f972c73e5653f35cd3181fa 100644 (file)
@@ -1047,11 +1047,11 @@ ir_reader::read_texture(s_expression *expr)
       }
 
       if (s_shadow->subexpressions.is_empty()) {
-        tex->shadow_comparitor = NULL;
+        tex->shadow_comparator = NULL;
       } else {
-        tex->shadow_comparitor = read_rvalue(s_shadow);
-        if (tex->shadow_comparitor == NULL) {
-           ir_read_error(NULL, "when reading shadow comparitor in (%s ..)",
+        tex->shadow_comparator = read_rvalue(s_shadow);
+        if (tex->shadow_comparator == NULL) {
+           ir_read_error(NULL, "when reading shadow comparator in (%s ..)",
                          tex->opcode_string());
            return NULL;
         }
index addcc683df0e487f8c8beb0353a98d0006fcb43a..d052606f4db5ddd6df31d3213ec1b195a853578b 100644 (file)
@@ -51,7 +51,7 @@ ir_rvalue_base_visitor::rvalue_visit(ir_texture *ir)
 {
    handle_rvalue(&ir->coordinate);
    handle_rvalue(&ir->projector);
-   handle_rvalue(&ir->shadow_comparitor);
+   handle_rvalue(&ir->shadow_comparator);
    handle_rvalue(&ir->offset);
 
    switch (ir->op) {
index 95df106d93f53449f59a9b6f4c07d72bf69d213c..698e5b36617321de2ad98b2c6695e1038640dd0e 100644 (file)
@@ -78,11 +78,11 @@ lower_texture_projection_visitor::visit_leave(ir_texture *ir)
                                               ir->coordinate,
                                               deref);
 
-   if (ir->shadow_comparitor) {
+   if (ir->shadow_comparator) {
       deref = new(mem_ctx) ir_dereference_variable(var);
-      ir->shadow_comparitor = new(mem_ctx) ir_expression(ir_binop_mul,
-                                                 ir->shadow_comparitor->type,
-                                                 ir->shadow_comparitor,
+      ir->shadow_comparator = new(mem_ctx) ir_expression(ir_binop_mul,
+                                                 ir->shadow_comparator->type,
+                                                 ir->shadow_comparator,
                                                  deref);
    }
 
index a40e5f716098b8c8964739addc2ee50bae2f894d..28b6e1856e8bd605d30f33532be729987fe57933 100644 (file)
@@ -267,7 +267,7 @@ ir_tree_grafting_visitor::visit_enter(ir_texture *ir)
    if (do_graft(&ir->coordinate) ||
        do_graft(&ir->projector) ||
        do_graft(&ir->offset) ||
-       do_graft(&ir->shadow_comparitor))
+       do_graft(&ir->shadow_comparator))
         return visit_stop;
 
    switch (ir->op) {
index bb223cfde963226d9a24ee15eae0c6268e2c2f0c..508cf5213642eab8f9ab0088d2a453de8038dfe3 100644 (file)
@@ -752,7 +752,7 @@ struct glsl_type {
     *
     * Note that this is often different than actual coordinate type used in
     * a texturing built-in function, since those pack additional values (such
-    * as the shadow comparitor or projector) into the coordinate type.
+    * as the shadow comparator or projector) into the coordinate type.
     */
    int coordinate_components() const;
 
index 544d4baddb05c180b92c09bd2f1a3112c4d64657..3040cbd2c36f3e93de47a0e26b4c7671dad290fe 100644 (file)
@@ -1065,7 +1065,7 @@ INTRINSIC_IDX_ACCESSORS(interp_mode, INTERP_MODE, unsigned)
 typedef enum {
    nir_tex_src_coord,
    nir_tex_src_projector,
-   nir_tex_src_comparitor, /* shadow comparitor */
+   nir_tex_src_comparator, /* shadow comparator */
    nir_tex_src_offset,
    nir_tex_src_bias,
    nir_tex_src_lod,
@@ -1263,7 +1263,7 @@ nir_tex_instr_src_type(nir_tex_instr *instr, unsigned src)
       }
 
    case nir_tex_src_projector:
-   case nir_tex_src_comparitor:
+   case nir_tex_src_comparator:
    case nir_tex_src_bias:
    case nir_tex_src_ddx:
    case nir_tex_src_ddy:
index 0efd4434f85959b74adfaa2896f70a5dbccbfa08..39f7af7c5822f3fc21156a5e2eb4c10ff6798442 100644 (file)
@@ -55,7 +55,7 @@ project_src(nir_builder *b, nir_tex_instr *tex)
    for (unsigned i = 0; i < tex->num_srcs; i++) {
       switch (tex->src[i].src_type) {
       case nir_tex_src_coord:
-      case nir_tex_src_comparitor:
+      case nir_tex_src_comparator:
          break;
       default:
          continue;
index e51b6f5369183533e40edee666caffb36cfb8c27..8a3d734669a611c0c8a8a30da19a68abf9a73b80 100644 (file)
@@ -707,8 +707,8 @@ print_tex_instr(nir_tex_instr *instr, print_state *state)
       case nir_tex_src_projector:
          fprintf(fp, "(projector)");
          break;
-      case nir_tex_src_comparitor:
-         fprintf(fp, "(comparitor)");
+      case nir_tex_src_comparator:
+         fprintf(fp, "(comparator)");
          break;
       case nir_tex_src_offset:
          fprintf(fp, "(offset)");
index f60c6e653ec4d5a48521c3f9b6712170c7687db5..7c35b8c614fb8a6e34713f59f45f7f6a530685e0 100644 (file)
@@ -1460,7 +1460,7 @@ vtn_handle_texture(struct vtn_builder *b, SpvOp opcode,
    case SpvOpImageSampleProjDrefExplicitLod:
    case SpvOpImageDrefGather:
       /* These all have an explicit depth value as their next source */
-      (*p++) = vtn_tex_src(b, w[idx++], nir_tex_src_comparitor);
+      (*p++) = vtn_tex_src(b, w[idx++], nir_tex_src_comparator);
       break;
 
    case SpvOpImageGather:
index 3f05acde4ceff0e4ea1ba20bb682bea95ea3d88d..d01e458de4b270cbdb4fbefe2c6d0922c81819da 100644 (file)
@@ -1433,7 +1433,7 @@ ttn_tex(struct ttn_compile *c, nir_alu_dest dest, nir_ssa_def **src)
       else
          instr->src[src_number].src = nir_src_for_ssa(ttn_channel(b, src[0], Z));
 
-      instr->src[src_number].src_type = nir_tex_src_comparitor;
+      instr->src[src_number].src_type = nir_tex_src_comparator;
       src_number++;
    }
 
index 9cf6717c17db9defd5e333c9e936067428988d43..ac6840cd609f13547a8ea7e4646d72d9576c8b8e 100644 (file)
@@ -1372,7 +1372,7 @@ emit_tex(struct ir3_compile *ctx, nir_tex_instr *tex)
                        lod = get_src(ctx, &tex->src[i].src)[0];
                        has_lod = true;
                        break;
-               case nir_tex_src_comparitor: /* shadow comparator */
+               case nir_tex_src_comparator: /* shadow comparator */
                        compare = get_src(ctx, &tex->src[i].src)[0];
                        break;
                case nir_tex_src_projector:
index a7c92d577b8cbdf3e966c2942eb170981fe7bc22..611c90d7bc32d32ac3ffe199ae07794c6ba6e6e2 100644 (file)
@@ -435,7 +435,7 @@ ntq_emit_tex(struct vc4_compile *c, nir_tex_instr *instr)
                         lod = ntq_get_src(c, instr->src[i].src, 0);
                         is_txl = true;
                         break;
-                case nir_tex_src_comparitor:
+                case nir_tex_src_comparator:
                         compare = ntq_get_src(c, instr->src[i].src, 0);
                         break;
                 default:
index cae8e9ac67f4ce8bb532581848f892afbc228645..b1b6248446d5eb0712300e7c4ae255eba355827a 100644 (file)
@@ -1405,7 +1405,7 @@ enum fb_write_logical_srcs {
 enum tex_logical_srcs {
    /** Texture coordinates */
    TEX_LOGICAL_SRC_COORDINATE,
-   /** Shadow comparitor */
+   /** Shadow comparator */
    TEX_LOGICAL_SRC_SHADOW_C,
    /** dPdx if the operation takes explicit derivatives, otherwise LOD value */
    TEX_LOGICAL_SRC_LOD,
index 2bfb8a0802f9ec4f6a52f330bf81de2a3ee6ea7d..50266ad90714e9b7b45b9d5befcc7474c16484a8 100644 (file)
@@ -3833,8 +3833,8 @@ lower_sampler_logical_send_gen4(const fs_builder &bld, fs_inst *inst, opcode op,
    }
 
    if (has_lod) {
-      /* Bias/LOD with shadow comparitor is unsupported in SIMD16 -- *Without*
-       * shadow comparitor (including RESINFO) it's unsupported in SIMD8 mode.
+      /* Bias/LOD with shadow comparator is unsupported in SIMD16 -- *Without*
+       * shadow comparator (including RESINFO) it's unsupported in SIMD8 mode.
        */
       assert(shadow_c.file != BAD_FILE ? bld.dispatch_width() == 8 :
              bld.dispatch_width() == 16);
index 855266f78ac1f168e25e24b28c460fa91284bb21..bfb286bb3449972c4da9b4d580f2604e54eb8fe8 100644 (file)
@@ -4439,7 +4439,7 @@ fs_visitor::nir_emit_texture(const fs_builder &bld, nir_tex_instr *instr)
          srcs[TEX_LOGICAL_SRC_LOD] =
             retype(get_nir_src_imm(instr->src[i].src), BRW_REGISTER_TYPE_F);
          break;
-      case nir_tex_src_comparitor:
+      case nir_tex_src_comparator:
          srcs[TEX_LOGICAL_SRC_SHADOW_C] = retype(src, BRW_REGISTER_TYPE_F);
          break;
       case nir_tex_src_coord:
index 0848e1ec536b0f313f69eedf9c7ca48efc705b58..7ae69f8b7c0caa2a4c4f1751d8957414e9e14f47 100644 (file)
@@ -104,7 +104,7 @@ lower_texture_grad_visitor::visit_leave(ir_texture *ir)
    /* Only lower textureGrad with cube maps or shadow samplers */
    if (ir->op != ir_txd ||
       (ir->sampler->type->sampler_dimensionality != GLSL_SAMPLER_DIM_CUBE &&
-       !ir->shadow_comparitor))
+       !ir->shadow_comparator))
       return visit_continue;
 
    /* Lower textureGrad() with samplerCube* even if we have the sample_d_c
index dc69ea971745caee07cd79421d6c2f3fe0e43259..2c5f75e12365704dab773e13db3f93cbf2dec70d 100644 (file)
@@ -254,7 +254,7 @@ public:
                      const glsl_type *dest_type,
                      src_reg coordinate,
                      int coord_components,
-                     src_reg shadow_comparitor,
+                     src_reg shadow_comparator,
                      src_reg lod, src_reg lod2,
                      src_reg sample_index,
                      uint32_t constant_offset,
index dde07d0d141d539be44cb3d098a1597424e3938e..9a851a82108ca492192040556369f2d25d212deb 100644 (file)
@@ -1804,7 +1804,7 @@ vec4_visitor::nir_emit_texture(nir_tex_instr *instr)
    src_reg sampler_reg = brw_imm_ud(sampler);
    src_reg coordinate;
    const glsl_type *coord_type = NULL;
-   src_reg shadow_comparitor;
+   src_reg shadow_comparator;
    src_reg offset_value;
    src_reg lod, lod2;
    src_reg sample_index;
@@ -1823,8 +1823,8 @@ vec4_visitor::nir_emit_texture(nir_tex_instr *instr)
    uint32_t constant_offset = 0;
    for (unsigned i = 0; i < instr->num_srcs; i++) {
       switch (instr->src[i].src_type) {
-      case nir_tex_src_comparitor:
-         shadow_comparitor = get_nir_src(instr->src[i].src,
+      case nir_tex_src_comparator:
+         shadow_comparator = get_nir_src(instr->src[i].src,
                                          BRW_REGISTER_TYPE_F, 1);
          break;
 
@@ -1960,7 +1960,7 @@ vec4_visitor::nir_emit_texture(nir_tex_instr *instr)
    ir_texture_opcode op = ir_texture_opcode_for_nir_texop(instr->op);
 
    emit_texture(op, dest, dest_type, coordinate, instr->coord_components,
-                shadow_comparitor,
+                shadow_comparator,
                 lod, lod2, sample_index,
                 constant_offset, offset_value, mcs,
                 texture, texture_reg, sampler_reg);
index 8c7901f2d41786974646eeef45eda3eecd84ee16..c615ac0bca0417954d2c3bfc91591ec091bf96ed 100644 (file)
@@ -901,7 +901,7 @@ vec4_visitor::emit_texture(ir_texture_opcode op,
                            const glsl_type *dest_type,
                            src_reg coordinate,
                            int coord_components,
-                           src_reg shadow_comparitor,
+                           src_reg shadow_comparator,
                            src_reg lod, src_reg lod2,
                            src_reg sample_index,
                            uint32_t constant_offset,
@@ -971,7 +971,7 @@ vec4_visitor::emit_texture(ir_texture_opcode op,
    inst->base_mrf = 2;
    inst->mlen = inst->header_size;
    inst->dst.writemask = WRITEMASK_XYZW;
-   inst->shadow_compare = shadow_comparitor.file != BAD_FILE;
+   inst->shadow_compare = shadow_comparator.file != BAD_FILE;
 
    inst->src[1] = surface_reg;
    inst->src[2] = sampler_reg;
@@ -999,11 +999,11 @@ vec4_visitor::emit_texture(ir_texture_opcode op,
          emit(MOV(dst_reg(MRF, param_base, coordinate.type, zero_mask),
                   brw_imm_d(0)));
       }
-      /* Load the shadow comparitor */
-      if (shadow_comparitor.file != BAD_FILE && op != ir_txd && (op != ir_tg4 || offset_value.file == BAD_FILE)) {
-        emit(MOV(dst_reg(MRF, param_base + 1, shadow_comparitor.type,
+      /* Load the shadow comparator */
+      if (shadow_comparator.file != BAD_FILE && op != ir_txd && (op != ir_tg4 || offset_value.file == BAD_FILE)) {
+        emit(MOV(dst_reg(MRF, param_base + 1, shadow_comparator.type,
                          WRITEMASK_X),
-                 shadow_comparitor));
+                 shadow_comparator));
         inst->mlen++;
       }
 
@@ -1012,7 +1012,7 @@ vec4_visitor::emit_texture(ir_texture_opcode op,
         int mrf, writemask;
         if (devinfo->gen >= 5) {
            mrf = param_base + 1;
-           if (shadow_comparitor.file != BAD_FILE) {
+           if (shadow_comparator.file != BAD_FILE) {
               writemask = WRITEMASK_Y;
               /* mlen already incremented */
            } else {
@@ -1058,17 +1058,17 @@ vec4_visitor::emit_texture(ir_texture_opcode op,
            emit(MOV(dst_reg(MRF, param_base + 1, type, WRITEMASK_YW), lod2));
            inst->mlen++;
 
-           if (dest_type->vector_elements == 3 || shadow_comparitor.file != BAD_FILE) {
+           if (dest_type->vector_elements == 3 || shadow_comparator.file != BAD_FILE) {
               lod.swizzle = BRW_SWIZZLE_ZZZZ;
               lod2.swizzle = BRW_SWIZZLE_ZZZZ;
               emit(MOV(dst_reg(MRF, param_base + 2, type, WRITEMASK_X), lod));
               emit(MOV(dst_reg(MRF, param_base + 2, type, WRITEMASK_Y), lod2));
               inst->mlen++;
 
-               if (shadow_comparitor.file != BAD_FILE) {
+               if (shadow_comparator.file != BAD_FILE) {
                   emit(MOV(dst_reg(MRF, param_base + 2,
-                                   shadow_comparitor.type, WRITEMASK_Z),
-                           shadow_comparitor));
+                                   shadow_comparator.type, WRITEMASK_Z),
+                           shadow_comparator));
                }
            }
         } else /* devinfo->gen == 4 */ {
@@ -1077,9 +1077,9 @@ vec4_visitor::emit_texture(ir_texture_opcode op,
            inst->mlen += 2;
         }
       } else if (op == ir_tg4 && offset_value.file != BAD_FILE) {
-         if (shadow_comparitor.file != BAD_FILE) {
-            emit(MOV(dst_reg(MRF, param_base, shadow_comparitor.type, WRITEMASK_W),
-                     shadow_comparitor));
+         if (shadow_comparator.file != BAD_FILE) {
+            emit(MOV(dst_reg(MRF, param_base, shadow_comparator.type, WRITEMASK_W),
+                     shadow_comparator));
          }
 
          emit(MOV(dst_reg(MRF, param_base + 1, glsl_type::ivec2_type, WRITEMASK_XY),
index fddcac24f874900de3c66df4eeaae9a8e23dd075..fd2c71f93ee94c656c098878d4ffef72d521c59c 100644 (file)
@@ -990,7 +990,7 @@ static void load_texture( texenv_fragment_program *p, GLuint unit )
 
    if (p->state->unit[unit].shadow) {
       texcoord = texcoord->clone(p->mem_ctx, NULL);
-      tex->shadow_comparitor = new(p->mem_ctx) ir_swizzle(texcoord,
+      tex->shadow_comparator = new(p->mem_ctx) ir_swizzle(texcoord,
                                                          coords, 0, 0, 0,
                                                          1);
       coords++;
index 558f0ea4f6892b1635776e301edd782062963c69..653b8221deedec203ad92d54f00b5730f74182b8 100644 (file)
@@ -2055,14 +2055,14 @@ ir_to_mesa_visitor::visit(ir_texture *ir)
         emit(ir, OPCODE_RCP, coord_dst, projector);
 
         /* In the case where we have to project the coordinates "by hand,"
-         * the shadow comparitor value must also be projected.
+         * the shadow comparator value must also be projected.
          */
         src_reg tmp_src = coord;
-        if (ir->shadow_comparitor) {
+        if (ir->shadow_comparator) {
            /* Slot the shadow value in as the second to last component of the
             * coord.
             */
-           ir->shadow_comparitor->accept(this);
+           ir->shadow_comparator->accept(this);
 
            tmp_src = get_temp(glsl_type::vec4_type);
            dst_reg tmp_dst = dst_reg(tmp_src);
@@ -2086,14 +2086,14 @@ ir_to_mesa_visitor::visit(ir_texture *ir)
    }
 
    /* If projection is done and the opcode is not OPCODE_TXP, then the shadow
-    * comparitor was put in the correct place (and projected) by the code,
+    * comparator was put in the correct place (and projected) by the code,
     * above, that handles by-hand projection.
     */
-   if (ir->shadow_comparitor && (!ir->projector || opcode == OPCODE_TXP)) {
+   if (ir->shadow_comparator && (!ir->projector || opcode == OPCODE_TXP)) {
       /* Slot the shadow value in as the second to last component of the
        * coord.
        */
-      ir->shadow_comparitor->accept(this);
+      ir->shadow_comparator->accept(this);
 
       /* XXX This will need to be updated for cubemap array samplers. */
       if (sampler_type->sampler_dimensionality == GLSL_SAMPLER_DIM_2D &&
@@ -2119,7 +2119,7 @@ ir_to_mesa_visitor::visit(ir_texture *ir)
    else
       inst = emit(ir, opcode, result_dst, coord);
 
-   if (ir->shadow_comparitor)
+   if (ir->shadow_comparator)
       inst->tex_shadow = GL_TRUE;
 
    inst->sampler = get_sampler_uniform_value(ir->sampler, shader_program,
index 68a5f6744852974a2127213e5ce3a95f9b9d5973..ed80d46dc4dec2422053d11e021d4219ec20d789 100644 (file)
@@ -634,7 +634,7 @@ ptn_tex(nir_builder *b, nir_alu_dest dest, nir_ssa_def **src,
       else
          instr->src[src_number].src = nir_src_for_ssa(ptn_channel(b, src[0], W));
 
-      instr->src[src_number].src_type = nir_tex_src_comparitor;
+      instr->src[src_number].src_type = nir_tex_src_comparator;
       src_number++;
    }
 
index 8707d284235656a30c46eca3837148e40e942267..c9ebb5ade8f7ae72cfce8011958ec0eac5e7d922 100644 (file)
@@ -3956,7 +3956,7 @@ glsl_to_tgsi_visitor::visit(ir_texture *ir)
 
    switch (ir->op) {
    case ir_tex:
-      opcode = (is_cube_array && ir->shadow_comparitor) ? TGSI_OPCODE_TEX2 : TGSI_OPCODE_TEX;
+      opcode = (is_cube_array && ir->shadow_comparator) ? TGSI_OPCODE_TEX2 : TGSI_OPCODE_TEX;
       if (ir->offset) {
          ir->offset->accept(this);
          offset[0] = this->result;
@@ -4073,11 +4073,11 @@ glsl_to_tgsi_visitor::visit(ir_texture *ir)
           * the shadow comparator value must also be projected.
           */
          st_src_reg tmp_src = coord;
-         if (ir->shadow_comparitor) {
+         if (ir->shadow_comparator) {
             /* Slot the shadow value in as the second to last component of the
              * coord.
              */
-            ir->shadow_comparitor->accept(this);
+            ir->shadow_comparator->accept(this);
 
             tmp_src = get_temp(glsl_type::vec4_type);
             st_dst_reg tmp_dst = st_dst_reg(tmp_src);
@@ -4104,11 +4104,11 @@ glsl_to_tgsi_visitor::visit(ir_texture *ir)
     * comparator was put in the correct place (and projected) by the code,
     * above, that handles by-hand projection.
     */
-   if (ir->shadow_comparitor && (!ir->projector || opcode == TGSI_OPCODE_TXP)) {
+   if (ir->shadow_comparator && (!ir->projector || opcode == TGSI_OPCODE_TXP)) {
       /* Slot the shadow value in as the second to last component of the
        * coord.
        */
-      ir->shadow_comparitor->accept(this);
+      ir->shadow_comparator->accept(this);
 
       if (is_cube_array) {
          cube_sc = get_temp(glsl_type::float_type);
@@ -4167,7 +4167,7 @@ glsl_to_tgsi_visitor::visit(ir_texture *ir)
    } else if (opcode == TGSI_OPCODE_TEX2) {
       inst = emit_asm(ir, opcode, result_dst, coord, cube_sc);
    } else if (opcode == TGSI_OPCODE_TG4) {
-      if (is_cube_array && ir->shadow_comparitor) {
+      if (is_cube_array && ir->shadow_comparator) {
          inst = emit_asm(ir, opcode, result_dst, coord, cube_sc);
       } else {
          inst = emit_asm(ir, opcode, result_dst, coord, component);
@@ -4175,7 +4175,7 @@ glsl_to_tgsi_visitor::visit(ir_texture *ir)
    } else
       inst = emit_asm(ir, opcode, result_dst, coord);
 
-   if (ir->shadow_comparitor)
+   if (ir->shadow_comparator)
       inst->tex_shadow = GL_TRUE;
 
    inst->resource.index = sampler_index;