001// ***** This file is automatically generated from FunctionBinary.java.jpp
002// ***** (and files it recursively includes).
003
004package daikon.inv.ternary.threeScalar;
005
006import daikon.*;
007import daikon.derive.unary.*;
008import daikon.inv.*;
009import daikon.inv.binary.twoScalar.*;
010import daikon.inv.unary.scalar.*;
011import daikon.suppress.*;
012import java.lang.reflect.*;
013import java.util.*;
014import java.util.logging.Logger;
015import org.checkerframework.checker.lock.qual.GuardSatisfied;
016import org.checkerframework.checker.nullness.qual.Nullable;
017import org.checkerframework.dataflow.qual.Pure;
018import org.checkerframework.dataflow.qual.SideEffectFree;
019import org.plumelib.util.ArraysPlume;
020import org.plumelib.util.MathPlume;
021import typequals.prototype.qual.NonPrototype;
022import typequals.prototype.qual.Prototype;
023
024/**
025 * Base class for each of the FunctionBinary functions and permutatons. Most of the work is done
026 * here. The subclasses basically define the function and return information describing the function
027 * and permutation to these methods.
028 */
029@SuppressWarnings("UnusedVariable")  // generated code, complex rules for when var is used
030public abstract class FunctionBinary extends ThreeScalar {
031  // We are Serializable, so we specify a version to allow changes to
032  // method signatures without breaking serialization.  If you add or
033  // remove fields, you should change this number to the current date.
034  static final long serialVersionUID = 20031030L;
035
036  /** Boolean. True if FunctionBinary invariants should be considered. */
037  public static boolean dkconfig_enabled = false;
038
039  public static Logger debug =
040    Logger.getLogger("daikon.inv.ternary.threeScalar.#CLASSNAME");
041
042  static final int[][] var_indices;
043  static {
044    var_indices = new int[7][];
045    var_indices[1] = new int[] { 0, 1, 2 };
046    var_indices[2] = new int[] { 1, 0, 2 };
047    var_indices[3] = new int[] { 2, 0, 1 };
048    var_indices[4] = new int[] { 0, 2, 1 };
049    var_indices[5] = new int[] { 1, 2, 0 };
050    var_indices[6] = new int[] { 2, 1, 0 };
051  }
052
053  protected FunctionBinary(PptSlice ppt) {
054    super(ppt);
055  }
056
057  protected @Prototype FunctionBinary() {
058    super();
059  }
060
061  /** returns whether or not this invariant is enabled */
062  @Override
063  public boolean enabled() {
064    return dkconfig_enabled;
065  }
066
067  /** FunctionBinary is only valid on isIntegral() types. */
068  @Override
069  public boolean instantiate_ok(VarInfo[] vis) {
070
071    if (!valid_types(vis)) {
072      return false;
073    }
074
075    // Make sure that each variable is integral (not boolean or hashcode)
076    if (!vis[0].file_rep_type.isIntegral()
077        || !vis[1].file_rep_type.isIntegral()
078        || !vis[2].file_rep_type.isIntegral())
079      return false;
080
081    return true;
082  }
083
084  // check_modified relies on func having no side effects.
085  abstract long func(long arg1, long arg2);
086  @Pure
087  abstract boolean is_symmetric();
088  abstract String[] get_method_name(@GuardSatisfied FunctionBinary this);
089  abstract int get_var_order(@GuardSatisfied FunctionBinary this);
090  abstract void set_function_id(int function_id);
091  abstract int get_function_id();
092
093  /**
094   * Map from function name (eg, MultiplyLong, MinimumFloat) to an array of instances (one for each
095   * valid permutation) for that function.
096   */
097  private static Map<String,@Prototype FunctionBinary[]> functions = new LinkedHashMap<>();
098
099  /**
100   * A list indexed by function number to an array of instances (one for each valid permutation) for
101   * that function. The array is the same one as is stored in the functions Map. This provides a
102   * faster access mechanism once we have the function id (which are calculated the first time
103   * through).
104   */
105  private static List<@Prototype FunctionBinary[]> func_list = new ArrayList<>();
106
107  private static void build_func_list() {
108
109    // Reflection seems to confuse clover
110    ///CLOVER:OFF
111
112    // Build the map of functions to array of instances for that function
113    debug.fine("Processing FunctionBinary");
114    functions = new LinkedHashMap<>();
115    @SuppressWarnings("unchecked")
116    Class<@Prototype FunctionBinary>[] subclasses = (Class<@Prototype FunctionBinary>[]) FunctionBinary.class.getDeclaredClasses();
117    for (int ii = 0; ii < subclasses.length; ii++) {
118      Class<@Prototype FunctionBinary> subc = subclasses[ii];
119      String function = subc.getName();
120      if (function.indexOf("CLOVER") >= 0) {
121        continue;
122      }
123      function = function.replaceFirst(".*FunctionBinary\\$", "");
124      function = function.replaceFirst("_.*", "");
125      if (function.equals("SubClass")) {
126        continue;
127      }
128      @Prototype FunctionBinary[] fb_arr = functions.get(function);
129      if (fb_arr == null) {
130        fb_arr = new @Prototype FunctionBinary[7];
131        functions.put(function, fb_arr);
132        func_list.add(fb_arr);
133      }
134      int func_id = func_list.indexOf(fb_arr);
135      @SuppressWarnings({"nonprototype"})
136      @Prototype FunctionBinary fb;
137      try {
138        Constructor<@Prototype FunctionBinary> con = subc.getDeclaredConstructor(new Class<?>[] {});
139        fb = con.newInstance(new Object[] {});
140      }  catch (Exception e) {
141        throw new Error(" can't create instance for " + subc.getName()
142                        + ": '" + e + "' ii = " + ii);
143      }
144      assert fb_arr[fb.get_var_order()] == null;
145      fb_arr[fb.get_var_order()] = fb;
146      fb.set_function_id(func_id);
147      debug.fine("Adding " + function + " " + fb.getClass().getName()
148                  + " " + fb.get_var_order() + " " + fb.get_function_id());
149    }
150    ///CLOVER:ON
151  }
152
153  /** Returns a list of all of the FunctionBinary prototype invariants. */
154  public static List<@Prototype Invariant> get_proto_all() {
155
156    List<@Prototype Invariant> result = new ArrayList<>();
157
158    // If this is the first call
159    if (functions.isEmpty()) {
160      build_func_list();
161    }
162
163    // Get the proto invariant for all of the subclasses and return them
164    for (@Prototype FunctionBinary[] fb_arr : func_list) {
165      for (int jj = 1; jj < fb_arr.length; jj++) {
166        @Prototype FunctionBinary fb = fb_arr[jj];
167        if (fb != null) {
168          result.add(fb);
169        }
170      }
171    }
172    return result;
173  }
174
175  /** Permuted result var. */
176  public VarInfo resultVar() {
177    return ppt.var_infos[var_indices[get_var_order()][0]];
178  }
179
180  /** Permuted arg1 var. */
181  public VarInfo argVar1() {
182    return ppt.var_infos[var_indices[get_var_order()][1]];
183  }
184
185  /** Permuted arg2 var. */
186  public VarInfo argVar2() {
187    return ppt.var_infos[var_indices[get_var_order()][2]];
188  }
189
190  /**
191   * Apply the specified sample to the function, returning the result. The caller is responsible
192   * for permuting the arguments.
193   */
194  public InvariantStatus check_ordered(long result, long arg1,
195                                      long arg2, int count) {
196    // This implementation relies on func having no side effects.
197    try {
198      if (!(result == func(arg1, arg2))) {
199        return InvariantStatus.FALSIFIED;
200      }
201    } catch (Exception e) {
202        return InvariantStatus.FALSIFIED;
203    }
204    return InvariantStatus.NO_CHANGE;
205  }
206
207  /**
208   * Apply the specified sample to the function, returning the result. The caller is responsible
209   * for permuting the arguments.
210   */
211  public InvariantStatus add_ordered(long result, long arg1,
212                                      long arg2, int count) {
213    return check_ordered(result, arg1, arg2, count);
214  }
215
216  /**
217   * Reorganize our already-seen state as if the variables had shifted order underneath us
218   * (re-arrangement given by the permutation). We accomplish this by returning the class that
219   * corresponds to the new permutation.
220   */
221  @Override
222  protected Invariant resurrect_done(int[] permutation) {
223
224    assert permutation.length == 3;
225    assert ArraysPlume.fnIsPermutation(permutation);
226
227    int[] new_order = new int[3];
228    int[] old_order = var_indices[get_var_order()];
229
230    // "permutation" is a permutation on the var_info array. old_order
231    // was the permutation that took the formatted invariant to the
232    // var_info array, so old_order^-1 is the permutation from the
233    // var_info array to the old formatted invariant. We want to find
234    // a new_order so that when we first do "permutation", then
235    // apply the new permutation from the var_info array to the
236    // formatted invariant, we get the same formatted invariant.
237    // What we want, then. is:
238    //    new_order^-1 o permutation = old_order^-1
239    // rearranging, this is equivalent to
240    //    new_order = permutation o old_order
241    new_order[0] = permutation[old_order[0]];
242    new_order[1] = permutation[old_order[1]];
243    new_order[2] = permutation[old_order[2]];
244
245    // Force symmetric functions into a canonical form so that
246    // we can match them when necessary and they always print the same.
247    // For example, order of 0, 1, 2 and 0, 2, 1 represent the same
248    // invariant for a symmetric function.  This forces them to always
249    // be represented as 0, 1, 2
250    if (is_symmetric()) {
251      if (new_order[2] < new_order[1]) {
252        int tmp = new_order[2];
253        new_order[2] = new_order[1];
254        new_order[1] = tmp;
255      }
256    }
257
258    // Look for the new order in the list of possible orders
259    int var_order = -1;
260    for (int i = 0; i < var_indices.length; i++) {
261      if (Arrays.equals(new_order, var_indices[i])) {
262        var_order = i;
263        break;
264      }
265    }
266    assert var_order != -1;
267
268    // If the var order hasn't changed, we don't need to do anything
269    if (var_order == get_var_order()) {
270      return this;
271    }
272
273    // Find the class that corresponds to the new order
274    if (functions.isEmpty()) {
275      build_func_list();
276    }
277    int func_id = get_function_id();
278    @Prototype FunctionBinary[] fb_arr = func_list.get(func_id);
279    assert fb_arr != null;
280    for (int ii = 0; ii < fb_arr.length; ii++) {
281      if ((fb_arr[ii] != null) && (fb_arr[ii].get_var_order() == var_order)) {
282        return fb_arr[ii].instantiate_dyn(ppt);
283      }
284    }
285
286    throw new Error("Could not find new ordering");
287  }
288
289  @Override
290  public String repr(@GuardSatisfied FunctionBinary this) {
291    return format();
292  }
293
294  @SideEffectFree
295  @Override
296  public String format_using(@GuardSatisfied FunctionBinary this, OutputFormat format) {
297    if (format == OutputFormat.SIMPLIFY) {
298      return format_simplify();
299    }
300    if (format == OutputFormat.CSHARPCONTRACT) {
301      return format_csharp_contract();
302    }
303
304    int var_order = get_var_order();
305    String[] methodname = get_method_name();
306
307    VarInfo argresultvi = ppt.var_infos[var_indices[var_order][0]];
308    VarInfo arg1vi = ppt.var_infos[var_indices[var_order][1]];
309    VarInfo arg2vi = ppt.var_infos[var_indices[var_order][2]];
310
311    String argresult_name = argresultvi.name_using(format);
312    String arg1_name = arg1vi.name_using(format);
313    String arg2_name = arg2vi.name_using(format);
314
315    if (format == OutputFormat.DAIKON) {
316      return argresult_name + " == (" + methodname[0] + arg1_name
317        + methodname[1] + arg2_name + methodname[2] + ")";
318    }
319
320    if (format.isJavaFamily()) {
321      if (methodname[1].equals(" || ") || methodname[1].equals(" && ")) {
322        return "(" +  argresult_name + " != 0) == ((" + methodname[0] + arg1_name + " != 0)"
323          + methodname[1] + "(" + arg2_name + methodname[2] + " != 0))";
324      } else {
325        return argresult_name + " == (" + methodname[0] + arg1_name
326          + methodname[1] + arg2_name + methodname[2] + ")";
327      }
328    }
329
330    return format_unimplemented(format);
331  }
332
333  public String format_simplify(@GuardSatisfied FunctionBinary this) {
334    int var_order = get_var_order();
335    String[] methodname = get_method_name();
336    VarInfo[] vis = ppt.var_infos;
337
338    String result = vis[var_indices[var_order][0]].simplifyFixedupName();
339    String arg1 = vis[var_indices[var_order][1]].simplifyFixedupName();
340    String arg2 = vis[var_indices[var_order][2]].simplifyFixedupName();
341    String func = null;
342    if (methodname[1].equals(" * ")) {
343      func = "*";
344    } else if (methodname[1].equals(" | ")) {
345      func = "|java-bitwise-or|";
346    } else if (methodname[1].equals(" || ")) {
347      func = "|java-logical-or|";
348    } else if (methodname[1].equals(", ")) {
349      if (methodname[0].equals("java.lang.Math.min(")) {
350        func = "min";
351      } else if (methodname[0].equals("java.lang.Math.max(")) {
352        func = "max";
353      } else if (methodname[0].equals("org.plumelib.util.MathPlume.gcd(")) {
354        func = "gcd";
355      } else if (methodname[0].equals("java.lang.Math.pow(")) {
356        func = "pow";
357      } else if (methodname[0].equals("org.plumelib.util.MathPlume.logicalXor(")) {
358        func = "|java-logical-xor|";
359      }
360    } else {
361      assert methodname[0].equals("");
362      assert methodname[2].equals("");
363      func = "|java-" + methodname[1].trim() + "|";
364    }
365    if (func == null) {
366      return "format_simplify_contract() doesn't know function " + methodname[0] + "-"
367        + methodname[1] + "-" + methodname[2];
368    }
369    return "(EQ " + result + " (" + func + " " + arg1 + " " + arg2 + "))";
370  }
371
372  public String format_csharp_contract(@GuardSatisfied FunctionBinary this) {
373    int var_order = get_var_order();
374    String[] methodname = get_method_name();
375
376    VarInfo argresultvi = ppt.var_infos[var_indices[var_order][0]];
377    VarInfo arg1vi = ppt.var_infos[var_indices[var_order][1]];
378    VarInfo arg2vi = ppt.var_infos[var_indices[var_order][2]];
379    String result = argresultvi.csharp_name();
380    String arg1 = arg1vi.csharp_name();
381    String arg2 = arg2vi.csharp_name();
382    String operator = null;
383
384    if (methodname[1].equals(" * ")) {
385      operator = "*";
386    } else if (methodname[1].equals(" | ")) {
387      operator = "|";
388    } else if (methodname[1].equals(" & ")) {
389      operator = "&";
390    } else if (methodname[1].equals(" / ")) {
391      operator = "/";
392    } else if (methodname[1].equals(" ^ ")) {
393      operator = "^";
394    } else if (methodname[1].equals(" % ")) {
395      operator = "%";
396    } else if (methodname[1].equals(" && ")) {
397      operator = "&&";
398    } else if (methodname[1].equals(" || ")) {
399      operator = "||";
400    } else if (methodname[1].equals(" >> ")) {
401      operator = ">>";
402    } else if (methodname[1].equals(" >>> ")) {
403      return result + " == " + arg1 + ".UnsignedRightShift(" + arg2 + ")";
404      //return result + " == CSharpDaikonLib.Extensions.UnsignedRightShift(" + arg1 + ", " + arg2 + ")";
405    } else if (methodname[1].equals(" << ")) {
406      operator = "<<";
407    }
408
409    if (operator != null) {
410      return result + " == (" + arg1 + " " + operator + " " + arg2 + ")";
411    }
412
413    String func = null;
414    if (methodname[1].equals(", ")) {
415      if (methodname[0].equals("java.lang.Math.min(")) {
416        func = "Math.Min";
417      } else if (methodname[0].equals("java.lang.Math.max(")) {
418        func = "Math.Max";
419      } else if (methodname[0].equals("org.plumelib.util.MathPlume.gcd(")) {
420        return result + " == CSharpDaikonLib.Extensions.GCD(" + arg1 + ", " + arg2 + ")";
421      } else if (methodname[0].equals("java.lang.Math.pow(")) {
422        return result + " == " + arg1 + ".Pow(" + arg2 + ")";
423      } else if (methodname[0].equals("org.plumelib.util.MathPlume.logicalXor(")) {
424        return result + " == (" + arg1 + " ^ " + arg2 + ")";
425      }
426    } else {
427      assert methodname[0].equals("");
428      assert methodname[2].equals("");
429      func = "|" + methodname[1].trim() + "|";
430    }
431
432    if (func == null) {
433      return "format_csharp_contract() doesn't know function " + methodname[0] + "-" + methodname[1] + "-" + methodname[2];
434    }
435    return result + " == " + func + "(" + arg1 + ", " + arg2 + ")";
436  }
437
438  // If our classes match, we must match
439  @Pure
440  @Override
441  public boolean isSameFormula(Invariant other) {
442    return true;
443  }
444  @Override
445  public double computeConfidence() {
446    if (logOn()) {
447      VarInfo v1 = ppt.var_infos[0];
448      VarInfo v2 = ppt.var_infos[1];
449      VarInfo v3 = ppt.var_infos[2];
450      log("computeConfidence(%s: num_values = %s, num_values(%s)=%s, num_values(%s)=%s, num_values(%s)=%s",
451          format(), ppt.num_values(),
452          v1.name(), ppt.parent.num_values(v1),
453          v2.name(), ppt.parent.num_values(v2),
454          v3.name(), ppt.parent.num_values(v3));
455    }
456    return Invariant.conf_is_ge(ppt.num_values(), 5);
457  }
458
459  /** If the arg is a sequence size, return the sequence; otherwise return null. */
460  private @Nullable VarInfo sized_sequence(VarInfo size) {
461    if (size.derived instanceof SequenceLength) {
462      return ((SequenceLength)size.derived).base;
463    }
464    return null;
465  }
466
467  @Pure
468  @Override
469  public @Nullable DiscardInfo isObviousDynamically(VarInfo[] vis) {
470
471    DiscardInfo super_result = super.isObviousDynamically(vis);
472    if (super_result != null) {
473      return super_result;
474    }
475
476    // Discard if any two of the three variables are the sizes of the
477    // same arrays.
478    VarInfo arr1 = sized_sequence(vis[0]);
479    VarInfo arr2 = sized_sequence(vis[1]);
480    VarInfo arr3 = sized_sequence(vis[2]);
481    if (((arr1 != null) && (arr1 == arr2))
482        || ((arr1 != null) && (arr1 == arr3))
483        || ((arr2 != null) && (arr2 == arr3))) {
484      return new DiscardInfo(this, DiscardCode.obvious,
485                    "two are sizes of same array:  "
486                    + vis[0].name() + " "
487                    + vis[1].name() + " "
488                    + vis[2].name());
489    }
490
491    return null;
492  }
493
494  // default is that it is not this function, overriden in the subclass
495  @Pure
496  public boolean isMultiply() {
497    return false;
498  }
499
500/**
501 * Represents the invariant {@code x = Multiply(y, z)} over three long
502 * scalars. 
503 */
504public static class MultiplyLong_xyz extends FunctionBinary {
505  // We are Serializable, so we specify a version to allow changes to
506  // method signatures without breaking serialization.  If you add or
507  // remove fields, you should change this number to the current date.
508  static final long serialVersionUID = 20031030L;
509
510  private static @Prototype MultiplyLong_xyz proto = new @Prototype MultiplyLong_xyz ();
511
512  /** Returns the prototype invariant for MultiplyLong_xyz */
513  public static @Prototype MultiplyLong_xyz get_proto() {
514    return proto;
515  }
516
517  /** instantiate an invariant on the specified slice */
518  @Override
519  protected MultiplyLong_xyz instantiate_dyn(@Prototype MultiplyLong_xyz this, PptSlice slice) {
520    return new MultiplyLong_xyz (slice);
521  }
522
523  private MultiplyLong_xyz (PptSlice slice) {
524    super(slice);
525  }
526
527  public @Prototype MultiplyLong_xyz () {
528    super();
529  }
530
531  private static String[] method_name = new String[] {"", " * ", ""};
532
533  @Override
534  public String[] get_method_name(@GuardSatisfied MultiplyLong_xyz this) {
535    return method_name;
536  }
537
538  private static int function_id = -1;
539
540  @Override
541  public int get_function_id() {
542    return function_id;
543  }
544
545  @Override
546  public void set_function_id(int function_id) {
547    assert MultiplyLong_xyz.function_id == -1;
548    MultiplyLong_xyz.function_id = function_id;
549  }
550
551  private static int var_order = 1;
552
553  @Override
554  public int get_var_order(@GuardSatisfied MultiplyLong_xyz this) {
555    return var_order;
556  }
557
558  @Pure
559  @Override
560  public boolean is_symmetric() {
561
562      return true;
563  }
564
565  @Override
566
567  public long func(long y, long z) {
568
569    return y * z;
570  }
571
572  @Override
573  public InvariantStatus check_modified(long x, long y,
574                                      long z, int count) {
575    return check_ordered(x, y, z, count);
576  }
577
578  @Override
579  public InvariantStatus add_modified(long x, long y,
580                                      long z, int count) {
581    if (Debug.logDetail()) {
582      log("result=%s, arg1=%s, arg2=%s", x, y, z);
583    }
584    return add_ordered(x, y, z, count);
585  }
586
587  @Pure
588  @Override
589  public boolean isMultiply() {
590    return true;
591  }
592
593  @Pure
594  @Override
595  public boolean isExact() {
596    return true;
597  }
598
599  /** Returns a list of non-instantiating suppressions for this invariant. */
600  @Pure
601  @Override
602  public @Nullable NISuppressionSet get_ni_suppressions() {
603    if (NIS.dkconfig_enabled && dkconfig_enabled) {
604      return suppressions;
605    } else {
606      return null;
607    }
608  }
609
610  /** definition of this invariant (the suppressee) */
611  private static NISuppressee suppressee = new NISuppressee(MultiplyLong_xyz.class, 3);
612
613  // suppressor definitions (used below)
614  private static NISuppressor result_eq_arg1 =
615      new NISuppressor(0, 1, IntEqual.class);
616  private static NISuppressor result_eq_arg2 =
617      new NISuppressor(0, 2, IntEqual.class);
618  private static NISuppressor arg1_eq_arg2 =
619      new NISuppressor(1, 2, IntEqual.class);
620
621  private static NISuppressor result_lt_arg1 =
622      new NISuppressor(0, 1, IntLessThan.class);
623  private static NISuppressor result_lt_arg2 =
624      new NISuppressor(0, 2, IntLessThan.class);
625  private static NISuppressor arg1_lt_arg2 =
626      new NISuppressor(1, 2, IntLessThan.class);
627  private static NISuppressor arg2_lt_arg1 =
628      new NISuppressor(2, 1, IntLessThan.class);
629
630  private static NISuppressor result_le_arg1 =
631      new NISuppressor(0, 1, IntLessEqual.class);
632  private static NISuppressor result_le_arg2 =
633      new NISuppressor(0, 2, IntLessEqual.class);
634  private static NISuppressor arg1_le_arg2 =
635      new NISuppressor(1, 2, IntLessEqual.class);
636  private static NISuppressor arg2_le_arg1 =
637      new NISuppressor(2, 1, IntLessEqual.class);
638
639  private static NISuppressor result_track0_arg1 =
640      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
641  private static NISuppressor result_track0_arg2 =
642      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
643  private static NISuppressor arg1_track0_arg2 =
644      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
645  private static NISuppressor arg1_track0_result =
646      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
647  private static NISuppressor arg2_track0_result =
648      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
649  private static NISuppressor arg2_track0_arg1 =
650      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
651
652  private static NISuppressor result_eq_1 =
653      new NISuppressor(0, RangeInt.EqualOne.class);
654  private static NISuppressor arg1_eq_1 =
655      new NISuppressor(1, RangeInt.EqualOne.class);
656  private static NISuppressor arg2_eq_1 =
657      new NISuppressor(2, RangeInt.EqualOne.class);
658
659  private static NISuppressor result_eq_0 =
660      new NISuppressor(0, RangeInt.EqualZero.class);
661  private static NISuppressor arg1_eq_0 =
662      new NISuppressor(1, RangeInt.EqualZero.class);
663  private static NISuppressor arg2_eq_0 =
664      new NISuppressor(2, RangeInt.EqualZero.class);
665
666  private static NISuppressor result_ne_0 =
667      new NISuppressor(0, NonZero.class);
668  private static NISuppressor arg1_ne_0 =
669      new NISuppressor(1, NonZero.class);
670  private static NISuppressor arg2_ne_0 =
671      new NISuppressor(2, NonZero.class);
672
673  private static NISuppressor result_ge_0 =
674      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
675  private static NISuppressor arg1_ge_0 =
676      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
677  private static NISuppressor arg2_ge_0 =
678      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
679
680  private static NISuppressor result_ge_64 =
681      new NISuppressor(0, RangeInt.GreaterEqual64.class);
682  private static NISuppressor arg1_ge_64 =
683      new NISuppressor(1, RangeInt.GreaterEqual64.class);
684  private static NISuppressor arg2_ge_64 =
685      new NISuppressor(2, RangeInt.GreaterEqual64.class);
686
687  private static NISuppressor result_boolean =
688      new NISuppressor(0, RangeInt.BooleanVal.class);
689  private static NISuppressor arg1_boolean =
690      new NISuppressor(1, RangeInt.BooleanVal.class);
691  private static NISuppressor arg2_boolean =
692      new NISuppressor(2, RangeInt.BooleanVal.class);
693
694  private static NISuppressor result_even =
695      new NISuppressor(0, RangeInt.Even.class);
696  private static NISuppressor arg1_even =
697      new NISuppressor(1, RangeInt.Even.class);
698  private static NISuppressor arg2_even =
699      new NISuppressor(2, RangeInt.Even.class);
700
701  private static NISuppressor result_power2 =
702      new NISuppressor(0, RangeInt.PowerOfTwo.class);
703  private static NISuppressor arg1_power2 =
704      new NISuppressor(1, RangeInt.PowerOfTwo.class);
705  private static NISuppressor arg2_power2 =
706      new NISuppressor(2, RangeInt.PowerOfTwo.class);
707
708  private static NISuppressor result_and0_arg1 =
709      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
710  private static NISuppressor result_and0_arg2 =
711      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
712  private static NISuppressor arg1_and0_arg2 =
713      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
714
715  // The arguments to bitwise subset are backwards from what one
716  // might expect.  The second argument is a subset of the first
717  // argument
718  private static NISuppressor arg1_bw_subset_arg2 =
719      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
720  private static NISuppressor arg2_bw_subset_arg1 =
721      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
722
723  private static NISuppressor result_shift0_arg1 =
724      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
725  private static NISuppressor result_shift0_arg2 =
726      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
727  private static NISuppressor arg1_shift0_arg2 =
728      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
729
730  private static NISuppressor arg2_divides_arg1 =
731      new NISuppressor(1, 2, NumericInt.Divides.class);
732  private static NISuppressor arg1_divides_arg2 =
733      new NISuppressor(2, 1, NumericInt.Divides.class);
734
735  private static NISuppressor arg2_valid_shift =
736      new NISuppressor(2, RangeInt.Bound0_63.class);
737
738    private static NISuppressionSet suppressions =
739      new NISuppressionSet(
740          new NISuppression[] {
741
742            // (r == 0) && (y == 0) ==> r = y * z
743            new NISuppression(result_eq_0, arg1_eq_0, suppressee),
744
745            // (r == 0) && (z == 0) ==> r = y * z
746            new NISuppression(result_eq_0, arg2_eq_0, suppressee),
747
748            // (r == y) && (z == 1) ==> r = y * z
749            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
750
751            // (r == z) && (y == 1) ==> r = y * z
752            new NISuppression(result_eq_arg2, arg1_eq_1, suppressee),
753
754            // (r == y) && (z boolean) && (z==0 ==> y==0)
755            // x = x * 0 is true if x == 0
756            // x = x * 1 is true for all x
757            new NISuppression(arg2_boolean, arg2_track0_arg1, result_eq_arg1,
758                               suppressee),
759
760            // (r == z) && (y boolean) && (y==0 ==> z=0)
761            new NISuppression(result_eq_arg2, arg1_track0_arg2, arg1_boolean,
762                               suppressee),
763
764          });
765
766  // Create a suppression factory for functionBinary
767
768}
769
770/**
771 * Represents the invariant {@code y = Multiply(x, z)} over three long
772 * scalars. 
773 */
774public static class MultiplyLong_yxz extends FunctionBinary {
775  // We are Serializable, so we specify a version to allow changes to
776  // method signatures without breaking serialization.  If you add or
777  // remove fields, you should change this number to the current date.
778  static final long serialVersionUID = 20031030L;
779
780  private static @Prototype MultiplyLong_yxz proto = new @Prototype MultiplyLong_yxz ();
781
782  /** Returns the prototype invariant for MultiplyLong_yxz */
783  public static @Prototype MultiplyLong_yxz get_proto() {
784    return proto;
785  }
786
787  /** instantiate an invariant on the specified slice */
788  @Override
789  protected MultiplyLong_yxz instantiate_dyn(@Prototype MultiplyLong_yxz this, PptSlice slice) {
790    return new MultiplyLong_yxz (slice);
791  }
792
793  private MultiplyLong_yxz (PptSlice slice) {
794    super(slice);
795  }
796
797  public @Prototype MultiplyLong_yxz () {
798    super();
799  }
800
801  private static String[] method_name = new String[] {"", " * ", ""};
802
803  @Override
804  public String[] get_method_name(@GuardSatisfied MultiplyLong_yxz this) {
805    return method_name;
806  }
807
808  private static int function_id = -1;
809
810  @Override
811  public int get_function_id() {
812    return function_id;
813  }
814
815  @Override
816  public void set_function_id(int function_id) {
817    assert MultiplyLong_yxz.function_id == -1;
818    MultiplyLong_yxz.function_id = function_id;
819  }
820
821  private static int var_order = 2;
822
823  @Override
824  public int get_var_order(@GuardSatisfied MultiplyLong_yxz this) {
825    return var_order;
826  }
827
828  @Pure
829  @Override
830  public boolean is_symmetric() {
831
832      return true;
833  }
834
835  @Override
836
837  public long func(long x, long z) {
838
839    return x * z;
840  }
841
842  @Override
843  public InvariantStatus check_modified(long x, long y,
844                                      long z, int count) {
845    return check_ordered(y, x, z, count);
846  }
847
848  @Override
849  public InvariantStatus add_modified(long x, long y,
850                                      long z, int count) {
851    if (Debug.logDetail()) {
852      log("result=%s, arg1=%s, arg2=%s", y, x, z);
853    }
854    return add_ordered(y, x, z, count);
855  }
856
857  @Pure
858  @Override
859  public boolean isMultiply() {
860    return true;
861  }
862
863  @Pure
864  @Override
865  public boolean isExact() {
866    return true;
867  }
868
869  /** Returns a list of non-instantiating suppressions for this invariant. */
870  @Pure
871  @Override
872  public @Nullable NISuppressionSet get_ni_suppressions() {
873    if (NIS.dkconfig_enabled && dkconfig_enabled) {
874      return suppressions;
875    } else {
876      return null;
877    }
878  }
879
880  /** definition of this invariant (the suppressee) */
881  private static NISuppressee suppressee = new NISuppressee(MultiplyLong_yxz.class, 3);
882
883  // suppressor definitions (used below)
884  private static NISuppressor result_eq_arg1 =
885      new NISuppressor(1, 0, IntEqual.class);
886  private static NISuppressor result_eq_arg2 =
887      new NISuppressor(1, 2, IntEqual.class);
888  private static NISuppressor arg1_eq_arg2 =
889      new NISuppressor(0, 2, IntEqual.class);
890
891  private static NISuppressor result_lt_arg1 =
892      new NISuppressor(1, 0, IntLessThan.class);
893  private static NISuppressor result_lt_arg2 =
894      new NISuppressor(1, 2, IntLessThan.class);
895  private static NISuppressor arg1_lt_arg2 =
896      new NISuppressor(0, 2, IntLessThan.class);
897  private static NISuppressor arg2_lt_arg1 =
898      new NISuppressor(2, 0, IntLessThan.class);
899
900  private static NISuppressor result_le_arg1 =
901      new NISuppressor(1, 0, IntLessEqual.class);
902  private static NISuppressor result_le_arg2 =
903      new NISuppressor(1, 2, IntLessEqual.class);
904  private static NISuppressor arg1_le_arg2 =
905      new NISuppressor(0, 2, IntLessEqual.class);
906  private static NISuppressor arg2_le_arg1 =
907      new NISuppressor(2, 0, IntLessEqual.class);
908
909  private static NISuppressor result_track0_arg1 =
910      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
911  private static NISuppressor result_track0_arg2 =
912      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
913  private static NISuppressor arg1_track0_arg2 =
914      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
915  private static NISuppressor arg1_track0_result =
916      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
917  private static NISuppressor arg2_track0_result =
918      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
919  private static NISuppressor arg2_track0_arg1 =
920      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
921
922  private static NISuppressor result_eq_1 =
923      new NISuppressor(1, RangeInt.EqualOne.class);
924  private static NISuppressor arg1_eq_1 =
925      new NISuppressor(0, RangeInt.EqualOne.class);
926  private static NISuppressor arg2_eq_1 =
927      new NISuppressor(2, RangeInt.EqualOne.class);
928
929  private static NISuppressor result_eq_0 =
930      new NISuppressor(1, RangeInt.EqualZero.class);
931  private static NISuppressor arg1_eq_0 =
932      new NISuppressor(0, RangeInt.EqualZero.class);
933  private static NISuppressor arg2_eq_0 =
934      new NISuppressor(2, RangeInt.EqualZero.class);
935
936  private static NISuppressor result_ne_0 =
937      new NISuppressor(1, NonZero.class);
938  private static NISuppressor arg1_ne_0 =
939      new NISuppressor(0, NonZero.class);
940  private static NISuppressor arg2_ne_0 =
941      new NISuppressor(2, NonZero.class);
942
943  private static NISuppressor result_ge_0 =
944      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
945  private static NISuppressor arg1_ge_0 =
946      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
947  private static NISuppressor arg2_ge_0 =
948      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
949
950  private static NISuppressor result_ge_64 =
951      new NISuppressor(1, RangeInt.GreaterEqual64.class);
952  private static NISuppressor arg1_ge_64 =
953      new NISuppressor(0, RangeInt.GreaterEqual64.class);
954  private static NISuppressor arg2_ge_64 =
955      new NISuppressor(2, RangeInt.GreaterEqual64.class);
956
957  private static NISuppressor result_boolean =
958      new NISuppressor(1, RangeInt.BooleanVal.class);
959  private static NISuppressor arg1_boolean =
960      new NISuppressor(0, RangeInt.BooleanVal.class);
961  private static NISuppressor arg2_boolean =
962      new NISuppressor(2, RangeInt.BooleanVal.class);
963
964  private static NISuppressor result_even =
965      new NISuppressor(1, RangeInt.Even.class);
966  private static NISuppressor arg1_even =
967      new NISuppressor(0, RangeInt.Even.class);
968  private static NISuppressor arg2_even =
969      new NISuppressor(2, RangeInt.Even.class);
970
971  private static NISuppressor result_power2 =
972      new NISuppressor(1, RangeInt.PowerOfTwo.class);
973  private static NISuppressor arg1_power2 =
974      new NISuppressor(0, RangeInt.PowerOfTwo.class);
975  private static NISuppressor arg2_power2 =
976      new NISuppressor(2, RangeInt.PowerOfTwo.class);
977
978  private static NISuppressor result_and0_arg1 =
979      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
980  private static NISuppressor result_and0_arg2 =
981      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
982  private static NISuppressor arg1_and0_arg2 =
983      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
984
985  // The arguments to bitwise subset are backwards from what one
986  // might expect.  The second argument is a subset of the first
987  // argument
988  private static NISuppressor arg1_bw_subset_arg2 =
989      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
990  private static NISuppressor arg2_bw_subset_arg1 =
991      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
992
993  private static NISuppressor result_shift0_arg1 =
994      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
995  private static NISuppressor result_shift0_arg2 =
996      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
997  private static NISuppressor arg1_shift0_arg2 =
998      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
999
1000  private static NISuppressor arg2_divides_arg1 =
1001      new NISuppressor(0, 2, NumericInt.Divides.class);
1002  private static NISuppressor arg1_divides_arg2 =
1003      new NISuppressor(2, 0, NumericInt.Divides.class);
1004
1005  private static NISuppressor arg2_valid_shift =
1006      new NISuppressor(2, RangeInt.Bound0_63.class);
1007
1008    private static NISuppressionSet suppressions =
1009      new NISuppressionSet(
1010          new NISuppression[] {
1011
1012            // (r == 0) && (x == 0) ==> r = x * z
1013            new NISuppression(result_eq_0, arg1_eq_0, suppressee),
1014
1015            // (r == 0) && (z == 0) ==> r = x * z
1016            new NISuppression(result_eq_0, arg2_eq_0, suppressee),
1017
1018            // (r == x) && (z == 1) ==> r = x * z
1019            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
1020
1021            // (r == z) && (x == 1) ==> r = x * z
1022            new NISuppression(result_eq_arg2, arg1_eq_1, suppressee),
1023
1024            // (r == x) && (z boolean) && (z==0 ==> x==0)
1025            // x = x * 0 is true if x == 0
1026            // x = x * 1 is true for all x
1027            new NISuppression(arg2_boolean, arg2_track0_arg1, result_eq_arg1,
1028                               suppressee),
1029
1030            // (r == z) && (x boolean) && (x==0 ==> z=0)
1031            new NISuppression(result_eq_arg2, arg1_track0_arg2, arg1_boolean,
1032                               suppressee),
1033
1034          });
1035
1036  // Create a suppression factory for functionBinary
1037
1038}
1039
1040/**
1041 * Represents the invariant {@code z = Multiply(x, y)} over three long
1042 * scalars. 
1043 */
1044public static class MultiplyLong_zxy extends FunctionBinary {
1045  // We are Serializable, so we specify a version to allow changes to
1046  // method signatures without breaking serialization.  If you add or
1047  // remove fields, you should change this number to the current date.
1048  static final long serialVersionUID = 20031030L;
1049
1050  private static @Prototype MultiplyLong_zxy proto = new @Prototype MultiplyLong_zxy ();
1051
1052  /** Returns the prototype invariant for MultiplyLong_zxy */
1053  public static @Prototype MultiplyLong_zxy get_proto() {
1054    return proto;
1055  }
1056
1057  /** instantiate an invariant on the specified slice */
1058  @Override
1059  protected MultiplyLong_zxy instantiate_dyn(@Prototype MultiplyLong_zxy this, PptSlice slice) {
1060    return new MultiplyLong_zxy (slice);
1061  }
1062
1063  private MultiplyLong_zxy (PptSlice slice) {
1064    super(slice);
1065  }
1066
1067  public @Prototype MultiplyLong_zxy () {
1068    super();
1069  }
1070
1071  private static String[] method_name = new String[] {"", " * ", ""};
1072
1073  @Override
1074  public String[] get_method_name(@GuardSatisfied MultiplyLong_zxy this) {
1075    return method_name;
1076  }
1077
1078  private static int function_id = -1;
1079
1080  @Override
1081  public int get_function_id() {
1082    return function_id;
1083  }
1084
1085  @Override
1086  public void set_function_id(int function_id) {
1087    assert MultiplyLong_zxy.function_id == -1;
1088    MultiplyLong_zxy.function_id = function_id;
1089  }
1090
1091  private static int var_order = 3;
1092
1093  @Override
1094  public int get_var_order(@GuardSatisfied MultiplyLong_zxy this) {
1095    return var_order;
1096  }
1097
1098  @Pure
1099  @Override
1100  public boolean is_symmetric() {
1101
1102      return true;
1103  }
1104
1105  @Override
1106
1107  public long func(long x, long y) {
1108
1109    return x * y;
1110  }
1111
1112  @Override
1113  public InvariantStatus check_modified(long x, long y,
1114                                      long z, int count) {
1115    return check_ordered(z, x, y, count);
1116  }
1117
1118  @Override
1119  public InvariantStatus add_modified(long x, long y,
1120                                      long z, int count) {
1121    if (Debug.logDetail()) {
1122      log("result=%s, arg1=%s, arg2=%s", z, x, y);
1123    }
1124    return add_ordered(z, x, y, count);
1125  }
1126
1127  @Pure
1128  @Override
1129  public boolean isMultiply() {
1130    return true;
1131  }
1132
1133  @Pure
1134  @Override
1135  public boolean isExact() {
1136    return true;
1137  }
1138
1139  /** Returns a list of non-instantiating suppressions for this invariant. */
1140  @Pure
1141  @Override
1142  public @Nullable NISuppressionSet get_ni_suppressions() {
1143    if (NIS.dkconfig_enabled && dkconfig_enabled) {
1144      return suppressions;
1145    } else {
1146      return null;
1147    }
1148  }
1149
1150  /** definition of this invariant (the suppressee) */
1151  private static NISuppressee suppressee = new NISuppressee(MultiplyLong_zxy.class, 3);
1152
1153  // suppressor definitions (used below)
1154  private static NISuppressor result_eq_arg1 =
1155      new NISuppressor(2, 0, IntEqual.class);
1156  private static NISuppressor result_eq_arg2 =
1157      new NISuppressor(2, 1, IntEqual.class);
1158  private static NISuppressor arg1_eq_arg2 =
1159      new NISuppressor(0, 1, IntEqual.class);
1160
1161  private static NISuppressor result_lt_arg1 =
1162      new NISuppressor(2, 0, IntLessThan.class);
1163  private static NISuppressor result_lt_arg2 =
1164      new NISuppressor(2, 1, IntLessThan.class);
1165  private static NISuppressor arg1_lt_arg2 =
1166      new NISuppressor(0, 1, IntLessThan.class);
1167  private static NISuppressor arg2_lt_arg1 =
1168      new NISuppressor(1, 0, IntLessThan.class);
1169
1170  private static NISuppressor result_le_arg1 =
1171      new NISuppressor(2, 0, IntLessEqual.class);
1172  private static NISuppressor result_le_arg2 =
1173      new NISuppressor(2, 1, IntLessEqual.class);
1174  private static NISuppressor arg1_le_arg2 =
1175      new NISuppressor(0, 1, IntLessEqual.class);
1176  private static NISuppressor arg2_le_arg1 =
1177      new NISuppressor(1, 0, IntLessEqual.class);
1178
1179  private static NISuppressor result_track0_arg1 =
1180      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
1181  private static NISuppressor result_track0_arg2 =
1182      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
1183  private static NISuppressor arg1_track0_arg2 =
1184      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
1185  private static NISuppressor arg1_track0_result =
1186      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
1187  private static NISuppressor arg2_track0_result =
1188      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
1189  private static NISuppressor arg2_track0_arg1 =
1190      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
1191
1192  private static NISuppressor result_eq_1 =
1193      new NISuppressor(2, RangeInt.EqualOne.class);
1194  private static NISuppressor arg1_eq_1 =
1195      new NISuppressor(0, RangeInt.EqualOne.class);
1196  private static NISuppressor arg2_eq_1 =
1197      new NISuppressor(1, RangeInt.EqualOne.class);
1198
1199  private static NISuppressor result_eq_0 =
1200      new NISuppressor(2, RangeInt.EqualZero.class);
1201  private static NISuppressor arg1_eq_0 =
1202      new NISuppressor(0, RangeInt.EqualZero.class);
1203  private static NISuppressor arg2_eq_0 =
1204      new NISuppressor(1, RangeInt.EqualZero.class);
1205
1206  private static NISuppressor result_ne_0 =
1207      new NISuppressor(2, NonZero.class);
1208  private static NISuppressor arg1_ne_0 =
1209      new NISuppressor(0, NonZero.class);
1210  private static NISuppressor arg2_ne_0 =
1211      new NISuppressor(1, NonZero.class);
1212
1213  private static NISuppressor result_ge_0 =
1214      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
1215  private static NISuppressor arg1_ge_0 =
1216      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
1217  private static NISuppressor arg2_ge_0 =
1218      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
1219
1220  private static NISuppressor result_ge_64 =
1221      new NISuppressor(2, RangeInt.GreaterEqual64.class);
1222  private static NISuppressor arg1_ge_64 =
1223      new NISuppressor(0, RangeInt.GreaterEqual64.class);
1224  private static NISuppressor arg2_ge_64 =
1225      new NISuppressor(1, RangeInt.GreaterEqual64.class);
1226
1227  private static NISuppressor result_boolean =
1228      new NISuppressor(2, RangeInt.BooleanVal.class);
1229  private static NISuppressor arg1_boolean =
1230      new NISuppressor(0, RangeInt.BooleanVal.class);
1231  private static NISuppressor arg2_boolean =
1232      new NISuppressor(1, RangeInt.BooleanVal.class);
1233
1234  private static NISuppressor result_even =
1235      new NISuppressor(2, RangeInt.Even.class);
1236  private static NISuppressor arg1_even =
1237      new NISuppressor(0, RangeInt.Even.class);
1238  private static NISuppressor arg2_even =
1239      new NISuppressor(1, RangeInt.Even.class);
1240
1241  private static NISuppressor result_power2 =
1242      new NISuppressor(2, RangeInt.PowerOfTwo.class);
1243  private static NISuppressor arg1_power2 =
1244      new NISuppressor(0, RangeInt.PowerOfTwo.class);
1245  private static NISuppressor arg2_power2 =
1246      new NISuppressor(1, RangeInt.PowerOfTwo.class);
1247
1248  private static NISuppressor result_and0_arg1 =
1249      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
1250  private static NISuppressor result_and0_arg2 =
1251      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
1252  private static NISuppressor arg1_and0_arg2 =
1253      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
1254
1255  // The arguments to bitwise subset are backwards from what one
1256  // might expect.  The second argument is a subset of the first
1257  // argument
1258  private static NISuppressor arg1_bw_subset_arg2 =
1259      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
1260  private static NISuppressor arg2_bw_subset_arg1 =
1261      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
1262
1263  private static NISuppressor result_shift0_arg1 =
1264      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
1265  private static NISuppressor result_shift0_arg2 =
1266      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
1267  private static NISuppressor arg1_shift0_arg2 =
1268      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
1269
1270  private static NISuppressor arg2_divides_arg1 =
1271      new NISuppressor(0, 1, NumericInt.Divides.class);
1272  private static NISuppressor arg1_divides_arg2 =
1273      new NISuppressor(1, 0, NumericInt.Divides.class);
1274
1275  private static NISuppressor arg2_valid_shift =
1276      new NISuppressor(1, RangeInt.Bound0_63.class);
1277
1278    private static NISuppressionSet suppressions =
1279      new NISuppressionSet(
1280          new NISuppression[] {
1281
1282            // (r == 0) && (x == 0) ==> r = x * y
1283            new NISuppression(result_eq_0, arg1_eq_0, suppressee),
1284
1285            // (r == 0) && (y == 0) ==> r = x * y
1286            new NISuppression(result_eq_0, arg2_eq_0, suppressee),
1287
1288            // (r == x) && (y == 1) ==> r = x * y
1289            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
1290
1291            // (r == y) && (x == 1) ==> r = x * y
1292            new NISuppression(result_eq_arg2, arg1_eq_1, suppressee),
1293
1294            // (r == x) && (y boolean) && (y==0 ==> x==0)
1295            // x = x * 0 is true if x == 0
1296            // x = x * 1 is true for all x
1297            new NISuppression(arg2_boolean, arg2_track0_arg1, result_eq_arg1,
1298                               suppressee),
1299
1300            // (r == y) && (x boolean) && (x==0 ==> y=0)
1301            new NISuppression(result_eq_arg2, arg1_track0_arg2, arg1_boolean,
1302                               suppressee),
1303
1304          });
1305
1306  // Create a suppression factory for functionBinary
1307
1308}
1309
1310  // #define EQUALITY_MIN_MAX_SUPPRESS
1311
1312  // default is that it is not this function, overriden in the subclass
1313  @Pure
1314  public boolean isMinimum() {
1315    return false;
1316  }
1317
1318/**
1319 * Represents the invariant {@code x = Minimum(y, z)} over three long
1320 * scalars. 
1321 */
1322public static class MinimumLong_xyz extends FunctionBinary {
1323  // We are Serializable, so we specify a version to allow changes to
1324  // method signatures without breaking serialization.  If you add or
1325  // remove fields, you should change this number to the current date.
1326  static final long serialVersionUID = 20031030L;
1327
1328  private static @Prototype MinimumLong_xyz proto = new @Prototype MinimumLong_xyz ();
1329
1330  /** Returns the prototype invariant for MinimumLong_xyz */
1331  public static @Prototype MinimumLong_xyz get_proto() {
1332    return proto;
1333  }
1334
1335  /** instantiate an invariant on the specified slice */
1336  @Override
1337  protected MinimumLong_xyz instantiate_dyn(@Prototype MinimumLong_xyz this, PptSlice slice) {
1338    return new MinimumLong_xyz (slice);
1339  }
1340
1341  private MinimumLong_xyz (PptSlice slice) {
1342    super(slice);
1343  }
1344
1345  public @Prototype MinimumLong_xyz () {
1346    super();
1347  }
1348
1349  private static String[] method_name = new String[] {"java.lang.Math.min(", ", ", ")"};
1350
1351  @Override
1352  public String[] get_method_name(@GuardSatisfied MinimumLong_xyz this) {
1353    return method_name;
1354  }
1355
1356  private static int function_id = -1;
1357
1358  @Override
1359  public int get_function_id() {
1360    return function_id;
1361  }
1362
1363  @Override
1364  public void set_function_id(int function_id) {
1365    assert MinimumLong_xyz.function_id == -1;
1366    MinimumLong_xyz.function_id = function_id;
1367  }
1368
1369  private static int var_order = 1;
1370
1371  @Override
1372  public int get_var_order(@GuardSatisfied MinimumLong_xyz this) {
1373    return var_order;
1374  }
1375
1376  @Pure
1377  @Override
1378  public boolean is_symmetric() {
1379
1380      return true;
1381  }
1382
1383  @Override
1384
1385  public long func(long y, long z) {
1386
1387    return Math.min(y, z);
1388  }
1389
1390  @Override
1391  public InvariantStatus check_modified(long x, long y,
1392                                      long z, int count) {
1393    return check_ordered(x, y, z, count);
1394  }
1395
1396  @Override
1397  public InvariantStatus add_modified(long x, long y,
1398                                      long z, int count) {
1399    if (Debug.logDetail()) {
1400      log("result=%s, arg1=%s, arg2=%s", x, y, z);
1401    }
1402    return add_ordered(x, y, z, count);
1403  }
1404
1405  @Pure
1406  @Override
1407  public boolean isMinimum() {
1408    return true;
1409  }
1410
1411  /** Returns a list of non-instantiating suppressions for this invariant. */
1412  @Pure
1413  @Override
1414  public @Nullable NISuppressionSet get_ni_suppressions() {
1415    if (NIS.dkconfig_enabled && dkconfig_enabled) {
1416      return suppressions;
1417    } else {
1418      return null;
1419    }
1420  }
1421
1422  /** definition of this invariant (the suppressee) */
1423  private static NISuppressee suppressee = new NISuppressee(MinimumLong_xyz.class, 3);
1424
1425  // suppressor definitions (used below)
1426  private static NISuppressor result_eq_arg1 =
1427      new NISuppressor(0, 1, IntEqual.class);
1428  private static NISuppressor result_eq_arg2 =
1429      new NISuppressor(0, 2, IntEqual.class);
1430  private static NISuppressor arg1_eq_arg2 =
1431      new NISuppressor(1, 2, IntEqual.class);
1432
1433  private static NISuppressor result_lt_arg1 =
1434      new NISuppressor(0, 1, IntLessThan.class);
1435  private static NISuppressor result_lt_arg2 =
1436      new NISuppressor(0, 2, IntLessThan.class);
1437  private static NISuppressor arg1_lt_arg2 =
1438      new NISuppressor(1, 2, IntLessThan.class);
1439  private static NISuppressor arg2_lt_arg1 =
1440      new NISuppressor(2, 1, IntLessThan.class);
1441
1442  private static NISuppressor result_le_arg1 =
1443      new NISuppressor(0, 1, IntLessEqual.class);
1444  private static NISuppressor result_le_arg2 =
1445      new NISuppressor(0, 2, IntLessEqual.class);
1446  private static NISuppressor arg1_le_arg2 =
1447      new NISuppressor(1, 2, IntLessEqual.class);
1448  private static NISuppressor arg2_le_arg1 =
1449      new NISuppressor(2, 1, IntLessEqual.class);
1450
1451  private static NISuppressor result_track0_arg1 =
1452      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
1453  private static NISuppressor result_track0_arg2 =
1454      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
1455  private static NISuppressor arg1_track0_arg2 =
1456      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
1457  private static NISuppressor arg1_track0_result =
1458      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
1459  private static NISuppressor arg2_track0_result =
1460      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
1461  private static NISuppressor arg2_track0_arg1 =
1462      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
1463
1464  private static NISuppressor result_eq_1 =
1465      new NISuppressor(0, RangeInt.EqualOne.class);
1466  private static NISuppressor arg1_eq_1 =
1467      new NISuppressor(1, RangeInt.EqualOne.class);
1468  private static NISuppressor arg2_eq_1 =
1469      new NISuppressor(2, RangeInt.EqualOne.class);
1470
1471  private static NISuppressor result_eq_0 =
1472      new NISuppressor(0, RangeInt.EqualZero.class);
1473  private static NISuppressor arg1_eq_0 =
1474      new NISuppressor(1, RangeInt.EqualZero.class);
1475  private static NISuppressor arg2_eq_0 =
1476      new NISuppressor(2, RangeInt.EqualZero.class);
1477
1478  private static NISuppressor result_ne_0 =
1479      new NISuppressor(0, NonZero.class);
1480  private static NISuppressor arg1_ne_0 =
1481      new NISuppressor(1, NonZero.class);
1482  private static NISuppressor arg2_ne_0 =
1483      new NISuppressor(2, NonZero.class);
1484
1485  private static NISuppressor result_ge_0 =
1486      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
1487  private static NISuppressor arg1_ge_0 =
1488      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
1489  private static NISuppressor arg2_ge_0 =
1490      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
1491
1492  private static NISuppressor result_ge_64 =
1493      new NISuppressor(0, RangeInt.GreaterEqual64.class);
1494  private static NISuppressor arg1_ge_64 =
1495      new NISuppressor(1, RangeInt.GreaterEqual64.class);
1496  private static NISuppressor arg2_ge_64 =
1497      new NISuppressor(2, RangeInt.GreaterEqual64.class);
1498
1499  private static NISuppressor result_boolean =
1500      new NISuppressor(0, RangeInt.BooleanVal.class);
1501  private static NISuppressor arg1_boolean =
1502      new NISuppressor(1, RangeInt.BooleanVal.class);
1503  private static NISuppressor arg2_boolean =
1504      new NISuppressor(2, RangeInt.BooleanVal.class);
1505
1506  private static NISuppressor result_even =
1507      new NISuppressor(0, RangeInt.Even.class);
1508  private static NISuppressor arg1_even =
1509      new NISuppressor(1, RangeInt.Even.class);
1510  private static NISuppressor arg2_even =
1511      new NISuppressor(2, RangeInt.Even.class);
1512
1513  private static NISuppressor result_power2 =
1514      new NISuppressor(0, RangeInt.PowerOfTwo.class);
1515  private static NISuppressor arg1_power2 =
1516      new NISuppressor(1, RangeInt.PowerOfTwo.class);
1517  private static NISuppressor arg2_power2 =
1518      new NISuppressor(2, RangeInt.PowerOfTwo.class);
1519
1520  private static NISuppressor result_and0_arg1 =
1521      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
1522  private static NISuppressor result_and0_arg2 =
1523      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
1524  private static NISuppressor arg1_and0_arg2 =
1525      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
1526
1527  // The arguments to bitwise subset are backwards from what one
1528  // might expect.  The second argument is a subset of the first
1529  // argument
1530  private static NISuppressor arg1_bw_subset_arg2 =
1531      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
1532  private static NISuppressor arg2_bw_subset_arg1 =
1533      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
1534
1535  private static NISuppressor result_shift0_arg1 =
1536      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
1537  private static NISuppressor result_shift0_arg2 =
1538      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
1539  private static NISuppressor arg1_shift0_arg2 =
1540      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
1541
1542  private static NISuppressor arg2_divides_arg1 =
1543      new NISuppressor(1, 2, NumericInt.Divides.class);
1544  private static NISuppressor arg1_divides_arg2 =
1545      new NISuppressor(2, 1, NumericInt.Divides.class);
1546
1547  private static NISuppressor arg2_valid_shift =
1548      new NISuppressor(2, RangeInt.Bound0_63.class);
1549
1550    private static NISuppressionSet suppressions =
1551      new NISuppressionSet(
1552          new NISuppression[] {
1553
1554            // (x == y) && (y <= z) ==> r = min(y, z)
1555            new NISuppression(result_eq_arg1, arg1_le_arg2, suppressee),
1556
1557            // (x == z) && (z <= y) ==> r = min(y, z)
1558            new NISuppression(result_eq_arg2, arg2_le_arg1, suppressee),
1559
1560            // (x boolean) && (y=0 <==> r=0) && (z == 1)
1561            // 0 = min (y, 1), true when (y == 0)
1562            // 1 = min (y, 1), true when (y > 0)
1563            new NISuppression(result_track0_arg1, arg1_track0_result,
1564                               result_boolean, arg1_ge_0, arg2_eq_1, suppressee),
1565
1566            // (x boolean) && (z=0 <==> r=0) && (y == 1)
1567            new NISuppression(result_track0_arg2, arg2_track0_result,
1568                               result_boolean, arg2_ge_0, arg1_eq_1, suppressee),
1569
1570          });
1571
1572  // Create a suppression factory for functionBinary
1573
1574}
1575
1576/**
1577 * Represents the invariant {@code y = Minimum(x, z)} over three long
1578 * scalars. 
1579 */
1580public static class MinimumLong_yxz extends FunctionBinary {
1581  // We are Serializable, so we specify a version to allow changes to
1582  // method signatures without breaking serialization.  If you add or
1583  // remove fields, you should change this number to the current date.
1584  static final long serialVersionUID = 20031030L;
1585
1586  private static @Prototype MinimumLong_yxz proto = new @Prototype MinimumLong_yxz ();
1587
1588  /** Returns the prototype invariant for MinimumLong_yxz */
1589  public static @Prototype MinimumLong_yxz get_proto() {
1590    return proto;
1591  }
1592
1593  /** instantiate an invariant on the specified slice */
1594  @Override
1595  protected MinimumLong_yxz instantiate_dyn(@Prototype MinimumLong_yxz this, PptSlice slice) {
1596    return new MinimumLong_yxz (slice);
1597  }
1598
1599  private MinimumLong_yxz (PptSlice slice) {
1600    super(slice);
1601  }
1602
1603  public @Prototype MinimumLong_yxz () {
1604    super();
1605  }
1606
1607  private static String[] method_name = new String[] {"java.lang.Math.min(", ", ", ")"};
1608
1609  @Override
1610  public String[] get_method_name(@GuardSatisfied MinimumLong_yxz this) {
1611    return method_name;
1612  }
1613
1614  private static int function_id = -1;
1615
1616  @Override
1617  public int get_function_id() {
1618    return function_id;
1619  }
1620
1621  @Override
1622  public void set_function_id(int function_id) {
1623    assert MinimumLong_yxz.function_id == -1;
1624    MinimumLong_yxz.function_id = function_id;
1625  }
1626
1627  private static int var_order = 2;
1628
1629  @Override
1630  public int get_var_order(@GuardSatisfied MinimumLong_yxz this) {
1631    return var_order;
1632  }
1633
1634  @Pure
1635  @Override
1636  public boolean is_symmetric() {
1637
1638      return true;
1639  }
1640
1641  @Override
1642
1643  public long func(long x, long z) {
1644
1645    return Math.min(x, z);
1646  }
1647
1648  @Override
1649  public InvariantStatus check_modified(long x, long y,
1650                                      long z, int count) {
1651    return check_ordered(y, x, z, count);
1652  }
1653
1654  @Override
1655  public InvariantStatus add_modified(long x, long y,
1656                                      long z, int count) {
1657    if (Debug.logDetail()) {
1658      log("result=%s, arg1=%s, arg2=%s", y, x, z);
1659    }
1660    return add_ordered(y, x, z, count);
1661  }
1662
1663  @Pure
1664  @Override
1665  public boolean isMinimum() {
1666    return true;
1667  }
1668
1669  /** Returns a list of non-instantiating suppressions for this invariant. */
1670  @Pure
1671  @Override
1672  public @Nullable NISuppressionSet get_ni_suppressions() {
1673    if (NIS.dkconfig_enabled && dkconfig_enabled) {
1674      return suppressions;
1675    } else {
1676      return null;
1677    }
1678  }
1679
1680  /** definition of this invariant (the suppressee) */
1681  private static NISuppressee suppressee = new NISuppressee(MinimumLong_yxz.class, 3);
1682
1683  // suppressor definitions (used below)
1684  private static NISuppressor result_eq_arg1 =
1685      new NISuppressor(1, 0, IntEqual.class);
1686  private static NISuppressor result_eq_arg2 =
1687      new NISuppressor(1, 2, IntEqual.class);
1688  private static NISuppressor arg1_eq_arg2 =
1689      new NISuppressor(0, 2, IntEqual.class);
1690
1691  private static NISuppressor result_lt_arg1 =
1692      new NISuppressor(1, 0, IntLessThan.class);
1693  private static NISuppressor result_lt_arg2 =
1694      new NISuppressor(1, 2, IntLessThan.class);
1695  private static NISuppressor arg1_lt_arg2 =
1696      new NISuppressor(0, 2, IntLessThan.class);
1697  private static NISuppressor arg2_lt_arg1 =
1698      new NISuppressor(2, 0, IntLessThan.class);
1699
1700  private static NISuppressor result_le_arg1 =
1701      new NISuppressor(1, 0, IntLessEqual.class);
1702  private static NISuppressor result_le_arg2 =
1703      new NISuppressor(1, 2, IntLessEqual.class);
1704  private static NISuppressor arg1_le_arg2 =
1705      new NISuppressor(0, 2, IntLessEqual.class);
1706  private static NISuppressor arg2_le_arg1 =
1707      new NISuppressor(2, 0, IntLessEqual.class);
1708
1709  private static NISuppressor result_track0_arg1 =
1710      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
1711  private static NISuppressor result_track0_arg2 =
1712      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
1713  private static NISuppressor arg1_track0_arg2 =
1714      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
1715  private static NISuppressor arg1_track0_result =
1716      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
1717  private static NISuppressor arg2_track0_result =
1718      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
1719  private static NISuppressor arg2_track0_arg1 =
1720      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
1721
1722  private static NISuppressor result_eq_1 =
1723      new NISuppressor(1, RangeInt.EqualOne.class);
1724  private static NISuppressor arg1_eq_1 =
1725      new NISuppressor(0, RangeInt.EqualOne.class);
1726  private static NISuppressor arg2_eq_1 =
1727      new NISuppressor(2, RangeInt.EqualOne.class);
1728
1729  private static NISuppressor result_eq_0 =
1730      new NISuppressor(1, RangeInt.EqualZero.class);
1731  private static NISuppressor arg1_eq_0 =
1732      new NISuppressor(0, RangeInt.EqualZero.class);
1733  private static NISuppressor arg2_eq_0 =
1734      new NISuppressor(2, RangeInt.EqualZero.class);
1735
1736  private static NISuppressor result_ne_0 =
1737      new NISuppressor(1, NonZero.class);
1738  private static NISuppressor arg1_ne_0 =
1739      new NISuppressor(0, NonZero.class);
1740  private static NISuppressor arg2_ne_0 =
1741      new NISuppressor(2, NonZero.class);
1742
1743  private static NISuppressor result_ge_0 =
1744      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
1745  private static NISuppressor arg1_ge_0 =
1746      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
1747  private static NISuppressor arg2_ge_0 =
1748      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
1749
1750  private static NISuppressor result_ge_64 =
1751      new NISuppressor(1, RangeInt.GreaterEqual64.class);
1752  private static NISuppressor arg1_ge_64 =
1753      new NISuppressor(0, RangeInt.GreaterEqual64.class);
1754  private static NISuppressor arg2_ge_64 =
1755      new NISuppressor(2, RangeInt.GreaterEqual64.class);
1756
1757  private static NISuppressor result_boolean =
1758      new NISuppressor(1, RangeInt.BooleanVal.class);
1759  private static NISuppressor arg1_boolean =
1760      new NISuppressor(0, RangeInt.BooleanVal.class);
1761  private static NISuppressor arg2_boolean =
1762      new NISuppressor(2, RangeInt.BooleanVal.class);
1763
1764  private static NISuppressor result_even =
1765      new NISuppressor(1, RangeInt.Even.class);
1766  private static NISuppressor arg1_even =
1767      new NISuppressor(0, RangeInt.Even.class);
1768  private static NISuppressor arg2_even =
1769      new NISuppressor(2, RangeInt.Even.class);
1770
1771  private static NISuppressor result_power2 =
1772      new NISuppressor(1, RangeInt.PowerOfTwo.class);
1773  private static NISuppressor arg1_power2 =
1774      new NISuppressor(0, RangeInt.PowerOfTwo.class);
1775  private static NISuppressor arg2_power2 =
1776      new NISuppressor(2, RangeInt.PowerOfTwo.class);
1777
1778  private static NISuppressor result_and0_arg1 =
1779      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
1780  private static NISuppressor result_and0_arg2 =
1781      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
1782  private static NISuppressor arg1_and0_arg2 =
1783      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
1784
1785  // The arguments to bitwise subset are backwards from what one
1786  // might expect.  The second argument is a subset of the first
1787  // argument
1788  private static NISuppressor arg1_bw_subset_arg2 =
1789      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
1790  private static NISuppressor arg2_bw_subset_arg1 =
1791      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
1792
1793  private static NISuppressor result_shift0_arg1 =
1794      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
1795  private static NISuppressor result_shift0_arg2 =
1796      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
1797  private static NISuppressor arg1_shift0_arg2 =
1798      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
1799
1800  private static NISuppressor arg2_divides_arg1 =
1801      new NISuppressor(0, 2, NumericInt.Divides.class);
1802  private static NISuppressor arg1_divides_arg2 =
1803      new NISuppressor(2, 0, NumericInt.Divides.class);
1804
1805  private static NISuppressor arg2_valid_shift =
1806      new NISuppressor(2, RangeInt.Bound0_63.class);
1807
1808    private static NISuppressionSet suppressions =
1809      new NISuppressionSet(
1810          new NISuppression[] {
1811
1812            // (y == x) && (x <= z) ==> r = min(x, z)
1813            new NISuppression(result_eq_arg1, arg1_le_arg2, suppressee),
1814
1815            // (y == z) && (z <= x) ==> r = min(x, z)
1816            new NISuppression(result_eq_arg2, arg2_le_arg1, suppressee),
1817
1818            // (y boolean) && (x=0 <==> r=0) && (z == 1)
1819            // 0 = min (x, 1), true when (x == 0)
1820            // 1 = min (x, 1), true when (x > 0)
1821            new NISuppression(result_track0_arg1, arg1_track0_result,
1822                               result_boolean, arg1_ge_0, arg2_eq_1, suppressee),
1823
1824            // (y boolean) && (z=0 <==> r=0) && (x == 1)
1825            new NISuppression(result_track0_arg2, arg2_track0_result,
1826                               result_boolean, arg2_ge_0, arg1_eq_1, suppressee),
1827
1828          });
1829
1830  // Create a suppression factory for functionBinary
1831
1832}
1833
1834/**
1835 * Represents the invariant {@code z = Minimum(x, y)} over three long
1836 * scalars. 
1837 */
1838public static class MinimumLong_zxy extends FunctionBinary {
1839  // We are Serializable, so we specify a version to allow changes to
1840  // method signatures without breaking serialization.  If you add or
1841  // remove fields, you should change this number to the current date.
1842  static final long serialVersionUID = 20031030L;
1843
1844  private static @Prototype MinimumLong_zxy proto = new @Prototype MinimumLong_zxy ();
1845
1846  /** Returns the prototype invariant for MinimumLong_zxy */
1847  public static @Prototype MinimumLong_zxy get_proto() {
1848    return proto;
1849  }
1850
1851  /** instantiate an invariant on the specified slice */
1852  @Override
1853  protected MinimumLong_zxy instantiate_dyn(@Prototype MinimumLong_zxy this, PptSlice slice) {
1854    return new MinimumLong_zxy (slice);
1855  }
1856
1857  private MinimumLong_zxy (PptSlice slice) {
1858    super(slice);
1859  }
1860
1861  public @Prototype MinimumLong_zxy () {
1862    super();
1863  }
1864
1865  private static String[] method_name = new String[] {"java.lang.Math.min(", ", ", ")"};
1866
1867  @Override
1868  public String[] get_method_name(@GuardSatisfied MinimumLong_zxy this) {
1869    return method_name;
1870  }
1871
1872  private static int function_id = -1;
1873
1874  @Override
1875  public int get_function_id() {
1876    return function_id;
1877  }
1878
1879  @Override
1880  public void set_function_id(int function_id) {
1881    assert MinimumLong_zxy.function_id == -1;
1882    MinimumLong_zxy.function_id = function_id;
1883  }
1884
1885  private static int var_order = 3;
1886
1887  @Override
1888  public int get_var_order(@GuardSatisfied MinimumLong_zxy this) {
1889    return var_order;
1890  }
1891
1892  @Pure
1893  @Override
1894  public boolean is_symmetric() {
1895
1896      return true;
1897  }
1898
1899  @Override
1900
1901  public long func(long x, long y) {
1902
1903    return Math.min(x, y);
1904  }
1905
1906  @Override
1907  public InvariantStatus check_modified(long x, long y,
1908                                      long z, int count) {
1909    return check_ordered(z, x, y, count);
1910  }
1911
1912  @Override
1913  public InvariantStatus add_modified(long x, long y,
1914                                      long z, int count) {
1915    if (Debug.logDetail()) {
1916      log("result=%s, arg1=%s, arg2=%s", z, x, y);
1917    }
1918    return add_ordered(z, x, y, count);
1919  }
1920
1921  @Pure
1922  @Override
1923  public boolean isMinimum() {
1924    return true;
1925  }
1926
1927  /** Returns a list of non-instantiating suppressions for this invariant. */
1928  @Pure
1929  @Override
1930  public @Nullable NISuppressionSet get_ni_suppressions() {
1931    if (NIS.dkconfig_enabled && dkconfig_enabled) {
1932      return suppressions;
1933    } else {
1934      return null;
1935    }
1936  }
1937
1938  /** definition of this invariant (the suppressee) */
1939  private static NISuppressee suppressee = new NISuppressee(MinimumLong_zxy.class, 3);
1940
1941  // suppressor definitions (used below)
1942  private static NISuppressor result_eq_arg1 =
1943      new NISuppressor(2, 0, IntEqual.class);
1944  private static NISuppressor result_eq_arg2 =
1945      new NISuppressor(2, 1, IntEqual.class);
1946  private static NISuppressor arg1_eq_arg2 =
1947      new NISuppressor(0, 1, IntEqual.class);
1948
1949  private static NISuppressor result_lt_arg1 =
1950      new NISuppressor(2, 0, IntLessThan.class);
1951  private static NISuppressor result_lt_arg2 =
1952      new NISuppressor(2, 1, IntLessThan.class);
1953  private static NISuppressor arg1_lt_arg2 =
1954      new NISuppressor(0, 1, IntLessThan.class);
1955  private static NISuppressor arg2_lt_arg1 =
1956      new NISuppressor(1, 0, IntLessThan.class);
1957
1958  private static NISuppressor result_le_arg1 =
1959      new NISuppressor(2, 0, IntLessEqual.class);
1960  private static NISuppressor result_le_arg2 =
1961      new NISuppressor(2, 1, IntLessEqual.class);
1962  private static NISuppressor arg1_le_arg2 =
1963      new NISuppressor(0, 1, IntLessEqual.class);
1964  private static NISuppressor arg2_le_arg1 =
1965      new NISuppressor(1, 0, IntLessEqual.class);
1966
1967  private static NISuppressor result_track0_arg1 =
1968      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
1969  private static NISuppressor result_track0_arg2 =
1970      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
1971  private static NISuppressor arg1_track0_arg2 =
1972      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
1973  private static NISuppressor arg1_track0_result =
1974      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
1975  private static NISuppressor arg2_track0_result =
1976      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
1977  private static NISuppressor arg2_track0_arg1 =
1978      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
1979
1980  private static NISuppressor result_eq_1 =
1981      new NISuppressor(2, RangeInt.EqualOne.class);
1982  private static NISuppressor arg1_eq_1 =
1983      new NISuppressor(0, RangeInt.EqualOne.class);
1984  private static NISuppressor arg2_eq_1 =
1985      new NISuppressor(1, RangeInt.EqualOne.class);
1986
1987  private static NISuppressor result_eq_0 =
1988      new NISuppressor(2, RangeInt.EqualZero.class);
1989  private static NISuppressor arg1_eq_0 =
1990      new NISuppressor(0, RangeInt.EqualZero.class);
1991  private static NISuppressor arg2_eq_0 =
1992      new NISuppressor(1, RangeInt.EqualZero.class);
1993
1994  private static NISuppressor result_ne_0 =
1995      new NISuppressor(2, NonZero.class);
1996  private static NISuppressor arg1_ne_0 =
1997      new NISuppressor(0, NonZero.class);
1998  private static NISuppressor arg2_ne_0 =
1999      new NISuppressor(1, NonZero.class);
2000
2001  private static NISuppressor result_ge_0 =
2002      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
2003  private static NISuppressor arg1_ge_0 =
2004      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
2005  private static NISuppressor arg2_ge_0 =
2006      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
2007
2008  private static NISuppressor result_ge_64 =
2009      new NISuppressor(2, RangeInt.GreaterEqual64.class);
2010  private static NISuppressor arg1_ge_64 =
2011      new NISuppressor(0, RangeInt.GreaterEqual64.class);
2012  private static NISuppressor arg2_ge_64 =
2013      new NISuppressor(1, RangeInt.GreaterEqual64.class);
2014
2015  private static NISuppressor result_boolean =
2016      new NISuppressor(2, RangeInt.BooleanVal.class);
2017  private static NISuppressor arg1_boolean =
2018      new NISuppressor(0, RangeInt.BooleanVal.class);
2019  private static NISuppressor arg2_boolean =
2020      new NISuppressor(1, RangeInt.BooleanVal.class);
2021
2022  private static NISuppressor result_even =
2023      new NISuppressor(2, RangeInt.Even.class);
2024  private static NISuppressor arg1_even =
2025      new NISuppressor(0, RangeInt.Even.class);
2026  private static NISuppressor arg2_even =
2027      new NISuppressor(1, RangeInt.Even.class);
2028
2029  private static NISuppressor result_power2 =
2030      new NISuppressor(2, RangeInt.PowerOfTwo.class);
2031  private static NISuppressor arg1_power2 =
2032      new NISuppressor(0, RangeInt.PowerOfTwo.class);
2033  private static NISuppressor arg2_power2 =
2034      new NISuppressor(1, RangeInt.PowerOfTwo.class);
2035
2036  private static NISuppressor result_and0_arg1 =
2037      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
2038  private static NISuppressor result_and0_arg2 =
2039      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
2040  private static NISuppressor arg1_and0_arg2 =
2041      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
2042
2043  // The arguments to bitwise subset are backwards from what one
2044  // might expect.  The second argument is a subset of the first
2045  // argument
2046  private static NISuppressor arg1_bw_subset_arg2 =
2047      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
2048  private static NISuppressor arg2_bw_subset_arg1 =
2049      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
2050
2051  private static NISuppressor result_shift0_arg1 =
2052      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
2053  private static NISuppressor result_shift0_arg2 =
2054      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
2055  private static NISuppressor arg1_shift0_arg2 =
2056      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
2057
2058  private static NISuppressor arg2_divides_arg1 =
2059      new NISuppressor(0, 1, NumericInt.Divides.class);
2060  private static NISuppressor arg1_divides_arg2 =
2061      new NISuppressor(1, 0, NumericInt.Divides.class);
2062
2063  private static NISuppressor arg2_valid_shift =
2064      new NISuppressor(1, RangeInt.Bound0_63.class);
2065
2066    private static NISuppressionSet suppressions =
2067      new NISuppressionSet(
2068          new NISuppression[] {
2069
2070            // (z == x) && (x <= y) ==> r = min(x, y)
2071            new NISuppression(result_eq_arg1, arg1_le_arg2, suppressee),
2072
2073            // (z == y) && (y <= x) ==> r = min(x, y)
2074            new NISuppression(result_eq_arg2, arg2_le_arg1, suppressee),
2075
2076            // (z boolean) && (x=0 <==> r=0) && (y == 1)
2077            // 0 = min (x, 1), true when (x == 0)
2078            // 1 = min (x, 1), true when (x > 0)
2079            new NISuppression(result_track0_arg1, arg1_track0_result,
2080                               result_boolean, arg1_ge_0, arg2_eq_1, suppressee),
2081
2082            // (z boolean) && (y=0 <==> r=0) && (x == 1)
2083            new NISuppression(result_track0_arg2, arg2_track0_result,
2084                               result_boolean, arg2_ge_0, arg1_eq_1, suppressee),
2085
2086          });
2087
2088  // Create a suppression factory for functionBinary
2089
2090}
2091
2092  // #define EQUALITY_MIN_MAX_SUPPRESS
2093
2094  // default is that it is not this function, overriden in the subclass
2095  @Pure
2096  public boolean isMaximum() {
2097    return false;
2098  }
2099
2100/**
2101 * Represents the invariant {@code x = Maximum(y, z)} over three long
2102 * scalars. 
2103 */
2104public static class MaximumLong_xyz extends FunctionBinary {
2105  // We are Serializable, so we specify a version to allow changes to
2106  // method signatures without breaking serialization.  If you add or
2107  // remove fields, you should change this number to the current date.
2108  static final long serialVersionUID = 20031030L;
2109
2110  private static @Prototype MaximumLong_xyz proto = new @Prototype MaximumLong_xyz ();
2111
2112  /** Returns the prototype invariant for MaximumLong_xyz */
2113  public static @Prototype MaximumLong_xyz get_proto() {
2114    return proto;
2115  }
2116
2117  /** instantiate an invariant on the specified slice */
2118  @Override
2119  protected MaximumLong_xyz instantiate_dyn(@Prototype MaximumLong_xyz this, PptSlice slice) {
2120    return new MaximumLong_xyz (slice);
2121  }
2122
2123  private MaximumLong_xyz (PptSlice slice) {
2124    super(slice);
2125  }
2126
2127  public @Prototype MaximumLong_xyz () {
2128    super();
2129  }
2130
2131  private static String[] method_name = new String[] {"java.lang.Math.max(", ", ", ")"};
2132
2133  @Override
2134  public String[] get_method_name(@GuardSatisfied MaximumLong_xyz this) {
2135    return method_name;
2136  }
2137
2138  private static int function_id = -1;
2139
2140  @Override
2141  public int get_function_id() {
2142    return function_id;
2143  }
2144
2145  @Override
2146  public void set_function_id(int function_id) {
2147    assert MaximumLong_xyz.function_id == -1;
2148    MaximumLong_xyz.function_id = function_id;
2149  }
2150
2151  private static int var_order = 1;
2152
2153  @Override
2154  public int get_var_order(@GuardSatisfied MaximumLong_xyz this) {
2155    return var_order;
2156  }
2157
2158  @Pure
2159  @Override
2160  public boolean is_symmetric() {
2161
2162      return true;
2163  }
2164
2165  @Override
2166
2167  public long func(long y, long z) {
2168
2169    return Math.max(y, z);
2170  }
2171
2172  @Override
2173  public InvariantStatus check_modified(long x, long y,
2174                                      long z, int count) {
2175    return check_ordered(x, y, z, count);
2176  }
2177
2178  @Override
2179  public InvariantStatus add_modified(long x, long y,
2180                                      long z, int count) {
2181    if (Debug.logDetail()) {
2182      log("result=%s, arg1=%s, arg2=%s", x, y, z);
2183    }
2184    return add_ordered(x, y, z, count);
2185  }
2186
2187  @Pure
2188  @Override
2189  public boolean isMaximum() {
2190    return true;
2191  }
2192
2193  /** Returns a list of non-instantiating suppressions for this invariant. */
2194  @Pure
2195  @Override
2196  public @Nullable NISuppressionSet get_ni_suppressions() {
2197    if (NIS.dkconfig_enabled && dkconfig_enabled) {
2198      return suppressions;
2199    } else {
2200      return null;
2201    }
2202  }
2203
2204  /** definition of this invariant (the suppressee) */
2205  private static NISuppressee suppressee = new NISuppressee(MaximumLong_xyz.class, 3);
2206
2207  // suppressor definitions (used below)
2208  private static NISuppressor result_eq_arg1 =
2209      new NISuppressor(0, 1, IntEqual.class);
2210  private static NISuppressor result_eq_arg2 =
2211      new NISuppressor(0, 2, IntEqual.class);
2212  private static NISuppressor arg1_eq_arg2 =
2213      new NISuppressor(1, 2, IntEqual.class);
2214
2215  private static NISuppressor result_lt_arg1 =
2216      new NISuppressor(0, 1, IntLessThan.class);
2217  private static NISuppressor result_lt_arg2 =
2218      new NISuppressor(0, 2, IntLessThan.class);
2219  private static NISuppressor arg1_lt_arg2 =
2220      new NISuppressor(1, 2, IntLessThan.class);
2221  private static NISuppressor arg2_lt_arg1 =
2222      new NISuppressor(2, 1, IntLessThan.class);
2223
2224  private static NISuppressor result_le_arg1 =
2225      new NISuppressor(0, 1, IntLessEqual.class);
2226  private static NISuppressor result_le_arg2 =
2227      new NISuppressor(0, 2, IntLessEqual.class);
2228  private static NISuppressor arg1_le_arg2 =
2229      new NISuppressor(1, 2, IntLessEqual.class);
2230  private static NISuppressor arg2_le_arg1 =
2231      new NISuppressor(2, 1, IntLessEqual.class);
2232
2233  private static NISuppressor result_track0_arg1 =
2234      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
2235  private static NISuppressor result_track0_arg2 =
2236      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
2237  private static NISuppressor arg1_track0_arg2 =
2238      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
2239  private static NISuppressor arg1_track0_result =
2240      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
2241  private static NISuppressor arg2_track0_result =
2242      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
2243  private static NISuppressor arg2_track0_arg1 =
2244      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
2245
2246  private static NISuppressor result_eq_1 =
2247      new NISuppressor(0, RangeInt.EqualOne.class);
2248  private static NISuppressor arg1_eq_1 =
2249      new NISuppressor(1, RangeInt.EqualOne.class);
2250  private static NISuppressor arg2_eq_1 =
2251      new NISuppressor(2, RangeInt.EqualOne.class);
2252
2253  private static NISuppressor result_eq_0 =
2254      new NISuppressor(0, RangeInt.EqualZero.class);
2255  private static NISuppressor arg1_eq_0 =
2256      new NISuppressor(1, RangeInt.EqualZero.class);
2257  private static NISuppressor arg2_eq_0 =
2258      new NISuppressor(2, RangeInt.EqualZero.class);
2259
2260  private static NISuppressor result_ne_0 =
2261      new NISuppressor(0, NonZero.class);
2262  private static NISuppressor arg1_ne_0 =
2263      new NISuppressor(1, NonZero.class);
2264  private static NISuppressor arg2_ne_0 =
2265      new NISuppressor(2, NonZero.class);
2266
2267  private static NISuppressor result_ge_0 =
2268      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
2269  private static NISuppressor arg1_ge_0 =
2270      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
2271  private static NISuppressor arg2_ge_0 =
2272      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
2273
2274  private static NISuppressor result_ge_64 =
2275      new NISuppressor(0, RangeInt.GreaterEqual64.class);
2276  private static NISuppressor arg1_ge_64 =
2277      new NISuppressor(1, RangeInt.GreaterEqual64.class);
2278  private static NISuppressor arg2_ge_64 =
2279      new NISuppressor(2, RangeInt.GreaterEqual64.class);
2280
2281  private static NISuppressor result_boolean =
2282      new NISuppressor(0, RangeInt.BooleanVal.class);
2283  private static NISuppressor arg1_boolean =
2284      new NISuppressor(1, RangeInt.BooleanVal.class);
2285  private static NISuppressor arg2_boolean =
2286      new NISuppressor(2, RangeInt.BooleanVal.class);
2287
2288  private static NISuppressor result_even =
2289      new NISuppressor(0, RangeInt.Even.class);
2290  private static NISuppressor arg1_even =
2291      new NISuppressor(1, RangeInt.Even.class);
2292  private static NISuppressor arg2_even =
2293      new NISuppressor(2, RangeInt.Even.class);
2294
2295  private static NISuppressor result_power2 =
2296      new NISuppressor(0, RangeInt.PowerOfTwo.class);
2297  private static NISuppressor arg1_power2 =
2298      new NISuppressor(1, RangeInt.PowerOfTwo.class);
2299  private static NISuppressor arg2_power2 =
2300      new NISuppressor(2, RangeInt.PowerOfTwo.class);
2301
2302  private static NISuppressor result_and0_arg1 =
2303      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
2304  private static NISuppressor result_and0_arg2 =
2305      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
2306  private static NISuppressor arg1_and0_arg2 =
2307      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
2308
2309  // The arguments to bitwise subset are backwards from what one
2310  // might expect.  The second argument is a subset of the first
2311  // argument
2312  private static NISuppressor arg1_bw_subset_arg2 =
2313      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
2314  private static NISuppressor arg2_bw_subset_arg1 =
2315      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
2316
2317  private static NISuppressor result_shift0_arg1 =
2318      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
2319  private static NISuppressor result_shift0_arg2 =
2320      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
2321  private static NISuppressor arg1_shift0_arg2 =
2322      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
2323
2324  private static NISuppressor arg2_divides_arg1 =
2325      new NISuppressor(1, 2, NumericInt.Divides.class);
2326  private static NISuppressor arg1_divides_arg2 =
2327      new NISuppressor(2, 1, NumericInt.Divides.class);
2328
2329  private static NISuppressor arg2_valid_shift =
2330      new NISuppressor(2, RangeInt.Bound0_63.class);
2331
2332    private static NISuppressionSet suppressions =
2333      new NISuppressionSet(
2334          new NISuppression[] {
2335
2336            // (r == y) && (z <= y) ==> r = max(y, z)
2337            new NISuppression(result_eq_arg1, arg2_le_arg1, suppressee),
2338
2339            // (r == z) && (y <= z) ==> r = max(y, z)
2340            new NISuppression(result_eq_arg2, arg1_le_arg2, suppressee),
2341
2342          });
2343
2344  // Create a suppression factory for functionBinary
2345
2346}
2347
2348/**
2349 * Represents the invariant {@code y = Maximum(x, z)} over three long
2350 * scalars. 
2351 */
2352public static class MaximumLong_yxz extends FunctionBinary {
2353  // We are Serializable, so we specify a version to allow changes to
2354  // method signatures without breaking serialization.  If you add or
2355  // remove fields, you should change this number to the current date.
2356  static final long serialVersionUID = 20031030L;
2357
2358  private static @Prototype MaximumLong_yxz proto = new @Prototype MaximumLong_yxz ();
2359
2360  /** Returns the prototype invariant for MaximumLong_yxz */
2361  public static @Prototype MaximumLong_yxz get_proto() {
2362    return proto;
2363  }
2364
2365  /** instantiate an invariant on the specified slice */
2366  @Override
2367  protected MaximumLong_yxz instantiate_dyn(@Prototype MaximumLong_yxz this, PptSlice slice) {
2368    return new MaximumLong_yxz (slice);
2369  }
2370
2371  private MaximumLong_yxz (PptSlice slice) {
2372    super(slice);
2373  }
2374
2375  public @Prototype MaximumLong_yxz () {
2376    super();
2377  }
2378
2379  private static String[] method_name = new String[] {"java.lang.Math.max(", ", ", ")"};
2380
2381  @Override
2382  public String[] get_method_name(@GuardSatisfied MaximumLong_yxz this) {
2383    return method_name;
2384  }
2385
2386  private static int function_id = -1;
2387
2388  @Override
2389  public int get_function_id() {
2390    return function_id;
2391  }
2392
2393  @Override
2394  public void set_function_id(int function_id) {
2395    assert MaximumLong_yxz.function_id == -1;
2396    MaximumLong_yxz.function_id = function_id;
2397  }
2398
2399  private static int var_order = 2;
2400
2401  @Override
2402  public int get_var_order(@GuardSatisfied MaximumLong_yxz this) {
2403    return var_order;
2404  }
2405
2406  @Pure
2407  @Override
2408  public boolean is_symmetric() {
2409
2410      return true;
2411  }
2412
2413  @Override
2414
2415  public long func(long x, long z) {
2416
2417    return Math.max(x, z);
2418  }
2419
2420  @Override
2421  public InvariantStatus check_modified(long x, long y,
2422                                      long z, int count) {
2423    return check_ordered(y, x, z, count);
2424  }
2425
2426  @Override
2427  public InvariantStatus add_modified(long x, long y,
2428                                      long z, int count) {
2429    if (Debug.logDetail()) {
2430      log("result=%s, arg1=%s, arg2=%s", y, x, z);
2431    }
2432    return add_ordered(y, x, z, count);
2433  }
2434
2435  @Pure
2436  @Override
2437  public boolean isMaximum() {
2438    return true;
2439  }
2440
2441  /** Returns a list of non-instantiating suppressions for this invariant. */
2442  @Pure
2443  @Override
2444  public @Nullable NISuppressionSet get_ni_suppressions() {
2445    if (NIS.dkconfig_enabled && dkconfig_enabled) {
2446      return suppressions;
2447    } else {
2448      return null;
2449    }
2450  }
2451
2452  /** definition of this invariant (the suppressee) */
2453  private static NISuppressee suppressee = new NISuppressee(MaximumLong_yxz.class, 3);
2454
2455  // suppressor definitions (used below)
2456  private static NISuppressor result_eq_arg1 =
2457      new NISuppressor(1, 0, IntEqual.class);
2458  private static NISuppressor result_eq_arg2 =
2459      new NISuppressor(1, 2, IntEqual.class);
2460  private static NISuppressor arg1_eq_arg2 =
2461      new NISuppressor(0, 2, IntEqual.class);
2462
2463  private static NISuppressor result_lt_arg1 =
2464      new NISuppressor(1, 0, IntLessThan.class);
2465  private static NISuppressor result_lt_arg2 =
2466      new NISuppressor(1, 2, IntLessThan.class);
2467  private static NISuppressor arg1_lt_arg2 =
2468      new NISuppressor(0, 2, IntLessThan.class);
2469  private static NISuppressor arg2_lt_arg1 =
2470      new NISuppressor(2, 0, IntLessThan.class);
2471
2472  private static NISuppressor result_le_arg1 =
2473      new NISuppressor(1, 0, IntLessEqual.class);
2474  private static NISuppressor result_le_arg2 =
2475      new NISuppressor(1, 2, IntLessEqual.class);
2476  private static NISuppressor arg1_le_arg2 =
2477      new NISuppressor(0, 2, IntLessEqual.class);
2478  private static NISuppressor arg2_le_arg1 =
2479      new NISuppressor(2, 0, IntLessEqual.class);
2480
2481  private static NISuppressor result_track0_arg1 =
2482      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
2483  private static NISuppressor result_track0_arg2 =
2484      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
2485  private static NISuppressor arg1_track0_arg2 =
2486      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
2487  private static NISuppressor arg1_track0_result =
2488      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
2489  private static NISuppressor arg2_track0_result =
2490      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
2491  private static NISuppressor arg2_track0_arg1 =
2492      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
2493
2494  private static NISuppressor result_eq_1 =
2495      new NISuppressor(1, RangeInt.EqualOne.class);
2496  private static NISuppressor arg1_eq_1 =
2497      new NISuppressor(0, RangeInt.EqualOne.class);
2498  private static NISuppressor arg2_eq_1 =
2499      new NISuppressor(2, RangeInt.EqualOne.class);
2500
2501  private static NISuppressor result_eq_0 =
2502      new NISuppressor(1, RangeInt.EqualZero.class);
2503  private static NISuppressor arg1_eq_0 =
2504      new NISuppressor(0, RangeInt.EqualZero.class);
2505  private static NISuppressor arg2_eq_0 =
2506      new NISuppressor(2, RangeInt.EqualZero.class);
2507
2508  private static NISuppressor result_ne_0 =
2509      new NISuppressor(1, NonZero.class);
2510  private static NISuppressor arg1_ne_0 =
2511      new NISuppressor(0, NonZero.class);
2512  private static NISuppressor arg2_ne_0 =
2513      new NISuppressor(2, NonZero.class);
2514
2515  private static NISuppressor result_ge_0 =
2516      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
2517  private static NISuppressor arg1_ge_0 =
2518      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
2519  private static NISuppressor arg2_ge_0 =
2520      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
2521
2522  private static NISuppressor result_ge_64 =
2523      new NISuppressor(1, RangeInt.GreaterEqual64.class);
2524  private static NISuppressor arg1_ge_64 =
2525      new NISuppressor(0, RangeInt.GreaterEqual64.class);
2526  private static NISuppressor arg2_ge_64 =
2527      new NISuppressor(2, RangeInt.GreaterEqual64.class);
2528
2529  private static NISuppressor result_boolean =
2530      new NISuppressor(1, RangeInt.BooleanVal.class);
2531  private static NISuppressor arg1_boolean =
2532      new NISuppressor(0, RangeInt.BooleanVal.class);
2533  private static NISuppressor arg2_boolean =
2534      new NISuppressor(2, RangeInt.BooleanVal.class);
2535
2536  private static NISuppressor result_even =
2537      new NISuppressor(1, RangeInt.Even.class);
2538  private static NISuppressor arg1_even =
2539      new NISuppressor(0, RangeInt.Even.class);
2540  private static NISuppressor arg2_even =
2541      new NISuppressor(2, RangeInt.Even.class);
2542
2543  private static NISuppressor result_power2 =
2544      new NISuppressor(1, RangeInt.PowerOfTwo.class);
2545  private static NISuppressor arg1_power2 =
2546      new NISuppressor(0, RangeInt.PowerOfTwo.class);
2547  private static NISuppressor arg2_power2 =
2548      new NISuppressor(2, RangeInt.PowerOfTwo.class);
2549
2550  private static NISuppressor result_and0_arg1 =
2551      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
2552  private static NISuppressor result_and0_arg2 =
2553      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
2554  private static NISuppressor arg1_and0_arg2 =
2555      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
2556
2557  // The arguments to bitwise subset are backwards from what one
2558  // might expect.  The second argument is a subset of the first
2559  // argument
2560  private static NISuppressor arg1_bw_subset_arg2 =
2561      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
2562  private static NISuppressor arg2_bw_subset_arg1 =
2563      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
2564
2565  private static NISuppressor result_shift0_arg1 =
2566      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
2567  private static NISuppressor result_shift0_arg2 =
2568      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
2569  private static NISuppressor arg1_shift0_arg2 =
2570      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
2571
2572  private static NISuppressor arg2_divides_arg1 =
2573      new NISuppressor(0, 2, NumericInt.Divides.class);
2574  private static NISuppressor arg1_divides_arg2 =
2575      new NISuppressor(2, 0, NumericInt.Divides.class);
2576
2577  private static NISuppressor arg2_valid_shift =
2578      new NISuppressor(2, RangeInt.Bound0_63.class);
2579
2580    private static NISuppressionSet suppressions =
2581      new NISuppressionSet(
2582          new NISuppression[] {
2583
2584            // (r == x) && (z <= x) ==> r = max(x, z)
2585            new NISuppression(result_eq_arg1, arg2_le_arg1, suppressee),
2586
2587            // (r == z) && (x <= z) ==> r = max(x, z)
2588            new NISuppression(result_eq_arg2, arg1_le_arg2, suppressee),
2589
2590          });
2591
2592  // Create a suppression factory for functionBinary
2593
2594}
2595
2596/**
2597 * Represents the invariant {@code z = Maximum(x, y)} over three long
2598 * scalars. 
2599 */
2600public static class MaximumLong_zxy extends FunctionBinary {
2601  // We are Serializable, so we specify a version to allow changes to
2602  // method signatures without breaking serialization.  If you add or
2603  // remove fields, you should change this number to the current date.
2604  static final long serialVersionUID = 20031030L;
2605
2606  private static @Prototype MaximumLong_zxy proto = new @Prototype MaximumLong_zxy ();
2607
2608  /** Returns the prototype invariant for MaximumLong_zxy */
2609  public static @Prototype MaximumLong_zxy get_proto() {
2610    return proto;
2611  }
2612
2613  /** instantiate an invariant on the specified slice */
2614  @Override
2615  protected MaximumLong_zxy instantiate_dyn(@Prototype MaximumLong_zxy this, PptSlice slice) {
2616    return new MaximumLong_zxy (slice);
2617  }
2618
2619  private MaximumLong_zxy (PptSlice slice) {
2620    super(slice);
2621  }
2622
2623  public @Prototype MaximumLong_zxy () {
2624    super();
2625  }
2626
2627  private static String[] method_name = new String[] {"java.lang.Math.max(", ", ", ")"};
2628
2629  @Override
2630  public String[] get_method_name(@GuardSatisfied MaximumLong_zxy this) {
2631    return method_name;
2632  }
2633
2634  private static int function_id = -1;
2635
2636  @Override
2637  public int get_function_id() {
2638    return function_id;
2639  }
2640
2641  @Override
2642  public void set_function_id(int function_id) {
2643    assert MaximumLong_zxy.function_id == -1;
2644    MaximumLong_zxy.function_id = function_id;
2645  }
2646
2647  private static int var_order = 3;
2648
2649  @Override
2650  public int get_var_order(@GuardSatisfied MaximumLong_zxy this) {
2651    return var_order;
2652  }
2653
2654  @Pure
2655  @Override
2656  public boolean is_symmetric() {
2657
2658      return true;
2659  }
2660
2661  @Override
2662
2663  public long func(long x, long y) {
2664
2665    return Math.max(x, y);
2666  }
2667
2668  @Override
2669  public InvariantStatus check_modified(long x, long y,
2670                                      long z, int count) {
2671    return check_ordered(z, x, y, count);
2672  }
2673
2674  @Override
2675  public InvariantStatus add_modified(long x, long y,
2676                                      long z, int count) {
2677    if (Debug.logDetail()) {
2678      log("result=%s, arg1=%s, arg2=%s", z, x, y);
2679    }
2680    return add_ordered(z, x, y, count);
2681  }
2682
2683  @Pure
2684  @Override
2685  public boolean isMaximum() {
2686    return true;
2687  }
2688
2689  /** Returns a list of non-instantiating suppressions for this invariant. */
2690  @Pure
2691  @Override
2692  public @Nullable NISuppressionSet get_ni_suppressions() {
2693    if (NIS.dkconfig_enabled && dkconfig_enabled) {
2694      return suppressions;
2695    } else {
2696      return null;
2697    }
2698  }
2699
2700  /** definition of this invariant (the suppressee) */
2701  private static NISuppressee suppressee = new NISuppressee(MaximumLong_zxy.class, 3);
2702
2703  // suppressor definitions (used below)
2704  private static NISuppressor result_eq_arg1 =
2705      new NISuppressor(2, 0, IntEqual.class);
2706  private static NISuppressor result_eq_arg2 =
2707      new NISuppressor(2, 1, IntEqual.class);
2708  private static NISuppressor arg1_eq_arg2 =
2709      new NISuppressor(0, 1, IntEqual.class);
2710
2711  private static NISuppressor result_lt_arg1 =
2712      new NISuppressor(2, 0, IntLessThan.class);
2713  private static NISuppressor result_lt_arg2 =
2714      new NISuppressor(2, 1, IntLessThan.class);
2715  private static NISuppressor arg1_lt_arg2 =
2716      new NISuppressor(0, 1, IntLessThan.class);
2717  private static NISuppressor arg2_lt_arg1 =
2718      new NISuppressor(1, 0, IntLessThan.class);
2719
2720  private static NISuppressor result_le_arg1 =
2721      new NISuppressor(2, 0, IntLessEqual.class);
2722  private static NISuppressor result_le_arg2 =
2723      new NISuppressor(2, 1, IntLessEqual.class);
2724  private static NISuppressor arg1_le_arg2 =
2725      new NISuppressor(0, 1, IntLessEqual.class);
2726  private static NISuppressor arg2_le_arg1 =
2727      new NISuppressor(1, 0, IntLessEqual.class);
2728
2729  private static NISuppressor result_track0_arg1 =
2730      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
2731  private static NISuppressor result_track0_arg2 =
2732      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
2733  private static NISuppressor arg1_track0_arg2 =
2734      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
2735  private static NISuppressor arg1_track0_result =
2736      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
2737  private static NISuppressor arg2_track0_result =
2738      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
2739  private static NISuppressor arg2_track0_arg1 =
2740      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
2741
2742  private static NISuppressor result_eq_1 =
2743      new NISuppressor(2, RangeInt.EqualOne.class);
2744  private static NISuppressor arg1_eq_1 =
2745      new NISuppressor(0, RangeInt.EqualOne.class);
2746  private static NISuppressor arg2_eq_1 =
2747      new NISuppressor(1, RangeInt.EqualOne.class);
2748
2749  private static NISuppressor result_eq_0 =
2750      new NISuppressor(2, RangeInt.EqualZero.class);
2751  private static NISuppressor arg1_eq_0 =
2752      new NISuppressor(0, RangeInt.EqualZero.class);
2753  private static NISuppressor arg2_eq_0 =
2754      new NISuppressor(1, RangeInt.EqualZero.class);
2755
2756  private static NISuppressor result_ne_0 =
2757      new NISuppressor(2, NonZero.class);
2758  private static NISuppressor arg1_ne_0 =
2759      new NISuppressor(0, NonZero.class);
2760  private static NISuppressor arg2_ne_0 =
2761      new NISuppressor(1, NonZero.class);
2762
2763  private static NISuppressor result_ge_0 =
2764      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
2765  private static NISuppressor arg1_ge_0 =
2766      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
2767  private static NISuppressor arg2_ge_0 =
2768      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
2769
2770  private static NISuppressor result_ge_64 =
2771      new NISuppressor(2, RangeInt.GreaterEqual64.class);
2772  private static NISuppressor arg1_ge_64 =
2773      new NISuppressor(0, RangeInt.GreaterEqual64.class);
2774  private static NISuppressor arg2_ge_64 =
2775      new NISuppressor(1, RangeInt.GreaterEqual64.class);
2776
2777  private static NISuppressor result_boolean =
2778      new NISuppressor(2, RangeInt.BooleanVal.class);
2779  private static NISuppressor arg1_boolean =
2780      new NISuppressor(0, RangeInt.BooleanVal.class);
2781  private static NISuppressor arg2_boolean =
2782      new NISuppressor(1, RangeInt.BooleanVal.class);
2783
2784  private static NISuppressor result_even =
2785      new NISuppressor(2, RangeInt.Even.class);
2786  private static NISuppressor arg1_even =
2787      new NISuppressor(0, RangeInt.Even.class);
2788  private static NISuppressor arg2_even =
2789      new NISuppressor(1, RangeInt.Even.class);
2790
2791  private static NISuppressor result_power2 =
2792      new NISuppressor(2, RangeInt.PowerOfTwo.class);
2793  private static NISuppressor arg1_power2 =
2794      new NISuppressor(0, RangeInt.PowerOfTwo.class);
2795  private static NISuppressor arg2_power2 =
2796      new NISuppressor(1, RangeInt.PowerOfTwo.class);
2797
2798  private static NISuppressor result_and0_arg1 =
2799      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
2800  private static NISuppressor result_and0_arg2 =
2801      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
2802  private static NISuppressor arg1_and0_arg2 =
2803      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
2804
2805  // The arguments to bitwise subset are backwards from what one
2806  // might expect.  The second argument is a subset of the first
2807  // argument
2808  private static NISuppressor arg1_bw_subset_arg2 =
2809      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
2810  private static NISuppressor arg2_bw_subset_arg1 =
2811      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
2812
2813  private static NISuppressor result_shift0_arg1 =
2814      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
2815  private static NISuppressor result_shift0_arg2 =
2816      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
2817  private static NISuppressor arg1_shift0_arg2 =
2818      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
2819
2820  private static NISuppressor arg2_divides_arg1 =
2821      new NISuppressor(0, 1, NumericInt.Divides.class);
2822  private static NISuppressor arg1_divides_arg2 =
2823      new NISuppressor(1, 0, NumericInt.Divides.class);
2824
2825  private static NISuppressor arg2_valid_shift =
2826      new NISuppressor(1, RangeInt.Bound0_63.class);
2827
2828    private static NISuppressionSet suppressions =
2829      new NISuppressionSet(
2830          new NISuppression[] {
2831
2832            // (r == x) && (y <= x) ==> r = max(x, y)
2833            new NISuppression(result_eq_arg1, arg2_le_arg1, suppressee),
2834
2835            // (r == y) && (x <= y) ==> r = max(x, y)
2836            new NISuppression(result_eq_arg2, arg1_le_arg2, suppressee),
2837
2838          });
2839
2840  // Create a suppression factory for functionBinary
2841
2842}
2843
2844  // default is that it is not this function, overriden in the subclass
2845  @Pure
2846  public boolean isDivision() {
2847    return false;
2848  }
2849
2850/**
2851 * Represents the invariant {@code x = Division(y, z)} over three long
2852 * scalars. 
2853 */
2854public static class DivisionLong_xyz extends FunctionBinary {
2855  // We are Serializable, so we specify a version to allow changes to
2856  // method signatures without breaking serialization.  If you add or
2857  // remove fields, you should change this number to the current date.
2858  static final long serialVersionUID = 20031030L;
2859
2860  private static @Prototype DivisionLong_xyz proto = new @Prototype DivisionLong_xyz ();
2861
2862  /** Returns the prototype invariant for DivisionLong_xyz */
2863  public static @Prototype DivisionLong_xyz get_proto() {
2864    return proto;
2865  }
2866
2867  /** instantiate an invariant on the specified slice */
2868  @Override
2869  protected DivisionLong_xyz instantiate_dyn(@Prototype DivisionLong_xyz this, PptSlice slice) {
2870    return new DivisionLong_xyz (slice);
2871  }
2872
2873  private DivisionLong_xyz (PptSlice slice) {
2874    super(slice);
2875  }
2876
2877  public @Prototype DivisionLong_xyz () {
2878    super();
2879  }
2880
2881  private static String[] method_name = new String[] {"", " / ", ""};
2882
2883  @Override
2884  public String[] get_method_name(@GuardSatisfied DivisionLong_xyz this) {
2885    return method_name;
2886  }
2887
2888  private static int function_id = -1;
2889
2890  @Override
2891  public int get_function_id() {
2892    return function_id;
2893  }
2894
2895  @Override
2896  public void set_function_id(int function_id) {
2897    assert DivisionLong_xyz.function_id == -1;
2898    DivisionLong_xyz.function_id = function_id;
2899  }
2900
2901  private static int var_order = 1;
2902
2903  @Override
2904  public int get_var_order(@GuardSatisfied DivisionLong_xyz this) {
2905    return var_order;
2906  }
2907
2908  @Pure
2909  @Override
2910  public boolean is_symmetric() {
2911
2912      return false;
2913  }
2914
2915  @Override
2916
2917  public long func(long y, long z) {
2918
2919    return (y / z);
2920  }
2921
2922  @Override
2923  public InvariantStatus check_modified(long x, long y,
2924                                      long z, int count) {
2925    return check_ordered(x, y, z, count);
2926  }
2927
2928  @Override
2929  public InvariantStatus add_modified(long x, long y,
2930                                      long z, int count) {
2931    if (Debug.logDetail()) {
2932      log("result=%s, arg1=%s, arg2=%s", x, y, z);
2933    }
2934    return add_ordered(x, y, z, count);
2935  }
2936
2937  @Pure
2938  @Override
2939  public boolean isDivision() {
2940    return true;
2941  }
2942
2943  @Pure
2944  @Override
2945  public boolean isExact() {
2946    return true;
2947  }
2948
2949  /** Returns a list of non-instantiating suppressions for this invariant. */
2950  @Pure
2951  @Override
2952  public @Nullable NISuppressionSet get_ni_suppressions() {
2953    if (NIS.dkconfig_enabled && dkconfig_enabled) {
2954      return suppressions;
2955    } else {
2956      return null;
2957    }
2958  }
2959
2960  /** definition of this invariant (the suppressee) */
2961  private static NISuppressee suppressee = new NISuppressee(DivisionLong_xyz.class, 3);
2962
2963  // suppressor definitions (used below)
2964  private static NISuppressor result_eq_arg1 =
2965      new NISuppressor(0, 1, IntEqual.class);
2966  private static NISuppressor result_eq_arg2 =
2967      new NISuppressor(0, 2, IntEqual.class);
2968  private static NISuppressor arg1_eq_arg2 =
2969      new NISuppressor(1, 2, IntEqual.class);
2970
2971  private static NISuppressor result_lt_arg1 =
2972      new NISuppressor(0, 1, IntLessThan.class);
2973  private static NISuppressor result_lt_arg2 =
2974      new NISuppressor(0, 2, IntLessThan.class);
2975  private static NISuppressor arg1_lt_arg2 =
2976      new NISuppressor(1, 2, IntLessThan.class);
2977  private static NISuppressor arg2_lt_arg1 =
2978      new NISuppressor(2, 1, IntLessThan.class);
2979
2980  private static NISuppressor result_le_arg1 =
2981      new NISuppressor(0, 1, IntLessEqual.class);
2982  private static NISuppressor result_le_arg2 =
2983      new NISuppressor(0, 2, IntLessEqual.class);
2984  private static NISuppressor arg1_le_arg2 =
2985      new NISuppressor(1, 2, IntLessEqual.class);
2986  private static NISuppressor arg2_le_arg1 =
2987      new NISuppressor(2, 1, IntLessEqual.class);
2988
2989  private static NISuppressor result_track0_arg1 =
2990      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
2991  private static NISuppressor result_track0_arg2 =
2992      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
2993  private static NISuppressor arg1_track0_arg2 =
2994      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
2995  private static NISuppressor arg1_track0_result =
2996      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
2997  private static NISuppressor arg2_track0_result =
2998      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
2999  private static NISuppressor arg2_track0_arg1 =
3000      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
3001
3002  private static NISuppressor result_eq_1 =
3003      new NISuppressor(0, RangeInt.EqualOne.class);
3004  private static NISuppressor arg1_eq_1 =
3005      new NISuppressor(1, RangeInt.EqualOne.class);
3006  private static NISuppressor arg2_eq_1 =
3007      new NISuppressor(2, RangeInt.EqualOne.class);
3008
3009  private static NISuppressor result_eq_0 =
3010      new NISuppressor(0, RangeInt.EqualZero.class);
3011  private static NISuppressor arg1_eq_0 =
3012      new NISuppressor(1, RangeInt.EqualZero.class);
3013  private static NISuppressor arg2_eq_0 =
3014      new NISuppressor(2, RangeInt.EqualZero.class);
3015
3016  private static NISuppressor result_ne_0 =
3017      new NISuppressor(0, NonZero.class);
3018  private static NISuppressor arg1_ne_0 =
3019      new NISuppressor(1, NonZero.class);
3020  private static NISuppressor arg2_ne_0 =
3021      new NISuppressor(2, NonZero.class);
3022
3023  private static NISuppressor result_ge_0 =
3024      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
3025  private static NISuppressor arg1_ge_0 =
3026      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
3027  private static NISuppressor arg2_ge_0 =
3028      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
3029
3030  private static NISuppressor result_ge_64 =
3031      new NISuppressor(0, RangeInt.GreaterEqual64.class);
3032  private static NISuppressor arg1_ge_64 =
3033      new NISuppressor(1, RangeInt.GreaterEqual64.class);
3034  private static NISuppressor arg2_ge_64 =
3035      new NISuppressor(2, RangeInt.GreaterEqual64.class);
3036
3037  private static NISuppressor result_boolean =
3038      new NISuppressor(0, RangeInt.BooleanVal.class);
3039  private static NISuppressor arg1_boolean =
3040      new NISuppressor(1, RangeInt.BooleanVal.class);
3041  private static NISuppressor arg2_boolean =
3042      new NISuppressor(2, RangeInt.BooleanVal.class);
3043
3044  private static NISuppressor result_even =
3045      new NISuppressor(0, RangeInt.Even.class);
3046  private static NISuppressor arg1_even =
3047      new NISuppressor(1, RangeInt.Even.class);
3048  private static NISuppressor arg2_even =
3049      new NISuppressor(2, RangeInt.Even.class);
3050
3051  private static NISuppressor result_power2 =
3052      new NISuppressor(0, RangeInt.PowerOfTwo.class);
3053  private static NISuppressor arg1_power2 =
3054      new NISuppressor(1, RangeInt.PowerOfTwo.class);
3055  private static NISuppressor arg2_power2 =
3056      new NISuppressor(2, RangeInt.PowerOfTwo.class);
3057
3058  private static NISuppressor result_and0_arg1 =
3059      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
3060  private static NISuppressor result_and0_arg2 =
3061      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
3062  private static NISuppressor arg1_and0_arg2 =
3063      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
3064
3065  // The arguments to bitwise subset are backwards from what one
3066  // might expect.  The second argument is a subset of the first
3067  // argument
3068  private static NISuppressor arg1_bw_subset_arg2 =
3069      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
3070  private static NISuppressor arg2_bw_subset_arg1 =
3071      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
3072
3073  private static NISuppressor result_shift0_arg1 =
3074      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
3075  private static NISuppressor result_shift0_arg2 =
3076      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
3077  private static NISuppressor arg1_shift0_arg2 =
3078      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
3079
3080  private static NISuppressor arg2_divides_arg1 =
3081      new NISuppressor(1, 2, NumericInt.Divides.class);
3082  private static NISuppressor arg1_divides_arg2 =
3083      new NISuppressor(2, 1, NumericInt.Divides.class);
3084
3085  private static NISuppressor arg2_valid_shift =
3086      new NISuppressor(2, RangeInt.Bound0_63.class);
3087
3088    private static NISuppressionSet suppressions =
3089      new NISuppressionSet(
3090          new NISuppression[] {
3091
3092            // (r == 0) && (y < z) && (y >= 0) && (z != 0) ==> r = y / z
3093            new NISuppression(result_eq_0, arg1_lt_arg2, arg1_ge_0, arg2_ne_0, suppressee),
3094
3095            // (y == z) && (z != 0) && (r == 1)
3096            new NISuppression(arg1_eq_arg2, arg2_ne_0, result_eq_1, suppressee),
3097
3098            // (r == y) && (z == 1) ==> r = y / z
3099            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
3100          });
3101
3102  // Create a suppression factory for functionBinary
3103
3104}
3105
3106/**
3107 * Represents the invariant {@code y = Division(x, z)} over three long
3108 * scalars. 
3109 */
3110public static class DivisionLong_yxz extends FunctionBinary {
3111  // We are Serializable, so we specify a version to allow changes to
3112  // method signatures without breaking serialization.  If you add or
3113  // remove fields, you should change this number to the current date.
3114  static final long serialVersionUID = 20031030L;
3115
3116  private static @Prototype DivisionLong_yxz proto = new @Prototype DivisionLong_yxz ();
3117
3118  /** Returns the prototype invariant for DivisionLong_yxz */
3119  public static @Prototype DivisionLong_yxz get_proto() {
3120    return proto;
3121  }
3122
3123  /** instantiate an invariant on the specified slice */
3124  @Override
3125  protected DivisionLong_yxz instantiate_dyn(@Prototype DivisionLong_yxz this, PptSlice slice) {
3126    return new DivisionLong_yxz (slice);
3127  }
3128
3129  private DivisionLong_yxz (PptSlice slice) {
3130    super(slice);
3131  }
3132
3133  public @Prototype DivisionLong_yxz () {
3134    super();
3135  }
3136
3137  private static String[] method_name = new String[] {"", " / ", ""};
3138
3139  @Override
3140  public String[] get_method_name(@GuardSatisfied DivisionLong_yxz this) {
3141    return method_name;
3142  }
3143
3144  private static int function_id = -1;
3145
3146  @Override
3147  public int get_function_id() {
3148    return function_id;
3149  }
3150
3151  @Override
3152  public void set_function_id(int function_id) {
3153    assert DivisionLong_yxz.function_id == -1;
3154    DivisionLong_yxz.function_id = function_id;
3155  }
3156
3157  private static int var_order = 2;
3158
3159  @Override
3160  public int get_var_order(@GuardSatisfied DivisionLong_yxz this) {
3161    return var_order;
3162  }
3163
3164  @Pure
3165  @Override
3166  public boolean is_symmetric() {
3167
3168      return false;
3169  }
3170
3171  @Override
3172
3173  public long func(long x, long z) {
3174
3175    return (x / z);
3176  }
3177
3178  @Override
3179  public InvariantStatus check_modified(long x, long y,
3180                                      long z, int count) {
3181    return check_ordered(y, x, z, count);
3182  }
3183
3184  @Override
3185  public InvariantStatus add_modified(long x, long y,
3186                                      long z, int count) {
3187    if (Debug.logDetail()) {
3188      log("result=%s, arg1=%s, arg2=%s", y, x, z);
3189    }
3190    return add_ordered(y, x, z, count);
3191  }
3192
3193  @Pure
3194  @Override
3195  public boolean isDivision() {
3196    return true;
3197  }
3198
3199  @Pure
3200  @Override
3201  public boolean isExact() {
3202    return true;
3203  }
3204
3205  /** Returns a list of non-instantiating suppressions for this invariant. */
3206  @Pure
3207  @Override
3208  public @Nullable NISuppressionSet get_ni_suppressions() {
3209    if (NIS.dkconfig_enabled && dkconfig_enabled) {
3210      return suppressions;
3211    } else {
3212      return null;
3213    }
3214  }
3215
3216  /** definition of this invariant (the suppressee) */
3217  private static NISuppressee suppressee = new NISuppressee(DivisionLong_yxz.class, 3);
3218
3219  // suppressor definitions (used below)
3220  private static NISuppressor result_eq_arg1 =
3221      new NISuppressor(1, 0, IntEqual.class);
3222  private static NISuppressor result_eq_arg2 =
3223      new NISuppressor(1, 2, IntEqual.class);
3224  private static NISuppressor arg1_eq_arg2 =
3225      new NISuppressor(0, 2, IntEqual.class);
3226
3227  private static NISuppressor result_lt_arg1 =
3228      new NISuppressor(1, 0, IntLessThan.class);
3229  private static NISuppressor result_lt_arg2 =
3230      new NISuppressor(1, 2, IntLessThan.class);
3231  private static NISuppressor arg1_lt_arg2 =
3232      new NISuppressor(0, 2, IntLessThan.class);
3233  private static NISuppressor arg2_lt_arg1 =
3234      new NISuppressor(2, 0, IntLessThan.class);
3235
3236  private static NISuppressor result_le_arg1 =
3237      new NISuppressor(1, 0, IntLessEqual.class);
3238  private static NISuppressor result_le_arg2 =
3239      new NISuppressor(1, 2, IntLessEqual.class);
3240  private static NISuppressor arg1_le_arg2 =
3241      new NISuppressor(0, 2, IntLessEqual.class);
3242  private static NISuppressor arg2_le_arg1 =
3243      new NISuppressor(2, 0, IntLessEqual.class);
3244
3245  private static NISuppressor result_track0_arg1 =
3246      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
3247  private static NISuppressor result_track0_arg2 =
3248      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
3249  private static NISuppressor arg1_track0_arg2 =
3250      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
3251  private static NISuppressor arg1_track0_result =
3252      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
3253  private static NISuppressor arg2_track0_result =
3254      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
3255  private static NISuppressor arg2_track0_arg1 =
3256      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
3257
3258  private static NISuppressor result_eq_1 =
3259      new NISuppressor(1, RangeInt.EqualOne.class);
3260  private static NISuppressor arg1_eq_1 =
3261      new NISuppressor(0, RangeInt.EqualOne.class);
3262  private static NISuppressor arg2_eq_1 =
3263      new NISuppressor(2, RangeInt.EqualOne.class);
3264
3265  private static NISuppressor result_eq_0 =
3266      new NISuppressor(1, RangeInt.EqualZero.class);
3267  private static NISuppressor arg1_eq_0 =
3268      new NISuppressor(0, RangeInt.EqualZero.class);
3269  private static NISuppressor arg2_eq_0 =
3270      new NISuppressor(2, RangeInt.EqualZero.class);
3271
3272  private static NISuppressor result_ne_0 =
3273      new NISuppressor(1, NonZero.class);
3274  private static NISuppressor arg1_ne_0 =
3275      new NISuppressor(0, NonZero.class);
3276  private static NISuppressor arg2_ne_0 =
3277      new NISuppressor(2, NonZero.class);
3278
3279  private static NISuppressor result_ge_0 =
3280      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
3281  private static NISuppressor arg1_ge_0 =
3282      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
3283  private static NISuppressor arg2_ge_0 =
3284      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
3285
3286  private static NISuppressor result_ge_64 =
3287      new NISuppressor(1, RangeInt.GreaterEqual64.class);
3288  private static NISuppressor arg1_ge_64 =
3289      new NISuppressor(0, RangeInt.GreaterEqual64.class);
3290  private static NISuppressor arg2_ge_64 =
3291      new NISuppressor(2, RangeInt.GreaterEqual64.class);
3292
3293  private static NISuppressor result_boolean =
3294      new NISuppressor(1, RangeInt.BooleanVal.class);
3295  private static NISuppressor arg1_boolean =
3296      new NISuppressor(0, RangeInt.BooleanVal.class);
3297  private static NISuppressor arg2_boolean =
3298      new NISuppressor(2, RangeInt.BooleanVal.class);
3299
3300  private static NISuppressor result_even =
3301      new NISuppressor(1, RangeInt.Even.class);
3302  private static NISuppressor arg1_even =
3303      new NISuppressor(0, RangeInt.Even.class);
3304  private static NISuppressor arg2_even =
3305      new NISuppressor(2, RangeInt.Even.class);
3306
3307  private static NISuppressor result_power2 =
3308      new NISuppressor(1, RangeInt.PowerOfTwo.class);
3309  private static NISuppressor arg1_power2 =
3310      new NISuppressor(0, RangeInt.PowerOfTwo.class);
3311  private static NISuppressor arg2_power2 =
3312      new NISuppressor(2, RangeInt.PowerOfTwo.class);
3313
3314  private static NISuppressor result_and0_arg1 =
3315      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
3316  private static NISuppressor result_and0_arg2 =
3317      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
3318  private static NISuppressor arg1_and0_arg2 =
3319      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
3320
3321  // The arguments to bitwise subset are backwards from what one
3322  // might expect.  The second argument is a subset of the first
3323  // argument
3324  private static NISuppressor arg1_bw_subset_arg2 =
3325      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
3326  private static NISuppressor arg2_bw_subset_arg1 =
3327      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
3328
3329  private static NISuppressor result_shift0_arg1 =
3330      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
3331  private static NISuppressor result_shift0_arg2 =
3332      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
3333  private static NISuppressor arg1_shift0_arg2 =
3334      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
3335
3336  private static NISuppressor arg2_divides_arg1 =
3337      new NISuppressor(0, 2, NumericInt.Divides.class);
3338  private static NISuppressor arg1_divides_arg2 =
3339      new NISuppressor(2, 0, NumericInt.Divides.class);
3340
3341  private static NISuppressor arg2_valid_shift =
3342      new NISuppressor(2, RangeInt.Bound0_63.class);
3343
3344    private static NISuppressionSet suppressions =
3345      new NISuppressionSet(
3346          new NISuppression[] {
3347
3348            // (r == 0) && (x < z) && (x >= 0) && (z != 0) ==> r = x / z
3349            new NISuppression(result_eq_0, arg1_lt_arg2, arg1_ge_0, arg2_ne_0, suppressee),
3350
3351            // (x == z) && (z != 0) && (r == 1)
3352            new NISuppression(arg1_eq_arg2, arg2_ne_0, result_eq_1, suppressee),
3353
3354            // (r == x) && (z == 1) ==> r = x / z
3355            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
3356          });
3357
3358  // Create a suppression factory for functionBinary
3359
3360}
3361
3362/**
3363 * Represents the invariant {@code z = Division(x, y)} over three long
3364 * scalars. 
3365 */
3366public static class DivisionLong_zxy extends FunctionBinary {
3367  // We are Serializable, so we specify a version to allow changes to
3368  // method signatures without breaking serialization.  If you add or
3369  // remove fields, you should change this number to the current date.
3370  static final long serialVersionUID = 20031030L;
3371
3372  private static @Prototype DivisionLong_zxy proto = new @Prototype DivisionLong_zxy ();
3373
3374  /** Returns the prototype invariant for DivisionLong_zxy */
3375  public static @Prototype DivisionLong_zxy get_proto() {
3376    return proto;
3377  }
3378
3379  /** instantiate an invariant on the specified slice */
3380  @Override
3381  protected DivisionLong_zxy instantiate_dyn(@Prototype DivisionLong_zxy this, PptSlice slice) {
3382    return new DivisionLong_zxy (slice);
3383  }
3384
3385  private DivisionLong_zxy (PptSlice slice) {
3386    super(slice);
3387  }
3388
3389  public @Prototype DivisionLong_zxy () {
3390    super();
3391  }
3392
3393  private static String[] method_name = new String[] {"", " / ", ""};
3394
3395  @Override
3396  public String[] get_method_name(@GuardSatisfied DivisionLong_zxy this) {
3397    return method_name;
3398  }
3399
3400  private static int function_id = -1;
3401
3402  @Override
3403  public int get_function_id() {
3404    return function_id;
3405  }
3406
3407  @Override
3408  public void set_function_id(int function_id) {
3409    assert DivisionLong_zxy.function_id == -1;
3410    DivisionLong_zxy.function_id = function_id;
3411  }
3412
3413  private static int var_order = 3;
3414
3415  @Override
3416  public int get_var_order(@GuardSatisfied DivisionLong_zxy this) {
3417    return var_order;
3418  }
3419
3420  @Pure
3421  @Override
3422  public boolean is_symmetric() {
3423
3424      return false;
3425  }
3426
3427  @Override
3428
3429  public long func(long x, long y) {
3430
3431    return (x / y);
3432  }
3433
3434  @Override
3435  public InvariantStatus check_modified(long x, long y,
3436                                      long z, int count) {
3437    return check_ordered(z, x, y, count);
3438  }
3439
3440  @Override
3441  public InvariantStatus add_modified(long x, long y,
3442                                      long z, int count) {
3443    if (Debug.logDetail()) {
3444      log("result=%s, arg1=%s, arg2=%s", z, x, y);
3445    }
3446    return add_ordered(z, x, y, count);
3447  }
3448
3449  @Pure
3450  @Override
3451  public boolean isDivision() {
3452    return true;
3453  }
3454
3455  @Pure
3456  @Override
3457  public boolean isExact() {
3458    return true;
3459  }
3460
3461  /** Returns a list of non-instantiating suppressions for this invariant. */
3462  @Pure
3463  @Override
3464  public @Nullable NISuppressionSet get_ni_suppressions() {
3465    if (NIS.dkconfig_enabled && dkconfig_enabled) {
3466      return suppressions;
3467    } else {
3468      return null;
3469    }
3470  }
3471
3472  /** definition of this invariant (the suppressee) */
3473  private static NISuppressee suppressee = new NISuppressee(DivisionLong_zxy.class, 3);
3474
3475  // suppressor definitions (used below)
3476  private static NISuppressor result_eq_arg1 =
3477      new NISuppressor(2, 0, IntEqual.class);
3478  private static NISuppressor result_eq_arg2 =
3479      new NISuppressor(2, 1, IntEqual.class);
3480  private static NISuppressor arg1_eq_arg2 =
3481      new NISuppressor(0, 1, IntEqual.class);
3482
3483  private static NISuppressor result_lt_arg1 =
3484      new NISuppressor(2, 0, IntLessThan.class);
3485  private static NISuppressor result_lt_arg2 =
3486      new NISuppressor(2, 1, IntLessThan.class);
3487  private static NISuppressor arg1_lt_arg2 =
3488      new NISuppressor(0, 1, IntLessThan.class);
3489  private static NISuppressor arg2_lt_arg1 =
3490      new NISuppressor(1, 0, IntLessThan.class);
3491
3492  private static NISuppressor result_le_arg1 =
3493      new NISuppressor(2, 0, IntLessEqual.class);
3494  private static NISuppressor result_le_arg2 =
3495      new NISuppressor(2, 1, IntLessEqual.class);
3496  private static NISuppressor arg1_le_arg2 =
3497      new NISuppressor(0, 1, IntLessEqual.class);
3498  private static NISuppressor arg2_le_arg1 =
3499      new NISuppressor(1, 0, IntLessEqual.class);
3500
3501  private static NISuppressor result_track0_arg1 =
3502      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
3503  private static NISuppressor result_track0_arg2 =
3504      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
3505  private static NISuppressor arg1_track0_arg2 =
3506      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
3507  private static NISuppressor arg1_track0_result =
3508      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
3509  private static NISuppressor arg2_track0_result =
3510      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
3511  private static NISuppressor arg2_track0_arg1 =
3512      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
3513
3514  private static NISuppressor result_eq_1 =
3515      new NISuppressor(2, RangeInt.EqualOne.class);
3516  private static NISuppressor arg1_eq_1 =
3517      new NISuppressor(0, RangeInt.EqualOne.class);
3518  private static NISuppressor arg2_eq_1 =
3519      new NISuppressor(1, RangeInt.EqualOne.class);
3520
3521  private static NISuppressor result_eq_0 =
3522      new NISuppressor(2, RangeInt.EqualZero.class);
3523  private static NISuppressor arg1_eq_0 =
3524      new NISuppressor(0, RangeInt.EqualZero.class);
3525  private static NISuppressor arg2_eq_0 =
3526      new NISuppressor(1, RangeInt.EqualZero.class);
3527
3528  private static NISuppressor result_ne_0 =
3529      new NISuppressor(2, NonZero.class);
3530  private static NISuppressor arg1_ne_0 =
3531      new NISuppressor(0, NonZero.class);
3532  private static NISuppressor arg2_ne_0 =
3533      new NISuppressor(1, NonZero.class);
3534
3535  private static NISuppressor result_ge_0 =
3536      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
3537  private static NISuppressor arg1_ge_0 =
3538      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
3539  private static NISuppressor arg2_ge_0 =
3540      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
3541
3542  private static NISuppressor result_ge_64 =
3543      new NISuppressor(2, RangeInt.GreaterEqual64.class);
3544  private static NISuppressor arg1_ge_64 =
3545      new NISuppressor(0, RangeInt.GreaterEqual64.class);
3546  private static NISuppressor arg2_ge_64 =
3547      new NISuppressor(1, RangeInt.GreaterEqual64.class);
3548
3549  private static NISuppressor result_boolean =
3550      new NISuppressor(2, RangeInt.BooleanVal.class);
3551  private static NISuppressor arg1_boolean =
3552      new NISuppressor(0, RangeInt.BooleanVal.class);
3553  private static NISuppressor arg2_boolean =
3554      new NISuppressor(1, RangeInt.BooleanVal.class);
3555
3556  private static NISuppressor result_even =
3557      new NISuppressor(2, RangeInt.Even.class);
3558  private static NISuppressor arg1_even =
3559      new NISuppressor(0, RangeInt.Even.class);
3560  private static NISuppressor arg2_even =
3561      new NISuppressor(1, RangeInt.Even.class);
3562
3563  private static NISuppressor result_power2 =
3564      new NISuppressor(2, RangeInt.PowerOfTwo.class);
3565  private static NISuppressor arg1_power2 =
3566      new NISuppressor(0, RangeInt.PowerOfTwo.class);
3567  private static NISuppressor arg2_power2 =
3568      new NISuppressor(1, RangeInt.PowerOfTwo.class);
3569
3570  private static NISuppressor result_and0_arg1 =
3571      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
3572  private static NISuppressor result_and0_arg2 =
3573      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
3574  private static NISuppressor arg1_and0_arg2 =
3575      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
3576
3577  // The arguments to bitwise subset are backwards from what one
3578  // might expect.  The second argument is a subset of the first
3579  // argument
3580  private static NISuppressor arg1_bw_subset_arg2 =
3581      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
3582  private static NISuppressor arg2_bw_subset_arg1 =
3583      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
3584
3585  private static NISuppressor result_shift0_arg1 =
3586      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
3587  private static NISuppressor result_shift0_arg2 =
3588      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
3589  private static NISuppressor arg1_shift0_arg2 =
3590      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
3591
3592  private static NISuppressor arg2_divides_arg1 =
3593      new NISuppressor(0, 1, NumericInt.Divides.class);
3594  private static NISuppressor arg1_divides_arg2 =
3595      new NISuppressor(1, 0, NumericInt.Divides.class);
3596
3597  private static NISuppressor arg2_valid_shift =
3598      new NISuppressor(1, RangeInt.Bound0_63.class);
3599
3600    private static NISuppressionSet suppressions =
3601      new NISuppressionSet(
3602          new NISuppression[] {
3603
3604            // (r == 0) && (x < y) && (x >= 0) && (y != 0) ==> r = x / y
3605            new NISuppression(result_eq_0, arg1_lt_arg2, arg1_ge_0, arg2_ne_0, suppressee),
3606
3607            // (x == y) && (y != 0) && (r == 1)
3608            new NISuppression(arg1_eq_arg2, arg2_ne_0, result_eq_1, suppressee),
3609
3610            // (r == x) && (y == 1) ==> r = x / y
3611            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
3612          });
3613
3614  // Create a suppression factory for functionBinary
3615
3616}
3617
3618/**
3619 * Represents the invariant {@code x = Division(z, y)} over three long
3620 * scalars. 
3621 */
3622public static class DivisionLong_xzy extends FunctionBinary {
3623  // We are Serializable, so we specify a version to allow changes to
3624  // method signatures without breaking serialization.  If you add or
3625  // remove fields, you should change this number to the current date.
3626  static final long serialVersionUID = 20031030L;
3627
3628  private static @Prototype DivisionLong_xzy proto = new @Prototype DivisionLong_xzy ();
3629
3630  /** Returns the prototype invariant for DivisionLong_xzy */
3631  public static @Prototype DivisionLong_xzy get_proto() {
3632    return proto;
3633  }
3634
3635  /** instantiate an invariant on the specified slice */
3636  @Override
3637  protected DivisionLong_xzy instantiate_dyn(@Prototype DivisionLong_xzy this, PptSlice slice) {
3638    return new DivisionLong_xzy (slice);
3639  }
3640
3641  private DivisionLong_xzy (PptSlice slice) {
3642    super(slice);
3643  }
3644
3645  public @Prototype DivisionLong_xzy () {
3646    super();
3647  }
3648
3649  private static String[] method_name = new String[] {"", " / ", ""};
3650
3651  @Override
3652  public String[] get_method_name(@GuardSatisfied DivisionLong_xzy this) {
3653    return method_name;
3654  }
3655
3656  private static int function_id = -1;
3657
3658  @Override
3659  public int get_function_id() {
3660    return function_id;
3661  }
3662
3663  @Override
3664  public void set_function_id(int function_id) {
3665    assert DivisionLong_xzy.function_id == -1;
3666    DivisionLong_xzy.function_id = function_id;
3667  }
3668
3669  private static int var_order = 4;
3670
3671  @Override
3672  public int get_var_order(@GuardSatisfied DivisionLong_xzy this) {
3673    return var_order;
3674  }
3675
3676  @Pure
3677  @Override
3678  public boolean is_symmetric() {
3679
3680      return false;
3681  }
3682
3683  @Override
3684
3685  public long func(long z, long y) {
3686
3687    return (z / y);
3688  }
3689
3690  @Override
3691  public InvariantStatus check_modified(long x, long y,
3692                                      long z, int count) {
3693    return check_ordered(x, z, y, count);
3694  }
3695
3696  @Override
3697  public InvariantStatus add_modified(long x, long y,
3698                                      long z, int count) {
3699    if (Debug.logDetail()) {
3700      log("result=%s, arg1=%s, arg2=%s", x, z, y);
3701    }
3702    return add_ordered(x, z, y, count);
3703  }
3704
3705  @Pure
3706  @Override
3707  public boolean isDivision() {
3708    return true;
3709  }
3710
3711  @Pure
3712  @Override
3713  public boolean isExact() {
3714    return true;
3715  }
3716
3717  /** Returns a list of non-instantiating suppressions for this invariant. */
3718  @Pure
3719  @Override
3720  public @Nullable NISuppressionSet get_ni_suppressions() {
3721    if (NIS.dkconfig_enabled && dkconfig_enabled) {
3722      return suppressions;
3723    } else {
3724      return null;
3725    }
3726  }
3727
3728  /** definition of this invariant (the suppressee) */
3729  private static NISuppressee suppressee = new NISuppressee(DivisionLong_xzy.class, 3);
3730
3731  // suppressor definitions (used below)
3732  private static NISuppressor result_eq_arg1 =
3733      new NISuppressor(0, 2, IntEqual.class);
3734  private static NISuppressor result_eq_arg2 =
3735      new NISuppressor(0, 1, IntEqual.class);
3736  private static NISuppressor arg1_eq_arg2 =
3737      new NISuppressor(2, 1, IntEqual.class);
3738
3739  private static NISuppressor result_lt_arg1 =
3740      new NISuppressor(0, 2, IntLessThan.class);
3741  private static NISuppressor result_lt_arg2 =
3742      new NISuppressor(0, 1, IntLessThan.class);
3743  private static NISuppressor arg1_lt_arg2 =
3744      new NISuppressor(2, 1, IntLessThan.class);
3745  private static NISuppressor arg2_lt_arg1 =
3746      new NISuppressor(1, 2, IntLessThan.class);
3747
3748  private static NISuppressor result_le_arg1 =
3749      new NISuppressor(0, 2, IntLessEqual.class);
3750  private static NISuppressor result_le_arg2 =
3751      new NISuppressor(0, 1, IntLessEqual.class);
3752  private static NISuppressor arg1_le_arg2 =
3753      new NISuppressor(2, 1, IntLessEqual.class);
3754  private static NISuppressor arg2_le_arg1 =
3755      new NISuppressor(1, 2, IntLessEqual.class);
3756
3757  private static NISuppressor result_track0_arg1 =
3758      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
3759  private static NISuppressor result_track0_arg2 =
3760      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
3761  private static NISuppressor arg1_track0_arg2 =
3762      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
3763  private static NISuppressor arg1_track0_result =
3764      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
3765  private static NISuppressor arg2_track0_result =
3766      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
3767  private static NISuppressor arg2_track0_arg1 =
3768      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
3769
3770  private static NISuppressor result_eq_1 =
3771      new NISuppressor(0, RangeInt.EqualOne.class);
3772  private static NISuppressor arg1_eq_1 =
3773      new NISuppressor(2, RangeInt.EqualOne.class);
3774  private static NISuppressor arg2_eq_1 =
3775      new NISuppressor(1, RangeInt.EqualOne.class);
3776
3777  private static NISuppressor result_eq_0 =
3778      new NISuppressor(0, RangeInt.EqualZero.class);
3779  private static NISuppressor arg1_eq_0 =
3780      new NISuppressor(2, RangeInt.EqualZero.class);
3781  private static NISuppressor arg2_eq_0 =
3782      new NISuppressor(1, RangeInt.EqualZero.class);
3783
3784  private static NISuppressor result_ne_0 =
3785      new NISuppressor(0, NonZero.class);
3786  private static NISuppressor arg1_ne_0 =
3787      new NISuppressor(2, NonZero.class);
3788  private static NISuppressor arg2_ne_0 =
3789      new NISuppressor(1, NonZero.class);
3790
3791  private static NISuppressor result_ge_0 =
3792      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
3793  private static NISuppressor arg1_ge_0 =
3794      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
3795  private static NISuppressor arg2_ge_0 =
3796      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
3797
3798  private static NISuppressor result_ge_64 =
3799      new NISuppressor(0, RangeInt.GreaterEqual64.class);
3800  private static NISuppressor arg1_ge_64 =
3801      new NISuppressor(2, RangeInt.GreaterEqual64.class);
3802  private static NISuppressor arg2_ge_64 =
3803      new NISuppressor(1, RangeInt.GreaterEqual64.class);
3804
3805  private static NISuppressor result_boolean =
3806      new NISuppressor(0, RangeInt.BooleanVal.class);
3807  private static NISuppressor arg1_boolean =
3808      new NISuppressor(2, RangeInt.BooleanVal.class);
3809  private static NISuppressor arg2_boolean =
3810      new NISuppressor(1, RangeInt.BooleanVal.class);
3811
3812  private static NISuppressor result_even =
3813      new NISuppressor(0, RangeInt.Even.class);
3814  private static NISuppressor arg1_even =
3815      new NISuppressor(2, RangeInt.Even.class);
3816  private static NISuppressor arg2_even =
3817      new NISuppressor(1, RangeInt.Even.class);
3818
3819  private static NISuppressor result_power2 =
3820      new NISuppressor(0, RangeInt.PowerOfTwo.class);
3821  private static NISuppressor arg1_power2 =
3822      new NISuppressor(2, RangeInt.PowerOfTwo.class);
3823  private static NISuppressor arg2_power2 =
3824      new NISuppressor(1, RangeInt.PowerOfTwo.class);
3825
3826  private static NISuppressor result_and0_arg1 =
3827      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
3828  private static NISuppressor result_and0_arg2 =
3829      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
3830  private static NISuppressor arg1_and0_arg2 =
3831      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
3832
3833  // The arguments to bitwise subset are backwards from what one
3834  // might expect.  The second argument is a subset of the first
3835  // argument
3836  private static NISuppressor arg1_bw_subset_arg2 =
3837      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
3838  private static NISuppressor arg2_bw_subset_arg1 =
3839      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
3840
3841  private static NISuppressor result_shift0_arg1 =
3842      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
3843  private static NISuppressor result_shift0_arg2 =
3844      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
3845  private static NISuppressor arg1_shift0_arg2 =
3846      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
3847
3848  private static NISuppressor arg2_divides_arg1 =
3849      new NISuppressor(2, 1, NumericInt.Divides.class);
3850  private static NISuppressor arg1_divides_arg2 =
3851      new NISuppressor(1, 2, NumericInt.Divides.class);
3852
3853  private static NISuppressor arg2_valid_shift =
3854      new NISuppressor(1, RangeInt.Bound0_63.class);
3855
3856    private static NISuppressionSet suppressions =
3857      new NISuppressionSet(
3858          new NISuppression[] {
3859
3860            // (r == 0) && (z < y) && (z >= 0) && (y != 0) ==> r = z / y
3861            new NISuppression(result_eq_0, arg1_lt_arg2, arg1_ge_0, arg2_ne_0, suppressee),
3862
3863            // (z == y) && (y != 0) && (r == 1)
3864            new NISuppression(arg1_eq_arg2, arg2_ne_0, result_eq_1, suppressee),
3865
3866            // (r == z) && (y == 1) ==> r = z / y
3867            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
3868          });
3869
3870  // Create a suppression factory for functionBinary
3871
3872}
3873
3874/**
3875 * Represents the invariant {@code y = Division(z, x)} over three long
3876 * scalars. 
3877 */
3878public static class DivisionLong_yzx extends FunctionBinary {
3879  // We are Serializable, so we specify a version to allow changes to
3880  // method signatures without breaking serialization.  If you add or
3881  // remove fields, you should change this number to the current date.
3882  static final long serialVersionUID = 20031030L;
3883
3884  private static @Prototype DivisionLong_yzx proto = new @Prototype DivisionLong_yzx ();
3885
3886  /** Returns the prototype invariant for DivisionLong_yzx */
3887  public static @Prototype DivisionLong_yzx get_proto() {
3888    return proto;
3889  }
3890
3891  /** instantiate an invariant on the specified slice */
3892  @Override
3893  protected DivisionLong_yzx instantiate_dyn(@Prototype DivisionLong_yzx this, PptSlice slice) {
3894    return new DivisionLong_yzx (slice);
3895  }
3896
3897  private DivisionLong_yzx (PptSlice slice) {
3898    super(slice);
3899  }
3900
3901  public @Prototype DivisionLong_yzx () {
3902    super();
3903  }
3904
3905  private static String[] method_name = new String[] {"", " / ", ""};
3906
3907  @Override
3908  public String[] get_method_name(@GuardSatisfied DivisionLong_yzx this) {
3909    return method_name;
3910  }
3911
3912  private static int function_id = -1;
3913
3914  @Override
3915  public int get_function_id() {
3916    return function_id;
3917  }
3918
3919  @Override
3920  public void set_function_id(int function_id) {
3921    assert DivisionLong_yzx.function_id == -1;
3922    DivisionLong_yzx.function_id = function_id;
3923  }
3924
3925  private static int var_order = 5;
3926
3927  @Override
3928  public int get_var_order(@GuardSatisfied DivisionLong_yzx this) {
3929    return var_order;
3930  }
3931
3932  @Pure
3933  @Override
3934  public boolean is_symmetric() {
3935
3936      return false;
3937  }
3938
3939  @Override
3940
3941  public long func(long z, long x) {
3942
3943    return (z / x);
3944  }
3945
3946  @Override
3947  public InvariantStatus check_modified(long x, long y,
3948                                      long z, int count) {
3949    return check_ordered(y, z, x, count);
3950  }
3951
3952  @Override
3953  public InvariantStatus add_modified(long x, long y,
3954                                      long z, int count) {
3955    if (Debug.logDetail()) {
3956      log("result=%s, arg1=%s, arg2=%s", y, z, x);
3957    }
3958    return add_ordered(y, z, x, count);
3959  }
3960
3961  @Pure
3962  @Override
3963  public boolean isDivision() {
3964    return true;
3965  }
3966
3967  @Pure
3968  @Override
3969  public boolean isExact() {
3970    return true;
3971  }
3972
3973  /** Returns a list of non-instantiating suppressions for this invariant. */
3974  @Pure
3975  @Override
3976  public @Nullable NISuppressionSet get_ni_suppressions() {
3977    if (NIS.dkconfig_enabled && dkconfig_enabled) {
3978      return suppressions;
3979    } else {
3980      return null;
3981    }
3982  }
3983
3984  /** definition of this invariant (the suppressee) */
3985  private static NISuppressee suppressee = new NISuppressee(DivisionLong_yzx.class, 3);
3986
3987  // suppressor definitions (used below)
3988  private static NISuppressor result_eq_arg1 =
3989      new NISuppressor(1, 2, IntEqual.class);
3990  private static NISuppressor result_eq_arg2 =
3991      new NISuppressor(1, 0, IntEqual.class);
3992  private static NISuppressor arg1_eq_arg2 =
3993      new NISuppressor(2, 0, IntEqual.class);
3994
3995  private static NISuppressor result_lt_arg1 =
3996      new NISuppressor(1, 2, IntLessThan.class);
3997  private static NISuppressor result_lt_arg2 =
3998      new NISuppressor(1, 0, IntLessThan.class);
3999  private static NISuppressor arg1_lt_arg2 =
4000      new NISuppressor(2, 0, IntLessThan.class);
4001  private static NISuppressor arg2_lt_arg1 =
4002      new NISuppressor(0, 2, IntLessThan.class);
4003
4004  private static NISuppressor result_le_arg1 =
4005      new NISuppressor(1, 2, IntLessEqual.class);
4006  private static NISuppressor result_le_arg2 =
4007      new NISuppressor(1, 0, IntLessEqual.class);
4008  private static NISuppressor arg1_le_arg2 =
4009      new NISuppressor(2, 0, IntLessEqual.class);
4010  private static NISuppressor arg2_le_arg1 =
4011      new NISuppressor(0, 2, IntLessEqual.class);
4012
4013  private static NISuppressor result_track0_arg1 =
4014      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
4015  private static NISuppressor result_track0_arg2 =
4016      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
4017  private static NISuppressor arg1_track0_arg2 =
4018      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
4019  private static NISuppressor arg1_track0_result =
4020      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
4021  private static NISuppressor arg2_track0_result =
4022      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
4023  private static NISuppressor arg2_track0_arg1 =
4024      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
4025
4026  private static NISuppressor result_eq_1 =
4027      new NISuppressor(1, RangeInt.EqualOne.class);
4028  private static NISuppressor arg1_eq_1 =
4029      new NISuppressor(2, RangeInt.EqualOne.class);
4030  private static NISuppressor arg2_eq_1 =
4031      new NISuppressor(0, RangeInt.EqualOne.class);
4032
4033  private static NISuppressor result_eq_0 =
4034      new NISuppressor(1, RangeInt.EqualZero.class);
4035  private static NISuppressor arg1_eq_0 =
4036      new NISuppressor(2, RangeInt.EqualZero.class);
4037  private static NISuppressor arg2_eq_0 =
4038      new NISuppressor(0, RangeInt.EqualZero.class);
4039
4040  private static NISuppressor result_ne_0 =
4041      new NISuppressor(1, NonZero.class);
4042  private static NISuppressor arg1_ne_0 =
4043      new NISuppressor(2, NonZero.class);
4044  private static NISuppressor arg2_ne_0 =
4045      new NISuppressor(0, NonZero.class);
4046
4047  private static NISuppressor result_ge_0 =
4048      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
4049  private static NISuppressor arg1_ge_0 =
4050      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
4051  private static NISuppressor arg2_ge_0 =
4052      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
4053
4054  private static NISuppressor result_ge_64 =
4055      new NISuppressor(1, RangeInt.GreaterEqual64.class);
4056  private static NISuppressor arg1_ge_64 =
4057      new NISuppressor(2, RangeInt.GreaterEqual64.class);
4058  private static NISuppressor arg2_ge_64 =
4059      new NISuppressor(0, RangeInt.GreaterEqual64.class);
4060
4061  private static NISuppressor result_boolean =
4062      new NISuppressor(1, RangeInt.BooleanVal.class);
4063  private static NISuppressor arg1_boolean =
4064      new NISuppressor(2, RangeInt.BooleanVal.class);
4065  private static NISuppressor arg2_boolean =
4066      new NISuppressor(0, RangeInt.BooleanVal.class);
4067
4068  private static NISuppressor result_even =
4069      new NISuppressor(1, RangeInt.Even.class);
4070  private static NISuppressor arg1_even =
4071      new NISuppressor(2, RangeInt.Even.class);
4072  private static NISuppressor arg2_even =
4073      new NISuppressor(0, RangeInt.Even.class);
4074
4075  private static NISuppressor result_power2 =
4076      new NISuppressor(1, RangeInt.PowerOfTwo.class);
4077  private static NISuppressor arg1_power2 =
4078      new NISuppressor(2, RangeInt.PowerOfTwo.class);
4079  private static NISuppressor arg2_power2 =
4080      new NISuppressor(0, RangeInt.PowerOfTwo.class);
4081
4082  private static NISuppressor result_and0_arg1 =
4083      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
4084  private static NISuppressor result_and0_arg2 =
4085      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
4086  private static NISuppressor arg1_and0_arg2 =
4087      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
4088
4089  // The arguments to bitwise subset are backwards from what one
4090  // might expect.  The second argument is a subset of the first
4091  // argument
4092  private static NISuppressor arg1_bw_subset_arg2 =
4093      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
4094  private static NISuppressor arg2_bw_subset_arg1 =
4095      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
4096
4097  private static NISuppressor result_shift0_arg1 =
4098      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
4099  private static NISuppressor result_shift0_arg2 =
4100      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
4101  private static NISuppressor arg1_shift0_arg2 =
4102      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
4103
4104  private static NISuppressor arg2_divides_arg1 =
4105      new NISuppressor(2, 0, NumericInt.Divides.class);
4106  private static NISuppressor arg1_divides_arg2 =
4107      new NISuppressor(0, 2, NumericInt.Divides.class);
4108
4109  private static NISuppressor arg2_valid_shift =
4110      new NISuppressor(0, RangeInt.Bound0_63.class);
4111
4112    private static NISuppressionSet suppressions =
4113      new NISuppressionSet(
4114          new NISuppression[] {
4115
4116            // (r == 0) && (z < x) && (z >= 0) && (x != 0) ==> r = z / x
4117            new NISuppression(result_eq_0, arg1_lt_arg2, arg1_ge_0, arg2_ne_0, suppressee),
4118
4119            // (z == x) && (x != 0) && (r == 1)
4120            new NISuppression(arg1_eq_arg2, arg2_ne_0, result_eq_1, suppressee),
4121
4122            // (r == z) && (x == 1) ==> r = z / x
4123            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
4124          });
4125
4126  // Create a suppression factory for functionBinary
4127
4128}
4129
4130/**
4131 * Represents the invariant {@code z = Division(y, x)} over three long
4132 * scalars. 
4133 */
4134public static class DivisionLong_zyx extends FunctionBinary {
4135  // We are Serializable, so we specify a version to allow changes to
4136  // method signatures without breaking serialization.  If you add or
4137  // remove fields, you should change this number to the current date.
4138  static final long serialVersionUID = 20031030L;
4139
4140  private static @Prototype DivisionLong_zyx proto = new @Prototype DivisionLong_zyx ();
4141
4142  /** Returns the prototype invariant for DivisionLong_zyx */
4143  public static @Prototype DivisionLong_zyx get_proto() {
4144    return proto;
4145  }
4146
4147  /** instantiate an invariant on the specified slice */
4148  @Override
4149  protected DivisionLong_zyx instantiate_dyn(@Prototype DivisionLong_zyx this, PptSlice slice) {
4150    return new DivisionLong_zyx (slice);
4151  }
4152
4153  private DivisionLong_zyx (PptSlice slice) {
4154    super(slice);
4155  }
4156
4157  public @Prototype DivisionLong_zyx () {
4158    super();
4159  }
4160
4161  private static String[] method_name = new String[] {"", " / ", ""};
4162
4163  @Override
4164  public String[] get_method_name(@GuardSatisfied DivisionLong_zyx this) {
4165    return method_name;
4166  }
4167
4168  private static int function_id = -1;
4169
4170  @Override
4171  public int get_function_id() {
4172    return function_id;
4173  }
4174
4175  @Override
4176  public void set_function_id(int function_id) {
4177    assert DivisionLong_zyx.function_id == -1;
4178    DivisionLong_zyx.function_id = function_id;
4179  }
4180
4181  private static int var_order = 6;
4182
4183  @Override
4184  public int get_var_order(@GuardSatisfied DivisionLong_zyx this) {
4185    return var_order;
4186  }
4187
4188  @Pure
4189  @Override
4190  public boolean is_symmetric() {
4191
4192      return false;
4193  }
4194
4195  @Override
4196
4197  public long func(long y, long x) {
4198
4199    return (y / x);
4200  }
4201
4202  @Override
4203  public InvariantStatus check_modified(long x, long y,
4204                                      long z, int count) {
4205    return check_ordered(z, y, x, count);
4206  }
4207
4208  @Override
4209  public InvariantStatus add_modified(long x, long y,
4210                                      long z, int count) {
4211    if (Debug.logDetail()) {
4212      log("result=%s, arg1=%s, arg2=%s", z, y, x);
4213    }
4214    return add_ordered(z, y, x, count);
4215  }
4216
4217  @Pure
4218  @Override
4219  public boolean isDivision() {
4220    return true;
4221  }
4222
4223  @Pure
4224  @Override
4225  public boolean isExact() {
4226    return true;
4227  }
4228
4229  /** Returns a list of non-instantiating suppressions for this invariant. */
4230  @Pure
4231  @Override
4232  public @Nullable NISuppressionSet get_ni_suppressions() {
4233    if (NIS.dkconfig_enabled && dkconfig_enabled) {
4234      return suppressions;
4235    } else {
4236      return null;
4237    }
4238  }
4239
4240  /** definition of this invariant (the suppressee) */
4241  private static NISuppressee suppressee = new NISuppressee(DivisionLong_zyx.class, 3);
4242
4243  // suppressor definitions (used below)
4244  private static NISuppressor result_eq_arg1 =
4245      new NISuppressor(2, 1, IntEqual.class);
4246  private static NISuppressor result_eq_arg2 =
4247      new NISuppressor(2, 0, IntEqual.class);
4248  private static NISuppressor arg1_eq_arg2 =
4249      new NISuppressor(1, 0, IntEqual.class);
4250
4251  private static NISuppressor result_lt_arg1 =
4252      new NISuppressor(2, 1, IntLessThan.class);
4253  private static NISuppressor result_lt_arg2 =
4254      new NISuppressor(2, 0, IntLessThan.class);
4255  private static NISuppressor arg1_lt_arg2 =
4256      new NISuppressor(1, 0, IntLessThan.class);
4257  private static NISuppressor arg2_lt_arg1 =
4258      new NISuppressor(0, 1, IntLessThan.class);
4259
4260  private static NISuppressor result_le_arg1 =
4261      new NISuppressor(2, 1, IntLessEqual.class);
4262  private static NISuppressor result_le_arg2 =
4263      new NISuppressor(2, 0, IntLessEqual.class);
4264  private static NISuppressor arg1_le_arg2 =
4265      new NISuppressor(1, 0, IntLessEqual.class);
4266  private static NISuppressor arg2_le_arg1 =
4267      new NISuppressor(0, 1, IntLessEqual.class);
4268
4269  private static NISuppressor result_track0_arg1 =
4270      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
4271  private static NISuppressor result_track0_arg2 =
4272      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
4273  private static NISuppressor arg1_track0_arg2 =
4274      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
4275  private static NISuppressor arg1_track0_result =
4276      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
4277  private static NISuppressor arg2_track0_result =
4278      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
4279  private static NISuppressor arg2_track0_arg1 =
4280      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
4281
4282  private static NISuppressor result_eq_1 =
4283      new NISuppressor(2, RangeInt.EqualOne.class);
4284  private static NISuppressor arg1_eq_1 =
4285      new NISuppressor(1, RangeInt.EqualOne.class);
4286  private static NISuppressor arg2_eq_1 =
4287      new NISuppressor(0, RangeInt.EqualOne.class);
4288
4289  private static NISuppressor result_eq_0 =
4290      new NISuppressor(2, RangeInt.EqualZero.class);
4291  private static NISuppressor arg1_eq_0 =
4292      new NISuppressor(1, RangeInt.EqualZero.class);
4293  private static NISuppressor arg2_eq_0 =
4294      new NISuppressor(0, RangeInt.EqualZero.class);
4295
4296  private static NISuppressor result_ne_0 =
4297      new NISuppressor(2, NonZero.class);
4298  private static NISuppressor arg1_ne_0 =
4299      new NISuppressor(1, NonZero.class);
4300  private static NISuppressor arg2_ne_0 =
4301      new NISuppressor(0, NonZero.class);
4302
4303  private static NISuppressor result_ge_0 =
4304      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
4305  private static NISuppressor arg1_ge_0 =
4306      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
4307  private static NISuppressor arg2_ge_0 =
4308      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
4309
4310  private static NISuppressor result_ge_64 =
4311      new NISuppressor(2, RangeInt.GreaterEqual64.class);
4312  private static NISuppressor arg1_ge_64 =
4313      new NISuppressor(1, RangeInt.GreaterEqual64.class);
4314  private static NISuppressor arg2_ge_64 =
4315      new NISuppressor(0, RangeInt.GreaterEqual64.class);
4316
4317  private static NISuppressor result_boolean =
4318      new NISuppressor(2, RangeInt.BooleanVal.class);
4319  private static NISuppressor arg1_boolean =
4320      new NISuppressor(1, RangeInt.BooleanVal.class);
4321  private static NISuppressor arg2_boolean =
4322      new NISuppressor(0, RangeInt.BooleanVal.class);
4323
4324  private static NISuppressor result_even =
4325      new NISuppressor(2, RangeInt.Even.class);
4326  private static NISuppressor arg1_even =
4327      new NISuppressor(1, RangeInt.Even.class);
4328  private static NISuppressor arg2_even =
4329      new NISuppressor(0, RangeInt.Even.class);
4330
4331  private static NISuppressor result_power2 =
4332      new NISuppressor(2, RangeInt.PowerOfTwo.class);
4333  private static NISuppressor arg1_power2 =
4334      new NISuppressor(1, RangeInt.PowerOfTwo.class);
4335  private static NISuppressor arg2_power2 =
4336      new NISuppressor(0, RangeInt.PowerOfTwo.class);
4337
4338  private static NISuppressor result_and0_arg1 =
4339      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
4340  private static NISuppressor result_and0_arg2 =
4341      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
4342  private static NISuppressor arg1_and0_arg2 =
4343      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
4344
4345  // The arguments to bitwise subset are backwards from what one
4346  // might expect.  The second argument is a subset of the first
4347  // argument
4348  private static NISuppressor arg1_bw_subset_arg2 =
4349      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
4350  private static NISuppressor arg2_bw_subset_arg1 =
4351      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
4352
4353  private static NISuppressor result_shift0_arg1 =
4354      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
4355  private static NISuppressor result_shift0_arg2 =
4356      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
4357  private static NISuppressor arg1_shift0_arg2 =
4358      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
4359
4360  private static NISuppressor arg2_divides_arg1 =
4361      new NISuppressor(1, 0, NumericInt.Divides.class);
4362  private static NISuppressor arg1_divides_arg2 =
4363      new NISuppressor(0, 1, NumericInt.Divides.class);
4364
4365  private static NISuppressor arg2_valid_shift =
4366      new NISuppressor(0, RangeInt.Bound0_63.class);
4367
4368    private static NISuppressionSet suppressions =
4369      new NISuppressionSet(
4370          new NISuppression[] {
4371
4372            // (r == 0) && (y < x) && (y >= 0) && (x != 0) ==> r = y / x
4373            new NISuppression(result_eq_0, arg1_lt_arg2, arg1_ge_0, arg2_ne_0, suppressee),
4374
4375            // (y == x) && (x != 0) && (r == 1)
4376            new NISuppression(arg1_eq_arg2, arg2_ne_0, result_eq_1, suppressee),
4377
4378            // (r == y) && (x == 1) ==> r = y / x
4379            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
4380          });
4381
4382  // Create a suppression factory for functionBinary
4383
4384}
4385
4386  // default is that it is not this function, overriden in the subclass
4387  @Pure
4388  public boolean isPower() {
4389    return false;
4390  }
4391
4392/**
4393 * Represents the invariant {@code x = Power(y, z)} over three long
4394 * scalars. 
4395 */
4396public static class PowerLong_xyz extends FunctionBinary {
4397  // We are Serializable, so we specify a version to allow changes to
4398  // method signatures without breaking serialization.  If you add or
4399  // remove fields, you should change this number to the current date.
4400  static final long serialVersionUID = 20031030L;
4401
4402  private static @Prototype PowerLong_xyz proto = new @Prototype PowerLong_xyz ();
4403
4404  /** Returns the prototype invariant for PowerLong_xyz */
4405  public static @Prototype PowerLong_xyz get_proto() {
4406    return proto;
4407  }
4408
4409  /** instantiate an invariant on the specified slice */
4410  @Override
4411  protected PowerLong_xyz instantiate_dyn(@Prototype PowerLong_xyz this, PptSlice slice) {
4412    return new PowerLong_xyz (slice);
4413  }
4414
4415  private PowerLong_xyz (PptSlice slice) {
4416    super(slice);
4417  }
4418
4419  public @Prototype PowerLong_xyz () {
4420    super();
4421  }
4422
4423  private static String[] method_name = new String[] {"java.lang.Math.pow(", ", ", ")"};
4424
4425  @Override
4426  public String[] get_method_name(@GuardSatisfied PowerLong_xyz this) {
4427    return method_name;
4428  }
4429
4430  private static int function_id = -1;
4431
4432  @Override
4433  public int get_function_id() {
4434    return function_id;
4435  }
4436
4437  @Override
4438  public void set_function_id(int function_id) {
4439    assert PowerLong_xyz.function_id == -1;
4440    PowerLong_xyz.function_id = function_id;
4441  }
4442
4443  private static int var_order = 1;
4444
4445  @Override
4446  public int get_var_order(@GuardSatisfied PowerLong_xyz this) {
4447    return var_order;
4448  }
4449
4450  @Pure
4451  @Override
4452  public boolean is_symmetric() {
4453
4454      return false;
4455  }
4456
4457  @Override
4458
4459  public long func(long y, long z) {
4460
4461    return MathPlume.pow(y, z);
4462  }
4463
4464  @Override
4465  public InvariantStatus check_modified(long x, long y,
4466                                      long z, int count) {
4467    return check_ordered(x, y, z, count);
4468  }
4469
4470  @Override
4471  public InvariantStatus add_modified(long x, long y,
4472                                      long z, int count) {
4473    if (Debug.logDetail()) {
4474      log("result=%s, arg1=%s, arg2=%s", x, y, z);
4475    }
4476    return add_ordered(x, y, z, count);
4477  }
4478
4479  @Pure
4480  @Override
4481  public boolean isPower() {
4482    return true;
4483  }
4484
4485  @Pure
4486  @Override
4487  public boolean isExact() {
4488    return true;
4489  }
4490
4491  /** Returns a list of non-instantiating suppressions for this invariant. */
4492  @Pure
4493  @Override
4494  public @Nullable NISuppressionSet get_ni_suppressions() {
4495    if (NIS.dkconfig_enabled && dkconfig_enabled) {
4496      return suppressions;
4497    } else {
4498      return null;
4499    }
4500  }
4501
4502  /** definition of this invariant (the suppressee) */
4503  private static NISuppressee suppressee = new NISuppressee(PowerLong_xyz.class, 3);
4504
4505  // suppressor definitions (used below)
4506  private static NISuppressor result_eq_arg1 =
4507      new NISuppressor(0, 1, IntEqual.class);
4508  private static NISuppressor result_eq_arg2 =
4509      new NISuppressor(0, 2, IntEqual.class);
4510  private static NISuppressor arg1_eq_arg2 =
4511      new NISuppressor(1, 2, IntEqual.class);
4512
4513  private static NISuppressor result_lt_arg1 =
4514      new NISuppressor(0, 1, IntLessThan.class);
4515  private static NISuppressor result_lt_arg2 =
4516      new NISuppressor(0, 2, IntLessThan.class);
4517  private static NISuppressor arg1_lt_arg2 =
4518      new NISuppressor(1, 2, IntLessThan.class);
4519  private static NISuppressor arg2_lt_arg1 =
4520      new NISuppressor(2, 1, IntLessThan.class);
4521
4522  private static NISuppressor result_le_arg1 =
4523      new NISuppressor(0, 1, IntLessEqual.class);
4524  private static NISuppressor result_le_arg2 =
4525      new NISuppressor(0, 2, IntLessEqual.class);
4526  private static NISuppressor arg1_le_arg2 =
4527      new NISuppressor(1, 2, IntLessEqual.class);
4528  private static NISuppressor arg2_le_arg1 =
4529      new NISuppressor(2, 1, IntLessEqual.class);
4530
4531  private static NISuppressor result_track0_arg1 =
4532      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
4533  private static NISuppressor result_track0_arg2 =
4534      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
4535  private static NISuppressor arg1_track0_arg2 =
4536      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
4537  private static NISuppressor arg1_track0_result =
4538      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
4539  private static NISuppressor arg2_track0_result =
4540      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
4541  private static NISuppressor arg2_track0_arg1 =
4542      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
4543
4544  private static NISuppressor result_eq_1 =
4545      new NISuppressor(0, RangeInt.EqualOne.class);
4546  private static NISuppressor arg1_eq_1 =
4547      new NISuppressor(1, RangeInt.EqualOne.class);
4548  private static NISuppressor arg2_eq_1 =
4549      new NISuppressor(2, RangeInt.EqualOne.class);
4550
4551  private static NISuppressor result_eq_0 =
4552      new NISuppressor(0, RangeInt.EqualZero.class);
4553  private static NISuppressor arg1_eq_0 =
4554      new NISuppressor(1, RangeInt.EqualZero.class);
4555  private static NISuppressor arg2_eq_0 =
4556      new NISuppressor(2, RangeInt.EqualZero.class);
4557
4558  private static NISuppressor result_ne_0 =
4559      new NISuppressor(0, NonZero.class);
4560  private static NISuppressor arg1_ne_0 =
4561      new NISuppressor(1, NonZero.class);
4562  private static NISuppressor arg2_ne_0 =
4563      new NISuppressor(2, NonZero.class);
4564
4565  private static NISuppressor result_ge_0 =
4566      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
4567  private static NISuppressor arg1_ge_0 =
4568      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
4569  private static NISuppressor arg2_ge_0 =
4570      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
4571
4572  private static NISuppressor result_ge_64 =
4573      new NISuppressor(0, RangeInt.GreaterEqual64.class);
4574  private static NISuppressor arg1_ge_64 =
4575      new NISuppressor(1, RangeInt.GreaterEqual64.class);
4576  private static NISuppressor arg2_ge_64 =
4577      new NISuppressor(2, RangeInt.GreaterEqual64.class);
4578
4579  private static NISuppressor result_boolean =
4580      new NISuppressor(0, RangeInt.BooleanVal.class);
4581  private static NISuppressor arg1_boolean =
4582      new NISuppressor(1, RangeInt.BooleanVal.class);
4583  private static NISuppressor arg2_boolean =
4584      new NISuppressor(2, RangeInt.BooleanVal.class);
4585
4586  private static NISuppressor result_even =
4587      new NISuppressor(0, RangeInt.Even.class);
4588  private static NISuppressor arg1_even =
4589      new NISuppressor(1, RangeInt.Even.class);
4590  private static NISuppressor arg2_even =
4591      new NISuppressor(2, RangeInt.Even.class);
4592
4593  private static NISuppressor result_power2 =
4594      new NISuppressor(0, RangeInt.PowerOfTwo.class);
4595  private static NISuppressor arg1_power2 =
4596      new NISuppressor(1, RangeInt.PowerOfTwo.class);
4597  private static NISuppressor arg2_power2 =
4598      new NISuppressor(2, RangeInt.PowerOfTwo.class);
4599
4600  private static NISuppressor result_and0_arg1 =
4601      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
4602  private static NISuppressor result_and0_arg2 =
4603      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
4604  private static NISuppressor arg1_and0_arg2 =
4605      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
4606
4607  // The arguments to bitwise subset are backwards from what one
4608  // might expect.  The second argument is a subset of the first
4609  // argument
4610  private static NISuppressor arg1_bw_subset_arg2 =
4611      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
4612  private static NISuppressor arg2_bw_subset_arg1 =
4613      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
4614
4615  private static NISuppressor result_shift0_arg1 =
4616      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
4617  private static NISuppressor result_shift0_arg2 =
4618      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
4619  private static NISuppressor arg1_shift0_arg2 =
4620      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
4621
4622  private static NISuppressor arg2_divides_arg1 =
4623      new NISuppressor(1, 2, NumericInt.Divides.class);
4624  private static NISuppressor arg1_divides_arg2 =
4625      new NISuppressor(2, 1, NumericInt.Divides.class);
4626
4627  private static NISuppressor arg2_valid_shift =
4628      new NISuppressor(2, RangeInt.Bound0_63.class);
4629
4630    // Note that any suppression that doesn't limit z to valid exponents
4631    // (>= 0), must check for valid exponents as well (so that the invariant
4632    // is correctly destroyed on invalid exponents)
4633    //
4634    // Note also that pow(0,0) == 1 and pow(0,x), where (x > 0), == 0
4635    // Another interesting artificat of pow is that for any even base, any
4636    // exponent >= 64 will yield a result of 0.  For example, pow(10,256) == 0
4637    // (at least for integers)
4638
4639    private static NISuppressionSet suppressions =
4640      new NISuppressionSet(
4641          new NISuppression[] {
4642
4643            // (r == 1) && (z == 0) ==> r = pow (y, z)
4644            new NISuppression(result_eq_1, arg2_eq_0, suppressee),
4645
4646            // (r == 1) && (y == 1) && (z >= 0)   ==> r = pow (y, z)
4647            new NISuppression(result_eq_1, arg1_eq_1, arg2_ge_0, suppressee),
4648
4649            // (r == 0) && (y == 0) && (z > 0)
4650            new NISuppression(result_eq_0, arg1_eq_0, arg2_ne_0, arg2_ge_0,
4651                              suppressee),
4652
4653            // (r == y) && (z == 1)    ==> r = pow (y, z)
4654            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
4655
4656            // (r == 0) && (y even) && (z >= 64)
4657            // with each multiply there is one more zero in the result and since
4658            // a long has 64 bits in it, it becomes zero at that point
4659            new NISuppression(result_eq_0, arg1_even, arg2_ge_64, suppressee),
4660
4661            // (r == 1) && (y boolean) && (y==0 <==> z==0) && (z >= 0)
4662            // 1 = pow (0, z) true iff (z == 0)
4663            // 1 = pow (1, z) true when z valid exponent
4664            new NISuppression(arg1_track0_arg2, arg2_ge_0, arg1_boolean,
4665                               result_eq_1, suppressee),
4666
4667            // (r == y) && (r boolean) && (z > 0)
4668            // 0 = pow (0, z) true when z != 0
4669            // 1 = pow (1, z) true when z valid exponent
4670            new NISuppression(result_eq_arg1, result_boolean, arg2_ne_0,
4671                               arg2_ge_0, suppressee),
4672
4673          });
4674
4675  // Create a suppression factory for functionBinary
4676
4677}
4678
4679/**
4680 * Represents the invariant {@code y = Power(x, z)} over three long
4681 * scalars. 
4682 */
4683public static class PowerLong_yxz extends FunctionBinary {
4684  // We are Serializable, so we specify a version to allow changes to
4685  // method signatures without breaking serialization.  If you add or
4686  // remove fields, you should change this number to the current date.
4687  static final long serialVersionUID = 20031030L;
4688
4689  private static @Prototype PowerLong_yxz proto = new @Prototype PowerLong_yxz ();
4690
4691  /** Returns the prototype invariant for PowerLong_yxz */
4692  public static @Prototype PowerLong_yxz get_proto() {
4693    return proto;
4694  }
4695
4696  /** instantiate an invariant on the specified slice */
4697  @Override
4698  protected PowerLong_yxz instantiate_dyn(@Prototype PowerLong_yxz this, PptSlice slice) {
4699    return new PowerLong_yxz (slice);
4700  }
4701
4702  private PowerLong_yxz (PptSlice slice) {
4703    super(slice);
4704  }
4705
4706  public @Prototype PowerLong_yxz () {
4707    super();
4708  }
4709
4710  private static String[] method_name = new String[] {"java.lang.Math.pow(", ", ", ")"};
4711
4712  @Override
4713  public String[] get_method_name(@GuardSatisfied PowerLong_yxz this) {
4714    return method_name;
4715  }
4716
4717  private static int function_id = -1;
4718
4719  @Override
4720  public int get_function_id() {
4721    return function_id;
4722  }
4723
4724  @Override
4725  public void set_function_id(int function_id) {
4726    assert PowerLong_yxz.function_id == -1;
4727    PowerLong_yxz.function_id = function_id;
4728  }
4729
4730  private static int var_order = 2;
4731
4732  @Override
4733  public int get_var_order(@GuardSatisfied PowerLong_yxz this) {
4734    return var_order;
4735  }
4736
4737  @Pure
4738  @Override
4739  public boolean is_symmetric() {
4740
4741      return false;
4742  }
4743
4744  @Override
4745
4746  public long func(long x, long z) {
4747
4748    return MathPlume.pow(x, z);
4749  }
4750
4751  @Override
4752  public InvariantStatus check_modified(long x, long y,
4753                                      long z, int count) {
4754    return check_ordered(y, x, z, count);
4755  }
4756
4757  @Override
4758  public InvariantStatus add_modified(long x, long y,
4759                                      long z, int count) {
4760    if (Debug.logDetail()) {
4761      log("result=%s, arg1=%s, arg2=%s", y, x, z);
4762    }
4763    return add_ordered(y, x, z, count);
4764  }
4765
4766  @Pure
4767  @Override
4768  public boolean isPower() {
4769    return true;
4770  }
4771
4772  @Pure
4773  @Override
4774  public boolean isExact() {
4775    return true;
4776  }
4777
4778  /** Returns a list of non-instantiating suppressions for this invariant. */
4779  @Pure
4780  @Override
4781  public @Nullable NISuppressionSet get_ni_suppressions() {
4782    if (NIS.dkconfig_enabled && dkconfig_enabled) {
4783      return suppressions;
4784    } else {
4785      return null;
4786    }
4787  }
4788
4789  /** definition of this invariant (the suppressee) */
4790  private static NISuppressee suppressee = new NISuppressee(PowerLong_yxz.class, 3);
4791
4792  // suppressor definitions (used below)
4793  private static NISuppressor result_eq_arg1 =
4794      new NISuppressor(1, 0, IntEqual.class);
4795  private static NISuppressor result_eq_arg2 =
4796      new NISuppressor(1, 2, IntEqual.class);
4797  private static NISuppressor arg1_eq_arg2 =
4798      new NISuppressor(0, 2, IntEqual.class);
4799
4800  private static NISuppressor result_lt_arg1 =
4801      new NISuppressor(1, 0, IntLessThan.class);
4802  private static NISuppressor result_lt_arg2 =
4803      new NISuppressor(1, 2, IntLessThan.class);
4804  private static NISuppressor arg1_lt_arg2 =
4805      new NISuppressor(0, 2, IntLessThan.class);
4806  private static NISuppressor arg2_lt_arg1 =
4807      new NISuppressor(2, 0, IntLessThan.class);
4808
4809  private static NISuppressor result_le_arg1 =
4810      new NISuppressor(1, 0, IntLessEqual.class);
4811  private static NISuppressor result_le_arg2 =
4812      new NISuppressor(1, 2, IntLessEqual.class);
4813  private static NISuppressor arg1_le_arg2 =
4814      new NISuppressor(0, 2, IntLessEqual.class);
4815  private static NISuppressor arg2_le_arg1 =
4816      new NISuppressor(2, 0, IntLessEqual.class);
4817
4818  private static NISuppressor result_track0_arg1 =
4819      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
4820  private static NISuppressor result_track0_arg2 =
4821      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
4822  private static NISuppressor arg1_track0_arg2 =
4823      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
4824  private static NISuppressor arg1_track0_result =
4825      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
4826  private static NISuppressor arg2_track0_result =
4827      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
4828  private static NISuppressor arg2_track0_arg1 =
4829      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
4830
4831  private static NISuppressor result_eq_1 =
4832      new NISuppressor(1, RangeInt.EqualOne.class);
4833  private static NISuppressor arg1_eq_1 =
4834      new NISuppressor(0, RangeInt.EqualOne.class);
4835  private static NISuppressor arg2_eq_1 =
4836      new NISuppressor(2, RangeInt.EqualOne.class);
4837
4838  private static NISuppressor result_eq_0 =
4839      new NISuppressor(1, RangeInt.EqualZero.class);
4840  private static NISuppressor arg1_eq_0 =
4841      new NISuppressor(0, RangeInt.EqualZero.class);
4842  private static NISuppressor arg2_eq_0 =
4843      new NISuppressor(2, RangeInt.EqualZero.class);
4844
4845  private static NISuppressor result_ne_0 =
4846      new NISuppressor(1, NonZero.class);
4847  private static NISuppressor arg1_ne_0 =
4848      new NISuppressor(0, NonZero.class);
4849  private static NISuppressor arg2_ne_0 =
4850      new NISuppressor(2, NonZero.class);
4851
4852  private static NISuppressor result_ge_0 =
4853      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
4854  private static NISuppressor arg1_ge_0 =
4855      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
4856  private static NISuppressor arg2_ge_0 =
4857      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
4858
4859  private static NISuppressor result_ge_64 =
4860      new NISuppressor(1, RangeInt.GreaterEqual64.class);
4861  private static NISuppressor arg1_ge_64 =
4862      new NISuppressor(0, RangeInt.GreaterEqual64.class);
4863  private static NISuppressor arg2_ge_64 =
4864      new NISuppressor(2, RangeInt.GreaterEqual64.class);
4865
4866  private static NISuppressor result_boolean =
4867      new NISuppressor(1, RangeInt.BooleanVal.class);
4868  private static NISuppressor arg1_boolean =
4869      new NISuppressor(0, RangeInt.BooleanVal.class);
4870  private static NISuppressor arg2_boolean =
4871      new NISuppressor(2, RangeInt.BooleanVal.class);
4872
4873  private static NISuppressor result_even =
4874      new NISuppressor(1, RangeInt.Even.class);
4875  private static NISuppressor arg1_even =
4876      new NISuppressor(0, RangeInt.Even.class);
4877  private static NISuppressor arg2_even =
4878      new NISuppressor(2, RangeInt.Even.class);
4879
4880  private static NISuppressor result_power2 =
4881      new NISuppressor(1, RangeInt.PowerOfTwo.class);
4882  private static NISuppressor arg1_power2 =
4883      new NISuppressor(0, RangeInt.PowerOfTwo.class);
4884  private static NISuppressor arg2_power2 =
4885      new NISuppressor(2, RangeInt.PowerOfTwo.class);
4886
4887  private static NISuppressor result_and0_arg1 =
4888      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
4889  private static NISuppressor result_and0_arg2 =
4890      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
4891  private static NISuppressor arg1_and0_arg2 =
4892      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
4893
4894  // The arguments to bitwise subset are backwards from what one
4895  // might expect.  The second argument is a subset of the first
4896  // argument
4897  private static NISuppressor arg1_bw_subset_arg2 =
4898      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
4899  private static NISuppressor arg2_bw_subset_arg1 =
4900      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
4901
4902  private static NISuppressor result_shift0_arg1 =
4903      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
4904  private static NISuppressor result_shift0_arg2 =
4905      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
4906  private static NISuppressor arg1_shift0_arg2 =
4907      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
4908
4909  private static NISuppressor arg2_divides_arg1 =
4910      new NISuppressor(0, 2, NumericInt.Divides.class);
4911  private static NISuppressor arg1_divides_arg2 =
4912      new NISuppressor(2, 0, NumericInt.Divides.class);
4913
4914  private static NISuppressor arg2_valid_shift =
4915      new NISuppressor(2, RangeInt.Bound0_63.class);
4916
4917    // Note that any suppression that doesn't limit z to valid exponents
4918    // (>= 0), must check for valid exponents as well (so that the invariant
4919    // is correctly destroyed on invalid exponents)
4920    //
4921    // Note also that pow(0,0) == 1 and pow(0,x), where (x > 0), == 0
4922    // Another interesting artificat of pow is that for any even base, any
4923    // exponent >= 64 will yield a result of 0.  For example, pow(10,256) == 0
4924    // (at least for integers)
4925
4926    private static NISuppressionSet suppressions =
4927      new NISuppressionSet(
4928          new NISuppression[] {
4929
4930            // (r == 1) && (z == 0) ==> r = pow (x, z)
4931            new NISuppression(result_eq_1, arg2_eq_0, suppressee),
4932
4933            // (r == 1) && (x == 1) && (z >= 0)   ==> r = pow (x, z)
4934            new NISuppression(result_eq_1, arg1_eq_1, arg2_ge_0, suppressee),
4935
4936            // (r == 0) && (x == 0) && (z > 0)
4937            new NISuppression(result_eq_0, arg1_eq_0, arg2_ne_0, arg2_ge_0,
4938                              suppressee),
4939
4940            // (r == x) && (z == 1)    ==> r = pow (x, z)
4941            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
4942
4943            // (r == 0) && (x even) && (z >= 64)
4944            // with each multiply there is one more zero in the result and since
4945            // a long has 64 bits in it, it becomes zero at that point
4946            new NISuppression(result_eq_0, arg1_even, arg2_ge_64, suppressee),
4947
4948            // (r == 1) && (x boolean) && (x==0 <==> z==0) && (z >= 0)
4949            // 1 = pow (0, z) true iff (z == 0)
4950            // 1 = pow (1, z) true when z valid exponent
4951            new NISuppression(arg1_track0_arg2, arg2_ge_0, arg1_boolean,
4952                               result_eq_1, suppressee),
4953
4954            // (r == x) && (r boolean) && (z > 0)
4955            // 0 = pow (0, z) true when z != 0
4956            // 1 = pow (1, z) true when z valid exponent
4957            new NISuppression(result_eq_arg1, result_boolean, arg2_ne_0,
4958                               arg2_ge_0, suppressee),
4959
4960          });
4961
4962  // Create a suppression factory for functionBinary
4963
4964}
4965
4966/**
4967 * Represents the invariant {@code z = Power(x, y)} over three long
4968 * scalars. 
4969 */
4970public static class PowerLong_zxy extends FunctionBinary {
4971  // We are Serializable, so we specify a version to allow changes to
4972  // method signatures without breaking serialization.  If you add or
4973  // remove fields, you should change this number to the current date.
4974  static final long serialVersionUID = 20031030L;
4975
4976  private static @Prototype PowerLong_zxy proto = new @Prototype PowerLong_zxy ();
4977
4978  /** Returns the prototype invariant for PowerLong_zxy */
4979  public static @Prototype PowerLong_zxy get_proto() {
4980    return proto;
4981  }
4982
4983  /** instantiate an invariant on the specified slice */
4984  @Override
4985  protected PowerLong_zxy instantiate_dyn(@Prototype PowerLong_zxy this, PptSlice slice) {
4986    return new PowerLong_zxy (slice);
4987  }
4988
4989  private PowerLong_zxy (PptSlice slice) {
4990    super(slice);
4991  }
4992
4993  public @Prototype PowerLong_zxy () {
4994    super();
4995  }
4996
4997  private static String[] method_name = new String[] {"java.lang.Math.pow(", ", ", ")"};
4998
4999  @Override
5000  public String[] get_method_name(@GuardSatisfied PowerLong_zxy this) {
5001    return method_name;
5002  }
5003
5004  private static int function_id = -1;
5005
5006  @Override
5007  public int get_function_id() {
5008    return function_id;
5009  }
5010
5011  @Override
5012  public void set_function_id(int function_id) {
5013    assert PowerLong_zxy.function_id == -1;
5014    PowerLong_zxy.function_id = function_id;
5015  }
5016
5017  private static int var_order = 3;
5018
5019  @Override
5020  public int get_var_order(@GuardSatisfied PowerLong_zxy this) {
5021    return var_order;
5022  }
5023
5024  @Pure
5025  @Override
5026  public boolean is_symmetric() {
5027
5028      return false;
5029  }
5030
5031  @Override
5032
5033  public long func(long x, long y) {
5034
5035    return MathPlume.pow(x, y);
5036  }
5037
5038  @Override
5039  public InvariantStatus check_modified(long x, long y,
5040                                      long z, int count) {
5041    return check_ordered(z, x, y, count);
5042  }
5043
5044  @Override
5045  public InvariantStatus add_modified(long x, long y,
5046                                      long z, int count) {
5047    if (Debug.logDetail()) {
5048      log("result=%s, arg1=%s, arg2=%s", z, x, y);
5049    }
5050    return add_ordered(z, x, y, count);
5051  }
5052
5053  @Pure
5054  @Override
5055  public boolean isPower() {
5056    return true;
5057  }
5058
5059  @Pure
5060  @Override
5061  public boolean isExact() {
5062    return true;
5063  }
5064
5065  /** Returns a list of non-instantiating suppressions for this invariant. */
5066  @Pure
5067  @Override
5068  public @Nullable NISuppressionSet get_ni_suppressions() {
5069    if (NIS.dkconfig_enabled && dkconfig_enabled) {
5070      return suppressions;
5071    } else {
5072      return null;
5073    }
5074  }
5075
5076  /** definition of this invariant (the suppressee) */
5077  private static NISuppressee suppressee = new NISuppressee(PowerLong_zxy.class, 3);
5078
5079  // suppressor definitions (used below)
5080  private static NISuppressor result_eq_arg1 =
5081      new NISuppressor(2, 0, IntEqual.class);
5082  private static NISuppressor result_eq_arg2 =
5083      new NISuppressor(2, 1, IntEqual.class);
5084  private static NISuppressor arg1_eq_arg2 =
5085      new NISuppressor(0, 1, IntEqual.class);
5086
5087  private static NISuppressor result_lt_arg1 =
5088      new NISuppressor(2, 0, IntLessThan.class);
5089  private static NISuppressor result_lt_arg2 =
5090      new NISuppressor(2, 1, IntLessThan.class);
5091  private static NISuppressor arg1_lt_arg2 =
5092      new NISuppressor(0, 1, IntLessThan.class);
5093  private static NISuppressor arg2_lt_arg1 =
5094      new NISuppressor(1, 0, IntLessThan.class);
5095
5096  private static NISuppressor result_le_arg1 =
5097      new NISuppressor(2, 0, IntLessEqual.class);
5098  private static NISuppressor result_le_arg2 =
5099      new NISuppressor(2, 1, IntLessEqual.class);
5100  private static NISuppressor arg1_le_arg2 =
5101      new NISuppressor(0, 1, IntLessEqual.class);
5102  private static NISuppressor arg2_le_arg1 =
5103      new NISuppressor(1, 0, IntLessEqual.class);
5104
5105  private static NISuppressor result_track0_arg1 =
5106      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
5107  private static NISuppressor result_track0_arg2 =
5108      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
5109  private static NISuppressor arg1_track0_arg2 =
5110      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
5111  private static NISuppressor arg1_track0_result =
5112      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
5113  private static NISuppressor arg2_track0_result =
5114      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
5115  private static NISuppressor arg2_track0_arg1 =
5116      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
5117
5118  private static NISuppressor result_eq_1 =
5119      new NISuppressor(2, RangeInt.EqualOne.class);
5120  private static NISuppressor arg1_eq_1 =
5121      new NISuppressor(0, RangeInt.EqualOne.class);
5122  private static NISuppressor arg2_eq_1 =
5123      new NISuppressor(1, RangeInt.EqualOne.class);
5124
5125  private static NISuppressor result_eq_0 =
5126      new NISuppressor(2, RangeInt.EqualZero.class);
5127  private static NISuppressor arg1_eq_0 =
5128      new NISuppressor(0, RangeInt.EqualZero.class);
5129  private static NISuppressor arg2_eq_0 =
5130      new NISuppressor(1, RangeInt.EqualZero.class);
5131
5132  private static NISuppressor result_ne_0 =
5133      new NISuppressor(2, NonZero.class);
5134  private static NISuppressor arg1_ne_0 =
5135      new NISuppressor(0, NonZero.class);
5136  private static NISuppressor arg2_ne_0 =
5137      new NISuppressor(1, NonZero.class);
5138
5139  private static NISuppressor result_ge_0 =
5140      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
5141  private static NISuppressor arg1_ge_0 =
5142      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
5143  private static NISuppressor arg2_ge_0 =
5144      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
5145
5146  private static NISuppressor result_ge_64 =
5147      new NISuppressor(2, RangeInt.GreaterEqual64.class);
5148  private static NISuppressor arg1_ge_64 =
5149      new NISuppressor(0, RangeInt.GreaterEqual64.class);
5150  private static NISuppressor arg2_ge_64 =
5151      new NISuppressor(1, RangeInt.GreaterEqual64.class);
5152
5153  private static NISuppressor result_boolean =
5154      new NISuppressor(2, RangeInt.BooleanVal.class);
5155  private static NISuppressor arg1_boolean =
5156      new NISuppressor(0, RangeInt.BooleanVal.class);
5157  private static NISuppressor arg2_boolean =
5158      new NISuppressor(1, RangeInt.BooleanVal.class);
5159
5160  private static NISuppressor result_even =
5161      new NISuppressor(2, RangeInt.Even.class);
5162  private static NISuppressor arg1_even =
5163      new NISuppressor(0, RangeInt.Even.class);
5164  private static NISuppressor arg2_even =
5165      new NISuppressor(1, RangeInt.Even.class);
5166
5167  private static NISuppressor result_power2 =
5168      new NISuppressor(2, RangeInt.PowerOfTwo.class);
5169  private static NISuppressor arg1_power2 =
5170      new NISuppressor(0, RangeInt.PowerOfTwo.class);
5171  private static NISuppressor arg2_power2 =
5172      new NISuppressor(1, RangeInt.PowerOfTwo.class);
5173
5174  private static NISuppressor result_and0_arg1 =
5175      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
5176  private static NISuppressor result_and0_arg2 =
5177      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
5178  private static NISuppressor arg1_and0_arg2 =
5179      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
5180
5181  // The arguments to bitwise subset are backwards from what one
5182  // might expect.  The second argument is a subset of the first
5183  // argument
5184  private static NISuppressor arg1_bw_subset_arg2 =
5185      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
5186  private static NISuppressor arg2_bw_subset_arg1 =
5187      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
5188
5189  private static NISuppressor result_shift0_arg1 =
5190      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
5191  private static NISuppressor result_shift0_arg2 =
5192      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
5193  private static NISuppressor arg1_shift0_arg2 =
5194      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
5195
5196  private static NISuppressor arg2_divides_arg1 =
5197      new NISuppressor(0, 1, NumericInt.Divides.class);
5198  private static NISuppressor arg1_divides_arg2 =
5199      new NISuppressor(1, 0, NumericInt.Divides.class);
5200
5201  private static NISuppressor arg2_valid_shift =
5202      new NISuppressor(1, RangeInt.Bound0_63.class);
5203
5204    // Note that any suppression that doesn't limit y to valid exponents
5205    // (>= 0), must check for valid exponents as well (so that the invariant
5206    // is correctly destroyed on invalid exponents)
5207    //
5208    // Note also that pow(0,0) == 1 and pow(0,x), where (x > 0), == 0
5209    // Another interesting artificat of pow is that for any even base, any
5210    // exponent >= 64 will yield a result of 0.  For example, pow(10,256) == 0
5211    // (at least for integers)
5212
5213    private static NISuppressionSet suppressions =
5214      new NISuppressionSet(
5215          new NISuppression[] {
5216
5217            // (r == 1) && (y == 0) ==> r = pow (x, y)
5218            new NISuppression(result_eq_1, arg2_eq_0, suppressee),
5219
5220            // (r == 1) && (x == 1) && (y >= 0)   ==> r = pow (x, y)
5221            new NISuppression(result_eq_1, arg1_eq_1, arg2_ge_0, suppressee),
5222
5223            // (r == 0) && (x == 0) && (y > 0)
5224            new NISuppression(result_eq_0, arg1_eq_0, arg2_ne_0, arg2_ge_0,
5225                              suppressee),
5226
5227            // (r == x) && (y == 1)    ==> r = pow (x, y)
5228            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
5229
5230            // (r == 0) && (x even) && (y >= 64)
5231            // with each multiply there is one more zero in the result and since
5232            // a long has 64 bits in it, it becomes zero at that point
5233            new NISuppression(result_eq_0, arg1_even, arg2_ge_64, suppressee),
5234
5235            // (r == 1) && (x boolean) && (x==0 <==> y==0) && (y >= 0)
5236            // 1 = pow (0, y) true iff (y == 0)
5237            // 1 = pow (1, y) true when y valid exponent
5238            new NISuppression(arg1_track0_arg2, arg2_ge_0, arg1_boolean,
5239                               result_eq_1, suppressee),
5240
5241            // (r == x) && (r boolean) && (y > 0)
5242            // 0 = pow (0, y) true when y != 0
5243            // 1 = pow (1, y) true when y valid exponent
5244            new NISuppression(result_eq_arg1, result_boolean, arg2_ne_0,
5245                               arg2_ge_0, suppressee),
5246
5247          });
5248
5249  // Create a suppression factory for functionBinary
5250
5251}
5252
5253/**
5254 * Represents the invariant {@code x = Power(z, y)} over three long
5255 * scalars. 
5256 */
5257public static class PowerLong_xzy extends FunctionBinary {
5258  // We are Serializable, so we specify a version to allow changes to
5259  // method signatures without breaking serialization.  If you add or
5260  // remove fields, you should change this number to the current date.
5261  static final long serialVersionUID = 20031030L;
5262
5263  private static @Prototype PowerLong_xzy proto = new @Prototype PowerLong_xzy ();
5264
5265  /** Returns the prototype invariant for PowerLong_xzy */
5266  public static @Prototype PowerLong_xzy get_proto() {
5267    return proto;
5268  }
5269
5270  /** instantiate an invariant on the specified slice */
5271  @Override
5272  protected PowerLong_xzy instantiate_dyn(@Prototype PowerLong_xzy this, PptSlice slice) {
5273    return new PowerLong_xzy (slice);
5274  }
5275
5276  private PowerLong_xzy (PptSlice slice) {
5277    super(slice);
5278  }
5279
5280  public @Prototype PowerLong_xzy () {
5281    super();
5282  }
5283
5284  private static String[] method_name = new String[] {"java.lang.Math.pow(", ", ", ")"};
5285
5286  @Override
5287  public String[] get_method_name(@GuardSatisfied PowerLong_xzy this) {
5288    return method_name;
5289  }
5290
5291  private static int function_id = -1;
5292
5293  @Override
5294  public int get_function_id() {
5295    return function_id;
5296  }
5297
5298  @Override
5299  public void set_function_id(int function_id) {
5300    assert PowerLong_xzy.function_id == -1;
5301    PowerLong_xzy.function_id = function_id;
5302  }
5303
5304  private static int var_order = 4;
5305
5306  @Override
5307  public int get_var_order(@GuardSatisfied PowerLong_xzy this) {
5308    return var_order;
5309  }
5310
5311  @Pure
5312  @Override
5313  public boolean is_symmetric() {
5314
5315      return false;
5316  }
5317
5318  @Override
5319
5320  public long func(long z, long y) {
5321
5322    return MathPlume.pow(z, y);
5323  }
5324
5325  @Override
5326  public InvariantStatus check_modified(long x, long y,
5327                                      long z, int count) {
5328    return check_ordered(x, z, y, count);
5329  }
5330
5331  @Override
5332  public InvariantStatus add_modified(long x, long y,
5333                                      long z, int count) {
5334    if (Debug.logDetail()) {
5335      log("result=%s, arg1=%s, arg2=%s", x, z, y);
5336    }
5337    return add_ordered(x, z, y, count);
5338  }
5339
5340  @Pure
5341  @Override
5342  public boolean isPower() {
5343    return true;
5344  }
5345
5346  @Pure
5347  @Override
5348  public boolean isExact() {
5349    return true;
5350  }
5351
5352  /** Returns a list of non-instantiating suppressions for this invariant. */
5353  @Pure
5354  @Override
5355  public @Nullable NISuppressionSet get_ni_suppressions() {
5356    if (NIS.dkconfig_enabled && dkconfig_enabled) {
5357      return suppressions;
5358    } else {
5359      return null;
5360    }
5361  }
5362
5363  /** definition of this invariant (the suppressee) */
5364  private static NISuppressee suppressee = new NISuppressee(PowerLong_xzy.class, 3);
5365
5366  // suppressor definitions (used below)
5367  private static NISuppressor result_eq_arg1 =
5368      new NISuppressor(0, 2, IntEqual.class);
5369  private static NISuppressor result_eq_arg2 =
5370      new NISuppressor(0, 1, IntEqual.class);
5371  private static NISuppressor arg1_eq_arg2 =
5372      new NISuppressor(2, 1, IntEqual.class);
5373
5374  private static NISuppressor result_lt_arg1 =
5375      new NISuppressor(0, 2, IntLessThan.class);
5376  private static NISuppressor result_lt_arg2 =
5377      new NISuppressor(0, 1, IntLessThan.class);
5378  private static NISuppressor arg1_lt_arg2 =
5379      new NISuppressor(2, 1, IntLessThan.class);
5380  private static NISuppressor arg2_lt_arg1 =
5381      new NISuppressor(1, 2, IntLessThan.class);
5382
5383  private static NISuppressor result_le_arg1 =
5384      new NISuppressor(0, 2, IntLessEqual.class);
5385  private static NISuppressor result_le_arg2 =
5386      new NISuppressor(0, 1, IntLessEqual.class);
5387  private static NISuppressor arg1_le_arg2 =
5388      new NISuppressor(2, 1, IntLessEqual.class);
5389  private static NISuppressor arg2_le_arg1 =
5390      new NISuppressor(1, 2, IntLessEqual.class);
5391
5392  private static NISuppressor result_track0_arg1 =
5393      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
5394  private static NISuppressor result_track0_arg2 =
5395      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
5396  private static NISuppressor arg1_track0_arg2 =
5397      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
5398  private static NISuppressor arg1_track0_result =
5399      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
5400  private static NISuppressor arg2_track0_result =
5401      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
5402  private static NISuppressor arg2_track0_arg1 =
5403      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
5404
5405  private static NISuppressor result_eq_1 =
5406      new NISuppressor(0, RangeInt.EqualOne.class);
5407  private static NISuppressor arg1_eq_1 =
5408      new NISuppressor(2, RangeInt.EqualOne.class);
5409  private static NISuppressor arg2_eq_1 =
5410      new NISuppressor(1, RangeInt.EqualOne.class);
5411
5412  private static NISuppressor result_eq_0 =
5413      new NISuppressor(0, RangeInt.EqualZero.class);
5414  private static NISuppressor arg1_eq_0 =
5415      new NISuppressor(2, RangeInt.EqualZero.class);
5416  private static NISuppressor arg2_eq_0 =
5417      new NISuppressor(1, RangeInt.EqualZero.class);
5418
5419  private static NISuppressor result_ne_0 =
5420      new NISuppressor(0, NonZero.class);
5421  private static NISuppressor arg1_ne_0 =
5422      new NISuppressor(2, NonZero.class);
5423  private static NISuppressor arg2_ne_0 =
5424      new NISuppressor(1, NonZero.class);
5425
5426  private static NISuppressor result_ge_0 =
5427      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
5428  private static NISuppressor arg1_ge_0 =
5429      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
5430  private static NISuppressor arg2_ge_0 =
5431      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
5432
5433  private static NISuppressor result_ge_64 =
5434      new NISuppressor(0, RangeInt.GreaterEqual64.class);
5435  private static NISuppressor arg1_ge_64 =
5436      new NISuppressor(2, RangeInt.GreaterEqual64.class);
5437  private static NISuppressor arg2_ge_64 =
5438      new NISuppressor(1, RangeInt.GreaterEqual64.class);
5439
5440  private static NISuppressor result_boolean =
5441      new NISuppressor(0, RangeInt.BooleanVal.class);
5442  private static NISuppressor arg1_boolean =
5443      new NISuppressor(2, RangeInt.BooleanVal.class);
5444  private static NISuppressor arg2_boolean =
5445      new NISuppressor(1, RangeInt.BooleanVal.class);
5446
5447  private static NISuppressor result_even =
5448      new NISuppressor(0, RangeInt.Even.class);
5449  private static NISuppressor arg1_even =
5450      new NISuppressor(2, RangeInt.Even.class);
5451  private static NISuppressor arg2_even =
5452      new NISuppressor(1, RangeInt.Even.class);
5453
5454  private static NISuppressor result_power2 =
5455      new NISuppressor(0, RangeInt.PowerOfTwo.class);
5456  private static NISuppressor arg1_power2 =
5457      new NISuppressor(2, RangeInt.PowerOfTwo.class);
5458  private static NISuppressor arg2_power2 =
5459      new NISuppressor(1, RangeInt.PowerOfTwo.class);
5460
5461  private static NISuppressor result_and0_arg1 =
5462      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
5463  private static NISuppressor result_and0_arg2 =
5464      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
5465  private static NISuppressor arg1_and0_arg2 =
5466      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
5467
5468  // The arguments to bitwise subset are backwards from what one
5469  // might expect.  The second argument is a subset of the first
5470  // argument
5471  private static NISuppressor arg1_bw_subset_arg2 =
5472      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
5473  private static NISuppressor arg2_bw_subset_arg1 =
5474      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
5475
5476  private static NISuppressor result_shift0_arg1 =
5477      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
5478  private static NISuppressor result_shift0_arg2 =
5479      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
5480  private static NISuppressor arg1_shift0_arg2 =
5481      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
5482
5483  private static NISuppressor arg2_divides_arg1 =
5484      new NISuppressor(2, 1, NumericInt.Divides.class);
5485  private static NISuppressor arg1_divides_arg2 =
5486      new NISuppressor(1, 2, NumericInt.Divides.class);
5487
5488  private static NISuppressor arg2_valid_shift =
5489      new NISuppressor(1, RangeInt.Bound0_63.class);
5490
5491    // Note that any suppression that doesn't limit y to valid exponents
5492    // (>= 0), must check for valid exponents as well (so that the invariant
5493    // is correctly destroyed on invalid exponents)
5494    //
5495    // Note also that pow(0,0) == 1 and pow(0,x), where (x > 0), == 0
5496    // Another interesting artificat of pow is that for any even base, any
5497    // exponent >= 64 will yield a result of 0.  For example, pow(10,256) == 0
5498    // (at least for integers)
5499
5500    private static NISuppressionSet suppressions =
5501      new NISuppressionSet(
5502          new NISuppression[] {
5503
5504            // (r == 1) && (y == 0) ==> r = pow (z, y)
5505            new NISuppression(result_eq_1, arg2_eq_0, suppressee),
5506
5507            // (r == 1) && (z == 1) && (y >= 0)   ==> r = pow (z, y)
5508            new NISuppression(result_eq_1, arg1_eq_1, arg2_ge_0, suppressee),
5509
5510            // (r == 0) && (z == 0) && (y > 0)
5511            new NISuppression(result_eq_0, arg1_eq_0, arg2_ne_0, arg2_ge_0,
5512                              suppressee),
5513
5514            // (r == z) && (y == 1)    ==> r = pow (z, y)
5515            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
5516
5517            // (r == 0) && (z even) && (y >= 64)
5518            // with each multiply there is one more zero in the result and since
5519            // a long has 64 bits in it, it becomes zero at that point
5520            new NISuppression(result_eq_0, arg1_even, arg2_ge_64, suppressee),
5521
5522            // (r == 1) && (z boolean) && (z==0 <==> y==0) && (y >= 0)
5523            // 1 = pow (0, y) true iff (y == 0)
5524            // 1 = pow (1, y) true when y valid exponent
5525            new NISuppression(arg1_track0_arg2, arg2_ge_0, arg1_boolean,
5526                               result_eq_1, suppressee),
5527
5528            // (r == z) && (r boolean) && (y > 0)
5529            // 0 = pow (0, y) true when y != 0
5530            // 1 = pow (1, y) true when y valid exponent
5531            new NISuppression(result_eq_arg1, result_boolean, arg2_ne_0,
5532                               arg2_ge_0, suppressee),
5533
5534          });
5535
5536  // Create a suppression factory for functionBinary
5537
5538}
5539
5540/**
5541 * Represents the invariant {@code y = Power(z, x)} over three long
5542 * scalars. 
5543 */
5544public static class PowerLong_yzx extends FunctionBinary {
5545  // We are Serializable, so we specify a version to allow changes to
5546  // method signatures without breaking serialization.  If you add or
5547  // remove fields, you should change this number to the current date.
5548  static final long serialVersionUID = 20031030L;
5549
5550  private static @Prototype PowerLong_yzx proto = new @Prototype PowerLong_yzx ();
5551
5552  /** Returns the prototype invariant for PowerLong_yzx */
5553  public static @Prototype PowerLong_yzx get_proto() {
5554    return proto;
5555  }
5556
5557  /** instantiate an invariant on the specified slice */
5558  @Override
5559  protected PowerLong_yzx instantiate_dyn(@Prototype PowerLong_yzx this, PptSlice slice) {
5560    return new PowerLong_yzx (slice);
5561  }
5562
5563  private PowerLong_yzx (PptSlice slice) {
5564    super(slice);
5565  }
5566
5567  public @Prototype PowerLong_yzx () {
5568    super();
5569  }
5570
5571  private static String[] method_name = new String[] {"java.lang.Math.pow(", ", ", ")"};
5572
5573  @Override
5574  public String[] get_method_name(@GuardSatisfied PowerLong_yzx this) {
5575    return method_name;
5576  }
5577
5578  private static int function_id = -1;
5579
5580  @Override
5581  public int get_function_id() {
5582    return function_id;
5583  }
5584
5585  @Override
5586  public void set_function_id(int function_id) {
5587    assert PowerLong_yzx.function_id == -1;
5588    PowerLong_yzx.function_id = function_id;
5589  }
5590
5591  private static int var_order = 5;
5592
5593  @Override
5594  public int get_var_order(@GuardSatisfied PowerLong_yzx this) {
5595    return var_order;
5596  }
5597
5598  @Pure
5599  @Override
5600  public boolean is_symmetric() {
5601
5602      return false;
5603  }
5604
5605  @Override
5606
5607  public long func(long z, long x) {
5608
5609    return MathPlume.pow(z, x);
5610  }
5611
5612  @Override
5613  public InvariantStatus check_modified(long x, long y,
5614                                      long z, int count) {
5615    return check_ordered(y, z, x, count);
5616  }
5617
5618  @Override
5619  public InvariantStatus add_modified(long x, long y,
5620                                      long z, int count) {
5621    if (Debug.logDetail()) {
5622      log("result=%s, arg1=%s, arg2=%s", y, z, x);
5623    }
5624    return add_ordered(y, z, x, count);
5625  }
5626
5627  @Pure
5628  @Override
5629  public boolean isPower() {
5630    return true;
5631  }
5632
5633  @Pure
5634  @Override
5635  public boolean isExact() {
5636    return true;
5637  }
5638
5639  /** Returns a list of non-instantiating suppressions for this invariant. */
5640  @Pure
5641  @Override
5642  public @Nullable NISuppressionSet get_ni_suppressions() {
5643    if (NIS.dkconfig_enabled && dkconfig_enabled) {
5644      return suppressions;
5645    } else {
5646      return null;
5647    }
5648  }
5649
5650  /** definition of this invariant (the suppressee) */
5651  private static NISuppressee suppressee = new NISuppressee(PowerLong_yzx.class, 3);
5652
5653  // suppressor definitions (used below)
5654  private static NISuppressor result_eq_arg1 =
5655      new NISuppressor(1, 2, IntEqual.class);
5656  private static NISuppressor result_eq_arg2 =
5657      new NISuppressor(1, 0, IntEqual.class);
5658  private static NISuppressor arg1_eq_arg2 =
5659      new NISuppressor(2, 0, IntEqual.class);
5660
5661  private static NISuppressor result_lt_arg1 =
5662      new NISuppressor(1, 2, IntLessThan.class);
5663  private static NISuppressor result_lt_arg2 =
5664      new NISuppressor(1, 0, IntLessThan.class);
5665  private static NISuppressor arg1_lt_arg2 =
5666      new NISuppressor(2, 0, IntLessThan.class);
5667  private static NISuppressor arg2_lt_arg1 =
5668      new NISuppressor(0, 2, IntLessThan.class);
5669
5670  private static NISuppressor result_le_arg1 =
5671      new NISuppressor(1, 2, IntLessEqual.class);
5672  private static NISuppressor result_le_arg2 =
5673      new NISuppressor(1, 0, IntLessEqual.class);
5674  private static NISuppressor arg1_le_arg2 =
5675      new NISuppressor(2, 0, IntLessEqual.class);
5676  private static NISuppressor arg2_le_arg1 =
5677      new NISuppressor(0, 2, IntLessEqual.class);
5678
5679  private static NISuppressor result_track0_arg1 =
5680      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
5681  private static NISuppressor result_track0_arg2 =
5682      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
5683  private static NISuppressor arg1_track0_arg2 =
5684      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
5685  private static NISuppressor arg1_track0_result =
5686      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
5687  private static NISuppressor arg2_track0_result =
5688      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
5689  private static NISuppressor arg2_track0_arg1 =
5690      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
5691
5692  private static NISuppressor result_eq_1 =
5693      new NISuppressor(1, RangeInt.EqualOne.class);
5694  private static NISuppressor arg1_eq_1 =
5695      new NISuppressor(2, RangeInt.EqualOne.class);
5696  private static NISuppressor arg2_eq_1 =
5697      new NISuppressor(0, RangeInt.EqualOne.class);
5698
5699  private static NISuppressor result_eq_0 =
5700      new NISuppressor(1, RangeInt.EqualZero.class);
5701  private static NISuppressor arg1_eq_0 =
5702      new NISuppressor(2, RangeInt.EqualZero.class);
5703  private static NISuppressor arg2_eq_0 =
5704      new NISuppressor(0, RangeInt.EqualZero.class);
5705
5706  private static NISuppressor result_ne_0 =
5707      new NISuppressor(1, NonZero.class);
5708  private static NISuppressor arg1_ne_0 =
5709      new NISuppressor(2, NonZero.class);
5710  private static NISuppressor arg2_ne_0 =
5711      new NISuppressor(0, NonZero.class);
5712
5713  private static NISuppressor result_ge_0 =
5714      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
5715  private static NISuppressor arg1_ge_0 =
5716      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
5717  private static NISuppressor arg2_ge_0 =
5718      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
5719
5720  private static NISuppressor result_ge_64 =
5721      new NISuppressor(1, RangeInt.GreaterEqual64.class);
5722  private static NISuppressor arg1_ge_64 =
5723      new NISuppressor(2, RangeInt.GreaterEqual64.class);
5724  private static NISuppressor arg2_ge_64 =
5725      new NISuppressor(0, RangeInt.GreaterEqual64.class);
5726
5727  private static NISuppressor result_boolean =
5728      new NISuppressor(1, RangeInt.BooleanVal.class);
5729  private static NISuppressor arg1_boolean =
5730      new NISuppressor(2, RangeInt.BooleanVal.class);
5731  private static NISuppressor arg2_boolean =
5732      new NISuppressor(0, RangeInt.BooleanVal.class);
5733
5734  private static NISuppressor result_even =
5735      new NISuppressor(1, RangeInt.Even.class);
5736  private static NISuppressor arg1_even =
5737      new NISuppressor(2, RangeInt.Even.class);
5738  private static NISuppressor arg2_even =
5739      new NISuppressor(0, RangeInt.Even.class);
5740
5741  private static NISuppressor result_power2 =
5742      new NISuppressor(1, RangeInt.PowerOfTwo.class);
5743  private static NISuppressor arg1_power2 =
5744      new NISuppressor(2, RangeInt.PowerOfTwo.class);
5745  private static NISuppressor arg2_power2 =
5746      new NISuppressor(0, RangeInt.PowerOfTwo.class);
5747
5748  private static NISuppressor result_and0_arg1 =
5749      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
5750  private static NISuppressor result_and0_arg2 =
5751      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
5752  private static NISuppressor arg1_and0_arg2 =
5753      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
5754
5755  // The arguments to bitwise subset are backwards from what one
5756  // might expect.  The second argument is a subset of the first
5757  // argument
5758  private static NISuppressor arg1_bw_subset_arg2 =
5759      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
5760  private static NISuppressor arg2_bw_subset_arg1 =
5761      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
5762
5763  private static NISuppressor result_shift0_arg1 =
5764      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
5765  private static NISuppressor result_shift0_arg2 =
5766      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
5767  private static NISuppressor arg1_shift0_arg2 =
5768      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
5769
5770  private static NISuppressor arg2_divides_arg1 =
5771      new NISuppressor(2, 0, NumericInt.Divides.class);
5772  private static NISuppressor arg1_divides_arg2 =
5773      new NISuppressor(0, 2, NumericInt.Divides.class);
5774
5775  private static NISuppressor arg2_valid_shift =
5776      new NISuppressor(0, RangeInt.Bound0_63.class);
5777
5778    // Note that any suppression that doesn't limit x to valid exponents
5779    // (>= 0), must check for valid exponents as well (so that the invariant
5780    // is correctly destroyed on invalid exponents)
5781    //
5782    // Note also that pow(0,0) == 1 and pow(0,x), where (x > 0), == 0
5783    // Another interesting artificat of pow is that for any even base, any
5784    // exponent >= 64 will yield a result of 0.  For example, pow(10,256) == 0
5785    // (at least for integers)
5786
5787    private static NISuppressionSet suppressions =
5788      new NISuppressionSet(
5789          new NISuppression[] {
5790
5791            // (r == 1) && (x == 0) ==> r = pow (z, x)
5792            new NISuppression(result_eq_1, arg2_eq_0, suppressee),
5793
5794            // (r == 1) && (z == 1) && (x >= 0)   ==> r = pow (z, x)
5795            new NISuppression(result_eq_1, arg1_eq_1, arg2_ge_0, suppressee),
5796
5797            // (r == 0) && (z == 0) && (x > 0)
5798            new NISuppression(result_eq_0, arg1_eq_0, arg2_ne_0, arg2_ge_0,
5799                              suppressee),
5800
5801            // (r == z) && (x == 1)    ==> r = pow (z, x)
5802            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
5803
5804            // (r == 0) && (z even) && (x >= 64)
5805            // with each multiply there is one more zero in the result and since
5806            // a long has 64 bits in it, it becomes zero at that point
5807            new NISuppression(result_eq_0, arg1_even, arg2_ge_64, suppressee),
5808
5809            // (r == 1) && (z boolean) && (z==0 <==> x==0) && (x >= 0)
5810            // 1 = pow (0, x) true iff (x == 0)
5811            // 1 = pow (1, x) true when x valid exponent
5812            new NISuppression(arg1_track0_arg2, arg2_ge_0, arg1_boolean,
5813                               result_eq_1, suppressee),
5814
5815            // (r == z) && (r boolean) && (x > 0)
5816            // 0 = pow (0, x) true when x != 0
5817            // 1 = pow (1, x) true when x valid exponent
5818            new NISuppression(result_eq_arg1, result_boolean, arg2_ne_0,
5819                               arg2_ge_0, suppressee),
5820
5821          });
5822
5823  // Create a suppression factory for functionBinary
5824
5825}
5826
5827/**
5828 * Represents the invariant {@code z = Power(y, x)} over three long
5829 * scalars. 
5830 */
5831public static class PowerLong_zyx extends FunctionBinary {
5832  // We are Serializable, so we specify a version to allow changes to
5833  // method signatures without breaking serialization.  If you add or
5834  // remove fields, you should change this number to the current date.
5835  static final long serialVersionUID = 20031030L;
5836
5837  private static @Prototype PowerLong_zyx proto = new @Prototype PowerLong_zyx ();
5838
5839  /** Returns the prototype invariant for PowerLong_zyx */
5840  public static @Prototype PowerLong_zyx get_proto() {
5841    return proto;
5842  }
5843
5844  /** instantiate an invariant on the specified slice */
5845  @Override
5846  protected PowerLong_zyx instantiate_dyn(@Prototype PowerLong_zyx this, PptSlice slice) {
5847    return new PowerLong_zyx (slice);
5848  }
5849
5850  private PowerLong_zyx (PptSlice slice) {
5851    super(slice);
5852  }
5853
5854  public @Prototype PowerLong_zyx () {
5855    super();
5856  }
5857
5858  private static String[] method_name = new String[] {"java.lang.Math.pow(", ", ", ")"};
5859
5860  @Override
5861  public String[] get_method_name(@GuardSatisfied PowerLong_zyx this) {
5862    return method_name;
5863  }
5864
5865  private static int function_id = -1;
5866
5867  @Override
5868  public int get_function_id() {
5869    return function_id;
5870  }
5871
5872  @Override
5873  public void set_function_id(int function_id) {
5874    assert PowerLong_zyx.function_id == -1;
5875    PowerLong_zyx.function_id = function_id;
5876  }
5877
5878  private static int var_order = 6;
5879
5880  @Override
5881  public int get_var_order(@GuardSatisfied PowerLong_zyx this) {
5882    return var_order;
5883  }
5884
5885  @Pure
5886  @Override
5887  public boolean is_symmetric() {
5888
5889      return false;
5890  }
5891
5892  @Override
5893
5894  public long func(long y, long x) {
5895
5896    return MathPlume.pow(y, x);
5897  }
5898
5899  @Override
5900  public InvariantStatus check_modified(long x, long y,
5901                                      long z, int count) {
5902    return check_ordered(z, y, x, count);
5903  }
5904
5905  @Override
5906  public InvariantStatus add_modified(long x, long y,
5907                                      long z, int count) {
5908    if (Debug.logDetail()) {
5909      log("result=%s, arg1=%s, arg2=%s", z, y, x);
5910    }
5911    return add_ordered(z, y, x, count);
5912  }
5913
5914  @Pure
5915  @Override
5916  public boolean isPower() {
5917    return true;
5918  }
5919
5920  @Pure
5921  @Override
5922  public boolean isExact() {
5923    return true;
5924  }
5925
5926  /** Returns a list of non-instantiating suppressions for this invariant. */
5927  @Pure
5928  @Override
5929  public @Nullable NISuppressionSet get_ni_suppressions() {
5930    if (NIS.dkconfig_enabled && dkconfig_enabled) {
5931      return suppressions;
5932    } else {
5933      return null;
5934    }
5935  }
5936
5937  /** definition of this invariant (the suppressee) */
5938  private static NISuppressee suppressee = new NISuppressee(PowerLong_zyx.class, 3);
5939
5940  // suppressor definitions (used below)
5941  private static NISuppressor result_eq_arg1 =
5942      new NISuppressor(2, 1, IntEqual.class);
5943  private static NISuppressor result_eq_arg2 =
5944      new NISuppressor(2, 0, IntEqual.class);
5945  private static NISuppressor arg1_eq_arg2 =
5946      new NISuppressor(1, 0, IntEqual.class);
5947
5948  private static NISuppressor result_lt_arg1 =
5949      new NISuppressor(2, 1, IntLessThan.class);
5950  private static NISuppressor result_lt_arg2 =
5951      new NISuppressor(2, 0, IntLessThan.class);
5952  private static NISuppressor arg1_lt_arg2 =
5953      new NISuppressor(1, 0, IntLessThan.class);
5954  private static NISuppressor arg2_lt_arg1 =
5955      new NISuppressor(0, 1, IntLessThan.class);
5956
5957  private static NISuppressor result_le_arg1 =
5958      new NISuppressor(2, 1, IntLessEqual.class);
5959  private static NISuppressor result_le_arg2 =
5960      new NISuppressor(2, 0, IntLessEqual.class);
5961  private static NISuppressor arg1_le_arg2 =
5962      new NISuppressor(1, 0, IntLessEqual.class);
5963  private static NISuppressor arg2_le_arg1 =
5964      new NISuppressor(0, 1, IntLessEqual.class);
5965
5966  private static NISuppressor result_track0_arg1 =
5967      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
5968  private static NISuppressor result_track0_arg2 =
5969      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
5970  private static NISuppressor arg1_track0_arg2 =
5971      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
5972  private static NISuppressor arg1_track0_result =
5973      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
5974  private static NISuppressor arg2_track0_result =
5975      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
5976  private static NISuppressor arg2_track0_arg1 =
5977      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
5978
5979  private static NISuppressor result_eq_1 =
5980      new NISuppressor(2, RangeInt.EqualOne.class);
5981  private static NISuppressor arg1_eq_1 =
5982      new NISuppressor(1, RangeInt.EqualOne.class);
5983  private static NISuppressor arg2_eq_1 =
5984      new NISuppressor(0, RangeInt.EqualOne.class);
5985
5986  private static NISuppressor result_eq_0 =
5987      new NISuppressor(2, RangeInt.EqualZero.class);
5988  private static NISuppressor arg1_eq_0 =
5989      new NISuppressor(1, RangeInt.EqualZero.class);
5990  private static NISuppressor arg2_eq_0 =
5991      new NISuppressor(0, RangeInt.EqualZero.class);
5992
5993  private static NISuppressor result_ne_0 =
5994      new NISuppressor(2, NonZero.class);
5995  private static NISuppressor arg1_ne_0 =
5996      new NISuppressor(1, NonZero.class);
5997  private static NISuppressor arg2_ne_0 =
5998      new NISuppressor(0, NonZero.class);
5999
6000  private static NISuppressor result_ge_0 =
6001      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
6002  private static NISuppressor arg1_ge_0 =
6003      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
6004  private static NISuppressor arg2_ge_0 =
6005      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
6006
6007  private static NISuppressor result_ge_64 =
6008      new NISuppressor(2, RangeInt.GreaterEqual64.class);
6009  private static NISuppressor arg1_ge_64 =
6010      new NISuppressor(1, RangeInt.GreaterEqual64.class);
6011  private static NISuppressor arg2_ge_64 =
6012      new NISuppressor(0, RangeInt.GreaterEqual64.class);
6013
6014  private static NISuppressor result_boolean =
6015      new NISuppressor(2, RangeInt.BooleanVal.class);
6016  private static NISuppressor arg1_boolean =
6017      new NISuppressor(1, RangeInt.BooleanVal.class);
6018  private static NISuppressor arg2_boolean =
6019      new NISuppressor(0, RangeInt.BooleanVal.class);
6020
6021  private static NISuppressor result_even =
6022      new NISuppressor(2, RangeInt.Even.class);
6023  private static NISuppressor arg1_even =
6024      new NISuppressor(1, RangeInt.Even.class);
6025  private static NISuppressor arg2_even =
6026      new NISuppressor(0, RangeInt.Even.class);
6027
6028  private static NISuppressor result_power2 =
6029      new NISuppressor(2, RangeInt.PowerOfTwo.class);
6030  private static NISuppressor arg1_power2 =
6031      new NISuppressor(1, RangeInt.PowerOfTwo.class);
6032  private static NISuppressor arg2_power2 =
6033      new NISuppressor(0, RangeInt.PowerOfTwo.class);
6034
6035  private static NISuppressor result_and0_arg1 =
6036      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
6037  private static NISuppressor result_and0_arg2 =
6038      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
6039  private static NISuppressor arg1_and0_arg2 =
6040      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
6041
6042  // The arguments to bitwise subset are backwards from what one
6043  // might expect.  The second argument is a subset of the first
6044  // argument
6045  private static NISuppressor arg1_bw_subset_arg2 =
6046      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
6047  private static NISuppressor arg2_bw_subset_arg1 =
6048      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
6049
6050  private static NISuppressor result_shift0_arg1 =
6051      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
6052  private static NISuppressor result_shift0_arg2 =
6053      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
6054  private static NISuppressor arg1_shift0_arg2 =
6055      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
6056
6057  private static NISuppressor arg2_divides_arg1 =
6058      new NISuppressor(1, 0, NumericInt.Divides.class);
6059  private static NISuppressor arg1_divides_arg2 =
6060      new NISuppressor(0, 1, NumericInt.Divides.class);
6061
6062  private static NISuppressor arg2_valid_shift =
6063      new NISuppressor(0, RangeInt.Bound0_63.class);
6064
6065    // Note that any suppression that doesn't limit x to valid exponents
6066    // (>= 0), must check for valid exponents as well (so that the invariant
6067    // is correctly destroyed on invalid exponents)
6068    //
6069    // Note also that pow(0,0) == 1 and pow(0,x), where (x > 0), == 0
6070    // Another interesting artificat of pow is that for any even base, any
6071    // exponent >= 64 will yield a result of 0.  For example, pow(10,256) == 0
6072    // (at least for integers)
6073
6074    private static NISuppressionSet suppressions =
6075      new NISuppressionSet(
6076          new NISuppression[] {
6077
6078            // (r == 1) && (x == 0) ==> r = pow (y, x)
6079            new NISuppression(result_eq_1, arg2_eq_0, suppressee),
6080
6081            // (r == 1) && (y == 1) && (x >= 0)   ==> r = pow (y, x)
6082            new NISuppression(result_eq_1, arg1_eq_1, arg2_ge_0, suppressee),
6083
6084            // (r == 0) && (y == 0) && (x > 0)
6085            new NISuppression(result_eq_0, arg1_eq_0, arg2_ne_0, arg2_ge_0,
6086                              suppressee),
6087
6088            // (r == y) && (x == 1)    ==> r = pow (y, x)
6089            new NISuppression(result_eq_arg1, arg2_eq_1, suppressee),
6090
6091            // (r == 0) && (y even) && (x >= 64)
6092            // with each multiply there is one more zero in the result and since
6093            // a long has 64 bits in it, it becomes zero at that point
6094            new NISuppression(result_eq_0, arg1_even, arg2_ge_64, suppressee),
6095
6096            // (r == 1) && (y boolean) && (y==0 <==> x==0) && (x >= 0)
6097            // 1 = pow (0, x) true iff (x == 0)
6098            // 1 = pow (1, x) true when x valid exponent
6099            new NISuppression(arg1_track0_arg2, arg2_ge_0, arg1_boolean,
6100                               result_eq_1, suppressee),
6101
6102            // (r == y) && (r boolean) && (x > 0)
6103            // 0 = pow (0, x) true when x != 0
6104            // 1 = pow (1, x) true when x valid exponent
6105            new NISuppression(result_eq_arg1, result_boolean, arg2_ne_0,
6106                               arg2_ge_0, suppressee),
6107
6108          });
6109
6110  // Create a suppression factory for functionBinary
6111
6112}
6113
6114  // #define EQUALITY_SUPPRESS 1
6115
6116  // default is that it is not this function, overriden in the subclass
6117  @Pure
6118  public boolean isBitwiseAnd() {
6119    return false;
6120  }
6121
6122/**
6123 * Represents the invariant {@code x = BitwiseAnd(y, z)} over three long
6124 * scalars. 
6125 */
6126public static class BitwiseAndLong_xyz extends FunctionBinary {
6127  // We are Serializable, so we specify a version to allow changes to
6128  // method signatures without breaking serialization.  If you add or
6129  // remove fields, you should change this number to the current date.
6130  static final long serialVersionUID = 20031030L;
6131
6132  private static @Prototype BitwiseAndLong_xyz proto = new @Prototype BitwiseAndLong_xyz ();
6133
6134  /** Returns the prototype invariant for BitwiseAndLong_xyz */
6135  public static @Prototype BitwiseAndLong_xyz get_proto() {
6136    return proto;
6137  }
6138
6139  /** instantiate an invariant on the specified slice */
6140  @Override
6141  protected BitwiseAndLong_xyz instantiate_dyn(@Prototype BitwiseAndLong_xyz this, PptSlice slice) {
6142    return new BitwiseAndLong_xyz (slice);
6143  }
6144
6145  private BitwiseAndLong_xyz (PptSlice slice) {
6146    super(slice);
6147  }
6148
6149  public @Prototype BitwiseAndLong_xyz () {
6150    super();
6151  }
6152
6153  private static String[] method_name = new String[] {"", " & ", ""};
6154
6155  @Override
6156  public String[] get_method_name(@GuardSatisfied BitwiseAndLong_xyz this) {
6157    return method_name;
6158  }
6159
6160  private static int function_id = -1;
6161
6162  @Override
6163  public int get_function_id() {
6164    return function_id;
6165  }
6166
6167  @Override
6168  public void set_function_id(int function_id) {
6169    assert BitwiseAndLong_xyz.function_id == -1;
6170    BitwiseAndLong_xyz.function_id = function_id;
6171  }
6172
6173  private static int var_order = 1;
6174
6175  @Override
6176  public int get_var_order(@GuardSatisfied BitwiseAndLong_xyz this) {
6177    return var_order;
6178  }
6179
6180  @Pure
6181  @Override
6182  public boolean is_symmetric() {
6183
6184      return true;
6185  }
6186
6187  @Override
6188
6189  public long func(long y, long z) {
6190
6191    return (y & z);
6192  }
6193
6194  @Override
6195  public InvariantStatus check_modified(long x, long y,
6196                                      long z, int count) {
6197    return check_ordered(x, y, z, count);
6198  }
6199
6200  @Override
6201  public InvariantStatus add_modified(long x, long y,
6202                                      long z, int count) {
6203    if (Debug.logDetail()) {
6204      log("result=%s, arg1=%s, arg2=%s", x, y, z);
6205    }
6206    return add_ordered(x, y, z, count);
6207  }
6208
6209  @Pure
6210  @Override
6211  public boolean isBitwiseAnd() {
6212    return true;
6213  }
6214
6215  @Pure
6216  @Override
6217  public boolean isExact() {
6218    return true;
6219  }
6220
6221  /** Returns a list of non-instantiating suppressions for this invariant. */
6222  @Pure
6223  @Override
6224  public @Nullable NISuppressionSet get_ni_suppressions() {
6225    if (NIS.dkconfig_enabled && dkconfig_enabled) {
6226      return suppressions;
6227    } else {
6228      return null;
6229    }
6230  }
6231
6232  /** definition of this invariant (the suppressee) */
6233  private static NISuppressee suppressee = new NISuppressee(BitwiseAndLong_xyz.class, 3);
6234
6235  // suppressor definitions (used below)
6236  private static NISuppressor result_eq_arg1 =
6237      new NISuppressor(0, 1, IntEqual.class);
6238  private static NISuppressor result_eq_arg2 =
6239      new NISuppressor(0, 2, IntEqual.class);
6240  private static NISuppressor arg1_eq_arg2 =
6241      new NISuppressor(1, 2, IntEqual.class);
6242
6243  private static NISuppressor result_lt_arg1 =
6244      new NISuppressor(0, 1, IntLessThan.class);
6245  private static NISuppressor result_lt_arg2 =
6246      new NISuppressor(0, 2, IntLessThan.class);
6247  private static NISuppressor arg1_lt_arg2 =
6248      new NISuppressor(1, 2, IntLessThan.class);
6249  private static NISuppressor arg2_lt_arg1 =
6250      new NISuppressor(2, 1, IntLessThan.class);
6251
6252  private static NISuppressor result_le_arg1 =
6253      new NISuppressor(0, 1, IntLessEqual.class);
6254  private static NISuppressor result_le_arg2 =
6255      new NISuppressor(0, 2, IntLessEqual.class);
6256  private static NISuppressor arg1_le_arg2 =
6257      new NISuppressor(1, 2, IntLessEqual.class);
6258  private static NISuppressor arg2_le_arg1 =
6259      new NISuppressor(2, 1, IntLessEqual.class);
6260
6261  private static NISuppressor result_track0_arg1 =
6262      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
6263  private static NISuppressor result_track0_arg2 =
6264      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
6265  private static NISuppressor arg1_track0_arg2 =
6266      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
6267  private static NISuppressor arg1_track0_result =
6268      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
6269  private static NISuppressor arg2_track0_result =
6270      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
6271  private static NISuppressor arg2_track0_arg1 =
6272      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
6273
6274  private static NISuppressor result_eq_1 =
6275      new NISuppressor(0, RangeInt.EqualOne.class);
6276  private static NISuppressor arg1_eq_1 =
6277      new NISuppressor(1, RangeInt.EqualOne.class);
6278  private static NISuppressor arg2_eq_1 =
6279      new NISuppressor(2, RangeInt.EqualOne.class);
6280
6281  private static NISuppressor result_eq_0 =
6282      new NISuppressor(0, RangeInt.EqualZero.class);
6283  private static NISuppressor arg1_eq_0 =
6284      new NISuppressor(1, RangeInt.EqualZero.class);
6285  private static NISuppressor arg2_eq_0 =
6286      new NISuppressor(2, RangeInt.EqualZero.class);
6287
6288  private static NISuppressor result_ne_0 =
6289      new NISuppressor(0, NonZero.class);
6290  private static NISuppressor arg1_ne_0 =
6291      new NISuppressor(1, NonZero.class);
6292  private static NISuppressor arg2_ne_0 =
6293      new NISuppressor(2, NonZero.class);
6294
6295  private static NISuppressor result_ge_0 =
6296      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
6297  private static NISuppressor arg1_ge_0 =
6298      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
6299  private static NISuppressor arg2_ge_0 =
6300      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
6301
6302  private static NISuppressor result_ge_64 =
6303      new NISuppressor(0, RangeInt.GreaterEqual64.class);
6304  private static NISuppressor arg1_ge_64 =
6305      new NISuppressor(1, RangeInt.GreaterEqual64.class);
6306  private static NISuppressor arg2_ge_64 =
6307      new NISuppressor(2, RangeInt.GreaterEqual64.class);
6308
6309  private static NISuppressor result_boolean =
6310      new NISuppressor(0, RangeInt.BooleanVal.class);
6311  private static NISuppressor arg1_boolean =
6312      new NISuppressor(1, RangeInt.BooleanVal.class);
6313  private static NISuppressor arg2_boolean =
6314      new NISuppressor(2, RangeInt.BooleanVal.class);
6315
6316  private static NISuppressor result_even =
6317      new NISuppressor(0, RangeInt.Even.class);
6318  private static NISuppressor arg1_even =
6319      new NISuppressor(1, RangeInt.Even.class);
6320  private static NISuppressor arg2_even =
6321      new NISuppressor(2, RangeInt.Even.class);
6322
6323  private static NISuppressor result_power2 =
6324      new NISuppressor(0, RangeInt.PowerOfTwo.class);
6325  private static NISuppressor arg1_power2 =
6326      new NISuppressor(1, RangeInt.PowerOfTwo.class);
6327  private static NISuppressor arg2_power2 =
6328      new NISuppressor(2, RangeInt.PowerOfTwo.class);
6329
6330  private static NISuppressor result_and0_arg1 =
6331      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
6332  private static NISuppressor result_and0_arg2 =
6333      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
6334  private static NISuppressor arg1_and0_arg2 =
6335      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
6336
6337  // The arguments to bitwise subset are backwards from what one
6338  // might expect.  The second argument is a subset of the first
6339  // argument
6340  private static NISuppressor arg1_bw_subset_arg2 =
6341      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
6342  private static NISuppressor arg2_bw_subset_arg1 =
6343      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
6344
6345  private static NISuppressor result_shift0_arg1 =
6346      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
6347  private static NISuppressor result_shift0_arg2 =
6348      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
6349  private static NISuppressor arg1_shift0_arg2 =
6350      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
6351
6352  private static NISuppressor arg2_divides_arg1 =
6353      new NISuppressor(1, 2, NumericInt.Divides.class);
6354  private static NISuppressor arg1_divides_arg2 =
6355      new NISuppressor(2, 1, NumericInt.Divides.class);
6356
6357  private static NISuppressor arg2_valid_shift =
6358      new NISuppressor(2, RangeInt.Bound0_63.class);
6359
6360    private static NISuppressionSet suppressions =
6361        new NISuppressionSet(
6362          new NISuppression[] {
6363
6364            // (r == y) && (y == z) && (r == z) ==> r = y &  z
6365            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
6366                               suppressee),
6367
6368            // (r == y) && (y bitwise subset z)
6369            new NISuppression(result_eq_arg1, arg1_bw_subset_arg2, suppressee),
6370
6371            // (r == z) && (z bitwise subset y)
6372            new NISuppression(result_eq_arg2, arg2_bw_subset_arg1, suppressee),
6373
6374            // (r == 0) && (y & z == 0) ==> r = y & z
6375            new NISuppression(result_eq_0, arg1_and0_arg2, suppressee),
6376
6377            // All of these are subsummed by the prior one
6378            // (r == 0) && (y == 0) ==> r = y & z
6379            // new NISuppression (result_eq_0, arg1_eq_0, suppressee),
6380
6381            // (r == 0) && (z == 0) ==> r = y & z
6382            // new NISuppression (result_eq_0, arg2_eq_0, suppressee),
6383
6384            // (r == 0) && (y boolean) && (z is even)
6385            // new NISuppression (result_eq_0, arg1_boolean, arg2_even, suppressee),
6386
6387            // (r == 0) && (z boolean) && (y is even)
6388            // new NISuppression (result_eq_0, arg2_boolean, arg1_even, suppressee),
6389
6390            // (r == 0) && (z > y) && (z power2) && (y >= 0)
6391            // new NISuppression (result_eq_0, arg1_lt_arg2, arg2_power2, arg1_ge_0,
6392            //                   suppressee),
6393
6394            // (r == 0) && (y > z) && (y power2) && (z >= 0)
6395            // new NISuppression (result_eq_0, arg2_lt_arg1, arg1_power2, arg2_ge_0,
6396            //                   suppressee),
6397
6398            // (r == y) && (r boolean) && (z == 1)
6399            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_1,
6400                               suppressee),
6401
6402            // (r == z) && (r boolean) && (y == 1)
6403            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_1,
6404                               suppressee),
6405
6406          });
6407
6408  // Create a suppression factory for functionBinary
6409
6410}
6411
6412/**
6413 * Represents the invariant {@code y = BitwiseAnd(x, z)} over three long
6414 * scalars. 
6415 */
6416public static class BitwiseAndLong_yxz extends FunctionBinary {
6417  // We are Serializable, so we specify a version to allow changes to
6418  // method signatures without breaking serialization.  If you add or
6419  // remove fields, you should change this number to the current date.
6420  static final long serialVersionUID = 20031030L;
6421
6422  private static @Prototype BitwiseAndLong_yxz proto = new @Prototype BitwiseAndLong_yxz ();
6423
6424  /** Returns the prototype invariant for BitwiseAndLong_yxz */
6425  public static @Prototype BitwiseAndLong_yxz get_proto() {
6426    return proto;
6427  }
6428
6429  /** instantiate an invariant on the specified slice */
6430  @Override
6431  protected BitwiseAndLong_yxz instantiate_dyn(@Prototype BitwiseAndLong_yxz this, PptSlice slice) {
6432    return new BitwiseAndLong_yxz (slice);
6433  }
6434
6435  private BitwiseAndLong_yxz (PptSlice slice) {
6436    super(slice);
6437  }
6438
6439  public @Prototype BitwiseAndLong_yxz () {
6440    super();
6441  }
6442
6443  private static String[] method_name = new String[] {"", " & ", ""};
6444
6445  @Override
6446  public String[] get_method_name(@GuardSatisfied BitwiseAndLong_yxz this) {
6447    return method_name;
6448  }
6449
6450  private static int function_id = -1;
6451
6452  @Override
6453  public int get_function_id() {
6454    return function_id;
6455  }
6456
6457  @Override
6458  public void set_function_id(int function_id) {
6459    assert BitwiseAndLong_yxz.function_id == -1;
6460    BitwiseAndLong_yxz.function_id = function_id;
6461  }
6462
6463  private static int var_order = 2;
6464
6465  @Override
6466  public int get_var_order(@GuardSatisfied BitwiseAndLong_yxz this) {
6467    return var_order;
6468  }
6469
6470  @Pure
6471  @Override
6472  public boolean is_symmetric() {
6473
6474      return true;
6475  }
6476
6477  @Override
6478
6479  public long func(long x, long z) {
6480
6481    return (x & z);
6482  }
6483
6484  @Override
6485  public InvariantStatus check_modified(long x, long y,
6486                                      long z, int count) {
6487    return check_ordered(y, x, z, count);
6488  }
6489
6490  @Override
6491  public InvariantStatus add_modified(long x, long y,
6492                                      long z, int count) {
6493    if (Debug.logDetail()) {
6494      log("result=%s, arg1=%s, arg2=%s", y, x, z);
6495    }
6496    return add_ordered(y, x, z, count);
6497  }
6498
6499  @Pure
6500  @Override
6501  public boolean isBitwiseAnd() {
6502    return true;
6503  }
6504
6505  @Pure
6506  @Override
6507  public boolean isExact() {
6508    return true;
6509  }
6510
6511  /** Returns a list of non-instantiating suppressions for this invariant. */
6512  @Pure
6513  @Override
6514  public @Nullable NISuppressionSet get_ni_suppressions() {
6515    if (NIS.dkconfig_enabled && dkconfig_enabled) {
6516      return suppressions;
6517    } else {
6518      return null;
6519    }
6520  }
6521
6522  /** definition of this invariant (the suppressee) */
6523  private static NISuppressee suppressee = new NISuppressee(BitwiseAndLong_yxz.class, 3);
6524
6525  // suppressor definitions (used below)
6526  private static NISuppressor result_eq_arg1 =
6527      new NISuppressor(1, 0, IntEqual.class);
6528  private static NISuppressor result_eq_arg2 =
6529      new NISuppressor(1, 2, IntEqual.class);
6530  private static NISuppressor arg1_eq_arg2 =
6531      new NISuppressor(0, 2, IntEqual.class);
6532
6533  private static NISuppressor result_lt_arg1 =
6534      new NISuppressor(1, 0, IntLessThan.class);
6535  private static NISuppressor result_lt_arg2 =
6536      new NISuppressor(1, 2, IntLessThan.class);
6537  private static NISuppressor arg1_lt_arg2 =
6538      new NISuppressor(0, 2, IntLessThan.class);
6539  private static NISuppressor arg2_lt_arg1 =
6540      new NISuppressor(2, 0, IntLessThan.class);
6541
6542  private static NISuppressor result_le_arg1 =
6543      new NISuppressor(1, 0, IntLessEqual.class);
6544  private static NISuppressor result_le_arg2 =
6545      new NISuppressor(1, 2, IntLessEqual.class);
6546  private static NISuppressor arg1_le_arg2 =
6547      new NISuppressor(0, 2, IntLessEqual.class);
6548  private static NISuppressor arg2_le_arg1 =
6549      new NISuppressor(2, 0, IntLessEqual.class);
6550
6551  private static NISuppressor result_track0_arg1 =
6552      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
6553  private static NISuppressor result_track0_arg2 =
6554      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
6555  private static NISuppressor arg1_track0_arg2 =
6556      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
6557  private static NISuppressor arg1_track0_result =
6558      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
6559  private static NISuppressor arg2_track0_result =
6560      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
6561  private static NISuppressor arg2_track0_arg1 =
6562      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
6563
6564  private static NISuppressor result_eq_1 =
6565      new NISuppressor(1, RangeInt.EqualOne.class);
6566  private static NISuppressor arg1_eq_1 =
6567      new NISuppressor(0, RangeInt.EqualOne.class);
6568  private static NISuppressor arg2_eq_1 =
6569      new NISuppressor(2, RangeInt.EqualOne.class);
6570
6571  private static NISuppressor result_eq_0 =
6572      new NISuppressor(1, RangeInt.EqualZero.class);
6573  private static NISuppressor arg1_eq_0 =
6574      new NISuppressor(0, RangeInt.EqualZero.class);
6575  private static NISuppressor arg2_eq_0 =
6576      new NISuppressor(2, RangeInt.EqualZero.class);
6577
6578  private static NISuppressor result_ne_0 =
6579      new NISuppressor(1, NonZero.class);
6580  private static NISuppressor arg1_ne_0 =
6581      new NISuppressor(0, NonZero.class);
6582  private static NISuppressor arg2_ne_0 =
6583      new NISuppressor(2, NonZero.class);
6584
6585  private static NISuppressor result_ge_0 =
6586      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
6587  private static NISuppressor arg1_ge_0 =
6588      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
6589  private static NISuppressor arg2_ge_0 =
6590      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
6591
6592  private static NISuppressor result_ge_64 =
6593      new NISuppressor(1, RangeInt.GreaterEqual64.class);
6594  private static NISuppressor arg1_ge_64 =
6595      new NISuppressor(0, RangeInt.GreaterEqual64.class);
6596  private static NISuppressor arg2_ge_64 =
6597      new NISuppressor(2, RangeInt.GreaterEqual64.class);
6598
6599  private static NISuppressor result_boolean =
6600      new NISuppressor(1, RangeInt.BooleanVal.class);
6601  private static NISuppressor arg1_boolean =
6602      new NISuppressor(0, RangeInt.BooleanVal.class);
6603  private static NISuppressor arg2_boolean =
6604      new NISuppressor(2, RangeInt.BooleanVal.class);
6605
6606  private static NISuppressor result_even =
6607      new NISuppressor(1, RangeInt.Even.class);
6608  private static NISuppressor arg1_even =
6609      new NISuppressor(0, RangeInt.Even.class);
6610  private static NISuppressor arg2_even =
6611      new NISuppressor(2, RangeInt.Even.class);
6612
6613  private static NISuppressor result_power2 =
6614      new NISuppressor(1, RangeInt.PowerOfTwo.class);
6615  private static NISuppressor arg1_power2 =
6616      new NISuppressor(0, RangeInt.PowerOfTwo.class);
6617  private static NISuppressor arg2_power2 =
6618      new NISuppressor(2, RangeInt.PowerOfTwo.class);
6619
6620  private static NISuppressor result_and0_arg1 =
6621      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
6622  private static NISuppressor result_and0_arg2 =
6623      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
6624  private static NISuppressor arg1_and0_arg2 =
6625      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
6626
6627  // The arguments to bitwise subset are backwards from what one
6628  // might expect.  The second argument is a subset of the first
6629  // argument
6630  private static NISuppressor arg1_bw_subset_arg2 =
6631      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
6632  private static NISuppressor arg2_bw_subset_arg1 =
6633      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
6634
6635  private static NISuppressor result_shift0_arg1 =
6636      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
6637  private static NISuppressor result_shift0_arg2 =
6638      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
6639  private static NISuppressor arg1_shift0_arg2 =
6640      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
6641
6642  private static NISuppressor arg2_divides_arg1 =
6643      new NISuppressor(0, 2, NumericInt.Divides.class);
6644  private static NISuppressor arg1_divides_arg2 =
6645      new NISuppressor(2, 0, NumericInt.Divides.class);
6646
6647  private static NISuppressor arg2_valid_shift =
6648      new NISuppressor(2, RangeInt.Bound0_63.class);
6649
6650    private static NISuppressionSet suppressions =
6651        new NISuppressionSet(
6652          new NISuppression[] {
6653
6654            // (r == x) && (x == z) && (r == z) ==> r = x &  z
6655            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
6656                               suppressee),
6657
6658            // (r == x) && (x bitwise subset z)
6659            new NISuppression(result_eq_arg1, arg1_bw_subset_arg2, suppressee),
6660
6661            // (r == z) && (z bitwise subset x)
6662            new NISuppression(result_eq_arg2, arg2_bw_subset_arg1, suppressee),
6663
6664            // (r == 0) && (x & z == 0) ==> r = x & z
6665            new NISuppression(result_eq_0, arg1_and0_arg2, suppressee),
6666
6667            // All of these are subsummed by the prior one
6668            // (r == 0) && (x == 0) ==> r = x & z
6669            // new NISuppression (result_eq_0, arg1_eq_0, suppressee),
6670
6671            // (r == 0) && (z == 0) ==> r = x & z
6672            // new NISuppression (result_eq_0, arg2_eq_0, suppressee),
6673
6674            // (r == 0) && (x boolean) && (z is even)
6675            // new NISuppression (result_eq_0, arg1_boolean, arg2_even, suppressee),
6676
6677            // (r == 0) && (z boolean) && (x is even)
6678            // new NISuppression (result_eq_0, arg2_boolean, arg1_even, suppressee),
6679
6680            // (r == 0) && (z > x) && (z power2) && (x >= 0)
6681            // new NISuppression (result_eq_0, arg1_lt_arg2, arg2_power2, arg1_ge_0,
6682            //                   suppressee),
6683
6684            // (r == 0) && (x > z) && (x power2) && (z >= 0)
6685            // new NISuppression (result_eq_0, arg2_lt_arg1, arg1_power2, arg2_ge_0,
6686            //                   suppressee),
6687
6688            // (r == x) && (r boolean) && (z == 1)
6689            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_1,
6690                               suppressee),
6691
6692            // (r == z) && (r boolean) && (x == 1)
6693            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_1,
6694                               suppressee),
6695
6696          });
6697
6698  // Create a suppression factory for functionBinary
6699
6700}
6701
6702/**
6703 * Represents the invariant {@code z = BitwiseAnd(x, y)} over three long
6704 * scalars. 
6705 */
6706public static class BitwiseAndLong_zxy extends FunctionBinary {
6707  // We are Serializable, so we specify a version to allow changes to
6708  // method signatures without breaking serialization.  If you add or
6709  // remove fields, you should change this number to the current date.
6710  static final long serialVersionUID = 20031030L;
6711
6712  private static @Prototype BitwiseAndLong_zxy proto = new @Prototype BitwiseAndLong_zxy ();
6713
6714  /** Returns the prototype invariant for BitwiseAndLong_zxy */
6715  public static @Prototype BitwiseAndLong_zxy get_proto() {
6716    return proto;
6717  }
6718
6719  /** instantiate an invariant on the specified slice */
6720  @Override
6721  protected BitwiseAndLong_zxy instantiate_dyn(@Prototype BitwiseAndLong_zxy this, PptSlice slice) {
6722    return new BitwiseAndLong_zxy (slice);
6723  }
6724
6725  private BitwiseAndLong_zxy (PptSlice slice) {
6726    super(slice);
6727  }
6728
6729  public @Prototype BitwiseAndLong_zxy () {
6730    super();
6731  }
6732
6733  private static String[] method_name = new String[] {"", " & ", ""};
6734
6735  @Override
6736  public String[] get_method_name(@GuardSatisfied BitwiseAndLong_zxy this) {
6737    return method_name;
6738  }
6739
6740  private static int function_id = -1;
6741
6742  @Override
6743  public int get_function_id() {
6744    return function_id;
6745  }
6746
6747  @Override
6748  public void set_function_id(int function_id) {
6749    assert BitwiseAndLong_zxy.function_id == -1;
6750    BitwiseAndLong_zxy.function_id = function_id;
6751  }
6752
6753  private static int var_order = 3;
6754
6755  @Override
6756  public int get_var_order(@GuardSatisfied BitwiseAndLong_zxy this) {
6757    return var_order;
6758  }
6759
6760  @Pure
6761  @Override
6762  public boolean is_symmetric() {
6763
6764      return true;
6765  }
6766
6767  @Override
6768
6769  public long func(long x, long y) {
6770
6771    return (x & y);
6772  }
6773
6774  @Override
6775  public InvariantStatus check_modified(long x, long y,
6776                                      long z, int count) {
6777    return check_ordered(z, x, y, count);
6778  }
6779
6780  @Override
6781  public InvariantStatus add_modified(long x, long y,
6782                                      long z, int count) {
6783    if (Debug.logDetail()) {
6784      log("result=%s, arg1=%s, arg2=%s", z, x, y);
6785    }
6786    return add_ordered(z, x, y, count);
6787  }
6788
6789  @Pure
6790  @Override
6791  public boolean isBitwiseAnd() {
6792    return true;
6793  }
6794
6795  @Pure
6796  @Override
6797  public boolean isExact() {
6798    return true;
6799  }
6800
6801  /** Returns a list of non-instantiating suppressions for this invariant. */
6802  @Pure
6803  @Override
6804  public @Nullable NISuppressionSet get_ni_suppressions() {
6805    if (NIS.dkconfig_enabled && dkconfig_enabled) {
6806      return suppressions;
6807    } else {
6808      return null;
6809    }
6810  }
6811
6812  /** definition of this invariant (the suppressee) */
6813  private static NISuppressee suppressee = new NISuppressee(BitwiseAndLong_zxy.class, 3);
6814
6815  // suppressor definitions (used below)
6816  private static NISuppressor result_eq_arg1 =
6817      new NISuppressor(2, 0, IntEqual.class);
6818  private static NISuppressor result_eq_arg2 =
6819      new NISuppressor(2, 1, IntEqual.class);
6820  private static NISuppressor arg1_eq_arg2 =
6821      new NISuppressor(0, 1, IntEqual.class);
6822
6823  private static NISuppressor result_lt_arg1 =
6824      new NISuppressor(2, 0, IntLessThan.class);
6825  private static NISuppressor result_lt_arg2 =
6826      new NISuppressor(2, 1, IntLessThan.class);
6827  private static NISuppressor arg1_lt_arg2 =
6828      new NISuppressor(0, 1, IntLessThan.class);
6829  private static NISuppressor arg2_lt_arg1 =
6830      new NISuppressor(1, 0, IntLessThan.class);
6831
6832  private static NISuppressor result_le_arg1 =
6833      new NISuppressor(2, 0, IntLessEqual.class);
6834  private static NISuppressor result_le_arg2 =
6835      new NISuppressor(2, 1, IntLessEqual.class);
6836  private static NISuppressor arg1_le_arg2 =
6837      new NISuppressor(0, 1, IntLessEqual.class);
6838  private static NISuppressor arg2_le_arg1 =
6839      new NISuppressor(1, 0, IntLessEqual.class);
6840
6841  private static NISuppressor result_track0_arg1 =
6842      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
6843  private static NISuppressor result_track0_arg2 =
6844      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
6845  private static NISuppressor arg1_track0_arg2 =
6846      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
6847  private static NISuppressor arg1_track0_result =
6848      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
6849  private static NISuppressor arg2_track0_result =
6850      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
6851  private static NISuppressor arg2_track0_arg1 =
6852      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
6853
6854  private static NISuppressor result_eq_1 =
6855      new NISuppressor(2, RangeInt.EqualOne.class);
6856  private static NISuppressor arg1_eq_1 =
6857      new NISuppressor(0, RangeInt.EqualOne.class);
6858  private static NISuppressor arg2_eq_1 =
6859      new NISuppressor(1, RangeInt.EqualOne.class);
6860
6861  private static NISuppressor result_eq_0 =
6862      new NISuppressor(2, RangeInt.EqualZero.class);
6863  private static NISuppressor arg1_eq_0 =
6864      new NISuppressor(0, RangeInt.EqualZero.class);
6865  private static NISuppressor arg2_eq_0 =
6866      new NISuppressor(1, RangeInt.EqualZero.class);
6867
6868  private static NISuppressor result_ne_0 =
6869      new NISuppressor(2, NonZero.class);
6870  private static NISuppressor arg1_ne_0 =
6871      new NISuppressor(0, NonZero.class);
6872  private static NISuppressor arg2_ne_0 =
6873      new NISuppressor(1, NonZero.class);
6874
6875  private static NISuppressor result_ge_0 =
6876      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
6877  private static NISuppressor arg1_ge_0 =
6878      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
6879  private static NISuppressor arg2_ge_0 =
6880      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
6881
6882  private static NISuppressor result_ge_64 =
6883      new NISuppressor(2, RangeInt.GreaterEqual64.class);
6884  private static NISuppressor arg1_ge_64 =
6885      new NISuppressor(0, RangeInt.GreaterEqual64.class);
6886  private static NISuppressor arg2_ge_64 =
6887      new NISuppressor(1, RangeInt.GreaterEqual64.class);
6888
6889  private static NISuppressor result_boolean =
6890      new NISuppressor(2, RangeInt.BooleanVal.class);
6891  private static NISuppressor arg1_boolean =
6892      new NISuppressor(0, RangeInt.BooleanVal.class);
6893  private static NISuppressor arg2_boolean =
6894      new NISuppressor(1, RangeInt.BooleanVal.class);
6895
6896  private static NISuppressor result_even =
6897      new NISuppressor(2, RangeInt.Even.class);
6898  private static NISuppressor arg1_even =
6899      new NISuppressor(0, RangeInt.Even.class);
6900  private static NISuppressor arg2_even =
6901      new NISuppressor(1, RangeInt.Even.class);
6902
6903  private static NISuppressor result_power2 =
6904      new NISuppressor(2, RangeInt.PowerOfTwo.class);
6905  private static NISuppressor arg1_power2 =
6906      new NISuppressor(0, RangeInt.PowerOfTwo.class);
6907  private static NISuppressor arg2_power2 =
6908      new NISuppressor(1, RangeInt.PowerOfTwo.class);
6909
6910  private static NISuppressor result_and0_arg1 =
6911      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
6912  private static NISuppressor result_and0_arg2 =
6913      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
6914  private static NISuppressor arg1_and0_arg2 =
6915      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
6916
6917  // The arguments to bitwise subset are backwards from what one
6918  // might expect.  The second argument is a subset of the first
6919  // argument
6920  private static NISuppressor arg1_bw_subset_arg2 =
6921      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
6922  private static NISuppressor arg2_bw_subset_arg1 =
6923      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
6924
6925  private static NISuppressor result_shift0_arg1 =
6926      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
6927  private static NISuppressor result_shift0_arg2 =
6928      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
6929  private static NISuppressor arg1_shift0_arg2 =
6930      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
6931
6932  private static NISuppressor arg2_divides_arg1 =
6933      new NISuppressor(0, 1, NumericInt.Divides.class);
6934  private static NISuppressor arg1_divides_arg2 =
6935      new NISuppressor(1, 0, NumericInt.Divides.class);
6936
6937  private static NISuppressor arg2_valid_shift =
6938      new NISuppressor(1, RangeInt.Bound0_63.class);
6939
6940    private static NISuppressionSet suppressions =
6941        new NISuppressionSet(
6942          new NISuppression[] {
6943
6944            // (r == x) && (x == y) && (r == y) ==> r = x &  y
6945            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
6946                               suppressee),
6947
6948            // (r == x) && (x bitwise subset y)
6949            new NISuppression(result_eq_arg1, arg1_bw_subset_arg2, suppressee),
6950
6951            // (r == y) && (y bitwise subset x)
6952            new NISuppression(result_eq_arg2, arg2_bw_subset_arg1, suppressee),
6953
6954            // (r == 0) && (x & y == 0) ==> r = x & y
6955            new NISuppression(result_eq_0, arg1_and0_arg2, suppressee),
6956
6957            // All of these are subsummed by the prior one
6958            // (r == 0) && (x == 0) ==> r = x & y
6959            // new NISuppression (result_eq_0, arg1_eq_0, suppressee),
6960
6961            // (r == 0) && (y == 0) ==> r = x & y
6962            // new NISuppression (result_eq_0, arg2_eq_0, suppressee),
6963
6964            // (r == 0) && (x boolean) && (y is even)
6965            // new NISuppression (result_eq_0, arg1_boolean, arg2_even, suppressee),
6966
6967            // (r == 0) && (y boolean) && (x is even)
6968            // new NISuppression (result_eq_0, arg2_boolean, arg1_even, suppressee),
6969
6970            // (r == 0) && (y > x) && (y power2) && (x >= 0)
6971            // new NISuppression (result_eq_0, arg1_lt_arg2, arg2_power2, arg1_ge_0,
6972            //                   suppressee),
6973
6974            // (r == 0) && (x > y) && (x power2) && (y >= 0)
6975            // new NISuppression (result_eq_0, arg2_lt_arg1, arg1_power2, arg2_ge_0,
6976            //                   suppressee),
6977
6978            // (r == x) && (r boolean) && (y == 1)
6979            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_1,
6980                               suppressee),
6981
6982            // (r == y) && (r boolean) && (x == 1)
6983            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_1,
6984                               suppressee),
6985
6986          });
6987
6988  // Create a suppression factory for functionBinary
6989
6990}
6991
6992  // default is that it is not this function, overriden in the subclass
6993  @Pure
6994  public boolean isLogicalAnd() {
6995    return false;
6996  }
6997
6998/**
6999 * Represents the invariant {@code x = LogicalAnd(y, z)} over three long
7000 * scalars. For logical operations, Daikon treats 0 as false and all other values as true.
7001 */
7002public static class LogicalAndLong_xyz extends FunctionBinary {
7003  // We are Serializable, so we specify a version to allow changes to
7004  // method signatures without breaking serialization.  If you add or
7005  // remove fields, you should change this number to the current date.
7006  static final long serialVersionUID = 20031030L;
7007
7008  private static @Prototype LogicalAndLong_xyz proto = new @Prototype LogicalAndLong_xyz ();
7009
7010  /** Returns the prototype invariant for LogicalAndLong_xyz */
7011  public static @Prototype LogicalAndLong_xyz get_proto() {
7012    return proto;
7013  }
7014
7015  /** instantiate an invariant on the specified slice */
7016  @Override
7017  protected LogicalAndLong_xyz instantiate_dyn(@Prototype LogicalAndLong_xyz this, PptSlice slice) {
7018    return new LogicalAndLong_xyz (slice);
7019  }
7020
7021  private LogicalAndLong_xyz (PptSlice slice) {
7022    super(slice);
7023  }
7024
7025  public @Prototype LogicalAndLong_xyz () {
7026    super();
7027  }
7028
7029  private static String[] method_name = new String[] {"", " && ", ""};
7030
7031  @Override
7032  public String[] get_method_name(@GuardSatisfied LogicalAndLong_xyz this) {
7033    return method_name;
7034  }
7035
7036  private static int function_id = -1;
7037
7038  @Override
7039  public int get_function_id() {
7040    return function_id;
7041  }
7042
7043  @Override
7044  public void set_function_id(int function_id) {
7045    assert LogicalAndLong_xyz.function_id == -1;
7046    LogicalAndLong_xyz.function_id = function_id;
7047  }
7048
7049  private static int var_order = 1;
7050
7051  @Override
7052  public int get_var_order(@GuardSatisfied LogicalAndLong_xyz this) {
7053    return var_order;
7054  }
7055
7056  @Pure
7057  @Override
7058  public boolean is_symmetric() {
7059
7060      return true;
7061  }
7062
7063  @Override
7064
7065  public long func(long y, long z) {
7066
7067      if ((y < 0) || (y > 1)) {
7068        throw new ArithmeticException("arg1 (" + y + ") is not boolean ");
7069      }
7070      if ((z < 0) || (z > 1)) {
7071        throw new ArithmeticException("arg2 (" + z + ") is not boolean ");
7072      }
7073
7074    return (((y != 0) && ( z != 0)) ? 1 : 0);
7075  }
7076
7077  @Override
7078  public InvariantStatus check_modified(long x, long y,
7079                                      long z, int count) {
7080    return check_ordered(x, y, z, count);
7081  }
7082
7083  @Override
7084  public InvariantStatus add_modified(long x, long y,
7085                                      long z, int count) {
7086    if (Debug.logDetail()) {
7087      log("result=%s, arg1=%s, arg2=%s", x, y, z);
7088    }
7089    return add_ordered(x, y, z, count);
7090  }
7091
7092  @Pure
7093  @Override
7094  public boolean isLogicalAnd() {
7095    return true;
7096  }
7097
7098  /** Returns a list of non-instantiating suppressions for this invariant. */
7099  @Pure
7100  @Override
7101  public @Nullable NISuppressionSet get_ni_suppressions() {
7102    if (NIS.dkconfig_enabled && dkconfig_enabled) {
7103      return suppressions;
7104    } else {
7105      return null;
7106    }
7107  }
7108
7109  /** definition of this invariant (the suppressee) */
7110  private static NISuppressee suppressee = new NISuppressee(LogicalAndLong_xyz.class, 3);
7111
7112  // suppressor definitions (used below)
7113  private static NISuppressor result_eq_arg1 =
7114      new NISuppressor(0, 1, IntEqual.class);
7115  private static NISuppressor result_eq_arg2 =
7116      new NISuppressor(0, 2, IntEqual.class);
7117  private static NISuppressor arg1_eq_arg2 =
7118      new NISuppressor(1, 2, IntEqual.class);
7119
7120  private static NISuppressor result_lt_arg1 =
7121      new NISuppressor(0, 1, IntLessThan.class);
7122  private static NISuppressor result_lt_arg2 =
7123      new NISuppressor(0, 2, IntLessThan.class);
7124  private static NISuppressor arg1_lt_arg2 =
7125      new NISuppressor(1, 2, IntLessThan.class);
7126  private static NISuppressor arg2_lt_arg1 =
7127      new NISuppressor(2, 1, IntLessThan.class);
7128
7129  private static NISuppressor result_le_arg1 =
7130      new NISuppressor(0, 1, IntLessEqual.class);
7131  private static NISuppressor result_le_arg2 =
7132      new NISuppressor(0, 2, IntLessEqual.class);
7133  private static NISuppressor arg1_le_arg2 =
7134      new NISuppressor(1, 2, IntLessEqual.class);
7135  private static NISuppressor arg2_le_arg1 =
7136      new NISuppressor(2, 1, IntLessEqual.class);
7137
7138  private static NISuppressor result_track0_arg1 =
7139      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
7140  private static NISuppressor result_track0_arg2 =
7141      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
7142  private static NISuppressor arg1_track0_arg2 =
7143      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
7144  private static NISuppressor arg1_track0_result =
7145      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
7146  private static NISuppressor arg2_track0_result =
7147      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
7148  private static NISuppressor arg2_track0_arg1 =
7149      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
7150
7151  private static NISuppressor result_eq_1 =
7152      new NISuppressor(0, RangeInt.EqualOne.class);
7153  private static NISuppressor arg1_eq_1 =
7154      new NISuppressor(1, RangeInt.EqualOne.class);
7155  private static NISuppressor arg2_eq_1 =
7156      new NISuppressor(2, RangeInt.EqualOne.class);
7157
7158  private static NISuppressor result_eq_0 =
7159      new NISuppressor(0, RangeInt.EqualZero.class);
7160  private static NISuppressor arg1_eq_0 =
7161      new NISuppressor(1, RangeInt.EqualZero.class);
7162  private static NISuppressor arg2_eq_0 =
7163      new NISuppressor(2, RangeInt.EqualZero.class);
7164
7165  private static NISuppressor result_ne_0 =
7166      new NISuppressor(0, NonZero.class);
7167  private static NISuppressor arg1_ne_0 =
7168      new NISuppressor(1, NonZero.class);
7169  private static NISuppressor arg2_ne_0 =
7170      new NISuppressor(2, NonZero.class);
7171
7172  private static NISuppressor result_ge_0 =
7173      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
7174  private static NISuppressor arg1_ge_0 =
7175      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
7176  private static NISuppressor arg2_ge_0 =
7177      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
7178
7179  private static NISuppressor result_ge_64 =
7180      new NISuppressor(0, RangeInt.GreaterEqual64.class);
7181  private static NISuppressor arg1_ge_64 =
7182      new NISuppressor(1, RangeInt.GreaterEqual64.class);
7183  private static NISuppressor arg2_ge_64 =
7184      new NISuppressor(2, RangeInt.GreaterEqual64.class);
7185
7186  private static NISuppressor result_boolean =
7187      new NISuppressor(0, RangeInt.BooleanVal.class);
7188  private static NISuppressor arg1_boolean =
7189      new NISuppressor(1, RangeInt.BooleanVal.class);
7190  private static NISuppressor arg2_boolean =
7191      new NISuppressor(2, RangeInt.BooleanVal.class);
7192
7193  private static NISuppressor result_even =
7194      new NISuppressor(0, RangeInt.Even.class);
7195  private static NISuppressor arg1_even =
7196      new NISuppressor(1, RangeInt.Even.class);
7197  private static NISuppressor arg2_even =
7198      new NISuppressor(2, RangeInt.Even.class);
7199
7200  private static NISuppressor result_power2 =
7201      new NISuppressor(0, RangeInt.PowerOfTwo.class);
7202  private static NISuppressor arg1_power2 =
7203      new NISuppressor(1, RangeInt.PowerOfTwo.class);
7204  private static NISuppressor arg2_power2 =
7205      new NISuppressor(2, RangeInt.PowerOfTwo.class);
7206
7207  private static NISuppressor result_and0_arg1 =
7208      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
7209  private static NISuppressor result_and0_arg2 =
7210      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
7211  private static NISuppressor arg1_and0_arg2 =
7212      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
7213
7214  // The arguments to bitwise subset are backwards from what one
7215  // might expect.  The second argument is a subset of the first
7216  // argument
7217  private static NISuppressor arg1_bw_subset_arg2 =
7218      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
7219  private static NISuppressor arg2_bw_subset_arg1 =
7220      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
7221
7222  private static NISuppressor result_shift0_arg1 =
7223      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
7224  private static NISuppressor result_shift0_arg2 =
7225      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
7226  private static NISuppressor arg1_shift0_arg2 =
7227      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
7228
7229  private static NISuppressor arg2_divides_arg1 =
7230      new NISuppressor(1, 2, NumericInt.Divides.class);
7231  private static NISuppressor arg1_divides_arg2 =
7232      new NISuppressor(2, 1, NumericInt.Divides.class);
7233
7234  private static NISuppressor arg2_valid_shift =
7235      new NISuppressor(2, RangeInt.Bound0_63.class);
7236
7237    private static NISuppressionSet suppressions =
7238        new NISuppressionSet(
7239          new NISuppression[] {
7240
7241            // (r == y) && (y == z) && (r == z) && (r is boolean)
7242            //    ==> r = y && z
7243            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
7244                               result_boolean, suppressee),
7245
7246            // (r == 0) && (y == 0) && (z is boolean) ==> r = y && z
7247            new NISuppression(result_eq_0, arg1_eq_0, arg2_boolean, suppressee),
7248
7249            // (r == 0) && (z == 0) && (y is boolean) ==> r = y && z
7250            new NISuppression(result_eq_0, arg2_eq_0, arg1_boolean, suppressee),
7251
7252            // (r == 0) && (y == 0) && (z boolean) ==> r = y && z
7253            new NISuppression(result_eq_0, arg1_eq_0, arg2_boolean, suppressee),
7254
7255            // (r == 0) && (z == 0) && (y boolean) ==> r = y && z
7256            new NISuppression(result_eq_0, arg2_eq_0, arg1_boolean, suppressee),
7257
7258            // (r == y) && (r boolean) && (z == 1)
7259            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_1,
7260                               suppressee),
7261
7262            // (r == z) && (r boolean) && (y == 1)
7263            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_1,
7264                               suppressee),
7265
7266          });
7267
7268  // Create a suppression factory for functionBinary
7269
7270}
7271
7272/**
7273 * Represents the invariant {@code y = LogicalAnd(x, z)} over three long
7274 * scalars. For logical operations, Daikon treats 0 as false and all other values as true.
7275 */
7276public static class LogicalAndLong_yxz extends FunctionBinary {
7277  // We are Serializable, so we specify a version to allow changes to
7278  // method signatures without breaking serialization.  If you add or
7279  // remove fields, you should change this number to the current date.
7280  static final long serialVersionUID = 20031030L;
7281
7282  private static @Prototype LogicalAndLong_yxz proto = new @Prototype LogicalAndLong_yxz ();
7283
7284  /** Returns the prototype invariant for LogicalAndLong_yxz */
7285  public static @Prototype LogicalAndLong_yxz get_proto() {
7286    return proto;
7287  }
7288
7289  /** instantiate an invariant on the specified slice */
7290  @Override
7291  protected LogicalAndLong_yxz instantiate_dyn(@Prototype LogicalAndLong_yxz this, PptSlice slice) {
7292    return new LogicalAndLong_yxz (slice);
7293  }
7294
7295  private LogicalAndLong_yxz (PptSlice slice) {
7296    super(slice);
7297  }
7298
7299  public @Prototype LogicalAndLong_yxz () {
7300    super();
7301  }
7302
7303  private static String[] method_name = new String[] {"", " && ", ""};
7304
7305  @Override
7306  public String[] get_method_name(@GuardSatisfied LogicalAndLong_yxz this) {
7307    return method_name;
7308  }
7309
7310  private static int function_id = -1;
7311
7312  @Override
7313  public int get_function_id() {
7314    return function_id;
7315  }
7316
7317  @Override
7318  public void set_function_id(int function_id) {
7319    assert LogicalAndLong_yxz.function_id == -1;
7320    LogicalAndLong_yxz.function_id = function_id;
7321  }
7322
7323  private static int var_order = 2;
7324
7325  @Override
7326  public int get_var_order(@GuardSatisfied LogicalAndLong_yxz this) {
7327    return var_order;
7328  }
7329
7330  @Pure
7331  @Override
7332  public boolean is_symmetric() {
7333
7334      return true;
7335  }
7336
7337  @Override
7338
7339  public long func(long x, long z) {
7340
7341      if ((x < 0) || (x > 1)) {
7342        throw new ArithmeticException("arg1 (" + x + ") is not boolean ");
7343      }
7344      if ((z < 0) || (z > 1)) {
7345        throw new ArithmeticException("arg2 (" + z + ") is not boolean ");
7346      }
7347
7348    return (((x != 0) && ( z != 0)) ? 1 : 0);
7349  }
7350
7351  @Override
7352  public InvariantStatus check_modified(long x, long y,
7353                                      long z, int count) {
7354    return check_ordered(y, x, z, count);
7355  }
7356
7357  @Override
7358  public InvariantStatus add_modified(long x, long y,
7359                                      long z, int count) {
7360    if (Debug.logDetail()) {
7361      log("result=%s, arg1=%s, arg2=%s", y, x, z);
7362    }
7363    return add_ordered(y, x, z, count);
7364  }
7365
7366  @Pure
7367  @Override
7368  public boolean isLogicalAnd() {
7369    return true;
7370  }
7371
7372  /** Returns a list of non-instantiating suppressions for this invariant. */
7373  @Pure
7374  @Override
7375  public @Nullable NISuppressionSet get_ni_suppressions() {
7376    if (NIS.dkconfig_enabled && dkconfig_enabled) {
7377      return suppressions;
7378    } else {
7379      return null;
7380    }
7381  }
7382
7383  /** definition of this invariant (the suppressee) */
7384  private static NISuppressee suppressee = new NISuppressee(LogicalAndLong_yxz.class, 3);
7385
7386  // suppressor definitions (used below)
7387  private static NISuppressor result_eq_arg1 =
7388      new NISuppressor(1, 0, IntEqual.class);
7389  private static NISuppressor result_eq_arg2 =
7390      new NISuppressor(1, 2, IntEqual.class);
7391  private static NISuppressor arg1_eq_arg2 =
7392      new NISuppressor(0, 2, IntEqual.class);
7393
7394  private static NISuppressor result_lt_arg1 =
7395      new NISuppressor(1, 0, IntLessThan.class);
7396  private static NISuppressor result_lt_arg2 =
7397      new NISuppressor(1, 2, IntLessThan.class);
7398  private static NISuppressor arg1_lt_arg2 =
7399      new NISuppressor(0, 2, IntLessThan.class);
7400  private static NISuppressor arg2_lt_arg1 =
7401      new NISuppressor(2, 0, IntLessThan.class);
7402
7403  private static NISuppressor result_le_arg1 =
7404      new NISuppressor(1, 0, IntLessEqual.class);
7405  private static NISuppressor result_le_arg2 =
7406      new NISuppressor(1, 2, IntLessEqual.class);
7407  private static NISuppressor arg1_le_arg2 =
7408      new NISuppressor(0, 2, IntLessEqual.class);
7409  private static NISuppressor arg2_le_arg1 =
7410      new NISuppressor(2, 0, IntLessEqual.class);
7411
7412  private static NISuppressor result_track0_arg1 =
7413      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
7414  private static NISuppressor result_track0_arg2 =
7415      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
7416  private static NISuppressor arg1_track0_arg2 =
7417      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
7418  private static NISuppressor arg1_track0_result =
7419      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
7420  private static NISuppressor arg2_track0_result =
7421      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
7422  private static NISuppressor arg2_track0_arg1 =
7423      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
7424
7425  private static NISuppressor result_eq_1 =
7426      new NISuppressor(1, RangeInt.EqualOne.class);
7427  private static NISuppressor arg1_eq_1 =
7428      new NISuppressor(0, RangeInt.EqualOne.class);
7429  private static NISuppressor arg2_eq_1 =
7430      new NISuppressor(2, RangeInt.EqualOne.class);
7431
7432  private static NISuppressor result_eq_0 =
7433      new NISuppressor(1, RangeInt.EqualZero.class);
7434  private static NISuppressor arg1_eq_0 =
7435      new NISuppressor(0, RangeInt.EqualZero.class);
7436  private static NISuppressor arg2_eq_0 =
7437      new NISuppressor(2, RangeInt.EqualZero.class);
7438
7439  private static NISuppressor result_ne_0 =
7440      new NISuppressor(1, NonZero.class);
7441  private static NISuppressor arg1_ne_0 =
7442      new NISuppressor(0, NonZero.class);
7443  private static NISuppressor arg2_ne_0 =
7444      new NISuppressor(2, NonZero.class);
7445
7446  private static NISuppressor result_ge_0 =
7447      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
7448  private static NISuppressor arg1_ge_0 =
7449      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
7450  private static NISuppressor arg2_ge_0 =
7451      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
7452
7453  private static NISuppressor result_ge_64 =
7454      new NISuppressor(1, RangeInt.GreaterEqual64.class);
7455  private static NISuppressor arg1_ge_64 =
7456      new NISuppressor(0, RangeInt.GreaterEqual64.class);
7457  private static NISuppressor arg2_ge_64 =
7458      new NISuppressor(2, RangeInt.GreaterEqual64.class);
7459
7460  private static NISuppressor result_boolean =
7461      new NISuppressor(1, RangeInt.BooleanVal.class);
7462  private static NISuppressor arg1_boolean =
7463      new NISuppressor(0, RangeInt.BooleanVal.class);
7464  private static NISuppressor arg2_boolean =
7465      new NISuppressor(2, RangeInt.BooleanVal.class);
7466
7467  private static NISuppressor result_even =
7468      new NISuppressor(1, RangeInt.Even.class);
7469  private static NISuppressor arg1_even =
7470      new NISuppressor(0, RangeInt.Even.class);
7471  private static NISuppressor arg2_even =
7472      new NISuppressor(2, RangeInt.Even.class);
7473
7474  private static NISuppressor result_power2 =
7475      new NISuppressor(1, RangeInt.PowerOfTwo.class);
7476  private static NISuppressor arg1_power2 =
7477      new NISuppressor(0, RangeInt.PowerOfTwo.class);
7478  private static NISuppressor arg2_power2 =
7479      new NISuppressor(2, RangeInt.PowerOfTwo.class);
7480
7481  private static NISuppressor result_and0_arg1 =
7482      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
7483  private static NISuppressor result_and0_arg2 =
7484      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
7485  private static NISuppressor arg1_and0_arg2 =
7486      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
7487
7488  // The arguments to bitwise subset are backwards from what one
7489  // might expect.  The second argument is a subset of the first
7490  // argument
7491  private static NISuppressor arg1_bw_subset_arg2 =
7492      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
7493  private static NISuppressor arg2_bw_subset_arg1 =
7494      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
7495
7496  private static NISuppressor result_shift0_arg1 =
7497      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
7498  private static NISuppressor result_shift0_arg2 =
7499      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
7500  private static NISuppressor arg1_shift0_arg2 =
7501      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
7502
7503  private static NISuppressor arg2_divides_arg1 =
7504      new NISuppressor(0, 2, NumericInt.Divides.class);
7505  private static NISuppressor arg1_divides_arg2 =
7506      new NISuppressor(2, 0, NumericInt.Divides.class);
7507
7508  private static NISuppressor arg2_valid_shift =
7509      new NISuppressor(2, RangeInt.Bound0_63.class);
7510
7511    private static NISuppressionSet suppressions =
7512        new NISuppressionSet(
7513          new NISuppression[] {
7514
7515            // (r == x) && (x == z) && (r == z) && (r is boolean)
7516            //    ==> r = x && z
7517            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
7518                               result_boolean, suppressee),
7519
7520            // (r == 0) && (x == 0) && (z is boolean) ==> r = x && z
7521            new NISuppression(result_eq_0, arg1_eq_0, arg2_boolean, suppressee),
7522
7523            // (r == 0) && (z == 0) && (x is boolean) ==> r = x && z
7524            new NISuppression(result_eq_0, arg2_eq_0, arg1_boolean, suppressee),
7525
7526            // (r == 0) && (x == 0) && (z boolean) ==> r = x && z
7527            new NISuppression(result_eq_0, arg1_eq_0, arg2_boolean, suppressee),
7528
7529            // (r == 0) && (z == 0) && (x boolean) ==> r = x && z
7530            new NISuppression(result_eq_0, arg2_eq_0, arg1_boolean, suppressee),
7531
7532            // (r == x) && (r boolean) && (z == 1)
7533            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_1,
7534                               suppressee),
7535
7536            // (r == z) && (r boolean) && (x == 1)
7537            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_1,
7538                               suppressee),
7539
7540          });
7541
7542  // Create a suppression factory for functionBinary
7543
7544}
7545
7546/**
7547 * Represents the invariant {@code z = LogicalAnd(x, y)} over three long
7548 * scalars. For logical operations, Daikon treats 0 as false and all other values as true.
7549 */
7550public static class LogicalAndLong_zxy extends FunctionBinary {
7551  // We are Serializable, so we specify a version to allow changes to
7552  // method signatures without breaking serialization.  If you add or
7553  // remove fields, you should change this number to the current date.
7554  static final long serialVersionUID = 20031030L;
7555
7556  private static @Prototype LogicalAndLong_zxy proto = new @Prototype LogicalAndLong_zxy ();
7557
7558  /** Returns the prototype invariant for LogicalAndLong_zxy */
7559  public static @Prototype LogicalAndLong_zxy get_proto() {
7560    return proto;
7561  }
7562
7563  /** instantiate an invariant on the specified slice */
7564  @Override
7565  protected LogicalAndLong_zxy instantiate_dyn(@Prototype LogicalAndLong_zxy this, PptSlice slice) {
7566    return new LogicalAndLong_zxy (slice);
7567  }
7568
7569  private LogicalAndLong_zxy (PptSlice slice) {
7570    super(slice);
7571  }
7572
7573  public @Prototype LogicalAndLong_zxy () {
7574    super();
7575  }
7576
7577  private static String[] method_name = new String[] {"", " && ", ""};
7578
7579  @Override
7580  public String[] get_method_name(@GuardSatisfied LogicalAndLong_zxy this) {
7581    return method_name;
7582  }
7583
7584  private static int function_id = -1;
7585
7586  @Override
7587  public int get_function_id() {
7588    return function_id;
7589  }
7590
7591  @Override
7592  public void set_function_id(int function_id) {
7593    assert LogicalAndLong_zxy.function_id == -1;
7594    LogicalAndLong_zxy.function_id = function_id;
7595  }
7596
7597  private static int var_order = 3;
7598
7599  @Override
7600  public int get_var_order(@GuardSatisfied LogicalAndLong_zxy this) {
7601    return var_order;
7602  }
7603
7604  @Pure
7605  @Override
7606  public boolean is_symmetric() {
7607
7608      return true;
7609  }
7610
7611  @Override
7612
7613  public long func(long x, long y) {
7614
7615      if ((x < 0) || (x > 1)) {
7616        throw new ArithmeticException("arg1 (" + x + ") is not boolean ");
7617      }
7618      if ((y < 0) || (y > 1)) {
7619        throw new ArithmeticException("arg2 (" + y + ") is not boolean ");
7620      }
7621
7622    return (((x != 0) && ( y != 0)) ? 1 : 0);
7623  }
7624
7625  @Override
7626  public InvariantStatus check_modified(long x, long y,
7627                                      long z, int count) {
7628    return check_ordered(z, x, y, count);
7629  }
7630
7631  @Override
7632  public InvariantStatus add_modified(long x, long y,
7633                                      long z, int count) {
7634    if (Debug.logDetail()) {
7635      log("result=%s, arg1=%s, arg2=%s", z, x, y);
7636    }
7637    return add_ordered(z, x, y, count);
7638  }
7639
7640  @Pure
7641  @Override
7642  public boolean isLogicalAnd() {
7643    return true;
7644  }
7645
7646  /** Returns a list of non-instantiating suppressions for this invariant. */
7647  @Pure
7648  @Override
7649  public @Nullable NISuppressionSet get_ni_suppressions() {
7650    if (NIS.dkconfig_enabled && dkconfig_enabled) {
7651      return suppressions;
7652    } else {
7653      return null;
7654    }
7655  }
7656
7657  /** definition of this invariant (the suppressee) */
7658  private static NISuppressee suppressee = new NISuppressee(LogicalAndLong_zxy.class, 3);
7659
7660  // suppressor definitions (used below)
7661  private static NISuppressor result_eq_arg1 =
7662      new NISuppressor(2, 0, IntEqual.class);
7663  private static NISuppressor result_eq_arg2 =
7664      new NISuppressor(2, 1, IntEqual.class);
7665  private static NISuppressor arg1_eq_arg2 =
7666      new NISuppressor(0, 1, IntEqual.class);
7667
7668  private static NISuppressor result_lt_arg1 =
7669      new NISuppressor(2, 0, IntLessThan.class);
7670  private static NISuppressor result_lt_arg2 =
7671      new NISuppressor(2, 1, IntLessThan.class);
7672  private static NISuppressor arg1_lt_arg2 =
7673      new NISuppressor(0, 1, IntLessThan.class);
7674  private static NISuppressor arg2_lt_arg1 =
7675      new NISuppressor(1, 0, IntLessThan.class);
7676
7677  private static NISuppressor result_le_arg1 =
7678      new NISuppressor(2, 0, IntLessEqual.class);
7679  private static NISuppressor result_le_arg2 =
7680      new NISuppressor(2, 1, IntLessEqual.class);
7681  private static NISuppressor arg1_le_arg2 =
7682      new NISuppressor(0, 1, IntLessEqual.class);
7683  private static NISuppressor arg2_le_arg1 =
7684      new NISuppressor(1, 0, IntLessEqual.class);
7685
7686  private static NISuppressor result_track0_arg1 =
7687      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
7688  private static NISuppressor result_track0_arg2 =
7689      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
7690  private static NISuppressor arg1_track0_arg2 =
7691      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
7692  private static NISuppressor arg1_track0_result =
7693      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
7694  private static NISuppressor arg2_track0_result =
7695      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
7696  private static NISuppressor arg2_track0_arg1 =
7697      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
7698
7699  private static NISuppressor result_eq_1 =
7700      new NISuppressor(2, RangeInt.EqualOne.class);
7701  private static NISuppressor arg1_eq_1 =
7702      new NISuppressor(0, RangeInt.EqualOne.class);
7703  private static NISuppressor arg2_eq_1 =
7704      new NISuppressor(1, RangeInt.EqualOne.class);
7705
7706  private static NISuppressor result_eq_0 =
7707      new NISuppressor(2, RangeInt.EqualZero.class);
7708  private static NISuppressor arg1_eq_0 =
7709      new NISuppressor(0, RangeInt.EqualZero.class);
7710  private static NISuppressor arg2_eq_0 =
7711      new NISuppressor(1, RangeInt.EqualZero.class);
7712
7713  private static NISuppressor result_ne_0 =
7714      new NISuppressor(2, NonZero.class);
7715  private static NISuppressor arg1_ne_0 =
7716      new NISuppressor(0, NonZero.class);
7717  private static NISuppressor arg2_ne_0 =
7718      new NISuppressor(1, NonZero.class);
7719
7720  private static NISuppressor result_ge_0 =
7721      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
7722  private static NISuppressor arg1_ge_0 =
7723      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
7724  private static NISuppressor arg2_ge_0 =
7725      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
7726
7727  private static NISuppressor result_ge_64 =
7728      new NISuppressor(2, RangeInt.GreaterEqual64.class);
7729  private static NISuppressor arg1_ge_64 =
7730      new NISuppressor(0, RangeInt.GreaterEqual64.class);
7731  private static NISuppressor arg2_ge_64 =
7732      new NISuppressor(1, RangeInt.GreaterEqual64.class);
7733
7734  private static NISuppressor result_boolean =
7735      new NISuppressor(2, RangeInt.BooleanVal.class);
7736  private static NISuppressor arg1_boolean =
7737      new NISuppressor(0, RangeInt.BooleanVal.class);
7738  private static NISuppressor arg2_boolean =
7739      new NISuppressor(1, RangeInt.BooleanVal.class);
7740
7741  private static NISuppressor result_even =
7742      new NISuppressor(2, RangeInt.Even.class);
7743  private static NISuppressor arg1_even =
7744      new NISuppressor(0, RangeInt.Even.class);
7745  private static NISuppressor arg2_even =
7746      new NISuppressor(1, RangeInt.Even.class);
7747
7748  private static NISuppressor result_power2 =
7749      new NISuppressor(2, RangeInt.PowerOfTwo.class);
7750  private static NISuppressor arg1_power2 =
7751      new NISuppressor(0, RangeInt.PowerOfTwo.class);
7752  private static NISuppressor arg2_power2 =
7753      new NISuppressor(1, RangeInt.PowerOfTwo.class);
7754
7755  private static NISuppressor result_and0_arg1 =
7756      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
7757  private static NISuppressor result_and0_arg2 =
7758      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
7759  private static NISuppressor arg1_and0_arg2 =
7760      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
7761
7762  // The arguments to bitwise subset are backwards from what one
7763  // might expect.  The second argument is a subset of the first
7764  // argument
7765  private static NISuppressor arg1_bw_subset_arg2 =
7766      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
7767  private static NISuppressor arg2_bw_subset_arg1 =
7768      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
7769
7770  private static NISuppressor result_shift0_arg1 =
7771      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
7772  private static NISuppressor result_shift0_arg2 =
7773      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
7774  private static NISuppressor arg1_shift0_arg2 =
7775      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
7776
7777  private static NISuppressor arg2_divides_arg1 =
7778      new NISuppressor(0, 1, NumericInt.Divides.class);
7779  private static NISuppressor arg1_divides_arg2 =
7780      new NISuppressor(1, 0, NumericInt.Divides.class);
7781
7782  private static NISuppressor arg2_valid_shift =
7783      new NISuppressor(1, RangeInt.Bound0_63.class);
7784
7785    private static NISuppressionSet suppressions =
7786        new NISuppressionSet(
7787          new NISuppression[] {
7788
7789            // (r == x) && (x == y) && (r == y) && (r is boolean)
7790            //    ==> r = x && y
7791            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
7792                               result_boolean, suppressee),
7793
7794            // (r == 0) && (x == 0) && (y is boolean) ==> r = x && y
7795            new NISuppression(result_eq_0, arg1_eq_0, arg2_boolean, suppressee),
7796
7797            // (r == 0) && (y == 0) && (x is boolean) ==> r = x && y
7798            new NISuppression(result_eq_0, arg2_eq_0, arg1_boolean, suppressee),
7799
7800            // (r == 0) && (x == 0) && (y boolean) ==> r = x && y
7801            new NISuppression(result_eq_0, arg1_eq_0, arg2_boolean, suppressee),
7802
7803            // (r == 0) && (y == 0) && (x boolean) ==> r = x && y
7804            new NISuppression(result_eq_0, arg2_eq_0, arg1_boolean, suppressee),
7805
7806            // (r == x) && (r boolean) && (y == 1)
7807            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_1,
7808                               suppressee),
7809
7810            // (r == y) && (r boolean) && (x == 1)
7811            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_1,
7812                               suppressee),
7813
7814          });
7815
7816  // Create a suppression factory for functionBinary
7817
7818}
7819
7820  // default is that it is not this function, overriden in the subclass
7821  @Pure
7822  public boolean isBitwiseXor() {
7823    return false;
7824  }
7825
7826/**
7827 * Represents the invariant {@code x = BitwiseXor(y, z)} over three long
7828 * scalars. 
7829 */
7830public static class BitwiseXorLong_xyz extends FunctionBinary {
7831  // We are Serializable, so we specify a version to allow changes to
7832  // method signatures without breaking serialization.  If you add or
7833  // remove fields, you should change this number to the current date.
7834  static final long serialVersionUID = 20031030L;
7835
7836  private static @Prototype BitwiseXorLong_xyz proto = new @Prototype BitwiseXorLong_xyz ();
7837
7838  /** Returns the prototype invariant for BitwiseXorLong_xyz */
7839  public static @Prototype BitwiseXorLong_xyz get_proto() {
7840    return proto;
7841  }
7842
7843  /** instantiate an invariant on the specified slice */
7844  @Override
7845  protected BitwiseXorLong_xyz instantiate_dyn(@Prototype BitwiseXorLong_xyz this, PptSlice slice) {
7846    return new BitwiseXorLong_xyz (slice);
7847  }
7848
7849  private BitwiseXorLong_xyz (PptSlice slice) {
7850    super(slice);
7851  }
7852
7853  public @Prototype BitwiseXorLong_xyz () {
7854    super();
7855  }
7856
7857  private static String[] method_name = new String[] {"", " ^ ", ""};
7858
7859  @Override
7860  public String[] get_method_name(@GuardSatisfied BitwiseXorLong_xyz this) {
7861    return method_name;
7862  }
7863
7864  private static int function_id = -1;
7865
7866  @Override
7867  public int get_function_id() {
7868    return function_id;
7869  }
7870
7871  @Override
7872  public void set_function_id(int function_id) {
7873    assert BitwiseXorLong_xyz.function_id == -1;
7874    BitwiseXorLong_xyz.function_id = function_id;
7875  }
7876
7877  private static int var_order = 1;
7878
7879  @Override
7880  public int get_var_order(@GuardSatisfied BitwiseXorLong_xyz this) {
7881    return var_order;
7882  }
7883
7884  @Pure
7885  @Override
7886  public boolean is_symmetric() {
7887
7888      return true;
7889  }
7890
7891  @Override
7892
7893  public long func(long y, long z) {
7894
7895    return (y ^ z);
7896  }
7897
7898  @Override
7899  public InvariantStatus check_modified(long x, long y,
7900                                      long z, int count) {
7901    return check_ordered(x, y, z, count);
7902  }
7903
7904  @Override
7905  public InvariantStatus add_modified(long x, long y,
7906                                      long z, int count) {
7907    if (Debug.logDetail()) {
7908      log("result=%s, arg1=%s, arg2=%s", x, y, z);
7909    }
7910    return add_ordered(x, y, z, count);
7911  }
7912
7913  @Pure
7914  @Override
7915  public boolean isBitwiseXor() {
7916    return true;
7917  }
7918
7919  /** Returns a list of non-instantiating suppressions for this invariant. */
7920  @Pure
7921  @Override
7922  public @Nullable NISuppressionSet get_ni_suppressions() {
7923    if (NIS.dkconfig_enabled && dkconfig_enabled) {
7924      return suppressions;
7925    } else {
7926      return null;
7927    }
7928  }
7929
7930  /** definition of this invariant (the suppressee) */
7931  private static NISuppressee suppressee = new NISuppressee(BitwiseXorLong_xyz.class, 3);
7932
7933  // suppressor definitions (used below)
7934  private static NISuppressor result_eq_arg1 =
7935      new NISuppressor(0, 1, IntEqual.class);
7936  private static NISuppressor result_eq_arg2 =
7937      new NISuppressor(0, 2, IntEqual.class);
7938  private static NISuppressor arg1_eq_arg2 =
7939      new NISuppressor(1, 2, IntEqual.class);
7940
7941  private static NISuppressor result_lt_arg1 =
7942      new NISuppressor(0, 1, IntLessThan.class);
7943  private static NISuppressor result_lt_arg2 =
7944      new NISuppressor(0, 2, IntLessThan.class);
7945  private static NISuppressor arg1_lt_arg2 =
7946      new NISuppressor(1, 2, IntLessThan.class);
7947  private static NISuppressor arg2_lt_arg1 =
7948      new NISuppressor(2, 1, IntLessThan.class);
7949
7950  private static NISuppressor result_le_arg1 =
7951      new NISuppressor(0, 1, IntLessEqual.class);
7952  private static NISuppressor result_le_arg2 =
7953      new NISuppressor(0, 2, IntLessEqual.class);
7954  private static NISuppressor arg1_le_arg2 =
7955      new NISuppressor(1, 2, IntLessEqual.class);
7956  private static NISuppressor arg2_le_arg1 =
7957      new NISuppressor(2, 1, IntLessEqual.class);
7958
7959  private static NISuppressor result_track0_arg1 =
7960      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
7961  private static NISuppressor result_track0_arg2 =
7962      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
7963  private static NISuppressor arg1_track0_arg2 =
7964      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
7965  private static NISuppressor arg1_track0_result =
7966      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
7967  private static NISuppressor arg2_track0_result =
7968      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
7969  private static NISuppressor arg2_track0_arg1 =
7970      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
7971
7972  private static NISuppressor result_eq_1 =
7973      new NISuppressor(0, RangeInt.EqualOne.class);
7974  private static NISuppressor arg1_eq_1 =
7975      new NISuppressor(1, RangeInt.EqualOne.class);
7976  private static NISuppressor arg2_eq_1 =
7977      new NISuppressor(2, RangeInt.EqualOne.class);
7978
7979  private static NISuppressor result_eq_0 =
7980      new NISuppressor(0, RangeInt.EqualZero.class);
7981  private static NISuppressor arg1_eq_0 =
7982      new NISuppressor(1, RangeInt.EqualZero.class);
7983  private static NISuppressor arg2_eq_0 =
7984      new NISuppressor(2, RangeInt.EqualZero.class);
7985
7986  private static NISuppressor result_ne_0 =
7987      new NISuppressor(0, NonZero.class);
7988  private static NISuppressor arg1_ne_0 =
7989      new NISuppressor(1, NonZero.class);
7990  private static NISuppressor arg2_ne_0 =
7991      new NISuppressor(2, NonZero.class);
7992
7993  private static NISuppressor result_ge_0 =
7994      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
7995  private static NISuppressor arg1_ge_0 =
7996      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
7997  private static NISuppressor arg2_ge_0 =
7998      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
7999
8000  private static NISuppressor result_ge_64 =
8001      new NISuppressor(0, RangeInt.GreaterEqual64.class);
8002  private static NISuppressor arg1_ge_64 =
8003      new NISuppressor(1, RangeInt.GreaterEqual64.class);
8004  private static NISuppressor arg2_ge_64 =
8005      new NISuppressor(2, RangeInt.GreaterEqual64.class);
8006
8007  private static NISuppressor result_boolean =
8008      new NISuppressor(0, RangeInt.BooleanVal.class);
8009  private static NISuppressor arg1_boolean =
8010      new NISuppressor(1, RangeInt.BooleanVal.class);
8011  private static NISuppressor arg2_boolean =
8012      new NISuppressor(2, RangeInt.BooleanVal.class);
8013
8014  private static NISuppressor result_even =
8015      new NISuppressor(0, RangeInt.Even.class);
8016  private static NISuppressor arg1_even =
8017      new NISuppressor(1, RangeInt.Even.class);
8018  private static NISuppressor arg2_even =
8019      new NISuppressor(2, RangeInt.Even.class);
8020
8021  private static NISuppressor result_power2 =
8022      new NISuppressor(0, RangeInt.PowerOfTwo.class);
8023  private static NISuppressor arg1_power2 =
8024      new NISuppressor(1, RangeInt.PowerOfTwo.class);
8025  private static NISuppressor arg2_power2 =
8026      new NISuppressor(2, RangeInt.PowerOfTwo.class);
8027
8028  private static NISuppressor result_and0_arg1 =
8029      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
8030  private static NISuppressor result_and0_arg2 =
8031      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
8032  private static NISuppressor arg1_and0_arg2 =
8033      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
8034
8035  // The arguments to bitwise subset are backwards from what one
8036  // might expect.  The second argument is a subset of the first
8037  // argument
8038  private static NISuppressor arg1_bw_subset_arg2 =
8039      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
8040  private static NISuppressor arg2_bw_subset_arg1 =
8041      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
8042
8043  private static NISuppressor result_shift0_arg1 =
8044      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
8045  private static NISuppressor result_shift0_arg2 =
8046      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
8047  private static NISuppressor arg1_shift0_arg2 =
8048      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
8049
8050  private static NISuppressor arg2_divides_arg1 =
8051      new NISuppressor(1, 2, NumericInt.Divides.class);
8052  private static NISuppressor arg1_divides_arg2 =
8053      new NISuppressor(2, 1, NumericInt.Divides.class);
8054
8055  private static NISuppressor arg2_valid_shift =
8056      new NISuppressor(2, RangeInt.Bound0_63.class);
8057
8058    private static NISuppressionSet suppressions =
8059        new NISuppressionSet(
8060          new NISuppression[] {
8061
8062            // (r == 0) && (y == z) ==> r = y ^ z
8063            new NISuppression(result_eq_0, arg1_eq_arg2, suppressee),
8064
8065            // (r == y) && (z == 0) ==> r = y ^ z
8066            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
8067
8068            // (r == z) && (y == 0) ==> r = y ^ z
8069            new NISuppression(result_eq_arg2, arg1_eq_0, suppressee),
8070
8071          });
8072
8073  // Create a suppression factory for functionBinary
8074
8075}
8076
8077/**
8078 * Represents the invariant {@code y = BitwiseXor(x, z)} over three long
8079 * scalars. 
8080 */
8081public static class BitwiseXorLong_yxz extends FunctionBinary {
8082  // We are Serializable, so we specify a version to allow changes to
8083  // method signatures without breaking serialization.  If you add or
8084  // remove fields, you should change this number to the current date.
8085  static final long serialVersionUID = 20031030L;
8086
8087  private static @Prototype BitwiseXorLong_yxz proto = new @Prototype BitwiseXorLong_yxz ();
8088
8089  /** Returns the prototype invariant for BitwiseXorLong_yxz */
8090  public static @Prototype BitwiseXorLong_yxz get_proto() {
8091    return proto;
8092  }
8093
8094  /** instantiate an invariant on the specified slice */
8095  @Override
8096  protected BitwiseXorLong_yxz instantiate_dyn(@Prototype BitwiseXorLong_yxz this, PptSlice slice) {
8097    return new BitwiseXorLong_yxz (slice);
8098  }
8099
8100  private BitwiseXorLong_yxz (PptSlice slice) {
8101    super(slice);
8102  }
8103
8104  public @Prototype BitwiseXorLong_yxz () {
8105    super();
8106  }
8107
8108  private static String[] method_name = new String[] {"", " ^ ", ""};
8109
8110  @Override
8111  public String[] get_method_name(@GuardSatisfied BitwiseXorLong_yxz this) {
8112    return method_name;
8113  }
8114
8115  private static int function_id = -1;
8116
8117  @Override
8118  public int get_function_id() {
8119    return function_id;
8120  }
8121
8122  @Override
8123  public void set_function_id(int function_id) {
8124    assert BitwiseXorLong_yxz.function_id == -1;
8125    BitwiseXorLong_yxz.function_id = function_id;
8126  }
8127
8128  private static int var_order = 2;
8129
8130  @Override
8131  public int get_var_order(@GuardSatisfied BitwiseXorLong_yxz this) {
8132    return var_order;
8133  }
8134
8135  @Pure
8136  @Override
8137  public boolean is_symmetric() {
8138
8139      return true;
8140  }
8141
8142  @Override
8143
8144  public long func(long x, long z) {
8145
8146    return (x ^ z);
8147  }
8148
8149  @Override
8150  public InvariantStatus check_modified(long x, long y,
8151                                      long z, int count) {
8152    return check_ordered(y, x, z, count);
8153  }
8154
8155  @Override
8156  public InvariantStatus add_modified(long x, long y,
8157                                      long z, int count) {
8158    if (Debug.logDetail()) {
8159      log("result=%s, arg1=%s, arg2=%s", y, x, z);
8160    }
8161    return add_ordered(y, x, z, count);
8162  }
8163
8164  @Pure
8165  @Override
8166  public boolean isBitwiseXor() {
8167    return true;
8168  }
8169
8170  /** Returns a list of non-instantiating suppressions for this invariant. */
8171  @Pure
8172  @Override
8173  public @Nullable NISuppressionSet get_ni_suppressions() {
8174    if (NIS.dkconfig_enabled && dkconfig_enabled) {
8175      return suppressions;
8176    } else {
8177      return null;
8178    }
8179  }
8180
8181  /** definition of this invariant (the suppressee) */
8182  private static NISuppressee suppressee = new NISuppressee(BitwiseXorLong_yxz.class, 3);
8183
8184  // suppressor definitions (used below)
8185  private static NISuppressor result_eq_arg1 =
8186      new NISuppressor(1, 0, IntEqual.class);
8187  private static NISuppressor result_eq_arg2 =
8188      new NISuppressor(1, 2, IntEqual.class);
8189  private static NISuppressor arg1_eq_arg2 =
8190      new NISuppressor(0, 2, IntEqual.class);
8191
8192  private static NISuppressor result_lt_arg1 =
8193      new NISuppressor(1, 0, IntLessThan.class);
8194  private static NISuppressor result_lt_arg2 =
8195      new NISuppressor(1, 2, IntLessThan.class);
8196  private static NISuppressor arg1_lt_arg2 =
8197      new NISuppressor(0, 2, IntLessThan.class);
8198  private static NISuppressor arg2_lt_arg1 =
8199      new NISuppressor(2, 0, IntLessThan.class);
8200
8201  private static NISuppressor result_le_arg1 =
8202      new NISuppressor(1, 0, IntLessEqual.class);
8203  private static NISuppressor result_le_arg2 =
8204      new NISuppressor(1, 2, IntLessEqual.class);
8205  private static NISuppressor arg1_le_arg2 =
8206      new NISuppressor(0, 2, IntLessEqual.class);
8207  private static NISuppressor arg2_le_arg1 =
8208      new NISuppressor(2, 0, IntLessEqual.class);
8209
8210  private static NISuppressor result_track0_arg1 =
8211      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
8212  private static NISuppressor result_track0_arg2 =
8213      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
8214  private static NISuppressor arg1_track0_arg2 =
8215      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
8216  private static NISuppressor arg1_track0_result =
8217      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
8218  private static NISuppressor arg2_track0_result =
8219      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
8220  private static NISuppressor arg2_track0_arg1 =
8221      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
8222
8223  private static NISuppressor result_eq_1 =
8224      new NISuppressor(1, RangeInt.EqualOne.class);
8225  private static NISuppressor arg1_eq_1 =
8226      new NISuppressor(0, RangeInt.EqualOne.class);
8227  private static NISuppressor arg2_eq_1 =
8228      new NISuppressor(2, RangeInt.EqualOne.class);
8229
8230  private static NISuppressor result_eq_0 =
8231      new NISuppressor(1, RangeInt.EqualZero.class);
8232  private static NISuppressor arg1_eq_0 =
8233      new NISuppressor(0, RangeInt.EqualZero.class);
8234  private static NISuppressor arg2_eq_0 =
8235      new NISuppressor(2, RangeInt.EqualZero.class);
8236
8237  private static NISuppressor result_ne_0 =
8238      new NISuppressor(1, NonZero.class);
8239  private static NISuppressor arg1_ne_0 =
8240      new NISuppressor(0, NonZero.class);
8241  private static NISuppressor arg2_ne_0 =
8242      new NISuppressor(2, NonZero.class);
8243
8244  private static NISuppressor result_ge_0 =
8245      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
8246  private static NISuppressor arg1_ge_0 =
8247      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
8248  private static NISuppressor arg2_ge_0 =
8249      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
8250
8251  private static NISuppressor result_ge_64 =
8252      new NISuppressor(1, RangeInt.GreaterEqual64.class);
8253  private static NISuppressor arg1_ge_64 =
8254      new NISuppressor(0, RangeInt.GreaterEqual64.class);
8255  private static NISuppressor arg2_ge_64 =
8256      new NISuppressor(2, RangeInt.GreaterEqual64.class);
8257
8258  private static NISuppressor result_boolean =
8259      new NISuppressor(1, RangeInt.BooleanVal.class);
8260  private static NISuppressor arg1_boolean =
8261      new NISuppressor(0, RangeInt.BooleanVal.class);
8262  private static NISuppressor arg2_boolean =
8263      new NISuppressor(2, RangeInt.BooleanVal.class);
8264
8265  private static NISuppressor result_even =
8266      new NISuppressor(1, RangeInt.Even.class);
8267  private static NISuppressor arg1_even =
8268      new NISuppressor(0, RangeInt.Even.class);
8269  private static NISuppressor arg2_even =
8270      new NISuppressor(2, RangeInt.Even.class);
8271
8272  private static NISuppressor result_power2 =
8273      new NISuppressor(1, RangeInt.PowerOfTwo.class);
8274  private static NISuppressor arg1_power2 =
8275      new NISuppressor(0, RangeInt.PowerOfTwo.class);
8276  private static NISuppressor arg2_power2 =
8277      new NISuppressor(2, RangeInt.PowerOfTwo.class);
8278
8279  private static NISuppressor result_and0_arg1 =
8280      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
8281  private static NISuppressor result_and0_arg2 =
8282      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
8283  private static NISuppressor arg1_and0_arg2 =
8284      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
8285
8286  // The arguments to bitwise subset are backwards from what one
8287  // might expect.  The second argument is a subset of the first
8288  // argument
8289  private static NISuppressor arg1_bw_subset_arg2 =
8290      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
8291  private static NISuppressor arg2_bw_subset_arg1 =
8292      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
8293
8294  private static NISuppressor result_shift0_arg1 =
8295      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
8296  private static NISuppressor result_shift0_arg2 =
8297      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
8298  private static NISuppressor arg1_shift0_arg2 =
8299      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
8300
8301  private static NISuppressor arg2_divides_arg1 =
8302      new NISuppressor(0, 2, NumericInt.Divides.class);
8303  private static NISuppressor arg1_divides_arg2 =
8304      new NISuppressor(2, 0, NumericInt.Divides.class);
8305
8306  private static NISuppressor arg2_valid_shift =
8307      new NISuppressor(2, RangeInt.Bound0_63.class);
8308
8309    private static NISuppressionSet suppressions =
8310        new NISuppressionSet(
8311          new NISuppression[] {
8312
8313            // (r == 0) && (x == z) ==> r = x ^ z
8314            new NISuppression(result_eq_0, arg1_eq_arg2, suppressee),
8315
8316            // (r == x) && (z == 0) ==> r = x ^ z
8317            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
8318
8319            // (r == z) && (x == 0) ==> r = x ^ z
8320            new NISuppression(result_eq_arg2, arg1_eq_0, suppressee),
8321
8322          });
8323
8324  // Create a suppression factory for functionBinary
8325
8326}
8327
8328/**
8329 * Represents the invariant {@code z = BitwiseXor(x, y)} over three long
8330 * scalars. 
8331 */
8332public static class BitwiseXorLong_zxy extends FunctionBinary {
8333  // We are Serializable, so we specify a version to allow changes to
8334  // method signatures without breaking serialization.  If you add or
8335  // remove fields, you should change this number to the current date.
8336  static final long serialVersionUID = 20031030L;
8337
8338  private static @Prototype BitwiseXorLong_zxy proto = new @Prototype BitwiseXorLong_zxy ();
8339
8340  /** Returns the prototype invariant for BitwiseXorLong_zxy */
8341  public static @Prototype BitwiseXorLong_zxy get_proto() {
8342    return proto;
8343  }
8344
8345  /** instantiate an invariant on the specified slice */
8346  @Override
8347  protected BitwiseXorLong_zxy instantiate_dyn(@Prototype BitwiseXorLong_zxy this, PptSlice slice) {
8348    return new BitwiseXorLong_zxy (slice);
8349  }
8350
8351  private BitwiseXorLong_zxy (PptSlice slice) {
8352    super(slice);
8353  }
8354
8355  public @Prototype BitwiseXorLong_zxy () {
8356    super();
8357  }
8358
8359  private static String[] method_name = new String[] {"", " ^ ", ""};
8360
8361  @Override
8362  public String[] get_method_name(@GuardSatisfied BitwiseXorLong_zxy this) {
8363    return method_name;
8364  }
8365
8366  private static int function_id = -1;
8367
8368  @Override
8369  public int get_function_id() {
8370    return function_id;
8371  }
8372
8373  @Override
8374  public void set_function_id(int function_id) {
8375    assert BitwiseXorLong_zxy.function_id == -1;
8376    BitwiseXorLong_zxy.function_id = function_id;
8377  }
8378
8379  private static int var_order = 3;
8380
8381  @Override
8382  public int get_var_order(@GuardSatisfied BitwiseXorLong_zxy this) {
8383    return var_order;
8384  }
8385
8386  @Pure
8387  @Override
8388  public boolean is_symmetric() {
8389
8390      return true;
8391  }
8392
8393  @Override
8394
8395  public long func(long x, long y) {
8396
8397    return (x ^ y);
8398  }
8399
8400  @Override
8401  public InvariantStatus check_modified(long x, long y,
8402                                      long z, int count) {
8403    return check_ordered(z, x, y, count);
8404  }
8405
8406  @Override
8407  public InvariantStatus add_modified(long x, long y,
8408                                      long z, int count) {
8409    if (Debug.logDetail()) {
8410      log("result=%s, arg1=%s, arg2=%s", z, x, y);
8411    }
8412    return add_ordered(z, x, y, count);
8413  }
8414
8415  @Pure
8416  @Override
8417  public boolean isBitwiseXor() {
8418    return true;
8419  }
8420
8421  /** Returns a list of non-instantiating suppressions for this invariant. */
8422  @Pure
8423  @Override
8424  public @Nullable NISuppressionSet get_ni_suppressions() {
8425    if (NIS.dkconfig_enabled && dkconfig_enabled) {
8426      return suppressions;
8427    } else {
8428      return null;
8429    }
8430  }
8431
8432  /** definition of this invariant (the suppressee) */
8433  private static NISuppressee suppressee = new NISuppressee(BitwiseXorLong_zxy.class, 3);
8434
8435  // suppressor definitions (used below)
8436  private static NISuppressor result_eq_arg1 =
8437      new NISuppressor(2, 0, IntEqual.class);
8438  private static NISuppressor result_eq_arg2 =
8439      new NISuppressor(2, 1, IntEqual.class);
8440  private static NISuppressor arg1_eq_arg2 =
8441      new NISuppressor(0, 1, IntEqual.class);
8442
8443  private static NISuppressor result_lt_arg1 =
8444      new NISuppressor(2, 0, IntLessThan.class);
8445  private static NISuppressor result_lt_arg2 =
8446      new NISuppressor(2, 1, IntLessThan.class);
8447  private static NISuppressor arg1_lt_arg2 =
8448      new NISuppressor(0, 1, IntLessThan.class);
8449  private static NISuppressor arg2_lt_arg1 =
8450      new NISuppressor(1, 0, IntLessThan.class);
8451
8452  private static NISuppressor result_le_arg1 =
8453      new NISuppressor(2, 0, IntLessEqual.class);
8454  private static NISuppressor result_le_arg2 =
8455      new NISuppressor(2, 1, IntLessEqual.class);
8456  private static NISuppressor arg1_le_arg2 =
8457      new NISuppressor(0, 1, IntLessEqual.class);
8458  private static NISuppressor arg2_le_arg1 =
8459      new NISuppressor(1, 0, IntLessEqual.class);
8460
8461  private static NISuppressor result_track0_arg1 =
8462      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
8463  private static NISuppressor result_track0_arg2 =
8464      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
8465  private static NISuppressor arg1_track0_arg2 =
8466      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
8467  private static NISuppressor arg1_track0_result =
8468      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
8469  private static NISuppressor arg2_track0_result =
8470      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
8471  private static NISuppressor arg2_track0_arg1 =
8472      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
8473
8474  private static NISuppressor result_eq_1 =
8475      new NISuppressor(2, RangeInt.EqualOne.class);
8476  private static NISuppressor arg1_eq_1 =
8477      new NISuppressor(0, RangeInt.EqualOne.class);
8478  private static NISuppressor arg2_eq_1 =
8479      new NISuppressor(1, RangeInt.EqualOne.class);
8480
8481  private static NISuppressor result_eq_0 =
8482      new NISuppressor(2, RangeInt.EqualZero.class);
8483  private static NISuppressor arg1_eq_0 =
8484      new NISuppressor(0, RangeInt.EqualZero.class);
8485  private static NISuppressor arg2_eq_0 =
8486      new NISuppressor(1, RangeInt.EqualZero.class);
8487
8488  private static NISuppressor result_ne_0 =
8489      new NISuppressor(2, NonZero.class);
8490  private static NISuppressor arg1_ne_0 =
8491      new NISuppressor(0, NonZero.class);
8492  private static NISuppressor arg2_ne_0 =
8493      new NISuppressor(1, NonZero.class);
8494
8495  private static NISuppressor result_ge_0 =
8496      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
8497  private static NISuppressor arg1_ge_0 =
8498      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
8499  private static NISuppressor arg2_ge_0 =
8500      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
8501
8502  private static NISuppressor result_ge_64 =
8503      new NISuppressor(2, RangeInt.GreaterEqual64.class);
8504  private static NISuppressor arg1_ge_64 =
8505      new NISuppressor(0, RangeInt.GreaterEqual64.class);
8506  private static NISuppressor arg2_ge_64 =
8507      new NISuppressor(1, RangeInt.GreaterEqual64.class);
8508
8509  private static NISuppressor result_boolean =
8510      new NISuppressor(2, RangeInt.BooleanVal.class);
8511  private static NISuppressor arg1_boolean =
8512      new NISuppressor(0, RangeInt.BooleanVal.class);
8513  private static NISuppressor arg2_boolean =
8514      new NISuppressor(1, RangeInt.BooleanVal.class);
8515
8516  private static NISuppressor result_even =
8517      new NISuppressor(2, RangeInt.Even.class);
8518  private static NISuppressor arg1_even =
8519      new NISuppressor(0, RangeInt.Even.class);
8520  private static NISuppressor arg2_even =
8521      new NISuppressor(1, RangeInt.Even.class);
8522
8523  private static NISuppressor result_power2 =
8524      new NISuppressor(2, RangeInt.PowerOfTwo.class);
8525  private static NISuppressor arg1_power2 =
8526      new NISuppressor(0, RangeInt.PowerOfTwo.class);
8527  private static NISuppressor arg2_power2 =
8528      new NISuppressor(1, RangeInt.PowerOfTwo.class);
8529
8530  private static NISuppressor result_and0_arg1 =
8531      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
8532  private static NISuppressor result_and0_arg2 =
8533      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
8534  private static NISuppressor arg1_and0_arg2 =
8535      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
8536
8537  // The arguments to bitwise subset are backwards from what one
8538  // might expect.  The second argument is a subset of the first
8539  // argument
8540  private static NISuppressor arg1_bw_subset_arg2 =
8541      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
8542  private static NISuppressor arg2_bw_subset_arg1 =
8543      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
8544
8545  private static NISuppressor result_shift0_arg1 =
8546      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
8547  private static NISuppressor result_shift0_arg2 =
8548      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
8549  private static NISuppressor arg1_shift0_arg2 =
8550      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
8551
8552  private static NISuppressor arg2_divides_arg1 =
8553      new NISuppressor(0, 1, NumericInt.Divides.class);
8554  private static NISuppressor arg1_divides_arg2 =
8555      new NISuppressor(1, 0, NumericInt.Divides.class);
8556
8557  private static NISuppressor arg2_valid_shift =
8558      new NISuppressor(1, RangeInt.Bound0_63.class);
8559
8560    private static NISuppressionSet suppressions =
8561        new NISuppressionSet(
8562          new NISuppression[] {
8563
8564            // (r == 0) && (x == y) ==> r = x ^ y
8565            new NISuppression(result_eq_0, arg1_eq_arg2, suppressee),
8566
8567            // (r == x) && (y == 0) ==> r = x ^ y
8568            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
8569
8570            // (r == y) && (x == 0) ==> r = x ^ y
8571            new NISuppression(result_eq_arg2, arg1_eq_0, suppressee),
8572
8573          });
8574
8575  // Create a suppression factory for functionBinary
8576
8577}
8578
8579  // #define METHOD_NAME {"", " ^ ", ""}
8580
8581  // default is that it is not this function, overriden in the subclass
8582  @Pure
8583  public boolean isLogicalXor() {
8584    return false;
8585  }
8586
8587/**
8588 * Represents the invariant {@code x = LogicalXor(y, z)} over three long
8589 * scalars. For logical operations, Daikon treats 0 as false and all other values as true.
8590 */
8591public static class LogicalXorLong_xyz extends FunctionBinary {
8592  // We are Serializable, so we specify a version to allow changes to
8593  // method signatures without breaking serialization.  If you add or
8594  // remove fields, you should change this number to the current date.
8595  static final long serialVersionUID = 20031030L;
8596
8597  private static @Prototype LogicalXorLong_xyz proto = new @Prototype LogicalXorLong_xyz ();
8598
8599  /** Returns the prototype invariant for LogicalXorLong_xyz */
8600  public static @Prototype LogicalXorLong_xyz get_proto() {
8601    return proto;
8602  }
8603
8604  /** instantiate an invariant on the specified slice */
8605  @Override
8606  protected LogicalXorLong_xyz instantiate_dyn(@Prototype LogicalXorLong_xyz this, PptSlice slice) {
8607    return new LogicalXorLong_xyz (slice);
8608  }
8609
8610  private LogicalXorLong_xyz (PptSlice slice) {
8611    super(slice);
8612  }
8613
8614  public @Prototype LogicalXorLong_xyz () {
8615    super();
8616  }
8617
8618  private static String[] method_name = new String[] {"org.plumelib.util.MathPlume.logicalXor(", ", ", ")"};
8619
8620  @Override
8621  public String[] get_method_name(@GuardSatisfied LogicalXorLong_xyz this) {
8622    return method_name;
8623  }
8624
8625  private static int function_id = -1;
8626
8627  @Override
8628  public int get_function_id() {
8629    return function_id;
8630  }
8631
8632  @Override
8633  public void set_function_id(int function_id) {
8634    assert LogicalXorLong_xyz.function_id == -1;
8635    LogicalXorLong_xyz.function_id = function_id;
8636  }
8637
8638  private static int var_order = 1;
8639
8640  @Override
8641  public int get_var_order(@GuardSatisfied LogicalXorLong_xyz this) {
8642    return var_order;
8643  }
8644
8645  @Pure
8646  @Override
8647  public boolean is_symmetric() {
8648
8649      return true;
8650  }
8651
8652  @Override
8653
8654  public long func(long y, long z) {
8655
8656      if ((y < 0) || (y > 1)) {
8657        throw new ArithmeticException("arg1 (" + y + ") is not boolean ");
8658      }
8659      if ((z < 0) || (z > 1)) {
8660        throw new ArithmeticException("arg2 (" + z + ") is not boolean ");
8661      }
8662
8663    return (((y != 0) ^ ( z != 0)) ? 1 : 0);
8664  }
8665
8666  @Override
8667  public InvariantStatus check_modified(long x, long y,
8668                                      long z, int count) {
8669    return check_ordered(x, y, z, count);
8670  }
8671
8672  @Override
8673  public InvariantStatus add_modified(long x, long y,
8674                                      long z, int count) {
8675    if (Debug.logDetail()) {
8676      log("result=%s, arg1=%s, arg2=%s", x, y, z);
8677    }
8678    return add_ordered(x, y, z, count);
8679  }
8680
8681  @Pure
8682  @Override
8683  public boolean isLogicalXor() {
8684    return true;
8685  }
8686
8687  /** Returns a list of non-instantiating suppressions for this invariant. */
8688  @Pure
8689  @Override
8690  public @Nullable NISuppressionSet get_ni_suppressions() {
8691    if (NIS.dkconfig_enabled && dkconfig_enabled) {
8692      return suppressions;
8693    } else {
8694      return null;
8695    }
8696  }
8697
8698  /** definition of this invariant (the suppressee) */
8699  private static NISuppressee suppressee = new NISuppressee(LogicalXorLong_xyz.class, 3);
8700
8701  // suppressor definitions (used below)
8702  private static NISuppressor result_eq_arg1 =
8703      new NISuppressor(0, 1, IntEqual.class);
8704  private static NISuppressor result_eq_arg2 =
8705      new NISuppressor(0, 2, IntEqual.class);
8706  private static NISuppressor arg1_eq_arg2 =
8707      new NISuppressor(1, 2, IntEqual.class);
8708
8709  private static NISuppressor result_lt_arg1 =
8710      new NISuppressor(0, 1, IntLessThan.class);
8711  private static NISuppressor result_lt_arg2 =
8712      new NISuppressor(0, 2, IntLessThan.class);
8713  private static NISuppressor arg1_lt_arg2 =
8714      new NISuppressor(1, 2, IntLessThan.class);
8715  private static NISuppressor arg2_lt_arg1 =
8716      new NISuppressor(2, 1, IntLessThan.class);
8717
8718  private static NISuppressor result_le_arg1 =
8719      new NISuppressor(0, 1, IntLessEqual.class);
8720  private static NISuppressor result_le_arg2 =
8721      new NISuppressor(0, 2, IntLessEqual.class);
8722  private static NISuppressor arg1_le_arg2 =
8723      new NISuppressor(1, 2, IntLessEqual.class);
8724  private static NISuppressor arg2_le_arg1 =
8725      new NISuppressor(2, 1, IntLessEqual.class);
8726
8727  private static NISuppressor result_track0_arg1 =
8728      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
8729  private static NISuppressor result_track0_arg2 =
8730      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
8731  private static NISuppressor arg1_track0_arg2 =
8732      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
8733  private static NISuppressor arg1_track0_result =
8734      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
8735  private static NISuppressor arg2_track0_result =
8736      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
8737  private static NISuppressor arg2_track0_arg1 =
8738      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
8739
8740  private static NISuppressor result_eq_1 =
8741      new NISuppressor(0, RangeInt.EqualOne.class);
8742  private static NISuppressor arg1_eq_1 =
8743      new NISuppressor(1, RangeInt.EqualOne.class);
8744  private static NISuppressor arg2_eq_1 =
8745      new NISuppressor(2, RangeInt.EqualOne.class);
8746
8747  private static NISuppressor result_eq_0 =
8748      new NISuppressor(0, RangeInt.EqualZero.class);
8749  private static NISuppressor arg1_eq_0 =
8750      new NISuppressor(1, RangeInt.EqualZero.class);
8751  private static NISuppressor arg2_eq_0 =
8752      new NISuppressor(2, RangeInt.EqualZero.class);
8753
8754  private static NISuppressor result_ne_0 =
8755      new NISuppressor(0, NonZero.class);
8756  private static NISuppressor arg1_ne_0 =
8757      new NISuppressor(1, NonZero.class);
8758  private static NISuppressor arg2_ne_0 =
8759      new NISuppressor(2, NonZero.class);
8760
8761  private static NISuppressor result_ge_0 =
8762      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
8763  private static NISuppressor arg1_ge_0 =
8764      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
8765  private static NISuppressor arg2_ge_0 =
8766      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
8767
8768  private static NISuppressor result_ge_64 =
8769      new NISuppressor(0, RangeInt.GreaterEqual64.class);
8770  private static NISuppressor arg1_ge_64 =
8771      new NISuppressor(1, RangeInt.GreaterEqual64.class);
8772  private static NISuppressor arg2_ge_64 =
8773      new NISuppressor(2, RangeInt.GreaterEqual64.class);
8774
8775  private static NISuppressor result_boolean =
8776      new NISuppressor(0, RangeInt.BooleanVal.class);
8777  private static NISuppressor arg1_boolean =
8778      new NISuppressor(1, RangeInt.BooleanVal.class);
8779  private static NISuppressor arg2_boolean =
8780      new NISuppressor(2, RangeInt.BooleanVal.class);
8781
8782  private static NISuppressor result_even =
8783      new NISuppressor(0, RangeInt.Even.class);
8784  private static NISuppressor arg1_even =
8785      new NISuppressor(1, RangeInt.Even.class);
8786  private static NISuppressor arg2_even =
8787      new NISuppressor(2, RangeInt.Even.class);
8788
8789  private static NISuppressor result_power2 =
8790      new NISuppressor(0, RangeInt.PowerOfTwo.class);
8791  private static NISuppressor arg1_power2 =
8792      new NISuppressor(1, RangeInt.PowerOfTwo.class);
8793  private static NISuppressor arg2_power2 =
8794      new NISuppressor(2, RangeInt.PowerOfTwo.class);
8795
8796  private static NISuppressor result_and0_arg1 =
8797      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
8798  private static NISuppressor result_and0_arg2 =
8799      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
8800  private static NISuppressor arg1_and0_arg2 =
8801      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
8802
8803  // The arguments to bitwise subset are backwards from what one
8804  // might expect.  The second argument is a subset of the first
8805  // argument
8806  private static NISuppressor arg1_bw_subset_arg2 =
8807      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
8808  private static NISuppressor arg2_bw_subset_arg1 =
8809      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
8810
8811  private static NISuppressor result_shift0_arg1 =
8812      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
8813  private static NISuppressor result_shift0_arg2 =
8814      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
8815  private static NISuppressor arg1_shift0_arg2 =
8816      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
8817
8818  private static NISuppressor arg2_divides_arg1 =
8819      new NISuppressor(1, 2, NumericInt.Divides.class);
8820  private static NISuppressor arg1_divides_arg2 =
8821      new NISuppressor(2, 1, NumericInt.Divides.class);
8822
8823  private static NISuppressor arg2_valid_shift =
8824      new NISuppressor(2, RangeInt.Bound0_63.class);
8825
8826    private static NISuppressionSet suppressions =
8827        new NISuppressionSet(
8828          new NISuppression[] {
8829
8830            // (r == 0) && (y == z) && (y boolean) ==> r = y ^ z
8831            new NISuppression(arg1_eq_arg2, arg1_boolean, result_eq_0,
8832                               suppressee),
8833
8834            // (r == y) && (z == 0) && (x boolean) ==> r = y ^ z
8835            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_0,
8836                               suppressee),
8837
8838            // (r == z) && (y == 0) && (x boolean)==> r = y ^ z
8839            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_0,
8840                               suppressee),
8841
8842          });
8843
8844  // Create a suppression factory for functionBinary
8845
8846}
8847
8848/**
8849 * Represents the invariant {@code y = LogicalXor(x, z)} over three long
8850 * scalars. For logical operations, Daikon treats 0 as false and all other values as true.
8851 */
8852public static class LogicalXorLong_yxz extends FunctionBinary {
8853  // We are Serializable, so we specify a version to allow changes to
8854  // method signatures without breaking serialization.  If you add or
8855  // remove fields, you should change this number to the current date.
8856  static final long serialVersionUID = 20031030L;
8857
8858  private static @Prototype LogicalXorLong_yxz proto = new @Prototype LogicalXorLong_yxz ();
8859
8860  /** Returns the prototype invariant for LogicalXorLong_yxz */
8861  public static @Prototype LogicalXorLong_yxz get_proto() {
8862    return proto;
8863  }
8864
8865  /** instantiate an invariant on the specified slice */
8866  @Override
8867  protected LogicalXorLong_yxz instantiate_dyn(@Prototype LogicalXorLong_yxz this, PptSlice slice) {
8868    return new LogicalXorLong_yxz (slice);
8869  }
8870
8871  private LogicalXorLong_yxz (PptSlice slice) {
8872    super(slice);
8873  }
8874
8875  public @Prototype LogicalXorLong_yxz () {
8876    super();
8877  }
8878
8879  private static String[] method_name = new String[] {"org.plumelib.util.MathPlume.logicalXor(", ", ", ")"};
8880
8881  @Override
8882  public String[] get_method_name(@GuardSatisfied LogicalXorLong_yxz this) {
8883    return method_name;
8884  }
8885
8886  private static int function_id = -1;
8887
8888  @Override
8889  public int get_function_id() {
8890    return function_id;
8891  }
8892
8893  @Override
8894  public void set_function_id(int function_id) {
8895    assert LogicalXorLong_yxz.function_id == -1;
8896    LogicalXorLong_yxz.function_id = function_id;
8897  }
8898
8899  private static int var_order = 2;
8900
8901  @Override
8902  public int get_var_order(@GuardSatisfied LogicalXorLong_yxz this) {
8903    return var_order;
8904  }
8905
8906  @Pure
8907  @Override
8908  public boolean is_symmetric() {
8909
8910      return true;
8911  }
8912
8913  @Override
8914
8915  public long func(long x, long z) {
8916
8917      if ((x < 0) || (x > 1)) {
8918        throw new ArithmeticException("arg1 (" + x + ") is not boolean ");
8919      }
8920      if ((z < 0) || (z > 1)) {
8921        throw new ArithmeticException("arg2 (" + z + ") is not boolean ");
8922      }
8923
8924    return (((x != 0) ^ ( z != 0)) ? 1 : 0);
8925  }
8926
8927  @Override
8928  public InvariantStatus check_modified(long x, long y,
8929                                      long z, int count) {
8930    return check_ordered(y, x, z, count);
8931  }
8932
8933  @Override
8934  public InvariantStatus add_modified(long x, long y,
8935                                      long z, int count) {
8936    if (Debug.logDetail()) {
8937      log("result=%s, arg1=%s, arg2=%s", y, x, z);
8938    }
8939    return add_ordered(y, x, z, count);
8940  }
8941
8942  @Pure
8943  @Override
8944  public boolean isLogicalXor() {
8945    return true;
8946  }
8947
8948  /** Returns a list of non-instantiating suppressions for this invariant. */
8949  @Pure
8950  @Override
8951  public @Nullable NISuppressionSet get_ni_suppressions() {
8952    if (NIS.dkconfig_enabled && dkconfig_enabled) {
8953      return suppressions;
8954    } else {
8955      return null;
8956    }
8957  }
8958
8959  /** definition of this invariant (the suppressee) */
8960  private static NISuppressee suppressee = new NISuppressee(LogicalXorLong_yxz.class, 3);
8961
8962  // suppressor definitions (used below)
8963  private static NISuppressor result_eq_arg1 =
8964      new NISuppressor(1, 0, IntEqual.class);
8965  private static NISuppressor result_eq_arg2 =
8966      new NISuppressor(1, 2, IntEqual.class);
8967  private static NISuppressor arg1_eq_arg2 =
8968      new NISuppressor(0, 2, IntEqual.class);
8969
8970  private static NISuppressor result_lt_arg1 =
8971      new NISuppressor(1, 0, IntLessThan.class);
8972  private static NISuppressor result_lt_arg2 =
8973      new NISuppressor(1, 2, IntLessThan.class);
8974  private static NISuppressor arg1_lt_arg2 =
8975      new NISuppressor(0, 2, IntLessThan.class);
8976  private static NISuppressor arg2_lt_arg1 =
8977      new NISuppressor(2, 0, IntLessThan.class);
8978
8979  private static NISuppressor result_le_arg1 =
8980      new NISuppressor(1, 0, IntLessEqual.class);
8981  private static NISuppressor result_le_arg2 =
8982      new NISuppressor(1, 2, IntLessEqual.class);
8983  private static NISuppressor arg1_le_arg2 =
8984      new NISuppressor(0, 2, IntLessEqual.class);
8985  private static NISuppressor arg2_le_arg1 =
8986      new NISuppressor(2, 0, IntLessEqual.class);
8987
8988  private static NISuppressor result_track0_arg1 =
8989      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
8990  private static NISuppressor result_track0_arg2 =
8991      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
8992  private static NISuppressor arg1_track0_arg2 =
8993      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
8994  private static NISuppressor arg1_track0_result =
8995      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
8996  private static NISuppressor arg2_track0_result =
8997      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
8998  private static NISuppressor arg2_track0_arg1 =
8999      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
9000
9001  private static NISuppressor result_eq_1 =
9002      new NISuppressor(1, RangeInt.EqualOne.class);
9003  private static NISuppressor arg1_eq_1 =
9004      new NISuppressor(0, RangeInt.EqualOne.class);
9005  private static NISuppressor arg2_eq_1 =
9006      new NISuppressor(2, RangeInt.EqualOne.class);
9007
9008  private static NISuppressor result_eq_0 =
9009      new NISuppressor(1, RangeInt.EqualZero.class);
9010  private static NISuppressor arg1_eq_0 =
9011      new NISuppressor(0, RangeInt.EqualZero.class);
9012  private static NISuppressor arg2_eq_0 =
9013      new NISuppressor(2, RangeInt.EqualZero.class);
9014
9015  private static NISuppressor result_ne_0 =
9016      new NISuppressor(1, NonZero.class);
9017  private static NISuppressor arg1_ne_0 =
9018      new NISuppressor(0, NonZero.class);
9019  private static NISuppressor arg2_ne_0 =
9020      new NISuppressor(2, NonZero.class);
9021
9022  private static NISuppressor result_ge_0 =
9023      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
9024  private static NISuppressor arg1_ge_0 =
9025      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
9026  private static NISuppressor arg2_ge_0 =
9027      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
9028
9029  private static NISuppressor result_ge_64 =
9030      new NISuppressor(1, RangeInt.GreaterEqual64.class);
9031  private static NISuppressor arg1_ge_64 =
9032      new NISuppressor(0, RangeInt.GreaterEqual64.class);
9033  private static NISuppressor arg2_ge_64 =
9034      new NISuppressor(2, RangeInt.GreaterEqual64.class);
9035
9036  private static NISuppressor result_boolean =
9037      new NISuppressor(1, RangeInt.BooleanVal.class);
9038  private static NISuppressor arg1_boolean =
9039      new NISuppressor(0, RangeInt.BooleanVal.class);
9040  private static NISuppressor arg2_boolean =
9041      new NISuppressor(2, RangeInt.BooleanVal.class);
9042
9043  private static NISuppressor result_even =
9044      new NISuppressor(1, RangeInt.Even.class);
9045  private static NISuppressor arg1_even =
9046      new NISuppressor(0, RangeInt.Even.class);
9047  private static NISuppressor arg2_even =
9048      new NISuppressor(2, RangeInt.Even.class);
9049
9050  private static NISuppressor result_power2 =
9051      new NISuppressor(1, RangeInt.PowerOfTwo.class);
9052  private static NISuppressor arg1_power2 =
9053      new NISuppressor(0, RangeInt.PowerOfTwo.class);
9054  private static NISuppressor arg2_power2 =
9055      new NISuppressor(2, RangeInt.PowerOfTwo.class);
9056
9057  private static NISuppressor result_and0_arg1 =
9058      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
9059  private static NISuppressor result_and0_arg2 =
9060      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
9061  private static NISuppressor arg1_and0_arg2 =
9062      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
9063
9064  // The arguments to bitwise subset are backwards from what one
9065  // might expect.  The second argument is a subset of the first
9066  // argument
9067  private static NISuppressor arg1_bw_subset_arg2 =
9068      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
9069  private static NISuppressor arg2_bw_subset_arg1 =
9070      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
9071
9072  private static NISuppressor result_shift0_arg1 =
9073      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
9074  private static NISuppressor result_shift0_arg2 =
9075      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
9076  private static NISuppressor arg1_shift0_arg2 =
9077      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
9078
9079  private static NISuppressor arg2_divides_arg1 =
9080      new NISuppressor(0, 2, NumericInt.Divides.class);
9081  private static NISuppressor arg1_divides_arg2 =
9082      new NISuppressor(2, 0, NumericInt.Divides.class);
9083
9084  private static NISuppressor arg2_valid_shift =
9085      new NISuppressor(2, RangeInt.Bound0_63.class);
9086
9087    private static NISuppressionSet suppressions =
9088        new NISuppressionSet(
9089          new NISuppression[] {
9090
9091            // (r == 0) && (x == z) && (x boolean) ==> r = x ^ z
9092            new NISuppression(arg1_eq_arg2, arg1_boolean, result_eq_0,
9093                               suppressee),
9094
9095            // (r == x) && (z == 0) && (y boolean) ==> r = x ^ z
9096            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_0,
9097                               suppressee),
9098
9099            // (r == z) && (x == 0) && (y boolean)==> r = x ^ z
9100            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_0,
9101                               suppressee),
9102
9103          });
9104
9105  // Create a suppression factory for functionBinary
9106
9107}
9108
9109/**
9110 * Represents the invariant {@code z = LogicalXor(x, y)} over three long
9111 * scalars. For logical operations, Daikon treats 0 as false and all other values as true.
9112 */
9113public static class LogicalXorLong_zxy extends FunctionBinary {
9114  // We are Serializable, so we specify a version to allow changes to
9115  // method signatures without breaking serialization.  If you add or
9116  // remove fields, you should change this number to the current date.
9117  static final long serialVersionUID = 20031030L;
9118
9119  private static @Prototype LogicalXorLong_zxy proto = new @Prototype LogicalXorLong_zxy ();
9120
9121  /** Returns the prototype invariant for LogicalXorLong_zxy */
9122  public static @Prototype LogicalXorLong_zxy get_proto() {
9123    return proto;
9124  }
9125
9126  /** instantiate an invariant on the specified slice */
9127  @Override
9128  protected LogicalXorLong_zxy instantiate_dyn(@Prototype LogicalXorLong_zxy this, PptSlice slice) {
9129    return new LogicalXorLong_zxy (slice);
9130  }
9131
9132  private LogicalXorLong_zxy (PptSlice slice) {
9133    super(slice);
9134  }
9135
9136  public @Prototype LogicalXorLong_zxy () {
9137    super();
9138  }
9139
9140  private static String[] method_name = new String[] {"org.plumelib.util.MathPlume.logicalXor(", ", ", ")"};
9141
9142  @Override
9143  public String[] get_method_name(@GuardSatisfied LogicalXorLong_zxy this) {
9144    return method_name;
9145  }
9146
9147  private static int function_id = -1;
9148
9149  @Override
9150  public int get_function_id() {
9151    return function_id;
9152  }
9153
9154  @Override
9155  public void set_function_id(int function_id) {
9156    assert LogicalXorLong_zxy.function_id == -1;
9157    LogicalXorLong_zxy.function_id = function_id;
9158  }
9159
9160  private static int var_order = 3;
9161
9162  @Override
9163  public int get_var_order(@GuardSatisfied LogicalXorLong_zxy this) {
9164    return var_order;
9165  }
9166
9167  @Pure
9168  @Override
9169  public boolean is_symmetric() {
9170
9171      return true;
9172  }
9173
9174  @Override
9175
9176  public long func(long x, long y) {
9177
9178      if ((x < 0) || (x > 1)) {
9179        throw new ArithmeticException("arg1 (" + x + ") is not boolean ");
9180      }
9181      if ((y < 0) || (y > 1)) {
9182        throw new ArithmeticException("arg2 (" + y + ") is not boolean ");
9183      }
9184
9185    return (((x != 0) ^ ( y != 0)) ? 1 : 0);
9186  }
9187
9188  @Override
9189  public InvariantStatus check_modified(long x, long y,
9190                                      long z, int count) {
9191    return check_ordered(z, x, y, count);
9192  }
9193
9194  @Override
9195  public InvariantStatus add_modified(long x, long y,
9196                                      long z, int count) {
9197    if (Debug.logDetail()) {
9198      log("result=%s, arg1=%s, arg2=%s", z, x, y);
9199    }
9200    return add_ordered(z, x, y, count);
9201  }
9202
9203  @Pure
9204  @Override
9205  public boolean isLogicalXor() {
9206    return true;
9207  }
9208
9209  /** Returns a list of non-instantiating suppressions for this invariant. */
9210  @Pure
9211  @Override
9212  public @Nullable NISuppressionSet get_ni_suppressions() {
9213    if (NIS.dkconfig_enabled && dkconfig_enabled) {
9214      return suppressions;
9215    } else {
9216      return null;
9217    }
9218  }
9219
9220  /** definition of this invariant (the suppressee) */
9221  private static NISuppressee suppressee = new NISuppressee(LogicalXorLong_zxy.class, 3);
9222
9223  // suppressor definitions (used below)
9224  private static NISuppressor result_eq_arg1 =
9225      new NISuppressor(2, 0, IntEqual.class);
9226  private static NISuppressor result_eq_arg2 =
9227      new NISuppressor(2, 1, IntEqual.class);
9228  private static NISuppressor arg1_eq_arg2 =
9229      new NISuppressor(0, 1, IntEqual.class);
9230
9231  private static NISuppressor result_lt_arg1 =
9232      new NISuppressor(2, 0, IntLessThan.class);
9233  private static NISuppressor result_lt_arg2 =
9234      new NISuppressor(2, 1, IntLessThan.class);
9235  private static NISuppressor arg1_lt_arg2 =
9236      new NISuppressor(0, 1, IntLessThan.class);
9237  private static NISuppressor arg2_lt_arg1 =
9238      new NISuppressor(1, 0, IntLessThan.class);
9239
9240  private static NISuppressor result_le_arg1 =
9241      new NISuppressor(2, 0, IntLessEqual.class);
9242  private static NISuppressor result_le_arg2 =
9243      new NISuppressor(2, 1, IntLessEqual.class);
9244  private static NISuppressor arg1_le_arg2 =
9245      new NISuppressor(0, 1, IntLessEqual.class);
9246  private static NISuppressor arg2_le_arg1 =
9247      new NISuppressor(1, 0, IntLessEqual.class);
9248
9249  private static NISuppressor result_track0_arg1 =
9250      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
9251  private static NISuppressor result_track0_arg2 =
9252      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
9253  private static NISuppressor arg1_track0_arg2 =
9254      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
9255  private static NISuppressor arg1_track0_result =
9256      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
9257  private static NISuppressor arg2_track0_result =
9258      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
9259  private static NISuppressor arg2_track0_arg1 =
9260      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
9261
9262  private static NISuppressor result_eq_1 =
9263      new NISuppressor(2, RangeInt.EqualOne.class);
9264  private static NISuppressor arg1_eq_1 =
9265      new NISuppressor(0, RangeInt.EqualOne.class);
9266  private static NISuppressor arg2_eq_1 =
9267      new NISuppressor(1, RangeInt.EqualOne.class);
9268
9269  private static NISuppressor result_eq_0 =
9270      new NISuppressor(2, RangeInt.EqualZero.class);
9271  private static NISuppressor arg1_eq_0 =
9272      new NISuppressor(0, RangeInt.EqualZero.class);
9273  private static NISuppressor arg2_eq_0 =
9274      new NISuppressor(1, RangeInt.EqualZero.class);
9275
9276  private static NISuppressor result_ne_0 =
9277      new NISuppressor(2, NonZero.class);
9278  private static NISuppressor arg1_ne_0 =
9279      new NISuppressor(0, NonZero.class);
9280  private static NISuppressor arg2_ne_0 =
9281      new NISuppressor(1, NonZero.class);
9282
9283  private static NISuppressor result_ge_0 =
9284      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
9285  private static NISuppressor arg1_ge_0 =
9286      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
9287  private static NISuppressor arg2_ge_0 =
9288      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
9289
9290  private static NISuppressor result_ge_64 =
9291      new NISuppressor(2, RangeInt.GreaterEqual64.class);
9292  private static NISuppressor arg1_ge_64 =
9293      new NISuppressor(0, RangeInt.GreaterEqual64.class);
9294  private static NISuppressor arg2_ge_64 =
9295      new NISuppressor(1, RangeInt.GreaterEqual64.class);
9296
9297  private static NISuppressor result_boolean =
9298      new NISuppressor(2, RangeInt.BooleanVal.class);
9299  private static NISuppressor arg1_boolean =
9300      new NISuppressor(0, RangeInt.BooleanVal.class);
9301  private static NISuppressor arg2_boolean =
9302      new NISuppressor(1, RangeInt.BooleanVal.class);
9303
9304  private static NISuppressor result_even =
9305      new NISuppressor(2, RangeInt.Even.class);
9306  private static NISuppressor arg1_even =
9307      new NISuppressor(0, RangeInt.Even.class);
9308  private static NISuppressor arg2_even =
9309      new NISuppressor(1, RangeInt.Even.class);
9310
9311  private static NISuppressor result_power2 =
9312      new NISuppressor(2, RangeInt.PowerOfTwo.class);
9313  private static NISuppressor arg1_power2 =
9314      new NISuppressor(0, RangeInt.PowerOfTwo.class);
9315  private static NISuppressor arg2_power2 =
9316      new NISuppressor(1, RangeInt.PowerOfTwo.class);
9317
9318  private static NISuppressor result_and0_arg1 =
9319      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
9320  private static NISuppressor result_and0_arg2 =
9321      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
9322  private static NISuppressor arg1_and0_arg2 =
9323      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
9324
9325  // The arguments to bitwise subset are backwards from what one
9326  // might expect.  The second argument is a subset of the first
9327  // argument
9328  private static NISuppressor arg1_bw_subset_arg2 =
9329      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
9330  private static NISuppressor arg2_bw_subset_arg1 =
9331      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
9332
9333  private static NISuppressor result_shift0_arg1 =
9334      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
9335  private static NISuppressor result_shift0_arg2 =
9336      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
9337  private static NISuppressor arg1_shift0_arg2 =
9338      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
9339
9340  private static NISuppressor arg2_divides_arg1 =
9341      new NISuppressor(0, 1, NumericInt.Divides.class);
9342  private static NISuppressor arg1_divides_arg2 =
9343      new NISuppressor(1, 0, NumericInt.Divides.class);
9344
9345  private static NISuppressor arg2_valid_shift =
9346      new NISuppressor(1, RangeInt.Bound0_63.class);
9347
9348    private static NISuppressionSet suppressions =
9349        new NISuppressionSet(
9350          new NISuppression[] {
9351
9352            // (r == 0) && (x == y) && (x boolean) ==> r = x ^ y
9353            new NISuppression(arg1_eq_arg2, arg1_boolean, result_eq_0,
9354                               suppressee),
9355
9356            // (r == x) && (y == 0) && (z boolean) ==> r = x ^ y
9357            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_0,
9358                               suppressee),
9359
9360            // (r == y) && (x == 0) && (z boolean)==> r = x ^ y
9361            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_0,
9362                               suppressee),
9363
9364          });
9365
9366  // Create a suppression factory for functionBinary
9367
9368}
9369
9370  // #define EQUALITY_SUPPRESS 1
9371
9372  // default is that it is not this function, overriden in the subclass
9373  @Pure
9374  public boolean isBitwiseOr() {
9375    return false;
9376  }
9377
9378/**
9379 * Represents the invariant {@code x = BitwiseOr(y, z)} over three long
9380 * scalars. 
9381 */
9382public static class BitwiseOrLong_xyz extends FunctionBinary {
9383  // We are Serializable, so we specify a version to allow changes to
9384  // method signatures without breaking serialization.  If you add or
9385  // remove fields, you should change this number to the current date.
9386  static final long serialVersionUID = 20031030L;
9387
9388  private static @Prototype BitwiseOrLong_xyz proto = new @Prototype BitwiseOrLong_xyz ();
9389
9390  /** Returns the prototype invariant for BitwiseOrLong_xyz */
9391  public static @Prototype BitwiseOrLong_xyz get_proto() {
9392    return proto;
9393  }
9394
9395  /** instantiate an invariant on the specified slice */
9396  @Override
9397  protected BitwiseOrLong_xyz instantiate_dyn(@Prototype BitwiseOrLong_xyz this, PptSlice slice) {
9398    return new BitwiseOrLong_xyz (slice);
9399  }
9400
9401  private BitwiseOrLong_xyz (PptSlice slice) {
9402    super(slice);
9403  }
9404
9405  public @Prototype BitwiseOrLong_xyz () {
9406    super();
9407  }
9408
9409  private static String[] method_name = new String[] {"", " | ", ""};
9410
9411  @Override
9412  public String[] get_method_name(@GuardSatisfied BitwiseOrLong_xyz this) {
9413    return method_name;
9414  }
9415
9416  private static int function_id = -1;
9417
9418  @Override
9419  public int get_function_id() {
9420    return function_id;
9421  }
9422
9423  @Override
9424  public void set_function_id(int function_id) {
9425    assert BitwiseOrLong_xyz.function_id == -1;
9426    BitwiseOrLong_xyz.function_id = function_id;
9427  }
9428
9429  private static int var_order = 1;
9430
9431  @Override
9432  public int get_var_order(@GuardSatisfied BitwiseOrLong_xyz this) {
9433    return var_order;
9434  }
9435
9436  @Pure
9437  @Override
9438  public boolean is_symmetric() {
9439
9440      return true;
9441  }
9442
9443  @Override
9444
9445  public long func(long y, long z) {
9446
9447    return (y | z);
9448  }
9449
9450  @Override
9451  public InvariantStatus check_modified(long x, long y,
9452                                      long z, int count) {
9453    return check_ordered(x, y, z, count);
9454  }
9455
9456  @Override
9457  public InvariantStatus add_modified(long x, long y,
9458                                      long z, int count) {
9459    if (Debug.logDetail()) {
9460      log("result=%s, arg1=%s, arg2=%s", x, y, z);
9461    }
9462    return add_ordered(x, y, z, count);
9463  }
9464
9465  @Pure
9466  @Override
9467  public boolean isBitwiseOr() {
9468    return true;
9469  }
9470
9471  /** Returns a list of non-instantiating suppressions for this invariant. */
9472  @Pure
9473  @Override
9474  public @Nullable NISuppressionSet get_ni_suppressions() {
9475    if (NIS.dkconfig_enabled && dkconfig_enabled) {
9476      return suppressions;
9477    } else {
9478      return null;
9479    }
9480  }
9481
9482  /** definition of this invariant (the suppressee) */
9483  private static NISuppressee suppressee = new NISuppressee(BitwiseOrLong_xyz.class, 3);
9484
9485  // suppressor definitions (used below)
9486  private static NISuppressor result_eq_arg1 =
9487      new NISuppressor(0, 1, IntEqual.class);
9488  private static NISuppressor result_eq_arg2 =
9489      new NISuppressor(0, 2, IntEqual.class);
9490  private static NISuppressor arg1_eq_arg2 =
9491      new NISuppressor(1, 2, IntEqual.class);
9492
9493  private static NISuppressor result_lt_arg1 =
9494      new NISuppressor(0, 1, IntLessThan.class);
9495  private static NISuppressor result_lt_arg2 =
9496      new NISuppressor(0, 2, IntLessThan.class);
9497  private static NISuppressor arg1_lt_arg2 =
9498      new NISuppressor(1, 2, IntLessThan.class);
9499  private static NISuppressor arg2_lt_arg1 =
9500      new NISuppressor(2, 1, IntLessThan.class);
9501
9502  private static NISuppressor result_le_arg1 =
9503      new NISuppressor(0, 1, IntLessEqual.class);
9504  private static NISuppressor result_le_arg2 =
9505      new NISuppressor(0, 2, IntLessEqual.class);
9506  private static NISuppressor arg1_le_arg2 =
9507      new NISuppressor(1, 2, IntLessEqual.class);
9508  private static NISuppressor arg2_le_arg1 =
9509      new NISuppressor(2, 1, IntLessEqual.class);
9510
9511  private static NISuppressor result_track0_arg1 =
9512      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
9513  private static NISuppressor result_track0_arg2 =
9514      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
9515  private static NISuppressor arg1_track0_arg2 =
9516      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
9517  private static NISuppressor arg1_track0_result =
9518      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
9519  private static NISuppressor arg2_track0_result =
9520      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
9521  private static NISuppressor arg2_track0_arg1 =
9522      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
9523
9524  private static NISuppressor result_eq_1 =
9525      new NISuppressor(0, RangeInt.EqualOne.class);
9526  private static NISuppressor arg1_eq_1 =
9527      new NISuppressor(1, RangeInt.EqualOne.class);
9528  private static NISuppressor arg2_eq_1 =
9529      new NISuppressor(2, RangeInt.EqualOne.class);
9530
9531  private static NISuppressor result_eq_0 =
9532      new NISuppressor(0, RangeInt.EqualZero.class);
9533  private static NISuppressor arg1_eq_0 =
9534      new NISuppressor(1, RangeInt.EqualZero.class);
9535  private static NISuppressor arg2_eq_0 =
9536      new NISuppressor(2, RangeInt.EqualZero.class);
9537
9538  private static NISuppressor result_ne_0 =
9539      new NISuppressor(0, NonZero.class);
9540  private static NISuppressor arg1_ne_0 =
9541      new NISuppressor(1, NonZero.class);
9542  private static NISuppressor arg2_ne_0 =
9543      new NISuppressor(2, NonZero.class);
9544
9545  private static NISuppressor result_ge_0 =
9546      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
9547  private static NISuppressor arg1_ge_0 =
9548      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
9549  private static NISuppressor arg2_ge_0 =
9550      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
9551
9552  private static NISuppressor result_ge_64 =
9553      new NISuppressor(0, RangeInt.GreaterEqual64.class);
9554  private static NISuppressor arg1_ge_64 =
9555      new NISuppressor(1, RangeInt.GreaterEqual64.class);
9556  private static NISuppressor arg2_ge_64 =
9557      new NISuppressor(2, RangeInt.GreaterEqual64.class);
9558
9559  private static NISuppressor result_boolean =
9560      new NISuppressor(0, RangeInt.BooleanVal.class);
9561  private static NISuppressor arg1_boolean =
9562      new NISuppressor(1, RangeInt.BooleanVal.class);
9563  private static NISuppressor arg2_boolean =
9564      new NISuppressor(2, RangeInt.BooleanVal.class);
9565
9566  private static NISuppressor result_even =
9567      new NISuppressor(0, RangeInt.Even.class);
9568  private static NISuppressor arg1_even =
9569      new NISuppressor(1, RangeInt.Even.class);
9570  private static NISuppressor arg2_even =
9571      new NISuppressor(2, RangeInt.Even.class);
9572
9573  private static NISuppressor result_power2 =
9574      new NISuppressor(0, RangeInt.PowerOfTwo.class);
9575  private static NISuppressor arg1_power2 =
9576      new NISuppressor(1, RangeInt.PowerOfTwo.class);
9577  private static NISuppressor arg2_power2 =
9578      new NISuppressor(2, RangeInt.PowerOfTwo.class);
9579
9580  private static NISuppressor result_and0_arg1 =
9581      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
9582  private static NISuppressor result_and0_arg2 =
9583      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
9584  private static NISuppressor arg1_and0_arg2 =
9585      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
9586
9587  // The arguments to bitwise subset are backwards from what one
9588  // might expect.  The second argument is a subset of the first
9589  // argument
9590  private static NISuppressor arg1_bw_subset_arg2 =
9591      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
9592  private static NISuppressor arg2_bw_subset_arg1 =
9593      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
9594
9595  private static NISuppressor result_shift0_arg1 =
9596      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
9597  private static NISuppressor result_shift0_arg2 =
9598      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
9599  private static NISuppressor arg1_shift0_arg2 =
9600      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
9601
9602  private static NISuppressor arg2_divides_arg1 =
9603      new NISuppressor(1, 2, NumericInt.Divides.class);
9604  private static NISuppressor arg1_divides_arg2 =
9605      new NISuppressor(2, 1, NumericInt.Divides.class);
9606
9607  private static NISuppressor arg2_valid_shift =
9608      new NISuppressor(2, RangeInt.Bound0_63.class);
9609
9610    private static NISuppressionSet suppressions =
9611        new NISuppressionSet(
9612          new NISuppression[] {
9613
9614            // (r == y) && (z bitwise subset y)
9615            new NISuppression(result_eq_arg1, arg2_bw_subset_arg1, suppressee),
9616
9617            // (r == z) && (y bitwise subset z)
9618            new NISuppression(result_eq_arg2, arg1_bw_subset_arg2, suppressee),
9619
9620            // All of the below are subsummed by the two above
9621            // (r == y) && (y == z) ==> r = y | z
9622            // new NISuppression (result_eq_arg1, arg1_eq_arg2, suppressee),
9623
9624            // (r == y) && (z == 0) ==> r = y | z
9625            // new NISuppression (result_eq_arg1, arg2_eq_0, suppressee),
9626
9627            // (r == z) && (y == 0) ==> r = y | z
9628            // new NISuppression (result_eq_arg2, arg1_eq_0, suppressee),
9629
9630            // (r == 1) && (y == 1) && (z boolean)
9631            // new NISuppression (result_eq_1, arg1_eq_1, arg2_boolean, suppressee),
9632
9633            // (r == 1) && (z == 1) && (y boolean)
9634            // new NISuppression (result_eq_1, arg2_eq_1, arg1_boolean, suppressee),
9635
9636          });
9637
9638  // Create a suppression factory for functionBinary
9639
9640}
9641
9642/**
9643 * Represents the invariant {@code y = BitwiseOr(x, z)} over three long
9644 * scalars. 
9645 */
9646public static class BitwiseOrLong_yxz extends FunctionBinary {
9647  // We are Serializable, so we specify a version to allow changes to
9648  // method signatures without breaking serialization.  If you add or
9649  // remove fields, you should change this number to the current date.
9650  static final long serialVersionUID = 20031030L;
9651
9652  private static @Prototype BitwiseOrLong_yxz proto = new @Prototype BitwiseOrLong_yxz ();
9653
9654  /** Returns the prototype invariant for BitwiseOrLong_yxz */
9655  public static @Prototype BitwiseOrLong_yxz get_proto() {
9656    return proto;
9657  }
9658
9659  /** instantiate an invariant on the specified slice */
9660  @Override
9661  protected BitwiseOrLong_yxz instantiate_dyn(@Prototype BitwiseOrLong_yxz this, PptSlice slice) {
9662    return new BitwiseOrLong_yxz (slice);
9663  }
9664
9665  private BitwiseOrLong_yxz (PptSlice slice) {
9666    super(slice);
9667  }
9668
9669  public @Prototype BitwiseOrLong_yxz () {
9670    super();
9671  }
9672
9673  private static String[] method_name = new String[] {"", " | ", ""};
9674
9675  @Override
9676  public String[] get_method_name(@GuardSatisfied BitwiseOrLong_yxz this) {
9677    return method_name;
9678  }
9679
9680  private static int function_id = -1;
9681
9682  @Override
9683  public int get_function_id() {
9684    return function_id;
9685  }
9686
9687  @Override
9688  public void set_function_id(int function_id) {
9689    assert BitwiseOrLong_yxz.function_id == -1;
9690    BitwiseOrLong_yxz.function_id = function_id;
9691  }
9692
9693  private static int var_order = 2;
9694
9695  @Override
9696  public int get_var_order(@GuardSatisfied BitwiseOrLong_yxz this) {
9697    return var_order;
9698  }
9699
9700  @Pure
9701  @Override
9702  public boolean is_symmetric() {
9703
9704      return true;
9705  }
9706
9707  @Override
9708
9709  public long func(long x, long z) {
9710
9711    return (x | z);
9712  }
9713
9714  @Override
9715  public InvariantStatus check_modified(long x, long y,
9716                                      long z, int count) {
9717    return check_ordered(y, x, z, count);
9718  }
9719
9720  @Override
9721  public InvariantStatus add_modified(long x, long y,
9722                                      long z, int count) {
9723    if (Debug.logDetail()) {
9724      log("result=%s, arg1=%s, arg2=%s", y, x, z);
9725    }
9726    return add_ordered(y, x, z, count);
9727  }
9728
9729  @Pure
9730  @Override
9731  public boolean isBitwiseOr() {
9732    return true;
9733  }
9734
9735  /** Returns a list of non-instantiating suppressions for this invariant. */
9736  @Pure
9737  @Override
9738  public @Nullable NISuppressionSet get_ni_suppressions() {
9739    if (NIS.dkconfig_enabled && dkconfig_enabled) {
9740      return suppressions;
9741    } else {
9742      return null;
9743    }
9744  }
9745
9746  /** definition of this invariant (the suppressee) */
9747  private static NISuppressee suppressee = new NISuppressee(BitwiseOrLong_yxz.class, 3);
9748
9749  // suppressor definitions (used below)
9750  private static NISuppressor result_eq_arg1 =
9751      new NISuppressor(1, 0, IntEqual.class);
9752  private static NISuppressor result_eq_arg2 =
9753      new NISuppressor(1, 2, IntEqual.class);
9754  private static NISuppressor arg1_eq_arg2 =
9755      new NISuppressor(0, 2, IntEqual.class);
9756
9757  private static NISuppressor result_lt_arg1 =
9758      new NISuppressor(1, 0, IntLessThan.class);
9759  private static NISuppressor result_lt_arg2 =
9760      new NISuppressor(1, 2, IntLessThan.class);
9761  private static NISuppressor arg1_lt_arg2 =
9762      new NISuppressor(0, 2, IntLessThan.class);
9763  private static NISuppressor arg2_lt_arg1 =
9764      new NISuppressor(2, 0, IntLessThan.class);
9765
9766  private static NISuppressor result_le_arg1 =
9767      new NISuppressor(1, 0, IntLessEqual.class);
9768  private static NISuppressor result_le_arg2 =
9769      new NISuppressor(1, 2, IntLessEqual.class);
9770  private static NISuppressor arg1_le_arg2 =
9771      new NISuppressor(0, 2, IntLessEqual.class);
9772  private static NISuppressor arg2_le_arg1 =
9773      new NISuppressor(2, 0, IntLessEqual.class);
9774
9775  private static NISuppressor result_track0_arg1 =
9776      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
9777  private static NISuppressor result_track0_arg2 =
9778      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
9779  private static NISuppressor arg1_track0_arg2 =
9780      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
9781  private static NISuppressor arg1_track0_result =
9782      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
9783  private static NISuppressor arg2_track0_result =
9784      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
9785  private static NISuppressor arg2_track0_arg1 =
9786      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
9787
9788  private static NISuppressor result_eq_1 =
9789      new NISuppressor(1, RangeInt.EqualOne.class);
9790  private static NISuppressor arg1_eq_1 =
9791      new NISuppressor(0, RangeInt.EqualOne.class);
9792  private static NISuppressor arg2_eq_1 =
9793      new NISuppressor(2, RangeInt.EqualOne.class);
9794
9795  private static NISuppressor result_eq_0 =
9796      new NISuppressor(1, RangeInt.EqualZero.class);
9797  private static NISuppressor arg1_eq_0 =
9798      new NISuppressor(0, RangeInt.EqualZero.class);
9799  private static NISuppressor arg2_eq_0 =
9800      new NISuppressor(2, RangeInt.EqualZero.class);
9801
9802  private static NISuppressor result_ne_0 =
9803      new NISuppressor(1, NonZero.class);
9804  private static NISuppressor arg1_ne_0 =
9805      new NISuppressor(0, NonZero.class);
9806  private static NISuppressor arg2_ne_0 =
9807      new NISuppressor(2, NonZero.class);
9808
9809  private static NISuppressor result_ge_0 =
9810      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
9811  private static NISuppressor arg1_ge_0 =
9812      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
9813  private static NISuppressor arg2_ge_0 =
9814      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
9815
9816  private static NISuppressor result_ge_64 =
9817      new NISuppressor(1, RangeInt.GreaterEqual64.class);
9818  private static NISuppressor arg1_ge_64 =
9819      new NISuppressor(0, RangeInt.GreaterEqual64.class);
9820  private static NISuppressor arg2_ge_64 =
9821      new NISuppressor(2, RangeInt.GreaterEqual64.class);
9822
9823  private static NISuppressor result_boolean =
9824      new NISuppressor(1, RangeInt.BooleanVal.class);
9825  private static NISuppressor arg1_boolean =
9826      new NISuppressor(0, RangeInt.BooleanVal.class);
9827  private static NISuppressor arg2_boolean =
9828      new NISuppressor(2, RangeInt.BooleanVal.class);
9829
9830  private static NISuppressor result_even =
9831      new NISuppressor(1, RangeInt.Even.class);
9832  private static NISuppressor arg1_even =
9833      new NISuppressor(0, RangeInt.Even.class);
9834  private static NISuppressor arg2_even =
9835      new NISuppressor(2, RangeInt.Even.class);
9836
9837  private static NISuppressor result_power2 =
9838      new NISuppressor(1, RangeInt.PowerOfTwo.class);
9839  private static NISuppressor arg1_power2 =
9840      new NISuppressor(0, RangeInt.PowerOfTwo.class);
9841  private static NISuppressor arg2_power2 =
9842      new NISuppressor(2, RangeInt.PowerOfTwo.class);
9843
9844  private static NISuppressor result_and0_arg1 =
9845      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
9846  private static NISuppressor result_and0_arg2 =
9847      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
9848  private static NISuppressor arg1_and0_arg2 =
9849      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
9850
9851  // The arguments to bitwise subset are backwards from what one
9852  // might expect.  The second argument is a subset of the first
9853  // argument
9854  private static NISuppressor arg1_bw_subset_arg2 =
9855      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
9856  private static NISuppressor arg2_bw_subset_arg1 =
9857      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
9858
9859  private static NISuppressor result_shift0_arg1 =
9860      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
9861  private static NISuppressor result_shift0_arg2 =
9862      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
9863  private static NISuppressor arg1_shift0_arg2 =
9864      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
9865
9866  private static NISuppressor arg2_divides_arg1 =
9867      new NISuppressor(0, 2, NumericInt.Divides.class);
9868  private static NISuppressor arg1_divides_arg2 =
9869      new NISuppressor(2, 0, NumericInt.Divides.class);
9870
9871  private static NISuppressor arg2_valid_shift =
9872      new NISuppressor(2, RangeInt.Bound0_63.class);
9873
9874    private static NISuppressionSet suppressions =
9875        new NISuppressionSet(
9876          new NISuppression[] {
9877
9878            // (r == x) && (z bitwise subset x)
9879            new NISuppression(result_eq_arg1, arg2_bw_subset_arg1, suppressee),
9880
9881            // (r == z) && (x bitwise subset z)
9882            new NISuppression(result_eq_arg2, arg1_bw_subset_arg2, suppressee),
9883
9884            // All of the below are subsummed by the two above
9885            // (r == x) && (x == z) ==> r = x | z
9886            // new NISuppression (result_eq_arg1, arg1_eq_arg2, suppressee),
9887
9888            // (r == x) && (z == 0) ==> r = x | z
9889            // new NISuppression (result_eq_arg1, arg2_eq_0, suppressee),
9890
9891            // (r == z) && (x == 0) ==> r = x | z
9892            // new NISuppression (result_eq_arg2, arg1_eq_0, suppressee),
9893
9894            // (r == 1) && (x == 1) && (z boolean)
9895            // new NISuppression (result_eq_1, arg1_eq_1, arg2_boolean, suppressee),
9896
9897            // (r == 1) && (z == 1) && (x boolean)
9898            // new NISuppression (result_eq_1, arg2_eq_1, arg1_boolean, suppressee),
9899
9900          });
9901
9902  // Create a suppression factory for functionBinary
9903
9904}
9905
9906/**
9907 * Represents the invariant {@code z = BitwiseOr(x, y)} over three long
9908 * scalars. 
9909 */
9910public static class BitwiseOrLong_zxy extends FunctionBinary {
9911  // We are Serializable, so we specify a version to allow changes to
9912  // method signatures without breaking serialization.  If you add or
9913  // remove fields, you should change this number to the current date.
9914  static final long serialVersionUID = 20031030L;
9915
9916  private static @Prototype BitwiseOrLong_zxy proto = new @Prototype BitwiseOrLong_zxy ();
9917
9918  /** Returns the prototype invariant for BitwiseOrLong_zxy */
9919  public static @Prototype BitwiseOrLong_zxy get_proto() {
9920    return proto;
9921  }
9922
9923  /** instantiate an invariant on the specified slice */
9924  @Override
9925  protected BitwiseOrLong_zxy instantiate_dyn(@Prototype BitwiseOrLong_zxy this, PptSlice slice) {
9926    return new BitwiseOrLong_zxy (slice);
9927  }
9928
9929  private BitwiseOrLong_zxy (PptSlice slice) {
9930    super(slice);
9931  }
9932
9933  public @Prototype BitwiseOrLong_zxy () {
9934    super();
9935  }
9936
9937  private static String[] method_name = new String[] {"", " | ", ""};
9938
9939  @Override
9940  public String[] get_method_name(@GuardSatisfied BitwiseOrLong_zxy this) {
9941    return method_name;
9942  }
9943
9944  private static int function_id = -1;
9945
9946  @Override
9947  public int get_function_id() {
9948    return function_id;
9949  }
9950
9951  @Override
9952  public void set_function_id(int function_id) {
9953    assert BitwiseOrLong_zxy.function_id == -1;
9954    BitwiseOrLong_zxy.function_id = function_id;
9955  }
9956
9957  private static int var_order = 3;
9958
9959  @Override
9960  public int get_var_order(@GuardSatisfied BitwiseOrLong_zxy this) {
9961    return var_order;
9962  }
9963
9964  @Pure
9965  @Override
9966  public boolean is_symmetric() {
9967
9968      return true;
9969  }
9970
9971  @Override
9972
9973  public long func(long x, long y) {
9974
9975    return (x | y);
9976  }
9977
9978  @Override
9979  public InvariantStatus check_modified(long x, long y,
9980                                      long z, int count) {
9981    return check_ordered(z, x, y, count);
9982  }
9983
9984  @Override
9985  public InvariantStatus add_modified(long x, long y,
9986                                      long z, int count) {
9987    if (Debug.logDetail()) {
9988      log("result=%s, arg1=%s, arg2=%s", z, x, y);
9989    }
9990    return add_ordered(z, x, y, count);
9991  }
9992
9993  @Pure
9994  @Override
9995  public boolean isBitwiseOr() {
9996    return true;
9997  }
9998
9999  /** Returns a list of non-instantiating suppressions for this invariant. */
10000  @Pure
10001  @Override
10002  public @Nullable NISuppressionSet get_ni_suppressions() {
10003    if (NIS.dkconfig_enabled && dkconfig_enabled) {
10004      return suppressions;
10005    } else {
10006      return null;
10007    }
10008  }
10009
10010  /** definition of this invariant (the suppressee) */
10011  private static NISuppressee suppressee = new NISuppressee(BitwiseOrLong_zxy.class, 3);
10012
10013  // suppressor definitions (used below)
10014  private static NISuppressor result_eq_arg1 =
10015      new NISuppressor(2, 0, IntEqual.class);
10016  private static NISuppressor result_eq_arg2 =
10017      new NISuppressor(2, 1, IntEqual.class);
10018  private static NISuppressor arg1_eq_arg2 =
10019      new NISuppressor(0, 1, IntEqual.class);
10020
10021  private static NISuppressor result_lt_arg1 =
10022      new NISuppressor(2, 0, IntLessThan.class);
10023  private static NISuppressor result_lt_arg2 =
10024      new NISuppressor(2, 1, IntLessThan.class);
10025  private static NISuppressor arg1_lt_arg2 =
10026      new NISuppressor(0, 1, IntLessThan.class);
10027  private static NISuppressor arg2_lt_arg1 =
10028      new NISuppressor(1, 0, IntLessThan.class);
10029
10030  private static NISuppressor result_le_arg1 =
10031      new NISuppressor(2, 0, IntLessEqual.class);
10032  private static NISuppressor result_le_arg2 =
10033      new NISuppressor(2, 1, IntLessEqual.class);
10034  private static NISuppressor arg1_le_arg2 =
10035      new NISuppressor(0, 1, IntLessEqual.class);
10036  private static NISuppressor arg2_le_arg1 =
10037      new NISuppressor(1, 0, IntLessEqual.class);
10038
10039  private static NISuppressor result_track0_arg1 =
10040      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
10041  private static NISuppressor result_track0_arg2 =
10042      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
10043  private static NISuppressor arg1_track0_arg2 =
10044      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
10045  private static NISuppressor arg1_track0_result =
10046      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
10047  private static NISuppressor arg2_track0_result =
10048      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
10049  private static NISuppressor arg2_track0_arg1 =
10050      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
10051
10052  private static NISuppressor result_eq_1 =
10053      new NISuppressor(2, RangeInt.EqualOne.class);
10054  private static NISuppressor arg1_eq_1 =
10055      new NISuppressor(0, RangeInt.EqualOne.class);
10056  private static NISuppressor arg2_eq_1 =
10057      new NISuppressor(1, RangeInt.EqualOne.class);
10058
10059  private static NISuppressor result_eq_0 =
10060      new NISuppressor(2, RangeInt.EqualZero.class);
10061  private static NISuppressor arg1_eq_0 =
10062      new NISuppressor(0, RangeInt.EqualZero.class);
10063  private static NISuppressor arg2_eq_0 =
10064      new NISuppressor(1, RangeInt.EqualZero.class);
10065
10066  private static NISuppressor result_ne_0 =
10067      new NISuppressor(2, NonZero.class);
10068  private static NISuppressor arg1_ne_0 =
10069      new NISuppressor(0, NonZero.class);
10070  private static NISuppressor arg2_ne_0 =
10071      new NISuppressor(1, NonZero.class);
10072
10073  private static NISuppressor result_ge_0 =
10074      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
10075  private static NISuppressor arg1_ge_0 =
10076      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
10077  private static NISuppressor arg2_ge_0 =
10078      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
10079
10080  private static NISuppressor result_ge_64 =
10081      new NISuppressor(2, RangeInt.GreaterEqual64.class);
10082  private static NISuppressor arg1_ge_64 =
10083      new NISuppressor(0, RangeInt.GreaterEqual64.class);
10084  private static NISuppressor arg2_ge_64 =
10085      new NISuppressor(1, RangeInt.GreaterEqual64.class);
10086
10087  private static NISuppressor result_boolean =
10088      new NISuppressor(2, RangeInt.BooleanVal.class);
10089  private static NISuppressor arg1_boolean =
10090      new NISuppressor(0, RangeInt.BooleanVal.class);
10091  private static NISuppressor arg2_boolean =
10092      new NISuppressor(1, RangeInt.BooleanVal.class);
10093
10094  private static NISuppressor result_even =
10095      new NISuppressor(2, RangeInt.Even.class);
10096  private static NISuppressor arg1_even =
10097      new NISuppressor(0, RangeInt.Even.class);
10098  private static NISuppressor arg2_even =
10099      new NISuppressor(1, RangeInt.Even.class);
10100
10101  private static NISuppressor result_power2 =
10102      new NISuppressor(2, RangeInt.PowerOfTwo.class);
10103  private static NISuppressor arg1_power2 =
10104      new NISuppressor(0, RangeInt.PowerOfTwo.class);
10105  private static NISuppressor arg2_power2 =
10106      new NISuppressor(1, RangeInt.PowerOfTwo.class);
10107
10108  private static NISuppressor result_and0_arg1 =
10109      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
10110  private static NISuppressor result_and0_arg2 =
10111      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
10112  private static NISuppressor arg1_and0_arg2 =
10113      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
10114
10115  // The arguments to bitwise subset are backwards from what one
10116  // might expect.  The second argument is a subset of the first
10117  // argument
10118  private static NISuppressor arg1_bw_subset_arg2 =
10119      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
10120  private static NISuppressor arg2_bw_subset_arg1 =
10121      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
10122
10123  private static NISuppressor result_shift0_arg1 =
10124      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
10125  private static NISuppressor result_shift0_arg2 =
10126      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
10127  private static NISuppressor arg1_shift0_arg2 =
10128      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
10129
10130  private static NISuppressor arg2_divides_arg1 =
10131      new NISuppressor(0, 1, NumericInt.Divides.class);
10132  private static NISuppressor arg1_divides_arg2 =
10133      new NISuppressor(1, 0, NumericInt.Divides.class);
10134
10135  private static NISuppressor arg2_valid_shift =
10136      new NISuppressor(1, RangeInt.Bound0_63.class);
10137
10138    private static NISuppressionSet suppressions =
10139        new NISuppressionSet(
10140          new NISuppression[] {
10141
10142            // (r == x) && (y bitwise subset x)
10143            new NISuppression(result_eq_arg1, arg2_bw_subset_arg1, suppressee),
10144
10145            // (r == y) && (x bitwise subset y)
10146            new NISuppression(result_eq_arg2, arg1_bw_subset_arg2, suppressee),
10147
10148            // All of the below are subsummed by the two above
10149            // (r == x) && (x == y) ==> r = x | y
10150            // new NISuppression (result_eq_arg1, arg1_eq_arg2, suppressee),
10151
10152            // (r == x) && (y == 0) ==> r = x | y
10153            // new NISuppression (result_eq_arg1, arg2_eq_0, suppressee),
10154
10155            // (r == y) && (x == 0) ==> r = x | y
10156            // new NISuppression (result_eq_arg2, arg1_eq_0, suppressee),
10157
10158            // (r == 1) && (x == 1) && (y boolean)
10159            // new NISuppression (result_eq_1, arg1_eq_1, arg2_boolean, suppressee),
10160
10161            // (r == 1) && (y == 1) && (x boolean)
10162            // new NISuppression (result_eq_1, arg2_eq_1, arg1_boolean, suppressee),
10163
10164          });
10165
10166  // Create a suppression factory for functionBinary
10167
10168}
10169
10170  // default is that it is not this function, overriden in the subclass
10171  @Pure
10172  public boolean isLogicalOr() {
10173    return false;
10174  }
10175
10176/**
10177 * Represents the invariant {@code x = LogicalOr(y, z)} over three long
10178 * scalars. For logical operations, Daikon treats 0 as false and all other values as true.
10179 */
10180public static class LogicalOrLong_xyz extends FunctionBinary {
10181  // We are Serializable, so we specify a version to allow changes to
10182  // method signatures without breaking serialization.  If you add or
10183  // remove fields, you should change this number to the current date.
10184  static final long serialVersionUID = 20031030L;
10185
10186  private static @Prototype LogicalOrLong_xyz proto = new @Prototype LogicalOrLong_xyz ();
10187
10188  /** Returns the prototype invariant for LogicalOrLong_xyz */
10189  public static @Prototype LogicalOrLong_xyz get_proto() {
10190    return proto;
10191  }
10192
10193  /** instantiate an invariant on the specified slice */
10194  @Override
10195  protected LogicalOrLong_xyz instantiate_dyn(@Prototype LogicalOrLong_xyz this, PptSlice slice) {
10196    return new LogicalOrLong_xyz (slice);
10197  }
10198
10199  private LogicalOrLong_xyz (PptSlice slice) {
10200    super(slice);
10201  }
10202
10203  public @Prototype LogicalOrLong_xyz () {
10204    super();
10205  }
10206
10207  private static String[] method_name = new String[] {"", " || ", ""};
10208
10209  @Override
10210  public String[] get_method_name(@GuardSatisfied LogicalOrLong_xyz this) {
10211    return method_name;
10212  }
10213
10214  private static int function_id = -1;
10215
10216  @Override
10217  public int get_function_id() {
10218    return function_id;
10219  }
10220
10221  @Override
10222  public void set_function_id(int function_id) {
10223    assert LogicalOrLong_xyz.function_id == -1;
10224    LogicalOrLong_xyz.function_id = function_id;
10225  }
10226
10227  private static int var_order = 1;
10228
10229  @Override
10230  public int get_var_order(@GuardSatisfied LogicalOrLong_xyz this) {
10231    return var_order;
10232  }
10233
10234  @Pure
10235  @Override
10236  public boolean is_symmetric() {
10237
10238      return true;
10239  }
10240
10241  @Override
10242
10243  public long func(long y, long z) {
10244
10245      if ((y < 0) || (y > 1)) {
10246        throw new ArithmeticException("arg1 (" + y + ") is not boolean ");
10247      }
10248      if ((z < 0) || (z > 1)) {
10249        throw new ArithmeticException("arg2 (" + z + ") is not boolean ");
10250      }
10251
10252    return (((y != 0) || ( z != 0)) ? 1 : 0);
10253  }
10254
10255  @Override
10256  public InvariantStatus check_modified(long x, long y,
10257                                      long z, int count) {
10258    return check_ordered(x, y, z, count);
10259  }
10260
10261  @Override
10262  public InvariantStatus add_modified(long x, long y,
10263                                      long z, int count) {
10264    if (Debug.logDetail()) {
10265      log("result=%s, arg1=%s, arg2=%s", x, y, z);
10266    }
10267    return add_ordered(x, y, z, count);
10268  }
10269
10270  @Pure
10271  @Override
10272  public boolean isLogicalOr() {
10273    return true;
10274  }
10275
10276  /** Returns a list of non-instantiating suppressions for this invariant. */
10277  @Pure
10278  @Override
10279  public @Nullable NISuppressionSet get_ni_suppressions() {
10280    if (NIS.dkconfig_enabled && dkconfig_enabled) {
10281      return suppressions;
10282    } else {
10283      return null;
10284    }
10285  }
10286
10287  /** definition of this invariant (the suppressee) */
10288  private static NISuppressee suppressee = new NISuppressee(LogicalOrLong_xyz.class, 3);
10289
10290  // suppressor definitions (used below)
10291  private static NISuppressor result_eq_arg1 =
10292      new NISuppressor(0, 1, IntEqual.class);
10293  private static NISuppressor result_eq_arg2 =
10294      new NISuppressor(0, 2, IntEqual.class);
10295  private static NISuppressor arg1_eq_arg2 =
10296      new NISuppressor(1, 2, IntEqual.class);
10297
10298  private static NISuppressor result_lt_arg1 =
10299      new NISuppressor(0, 1, IntLessThan.class);
10300  private static NISuppressor result_lt_arg2 =
10301      new NISuppressor(0, 2, IntLessThan.class);
10302  private static NISuppressor arg1_lt_arg2 =
10303      new NISuppressor(1, 2, IntLessThan.class);
10304  private static NISuppressor arg2_lt_arg1 =
10305      new NISuppressor(2, 1, IntLessThan.class);
10306
10307  private static NISuppressor result_le_arg1 =
10308      new NISuppressor(0, 1, IntLessEqual.class);
10309  private static NISuppressor result_le_arg2 =
10310      new NISuppressor(0, 2, IntLessEqual.class);
10311  private static NISuppressor arg1_le_arg2 =
10312      new NISuppressor(1, 2, IntLessEqual.class);
10313  private static NISuppressor arg2_le_arg1 =
10314      new NISuppressor(2, 1, IntLessEqual.class);
10315
10316  private static NISuppressor result_track0_arg1 =
10317      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
10318  private static NISuppressor result_track0_arg2 =
10319      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
10320  private static NISuppressor arg1_track0_arg2 =
10321      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
10322  private static NISuppressor arg1_track0_result =
10323      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
10324  private static NISuppressor arg2_track0_result =
10325      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
10326  private static NISuppressor arg2_track0_arg1 =
10327      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
10328
10329  private static NISuppressor result_eq_1 =
10330      new NISuppressor(0, RangeInt.EqualOne.class);
10331  private static NISuppressor arg1_eq_1 =
10332      new NISuppressor(1, RangeInt.EqualOne.class);
10333  private static NISuppressor arg2_eq_1 =
10334      new NISuppressor(2, RangeInt.EqualOne.class);
10335
10336  private static NISuppressor result_eq_0 =
10337      new NISuppressor(0, RangeInt.EqualZero.class);
10338  private static NISuppressor arg1_eq_0 =
10339      new NISuppressor(1, RangeInt.EqualZero.class);
10340  private static NISuppressor arg2_eq_0 =
10341      new NISuppressor(2, RangeInt.EqualZero.class);
10342
10343  private static NISuppressor result_ne_0 =
10344      new NISuppressor(0, NonZero.class);
10345  private static NISuppressor arg1_ne_0 =
10346      new NISuppressor(1, NonZero.class);
10347  private static NISuppressor arg2_ne_0 =
10348      new NISuppressor(2, NonZero.class);
10349
10350  private static NISuppressor result_ge_0 =
10351      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
10352  private static NISuppressor arg1_ge_0 =
10353      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
10354  private static NISuppressor arg2_ge_0 =
10355      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
10356
10357  private static NISuppressor result_ge_64 =
10358      new NISuppressor(0, RangeInt.GreaterEqual64.class);
10359  private static NISuppressor arg1_ge_64 =
10360      new NISuppressor(1, RangeInt.GreaterEqual64.class);
10361  private static NISuppressor arg2_ge_64 =
10362      new NISuppressor(2, RangeInt.GreaterEqual64.class);
10363
10364  private static NISuppressor result_boolean =
10365      new NISuppressor(0, RangeInt.BooleanVal.class);
10366  private static NISuppressor arg1_boolean =
10367      new NISuppressor(1, RangeInt.BooleanVal.class);
10368  private static NISuppressor arg2_boolean =
10369      new NISuppressor(2, RangeInt.BooleanVal.class);
10370
10371  private static NISuppressor result_even =
10372      new NISuppressor(0, RangeInt.Even.class);
10373  private static NISuppressor arg1_even =
10374      new NISuppressor(1, RangeInt.Even.class);
10375  private static NISuppressor arg2_even =
10376      new NISuppressor(2, RangeInt.Even.class);
10377
10378  private static NISuppressor result_power2 =
10379      new NISuppressor(0, RangeInt.PowerOfTwo.class);
10380  private static NISuppressor arg1_power2 =
10381      new NISuppressor(1, RangeInt.PowerOfTwo.class);
10382  private static NISuppressor arg2_power2 =
10383      new NISuppressor(2, RangeInt.PowerOfTwo.class);
10384
10385  private static NISuppressor result_and0_arg1 =
10386      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
10387  private static NISuppressor result_and0_arg2 =
10388      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
10389  private static NISuppressor arg1_and0_arg2 =
10390      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
10391
10392  // The arguments to bitwise subset are backwards from what one
10393  // might expect.  The second argument is a subset of the first
10394  // argument
10395  private static NISuppressor arg1_bw_subset_arg2 =
10396      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
10397  private static NISuppressor arg2_bw_subset_arg1 =
10398      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
10399
10400  private static NISuppressor result_shift0_arg1 =
10401      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
10402  private static NISuppressor result_shift0_arg2 =
10403      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
10404  private static NISuppressor arg1_shift0_arg2 =
10405      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
10406
10407  private static NISuppressor arg2_divides_arg1 =
10408      new NISuppressor(1, 2, NumericInt.Divides.class);
10409  private static NISuppressor arg1_divides_arg2 =
10410      new NISuppressor(2, 1, NumericInt.Divides.class);
10411
10412  private static NISuppressor arg2_valid_shift =
10413      new NISuppressor(2, RangeInt.Bound0_63.class);
10414
10415    private static NISuppressionSet suppressions =
10416        new NISuppressionSet(
10417          new NISuppression[] {
10418
10419            // Note that
10420            // x == y && y == z does NOT imply x == z because of possibly
10421            // missing values.  For example:
10422            //
10423            //  Sample    X         Y           Z
10424            //    1       1         1           missing
10425            //    2       0         missing     1
10426            //    3       missing   0           0
10427            //
10428            //  The best solution seems to be to include all three
10429            //  equalities for the suppression
10430
10431            // (r == y) && (y == z) && (r == z) && (r is boolean)
10432            //    ==> r = y | z
10433            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
10434                               result_boolean, suppressee),
10435
10436            // (r == y) && (z == 0) && (r is boolean) ==> r = y | z
10437            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_0,
10438                               suppressee),
10439
10440            // (r == z) && (y == 0) && (r is boolean) ==> r = y | z
10441            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_0,
10442                               suppressee),
10443
10444            // (r == 1) && (y == 1) && (z boolean)
10445            new NISuppression(result_eq_1, arg1_eq_1, arg2_boolean, suppressee),
10446
10447            // (r == 1) && (z == 1) && (y boolean)
10448            new NISuppression(result_eq_1, arg2_eq_1, arg1_boolean, suppressee),
10449
10450          });
10451
10452  // Create a suppression factory for functionBinary
10453
10454}
10455
10456/**
10457 * Represents the invariant {@code y = LogicalOr(x, z)} over three long
10458 * scalars. For logical operations, Daikon treats 0 as false and all other values as true.
10459 */
10460public static class LogicalOrLong_yxz extends FunctionBinary {
10461  // We are Serializable, so we specify a version to allow changes to
10462  // method signatures without breaking serialization.  If you add or
10463  // remove fields, you should change this number to the current date.
10464  static final long serialVersionUID = 20031030L;
10465
10466  private static @Prototype LogicalOrLong_yxz proto = new @Prototype LogicalOrLong_yxz ();
10467
10468  /** Returns the prototype invariant for LogicalOrLong_yxz */
10469  public static @Prototype LogicalOrLong_yxz get_proto() {
10470    return proto;
10471  }
10472
10473  /** instantiate an invariant on the specified slice */
10474  @Override
10475  protected LogicalOrLong_yxz instantiate_dyn(@Prototype LogicalOrLong_yxz this, PptSlice slice) {
10476    return new LogicalOrLong_yxz (slice);
10477  }
10478
10479  private LogicalOrLong_yxz (PptSlice slice) {
10480    super(slice);
10481  }
10482
10483  public @Prototype LogicalOrLong_yxz () {
10484    super();
10485  }
10486
10487  private static String[] method_name = new String[] {"", " || ", ""};
10488
10489  @Override
10490  public String[] get_method_name(@GuardSatisfied LogicalOrLong_yxz this) {
10491    return method_name;
10492  }
10493
10494  private static int function_id = -1;
10495
10496  @Override
10497  public int get_function_id() {
10498    return function_id;
10499  }
10500
10501  @Override
10502  public void set_function_id(int function_id) {
10503    assert LogicalOrLong_yxz.function_id == -1;
10504    LogicalOrLong_yxz.function_id = function_id;
10505  }
10506
10507  private static int var_order = 2;
10508
10509  @Override
10510  public int get_var_order(@GuardSatisfied LogicalOrLong_yxz this) {
10511    return var_order;
10512  }
10513
10514  @Pure
10515  @Override
10516  public boolean is_symmetric() {
10517
10518      return true;
10519  }
10520
10521  @Override
10522
10523  public long func(long x, long z) {
10524
10525      if ((x < 0) || (x > 1)) {
10526        throw new ArithmeticException("arg1 (" + x + ") is not boolean ");
10527      }
10528      if ((z < 0) || (z > 1)) {
10529        throw new ArithmeticException("arg2 (" + z + ") is not boolean ");
10530      }
10531
10532    return (((x != 0) || ( z != 0)) ? 1 : 0);
10533  }
10534
10535  @Override
10536  public InvariantStatus check_modified(long x, long y,
10537                                      long z, int count) {
10538    return check_ordered(y, x, z, count);
10539  }
10540
10541  @Override
10542  public InvariantStatus add_modified(long x, long y,
10543                                      long z, int count) {
10544    if (Debug.logDetail()) {
10545      log("result=%s, arg1=%s, arg2=%s", y, x, z);
10546    }
10547    return add_ordered(y, x, z, count);
10548  }
10549
10550  @Pure
10551  @Override
10552  public boolean isLogicalOr() {
10553    return true;
10554  }
10555
10556  /** Returns a list of non-instantiating suppressions for this invariant. */
10557  @Pure
10558  @Override
10559  public @Nullable NISuppressionSet get_ni_suppressions() {
10560    if (NIS.dkconfig_enabled && dkconfig_enabled) {
10561      return suppressions;
10562    } else {
10563      return null;
10564    }
10565  }
10566
10567  /** definition of this invariant (the suppressee) */
10568  private static NISuppressee suppressee = new NISuppressee(LogicalOrLong_yxz.class, 3);
10569
10570  // suppressor definitions (used below)
10571  private static NISuppressor result_eq_arg1 =
10572      new NISuppressor(1, 0, IntEqual.class);
10573  private static NISuppressor result_eq_arg2 =
10574      new NISuppressor(1, 2, IntEqual.class);
10575  private static NISuppressor arg1_eq_arg2 =
10576      new NISuppressor(0, 2, IntEqual.class);
10577
10578  private static NISuppressor result_lt_arg1 =
10579      new NISuppressor(1, 0, IntLessThan.class);
10580  private static NISuppressor result_lt_arg2 =
10581      new NISuppressor(1, 2, IntLessThan.class);
10582  private static NISuppressor arg1_lt_arg2 =
10583      new NISuppressor(0, 2, IntLessThan.class);
10584  private static NISuppressor arg2_lt_arg1 =
10585      new NISuppressor(2, 0, IntLessThan.class);
10586
10587  private static NISuppressor result_le_arg1 =
10588      new NISuppressor(1, 0, IntLessEqual.class);
10589  private static NISuppressor result_le_arg2 =
10590      new NISuppressor(1, 2, IntLessEqual.class);
10591  private static NISuppressor arg1_le_arg2 =
10592      new NISuppressor(0, 2, IntLessEqual.class);
10593  private static NISuppressor arg2_le_arg1 =
10594      new NISuppressor(2, 0, IntLessEqual.class);
10595
10596  private static NISuppressor result_track0_arg1 =
10597      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
10598  private static NISuppressor result_track0_arg2 =
10599      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
10600  private static NISuppressor arg1_track0_arg2 =
10601      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
10602  private static NISuppressor arg1_track0_result =
10603      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
10604  private static NISuppressor arg2_track0_result =
10605      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
10606  private static NISuppressor arg2_track0_arg1 =
10607      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
10608
10609  private static NISuppressor result_eq_1 =
10610      new NISuppressor(1, RangeInt.EqualOne.class);
10611  private static NISuppressor arg1_eq_1 =
10612      new NISuppressor(0, RangeInt.EqualOne.class);
10613  private static NISuppressor arg2_eq_1 =
10614      new NISuppressor(2, RangeInt.EqualOne.class);
10615
10616  private static NISuppressor result_eq_0 =
10617      new NISuppressor(1, RangeInt.EqualZero.class);
10618  private static NISuppressor arg1_eq_0 =
10619      new NISuppressor(0, RangeInt.EqualZero.class);
10620  private static NISuppressor arg2_eq_0 =
10621      new NISuppressor(2, RangeInt.EqualZero.class);
10622
10623  private static NISuppressor result_ne_0 =
10624      new NISuppressor(1, NonZero.class);
10625  private static NISuppressor arg1_ne_0 =
10626      new NISuppressor(0, NonZero.class);
10627  private static NISuppressor arg2_ne_0 =
10628      new NISuppressor(2, NonZero.class);
10629
10630  private static NISuppressor result_ge_0 =
10631      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
10632  private static NISuppressor arg1_ge_0 =
10633      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
10634  private static NISuppressor arg2_ge_0 =
10635      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
10636
10637  private static NISuppressor result_ge_64 =
10638      new NISuppressor(1, RangeInt.GreaterEqual64.class);
10639  private static NISuppressor arg1_ge_64 =
10640      new NISuppressor(0, RangeInt.GreaterEqual64.class);
10641  private static NISuppressor arg2_ge_64 =
10642      new NISuppressor(2, RangeInt.GreaterEqual64.class);
10643
10644  private static NISuppressor result_boolean =
10645      new NISuppressor(1, RangeInt.BooleanVal.class);
10646  private static NISuppressor arg1_boolean =
10647      new NISuppressor(0, RangeInt.BooleanVal.class);
10648  private static NISuppressor arg2_boolean =
10649      new NISuppressor(2, RangeInt.BooleanVal.class);
10650
10651  private static NISuppressor result_even =
10652      new NISuppressor(1, RangeInt.Even.class);
10653  private static NISuppressor arg1_even =
10654      new NISuppressor(0, RangeInt.Even.class);
10655  private static NISuppressor arg2_even =
10656      new NISuppressor(2, RangeInt.Even.class);
10657
10658  private static NISuppressor result_power2 =
10659      new NISuppressor(1, RangeInt.PowerOfTwo.class);
10660  private static NISuppressor arg1_power2 =
10661      new NISuppressor(0, RangeInt.PowerOfTwo.class);
10662  private static NISuppressor arg2_power2 =
10663      new NISuppressor(2, RangeInt.PowerOfTwo.class);
10664
10665  private static NISuppressor result_and0_arg1 =
10666      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
10667  private static NISuppressor result_and0_arg2 =
10668      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
10669  private static NISuppressor arg1_and0_arg2 =
10670      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
10671
10672  // The arguments to bitwise subset are backwards from what one
10673  // might expect.  The second argument is a subset of the first
10674  // argument
10675  private static NISuppressor arg1_bw_subset_arg2 =
10676      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
10677  private static NISuppressor arg2_bw_subset_arg1 =
10678      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
10679
10680  private static NISuppressor result_shift0_arg1 =
10681      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
10682  private static NISuppressor result_shift0_arg2 =
10683      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
10684  private static NISuppressor arg1_shift0_arg2 =
10685      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
10686
10687  private static NISuppressor arg2_divides_arg1 =
10688      new NISuppressor(0, 2, NumericInt.Divides.class);
10689  private static NISuppressor arg1_divides_arg2 =
10690      new NISuppressor(2, 0, NumericInt.Divides.class);
10691
10692  private static NISuppressor arg2_valid_shift =
10693      new NISuppressor(2, RangeInt.Bound0_63.class);
10694
10695    private static NISuppressionSet suppressions =
10696        new NISuppressionSet(
10697          new NISuppression[] {
10698
10699            // Note that
10700            // x == y && y == z does NOT imply x == z because of possibly
10701            // missing values.  For example:
10702            //
10703            //  Sample    X         Y           Z
10704            //    1       1         1           missing
10705            //    2       0         missing     1
10706            //    3       missing   0           0
10707            //
10708            //  The best solution seems to be to include all three
10709            //  equalities for the suppression
10710
10711            // (r == x) && (x == z) && (r == z) && (r is boolean)
10712            //    ==> r = x | z
10713            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
10714                               result_boolean, suppressee),
10715
10716            // (r == x) && (z == 0) && (r is boolean) ==> r = x | z
10717            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_0,
10718                               suppressee),
10719
10720            // (r == z) && (x == 0) && (r is boolean) ==> r = x | z
10721            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_0,
10722                               suppressee),
10723
10724            // (r == 1) && (x == 1) && (z boolean)
10725            new NISuppression(result_eq_1, arg1_eq_1, arg2_boolean, suppressee),
10726
10727            // (r == 1) && (z == 1) && (x boolean)
10728            new NISuppression(result_eq_1, arg2_eq_1, arg1_boolean, suppressee),
10729
10730          });
10731
10732  // Create a suppression factory for functionBinary
10733
10734}
10735
10736/**
10737 * Represents the invariant {@code z = LogicalOr(x, y)} over three long
10738 * scalars. For logical operations, Daikon treats 0 as false and all other values as true.
10739 */
10740public static class LogicalOrLong_zxy extends FunctionBinary {
10741  // We are Serializable, so we specify a version to allow changes to
10742  // method signatures without breaking serialization.  If you add or
10743  // remove fields, you should change this number to the current date.
10744  static final long serialVersionUID = 20031030L;
10745
10746  private static @Prototype LogicalOrLong_zxy proto = new @Prototype LogicalOrLong_zxy ();
10747
10748  /** Returns the prototype invariant for LogicalOrLong_zxy */
10749  public static @Prototype LogicalOrLong_zxy get_proto() {
10750    return proto;
10751  }
10752
10753  /** instantiate an invariant on the specified slice */
10754  @Override
10755  protected LogicalOrLong_zxy instantiate_dyn(@Prototype LogicalOrLong_zxy this, PptSlice slice) {
10756    return new LogicalOrLong_zxy (slice);
10757  }
10758
10759  private LogicalOrLong_zxy (PptSlice slice) {
10760    super(slice);
10761  }
10762
10763  public @Prototype LogicalOrLong_zxy () {
10764    super();
10765  }
10766
10767  private static String[] method_name = new String[] {"", " || ", ""};
10768
10769  @Override
10770  public String[] get_method_name(@GuardSatisfied LogicalOrLong_zxy this) {
10771    return method_name;
10772  }
10773
10774  private static int function_id = -1;
10775
10776  @Override
10777  public int get_function_id() {
10778    return function_id;
10779  }
10780
10781  @Override
10782  public void set_function_id(int function_id) {
10783    assert LogicalOrLong_zxy.function_id == -1;
10784    LogicalOrLong_zxy.function_id = function_id;
10785  }
10786
10787  private static int var_order = 3;
10788
10789  @Override
10790  public int get_var_order(@GuardSatisfied LogicalOrLong_zxy this) {
10791    return var_order;
10792  }
10793
10794  @Pure
10795  @Override
10796  public boolean is_symmetric() {
10797
10798      return true;
10799  }
10800
10801  @Override
10802
10803  public long func(long x, long y) {
10804
10805      if ((x < 0) || (x > 1)) {
10806        throw new ArithmeticException("arg1 (" + x + ") is not boolean ");
10807      }
10808      if ((y < 0) || (y > 1)) {
10809        throw new ArithmeticException("arg2 (" + y + ") is not boolean ");
10810      }
10811
10812    return (((x != 0) || ( y != 0)) ? 1 : 0);
10813  }
10814
10815  @Override
10816  public InvariantStatus check_modified(long x, long y,
10817                                      long z, int count) {
10818    return check_ordered(z, x, y, count);
10819  }
10820
10821  @Override
10822  public InvariantStatus add_modified(long x, long y,
10823                                      long z, int count) {
10824    if (Debug.logDetail()) {
10825      log("result=%s, arg1=%s, arg2=%s", z, x, y);
10826    }
10827    return add_ordered(z, x, y, count);
10828  }
10829
10830  @Pure
10831  @Override
10832  public boolean isLogicalOr() {
10833    return true;
10834  }
10835
10836  /** Returns a list of non-instantiating suppressions for this invariant. */
10837  @Pure
10838  @Override
10839  public @Nullable NISuppressionSet get_ni_suppressions() {
10840    if (NIS.dkconfig_enabled && dkconfig_enabled) {
10841      return suppressions;
10842    } else {
10843      return null;
10844    }
10845  }
10846
10847  /** definition of this invariant (the suppressee) */
10848  private static NISuppressee suppressee = new NISuppressee(LogicalOrLong_zxy.class, 3);
10849
10850  // suppressor definitions (used below)
10851  private static NISuppressor result_eq_arg1 =
10852      new NISuppressor(2, 0, IntEqual.class);
10853  private static NISuppressor result_eq_arg2 =
10854      new NISuppressor(2, 1, IntEqual.class);
10855  private static NISuppressor arg1_eq_arg2 =
10856      new NISuppressor(0, 1, IntEqual.class);
10857
10858  private static NISuppressor result_lt_arg1 =
10859      new NISuppressor(2, 0, IntLessThan.class);
10860  private static NISuppressor result_lt_arg2 =
10861      new NISuppressor(2, 1, IntLessThan.class);
10862  private static NISuppressor arg1_lt_arg2 =
10863      new NISuppressor(0, 1, IntLessThan.class);
10864  private static NISuppressor arg2_lt_arg1 =
10865      new NISuppressor(1, 0, IntLessThan.class);
10866
10867  private static NISuppressor result_le_arg1 =
10868      new NISuppressor(2, 0, IntLessEqual.class);
10869  private static NISuppressor result_le_arg2 =
10870      new NISuppressor(2, 1, IntLessEqual.class);
10871  private static NISuppressor arg1_le_arg2 =
10872      new NISuppressor(0, 1, IntLessEqual.class);
10873  private static NISuppressor arg2_le_arg1 =
10874      new NISuppressor(1, 0, IntLessEqual.class);
10875
10876  private static NISuppressor result_track0_arg1 =
10877      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
10878  private static NISuppressor result_track0_arg2 =
10879      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
10880  private static NISuppressor arg1_track0_arg2 =
10881      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
10882  private static NISuppressor arg1_track0_result =
10883      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
10884  private static NISuppressor arg2_track0_result =
10885      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
10886  private static NISuppressor arg2_track0_arg1 =
10887      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
10888
10889  private static NISuppressor result_eq_1 =
10890      new NISuppressor(2, RangeInt.EqualOne.class);
10891  private static NISuppressor arg1_eq_1 =
10892      new NISuppressor(0, RangeInt.EqualOne.class);
10893  private static NISuppressor arg2_eq_1 =
10894      new NISuppressor(1, RangeInt.EqualOne.class);
10895
10896  private static NISuppressor result_eq_0 =
10897      new NISuppressor(2, RangeInt.EqualZero.class);
10898  private static NISuppressor arg1_eq_0 =
10899      new NISuppressor(0, RangeInt.EqualZero.class);
10900  private static NISuppressor arg2_eq_0 =
10901      new NISuppressor(1, RangeInt.EqualZero.class);
10902
10903  private static NISuppressor result_ne_0 =
10904      new NISuppressor(2, NonZero.class);
10905  private static NISuppressor arg1_ne_0 =
10906      new NISuppressor(0, NonZero.class);
10907  private static NISuppressor arg2_ne_0 =
10908      new NISuppressor(1, NonZero.class);
10909
10910  private static NISuppressor result_ge_0 =
10911      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
10912  private static NISuppressor arg1_ge_0 =
10913      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
10914  private static NISuppressor arg2_ge_0 =
10915      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
10916
10917  private static NISuppressor result_ge_64 =
10918      new NISuppressor(2, RangeInt.GreaterEqual64.class);
10919  private static NISuppressor arg1_ge_64 =
10920      new NISuppressor(0, RangeInt.GreaterEqual64.class);
10921  private static NISuppressor arg2_ge_64 =
10922      new NISuppressor(1, RangeInt.GreaterEqual64.class);
10923
10924  private static NISuppressor result_boolean =
10925      new NISuppressor(2, RangeInt.BooleanVal.class);
10926  private static NISuppressor arg1_boolean =
10927      new NISuppressor(0, RangeInt.BooleanVal.class);
10928  private static NISuppressor arg2_boolean =
10929      new NISuppressor(1, RangeInt.BooleanVal.class);
10930
10931  private static NISuppressor result_even =
10932      new NISuppressor(2, RangeInt.Even.class);
10933  private static NISuppressor arg1_even =
10934      new NISuppressor(0, RangeInt.Even.class);
10935  private static NISuppressor arg2_even =
10936      new NISuppressor(1, RangeInt.Even.class);
10937
10938  private static NISuppressor result_power2 =
10939      new NISuppressor(2, RangeInt.PowerOfTwo.class);
10940  private static NISuppressor arg1_power2 =
10941      new NISuppressor(0, RangeInt.PowerOfTwo.class);
10942  private static NISuppressor arg2_power2 =
10943      new NISuppressor(1, RangeInt.PowerOfTwo.class);
10944
10945  private static NISuppressor result_and0_arg1 =
10946      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
10947  private static NISuppressor result_and0_arg2 =
10948      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
10949  private static NISuppressor arg1_and0_arg2 =
10950      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
10951
10952  // The arguments to bitwise subset are backwards from what one
10953  // might expect.  The second argument is a subset of the first
10954  // argument
10955  private static NISuppressor arg1_bw_subset_arg2 =
10956      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
10957  private static NISuppressor arg2_bw_subset_arg1 =
10958      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
10959
10960  private static NISuppressor result_shift0_arg1 =
10961      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
10962  private static NISuppressor result_shift0_arg2 =
10963      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
10964  private static NISuppressor arg1_shift0_arg2 =
10965      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
10966
10967  private static NISuppressor arg2_divides_arg1 =
10968      new NISuppressor(0, 1, NumericInt.Divides.class);
10969  private static NISuppressor arg1_divides_arg2 =
10970      new NISuppressor(1, 0, NumericInt.Divides.class);
10971
10972  private static NISuppressor arg2_valid_shift =
10973      new NISuppressor(1, RangeInt.Bound0_63.class);
10974
10975    private static NISuppressionSet suppressions =
10976        new NISuppressionSet(
10977          new NISuppression[] {
10978
10979            // Note that
10980            // x == y && y == z does NOT imply x == z because of possibly
10981            // missing values.  For example:
10982            //
10983            //  Sample    X         Y           Z
10984            //    1       1         1           missing
10985            //    2       0         missing     1
10986            //    3       missing   0           0
10987            //
10988            //  The best solution seems to be to include all three
10989            //  equalities for the suppression
10990
10991            // (r == x) && (x == y) && (r == y) && (r is boolean)
10992            //    ==> r = x | y
10993            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
10994                               result_boolean, suppressee),
10995
10996            // (r == x) && (y == 0) && (r is boolean) ==> r = x | y
10997            new NISuppression(result_eq_arg1, result_boolean, arg2_eq_0,
10998                               suppressee),
10999
11000            // (r == y) && (x == 0) && (r is boolean) ==> r = x | y
11001            new NISuppression(result_eq_arg2, result_boolean, arg1_eq_0,
11002                               suppressee),
11003
11004            // (r == 1) && (x == 1) && (y boolean)
11005            new NISuppression(result_eq_1, arg1_eq_1, arg2_boolean, suppressee),
11006
11007            // (r == 1) && (y == 1) && (x boolean)
11008            new NISuppression(result_eq_1, arg2_eq_1, arg1_boolean, suppressee),
11009
11010          });
11011
11012  // Create a suppression factory for functionBinary
11013
11014}
11015
11016  // #define EQUALITY_SUPPRESS 1
11017
11018  // default is that it is not this function, overriden in the subclass
11019  @Pure
11020  public boolean isGcd() {
11021    return false;
11022  }
11023
11024/**
11025 * Represents the invariant {@code x = Gcd(y, z)} over three long
11026 * scalars. 
11027 */
11028public static class GcdLong_xyz extends FunctionBinary {
11029  // We are Serializable, so we specify a version to allow changes to
11030  // method signatures without breaking serialization.  If you add or
11031  // remove fields, you should change this number to the current date.
11032  static final long serialVersionUID = 20031030L;
11033
11034  private static @Prototype GcdLong_xyz proto = new @Prototype GcdLong_xyz ();
11035
11036  /** Returns the prototype invariant for GcdLong_xyz */
11037  public static @Prototype GcdLong_xyz get_proto() {
11038    return proto;
11039  }
11040
11041  /** instantiate an invariant on the specified slice */
11042  @Override
11043  protected GcdLong_xyz instantiate_dyn(@Prototype GcdLong_xyz this, PptSlice slice) {
11044    return new GcdLong_xyz (slice);
11045  }
11046
11047  private GcdLong_xyz (PptSlice slice) {
11048    super(slice);
11049  }
11050
11051  public @Prototype GcdLong_xyz () {
11052    super();
11053  }
11054
11055  private static String[] method_name = new String[] {"org.plumelib.util.MathPlume.gcd(", ", ", ")"};
11056
11057  @Override
11058  public String[] get_method_name(@GuardSatisfied GcdLong_xyz this) {
11059    return method_name;
11060  }
11061
11062  private static int function_id = -1;
11063
11064  @Override
11065  public int get_function_id() {
11066    return function_id;
11067  }
11068
11069  @Override
11070  public void set_function_id(int function_id) {
11071    assert GcdLong_xyz.function_id == -1;
11072    GcdLong_xyz.function_id = function_id;
11073  }
11074
11075  private static int var_order = 1;
11076
11077  @Override
11078  public int get_var_order(@GuardSatisfied GcdLong_xyz this) {
11079    return var_order;
11080  }
11081
11082  @Pure
11083  @Override
11084  public boolean is_symmetric() {
11085
11086      return true;
11087  }
11088
11089  @Override
11090
11091  public long func(long y, long z) {
11092
11093    return MathPlume.gcd(y, z);
11094  }
11095
11096  @Override
11097  public InvariantStatus check_modified(long x, long y,
11098                                      long z, int count) {
11099    return check_ordered(x, y, z, count);
11100  }
11101
11102  @Override
11103  public InvariantStatus add_modified(long x, long y,
11104                                      long z, int count) {
11105    if (Debug.logDetail()) {
11106      log("result=%s, arg1=%s, arg2=%s", x, y, z);
11107    }
11108    return add_ordered(x, y, z, count);
11109  }
11110
11111  @Pure
11112  @Override
11113  public boolean isGcd() {
11114    return true;
11115  }
11116
11117  /** Returns a list of non-instantiating suppressions for this invariant. */
11118  @Pure
11119  @Override
11120  public @Nullable NISuppressionSet get_ni_suppressions() {
11121    if (NIS.dkconfig_enabled && dkconfig_enabled) {
11122      return suppressions;
11123    } else {
11124      return null;
11125    }
11126  }
11127
11128  /** definition of this invariant (the suppressee) */
11129  private static NISuppressee suppressee = new NISuppressee(GcdLong_xyz.class, 3);
11130
11131  // suppressor definitions (used below)
11132  private static NISuppressor result_eq_arg1 =
11133      new NISuppressor(0, 1, IntEqual.class);
11134  private static NISuppressor result_eq_arg2 =
11135      new NISuppressor(0, 2, IntEqual.class);
11136  private static NISuppressor arg1_eq_arg2 =
11137      new NISuppressor(1, 2, IntEqual.class);
11138
11139  private static NISuppressor result_lt_arg1 =
11140      new NISuppressor(0, 1, IntLessThan.class);
11141  private static NISuppressor result_lt_arg2 =
11142      new NISuppressor(0, 2, IntLessThan.class);
11143  private static NISuppressor arg1_lt_arg2 =
11144      new NISuppressor(1, 2, IntLessThan.class);
11145  private static NISuppressor arg2_lt_arg1 =
11146      new NISuppressor(2, 1, IntLessThan.class);
11147
11148  private static NISuppressor result_le_arg1 =
11149      new NISuppressor(0, 1, IntLessEqual.class);
11150  private static NISuppressor result_le_arg2 =
11151      new NISuppressor(0, 2, IntLessEqual.class);
11152  private static NISuppressor arg1_le_arg2 =
11153      new NISuppressor(1, 2, IntLessEqual.class);
11154  private static NISuppressor arg2_le_arg1 =
11155      new NISuppressor(2, 1, IntLessEqual.class);
11156
11157  private static NISuppressor result_track0_arg1 =
11158      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
11159  private static NISuppressor result_track0_arg2 =
11160      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
11161  private static NISuppressor arg1_track0_arg2 =
11162      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
11163  private static NISuppressor arg1_track0_result =
11164      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
11165  private static NISuppressor arg2_track0_result =
11166      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
11167  private static NISuppressor arg2_track0_arg1 =
11168      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
11169
11170  private static NISuppressor result_eq_1 =
11171      new NISuppressor(0, RangeInt.EqualOne.class);
11172  private static NISuppressor arg1_eq_1 =
11173      new NISuppressor(1, RangeInt.EqualOne.class);
11174  private static NISuppressor arg2_eq_1 =
11175      new NISuppressor(2, RangeInt.EqualOne.class);
11176
11177  private static NISuppressor result_eq_0 =
11178      new NISuppressor(0, RangeInt.EqualZero.class);
11179  private static NISuppressor arg1_eq_0 =
11180      new NISuppressor(1, RangeInt.EqualZero.class);
11181  private static NISuppressor arg2_eq_0 =
11182      new NISuppressor(2, RangeInt.EqualZero.class);
11183
11184  private static NISuppressor result_ne_0 =
11185      new NISuppressor(0, NonZero.class);
11186  private static NISuppressor arg1_ne_0 =
11187      new NISuppressor(1, NonZero.class);
11188  private static NISuppressor arg2_ne_0 =
11189      new NISuppressor(2, NonZero.class);
11190
11191  private static NISuppressor result_ge_0 =
11192      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
11193  private static NISuppressor arg1_ge_0 =
11194      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
11195  private static NISuppressor arg2_ge_0 =
11196      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
11197
11198  private static NISuppressor result_ge_64 =
11199      new NISuppressor(0, RangeInt.GreaterEqual64.class);
11200  private static NISuppressor arg1_ge_64 =
11201      new NISuppressor(1, RangeInt.GreaterEqual64.class);
11202  private static NISuppressor arg2_ge_64 =
11203      new NISuppressor(2, RangeInt.GreaterEqual64.class);
11204
11205  private static NISuppressor result_boolean =
11206      new NISuppressor(0, RangeInt.BooleanVal.class);
11207  private static NISuppressor arg1_boolean =
11208      new NISuppressor(1, RangeInt.BooleanVal.class);
11209  private static NISuppressor arg2_boolean =
11210      new NISuppressor(2, RangeInt.BooleanVal.class);
11211
11212  private static NISuppressor result_even =
11213      new NISuppressor(0, RangeInt.Even.class);
11214  private static NISuppressor arg1_even =
11215      new NISuppressor(1, RangeInt.Even.class);
11216  private static NISuppressor arg2_even =
11217      new NISuppressor(2, RangeInt.Even.class);
11218
11219  private static NISuppressor result_power2 =
11220      new NISuppressor(0, RangeInt.PowerOfTwo.class);
11221  private static NISuppressor arg1_power2 =
11222      new NISuppressor(1, RangeInt.PowerOfTwo.class);
11223  private static NISuppressor arg2_power2 =
11224      new NISuppressor(2, RangeInt.PowerOfTwo.class);
11225
11226  private static NISuppressor result_and0_arg1 =
11227      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
11228  private static NISuppressor result_and0_arg2 =
11229      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
11230  private static NISuppressor arg1_and0_arg2 =
11231      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
11232
11233  // The arguments to bitwise subset are backwards from what one
11234  // might expect.  The second argument is a subset of the first
11235  // argument
11236  private static NISuppressor arg1_bw_subset_arg2 =
11237      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
11238  private static NISuppressor arg2_bw_subset_arg1 =
11239      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
11240
11241  private static NISuppressor result_shift0_arg1 =
11242      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
11243  private static NISuppressor result_shift0_arg2 =
11244      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
11245  private static NISuppressor arg1_shift0_arg2 =
11246      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
11247
11248  private static NISuppressor arg2_divides_arg1 =
11249      new NISuppressor(1, 2, NumericInt.Divides.class);
11250  private static NISuppressor arg1_divides_arg2 =
11251      new NISuppressor(2, 1, NumericInt.Divides.class);
11252
11253  private static NISuppressor arg2_valid_shift =
11254      new NISuppressor(2, RangeInt.Bound0_63.class);
11255
11256    // gcd (0, y) == y
11257    // gcd (0, 0) == 0
11258    // gcd (1, y) == 1
11259
11260    private static NISuppressionSet suppressions =
11261        new NISuppressionSet(
11262          new NISuppression[] {
11263
11264            // (r == y) && (y == z) && (r == z) && (r >= 0)
11265            //    ==> r = Gcd (y, z)
11266            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
11267                               result_ge_0, suppressee),
11268
11269            // (r == y) && (z == 0) && (r >= 0) ==> r = gcd (y, z)
11270            new NISuppression(result_eq_arg1, result_ge_0, arg2_eq_0, suppressee),
11271
11272            // (r == z) && (y == 0) && (r >= 0) ==> r = gcd (y, z)
11273            new NISuppression(result_eq_arg2, result_ge_0, arg1_eq_0, suppressee),
11274
11275            // (r == 1) && (z == 1)        ==> r = gcd (y, art2)
11276            new NISuppression(result_eq_1, arg2_eq_1, suppressee),
11277
11278            // (r == 1) && (y == 1)        ==> r = gcd (y, art2)
11279            new NISuppression(result_eq_1, arg1_eq_1, suppressee),
11280
11281            // (r == y) && (y divides z) && (r >= 0)
11282            new NISuppression(result_eq_arg1, arg1_divides_arg2, result_ge_0, suppressee),
11283
11284            // (r == z) && (z divides y) && (r >= 0)
11285            new NISuppression(result_eq_arg2, arg2_divides_arg1, result_ge_0, suppressee),
11286
11287            // (r == z) && (z boolean) && (z==0 ==> y==0)
11288            // 0 = gcd (y, 0) true when (y == 0)
11289            // 1 = gcd (y, 1) always true
11290            new NISuppression(result_eq_arg2, arg2_track0_arg1, arg2_boolean,
11291                               suppressee),
11292
11293            // (r == y) && (y boolean) && (y==0 ==> z==0)
11294            // 0 = gcd (0, z), true if (z == 0)
11295            // 1 = gcd (1, z), always true
11296            new NISuppression(result_eq_arg1, arg1_boolean, arg1_track0_arg2,
11297                               suppressee),
11298
11299          });
11300
11301  // Create a suppression factory for functionBinary
11302
11303}
11304
11305/**
11306 * Represents the invariant {@code y = Gcd(x, z)} over three long
11307 * scalars. 
11308 */
11309public static class GcdLong_yxz extends FunctionBinary {
11310  // We are Serializable, so we specify a version to allow changes to
11311  // method signatures without breaking serialization.  If you add or
11312  // remove fields, you should change this number to the current date.
11313  static final long serialVersionUID = 20031030L;
11314
11315  private static @Prototype GcdLong_yxz proto = new @Prototype GcdLong_yxz ();
11316
11317  /** Returns the prototype invariant for GcdLong_yxz */
11318  public static @Prototype GcdLong_yxz get_proto() {
11319    return proto;
11320  }
11321
11322  /** instantiate an invariant on the specified slice */
11323  @Override
11324  protected GcdLong_yxz instantiate_dyn(@Prototype GcdLong_yxz this, PptSlice slice) {
11325    return new GcdLong_yxz (slice);
11326  }
11327
11328  private GcdLong_yxz (PptSlice slice) {
11329    super(slice);
11330  }
11331
11332  public @Prototype GcdLong_yxz () {
11333    super();
11334  }
11335
11336  private static String[] method_name = new String[] {"org.plumelib.util.MathPlume.gcd(", ", ", ")"};
11337
11338  @Override
11339  public String[] get_method_name(@GuardSatisfied GcdLong_yxz this) {
11340    return method_name;
11341  }
11342
11343  private static int function_id = -1;
11344
11345  @Override
11346  public int get_function_id() {
11347    return function_id;
11348  }
11349
11350  @Override
11351  public void set_function_id(int function_id) {
11352    assert GcdLong_yxz.function_id == -1;
11353    GcdLong_yxz.function_id = function_id;
11354  }
11355
11356  private static int var_order = 2;
11357
11358  @Override
11359  public int get_var_order(@GuardSatisfied GcdLong_yxz this) {
11360    return var_order;
11361  }
11362
11363  @Pure
11364  @Override
11365  public boolean is_symmetric() {
11366
11367      return true;
11368  }
11369
11370  @Override
11371
11372  public long func(long x, long z) {
11373
11374    return MathPlume.gcd(x, z);
11375  }
11376
11377  @Override
11378  public InvariantStatus check_modified(long x, long y,
11379                                      long z, int count) {
11380    return check_ordered(y, x, z, count);
11381  }
11382
11383  @Override
11384  public InvariantStatus add_modified(long x, long y,
11385                                      long z, int count) {
11386    if (Debug.logDetail()) {
11387      log("result=%s, arg1=%s, arg2=%s", y, x, z);
11388    }
11389    return add_ordered(y, x, z, count);
11390  }
11391
11392  @Pure
11393  @Override
11394  public boolean isGcd() {
11395    return true;
11396  }
11397
11398  /** Returns a list of non-instantiating suppressions for this invariant. */
11399  @Pure
11400  @Override
11401  public @Nullable NISuppressionSet get_ni_suppressions() {
11402    if (NIS.dkconfig_enabled && dkconfig_enabled) {
11403      return suppressions;
11404    } else {
11405      return null;
11406    }
11407  }
11408
11409  /** definition of this invariant (the suppressee) */
11410  private static NISuppressee suppressee = new NISuppressee(GcdLong_yxz.class, 3);
11411
11412  // suppressor definitions (used below)
11413  private static NISuppressor result_eq_arg1 =
11414      new NISuppressor(1, 0, IntEqual.class);
11415  private static NISuppressor result_eq_arg2 =
11416      new NISuppressor(1, 2, IntEqual.class);
11417  private static NISuppressor arg1_eq_arg2 =
11418      new NISuppressor(0, 2, IntEqual.class);
11419
11420  private static NISuppressor result_lt_arg1 =
11421      new NISuppressor(1, 0, IntLessThan.class);
11422  private static NISuppressor result_lt_arg2 =
11423      new NISuppressor(1, 2, IntLessThan.class);
11424  private static NISuppressor arg1_lt_arg2 =
11425      new NISuppressor(0, 2, IntLessThan.class);
11426  private static NISuppressor arg2_lt_arg1 =
11427      new NISuppressor(2, 0, IntLessThan.class);
11428
11429  private static NISuppressor result_le_arg1 =
11430      new NISuppressor(1, 0, IntLessEqual.class);
11431  private static NISuppressor result_le_arg2 =
11432      new NISuppressor(1, 2, IntLessEqual.class);
11433  private static NISuppressor arg1_le_arg2 =
11434      new NISuppressor(0, 2, IntLessEqual.class);
11435  private static NISuppressor arg2_le_arg1 =
11436      new NISuppressor(2, 0, IntLessEqual.class);
11437
11438  private static NISuppressor result_track0_arg1 =
11439      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
11440  private static NISuppressor result_track0_arg2 =
11441      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
11442  private static NISuppressor arg1_track0_arg2 =
11443      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
11444  private static NISuppressor arg1_track0_result =
11445      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
11446  private static NISuppressor arg2_track0_result =
11447      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
11448  private static NISuppressor arg2_track0_arg1 =
11449      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
11450
11451  private static NISuppressor result_eq_1 =
11452      new NISuppressor(1, RangeInt.EqualOne.class);
11453  private static NISuppressor arg1_eq_1 =
11454      new NISuppressor(0, RangeInt.EqualOne.class);
11455  private static NISuppressor arg2_eq_1 =
11456      new NISuppressor(2, RangeInt.EqualOne.class);
11457
11458  private static NISuppressor result_eq_0 =
11459      new NISuppressor(1, RangeInt.EqualZero.class);
11460  private static NISuppressor arg1_eq_0 =
11461      new NISuppressor(0, RangeInt.EqualZero.class);
11462  private static NISuppressor arg2_eq_0 =
11463      new NISuppressor(2, RangeInt.EqualZero.class);
11464
11465  private static NISuppressor result_ne_0 =
11466      new NISuppressor(1, NonZero.class);
11467  private static NISuppressor arg1_ne_0 =
11468      new NISuppressor(0, NonZero.class);
11469  private static NISuppressor arg2_ne_0 =
11470      new NISuppressor(2, NonZero.class);
11471
11472  private static NISuppressor result_ge_0 =
11473      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
11474  private static NISuppressor arg1_ge_0 =
11475      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
11476  private static NISuppressor arg2_ge_0 =
11477      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
11478
11479  private static NISuppressor result_ge_64 =
11480      new NISuppressor(1, RangeInt.GreaterEqual64.class);
11481  private static NISuppressor arg1_ge_64 =
11482      new NISuppressor(0, RangeInt.GreaterEqual64.class);
11483  private static NISuppressor arg2_ge_64 =
11484      new NISuppressor(2, RangeInt.GreaterEqual64.class);
11485
11486  private static NISuppressor result_boolean =
11487      new NISuppressor(1, RangeInt.BooleanVal.class);
11488  private static NISuppressor arg1_boolean =
11489      new NISuppressor(0, RangeInt.BooleanVal.class);
11490  private static NISuppressor arg2_boolean =
11491      new NISuppressor(2, RangeInt.BooleanVal.class);
11492
11493  private static NISuppressor result_even =
11494      new NISuppressor(1, RangeInt.Even.class);
11495  private static NISuppressor arg1_even =
11496      new NISuppressor(0, RangeInt.Even.class);
11497  private static NISuppressor arg2_even =
11498      new NISuppressor(2, RangeInt.Even.class);
11499
11500  private static NISuppressor result_power2 =
11501      new NISuppressor(1, RangeInt.PowerOfTwo.class);
11502  private static NISuppressor arg1_power2 =
11503      new NISuppressor(0, RangeInt.PowerOfTwo.class);
11504  private static NISuppressor arg2_power2 =
11505      new NISuppressor(2, RangeInt.PowerOfTwo.class);
11506
11507  private static NISuppressor result_and0_arg1 =
11508      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
11509  private static NISuppressor result_and0_arg2 =
11510      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
11511  private static NISuppressor arg1_and0_arg2 =
11512      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
11513
11514  // The arguments to bitwise subset are backwards from what one
11515  // might expect.  The second argument is a subset of the first
11516  // argument
11517  private static NISuppressor arg1_bw_subset_arg2 =
11518      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
11519  private static NISuppressor arg2_bw_subset_arg1 =
11520      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
11521
11522  private static NISuppressor result_shift0_arg1 =
11523      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
11524  private static NISuppressor result_shift0_arg2 =
11525      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
11526  private static NISuppressor arg1_shift0_arg2 =
11527      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
11528
11529  private static NISuppressor arg2_divides_arg1 =
11530      new NISuppressor(0, 2, NumericInt.Divides.class);
11531  private static NISuppressor arg1_divides_arg2 =
11532      new NISuppressor(2, 0, NumericInt.Divides.class);
11533
11534  private static NISuppressor arg2_valid_shift =
11535      new NISuppressor(2, RangeInt.Bound0_63.class);
11536
11537    // gcd (0, y) == y
11538    // gcd (0, 0) == 0
11539    // gcd (1, y) == 1
11540
11541    private static NISuppressionSet suppressions =
11542        new NISuppressionSet(
11543          new NISuppression[] {
11544
11545            // (r == x) && (x == z) && (r == z) && (r >= 0)
11546            //    ==> r = Gcd (x, z)
11547            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
11548                               result_ge_0, suppressee),
11549
11550            // (r == x) && (z == 0) && (r >= 0) ==> r = gcd (x, z)
11551            new NISuppression(result_eq_arg1, result_ge_0, arg2_eq_0, suppressee),
11552
11553            // (r == z) && (x == 0) && (r >= 0) ==> r = gcd (x, z)
11554            new NISuppression(result_eq_arg2, result_ge_0, arg1_eq_0, suppressee),
11555
11556            // (r == 1) && (z == 1)        ==> r = gcd (x, art2)
11557            new NISuppression(result_eq_1, arg2_eq_1, suppressee),
11558
11559            // (r == 1) && (x == 1)        ==> r = gcd (x, art2)
11560            new NISuppression(result_eq_1, arg1_eq_1, suppressee),
11561
11562            // (r == x) && (x divides z) && (r >= 0)
11563            new NISuppression(result_eq_arg1, arg1_divides_arg2, result_ge_0, suppressee),
11564
11565            // (r == z) && (z divides x) && (r >= 0)
11566            new NISuppression(result_eq_arg2, arg2_divides_arg1, result_ge_0, suppressee),
11567
11568            // (r == z) && (z boolean) && (z==0 ==> x==0)
11569            // 0 = gcd (x, 0) true when (x == 0)
11570            // 1 = gcd (x, 1) always true
11571            new NISuppression(result_eq_arg2, arg2_track0_arg1, arg2_boolean,
11572                               suppressee),
11573
11574            // (r == x) && (x boolean) && (x==0 ==> z==0)
11575            // 0 = gcd (0, z), true if (z == 0)
11576            // 1 = gcd (1, z), always true
11577            new NISuppression(result_eq_arg1, arg1_boolean, arg1_track0_arg2,
11578                               suppressee),
11579
11580          });
11581
11582  // Create a suppression factory for functionBinary
11583
11584}
11585
11586/**
11587 * Represents the invariant {@code z = Gcd(x, y)} over three long
11588 * scalars. 
11589 */
11590public static class GcdLong_zxy extends FunctionBinary {
11591  // We are Serializable, so we specify a version to allow changes to
11592  // method signatures without breaking serialization.  If you add or
11593  // remove fields, you should change this number to the current date.
11594  static final long serialVersionUID = 20031030L;
11595
11596  private static @Prototype GcdLong_zxy proto = new @Prototype GcdLong_zxy ();
11597
11598  /** Returns the prototype invariant for GcdLong_zxy */
11599  public static @Prototype GcdLong_zxy get_proto() {
11600    return proto;
11601  }
11602
11603  /** instantiate an invariant on the specified slice */
11604  @Override
11605  protected GcdLong_zxy instantiate_dyn(@Prototype GcdLong_zxy this, PptSlice slice) {
11606    return new GcdLong_zxy (slice);
11607  }
11608
11609  private GcdLong_zxy (PptSlice slice) {
11610    super(slice);
11611  }
11612
11613  public @Prototype GcdLong_zxy () {
11614    super();
11615  }
11616
11617  private static String[] method_name = new String[] {"org.plumelib.util.MathPlume.gcd(", ", ", ")"};
11618
11619  @Override
11620  public String[] get_method_name(@GuardSatisfied GcdLong_zxy this) {
11621    return method_name;
11622  }
11623
11624  private static int function_id = -1;
11625
11626  @Override
11627  public int get_function_id() {
11628    return function_id;
11629  }
11630
11631  @Override
11632  public void set_function_id(int function_id) {
11633    assert GcdLong_zxy.function_id == -1;
11634    GcdLong_zxy.function_id = function_id;
11635  }
11636
11637  private static int var_order = 3;
11638
11639  @Override
11640  public int get_var_order(@GuardSatisfied GcdLong_zxy this) {
11641    return var_order;
11642  }
11643
11644  @Pure
11645  @Override
11646  public boolean is_symmetric() {
11647
11648      return true;
11649  }
11650
11651  @Override
11652
11653  public long func(long x, long y) {
11654
11655    return MathPlume.gcd(x, y);
11656  }
11657
11658  @Override
11659  public InvariantStatus check_modified(long x, long y,
11660                                      long z, int count) {
11661    return check_ordered(z, x, y, count);
11662  }
11663
11664  @Override
11665  public InvariantStatus add_modified(long x, long y,
11666                                      long z, int count) {
11667    if (Debug.logDetail()) {
11668      log("result=%s, arg1=%s, arg2=%s", z, x, y);
11669    }
11670    return add_ordered(z, x, y, count);
11671  }
11672
11673  @Pure
11674  @Override
11675  public boolean isGcd() {
11676    return true;
11677  }
11678
11679  /** Returns a list of non-instantiating suppressions for this invariant. */
11680  @Pure
11681  @Override
11682  public @Nullable NISuppressionSet get_ni_suppressions() {
11683    if (NIS.dkconfig_enabled && dkconfig_enabled) {
11684      return suppressions;
11685    } else {
11686      return null;
11687    }
11688  }
11689
11690  /** definition of this invariant (the suppressee) */
11691  private static NISuppressee suppressee = new NISuppressee(GcdLong_zxy.class, 3);
11692
11693  // suppressor definitions (used below)
11694  private static NISuppressor result_eq_arg1 =
11695      new NISuppressor(2, 0, IntEqual.class);
11696  private static NISuppressor result_eq_arg2 =
11697      new NISuppressor(2, 1, IntEqual.class);
11698  private static NISuppressor arg1_eq_arg2 =
11699      new NISuppressor(0, 1, IntEqual.class);
11700
11701  private static NISuppressor result_lt_arg1 =
11702      new NISuppressor(2, 0, IntLessThan.class);
11703  private static NISuppressor result_lt_arg2 =
11704      new NISuppressor(2, 1, IntLessThan.class);
11705  private static NISuppressor arg1_lt_arg2 =
11706      new NISuppressor(0, 1, IntLessThan.class);
11707  private static NISuppressor arg2_lt_arg1 =
11708      new NISuppressor(1, 0, IntLessThan.class);
11709
11710  private static NISuppressor result_le_arg1 =
11711      new NISuppressor(2, 0, IntLessEqual.class);
11712  private static NISuppressor result_le_arg2 =
11713      new NISuppressor(2, 1, IntLessEqual.class);
11714  private static NISuppressor arg1_le_arg2 =
11715      new NISuppressor(0, 1, IntLessEqual.class);
11716  private static NISuppressor arg2_le_arg1 =
11717      new NISuppressor(1, 0, IntLessEqual.class);
11718
11719  private static NISuppressor result_track0_arg1 =
11720      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
11721  private static NISuppressor result_track0_arg2 =
11722      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
11723  private static NISuppressor arg1_track0_arg2 =
11724      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
11725  private static NISuppressor arg1_track0_result =
11726      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
11727  private static NISuppressor arg2_track0_result =
11728      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
11729  private static NISuppressor arg2_track0_arg1 =
11730      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
11731
11732  private static NISuppressor result_eq_1 =
11733      new NISuppressor(2, RangeInt.EqualOne.class);
11734  private static NISuppressor arg1_eq_1 =
11735      new NISuppressor(0, RangeInt.EqualOne.class);
11736  private static NISuppressor arg2_eq_1 =
11737      new NISuppressor(1, RangeInt.EqualOne.class);
11738
11739  private static NISuppressor result_eq_0 =
11740      new NISuppressor(2, RangeInt.EqualZero.class);
11741  private static NISuppressor arg1_eq_0 =
11742      new NISuppressor(0, RangeInt.EqualZero.class);
11743  private static NISuppressor arg2_eq_0 =
11744      new NISuppressor(1, RangeInt.EqualZero.class);
11745
11746  private static NISuppressor result_ne_0 =
11747      new NISuppressor(2, NonZero.class);
11748  private static NISuppressor arg1_ne_0 =
11749      new NISuppressor(0, NonZero.class);
11750  private static NISuppressor arg2_ne_0 =
11751      new NISuppressor(1, NonZero.class);
11752
11753  private static NISuppressor result_ge_0 =
11754      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
11755  private static NISuppressor arg1_ge_0 =
11756      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
11757  private static NISuppressor arg2_ge_0 =
11758      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
11759
11760  private static NISuppressor result_ge_64 =
11761      new NISuppressor(2, RangeInt.GreaterEqual64.class);
11762  private static NISuppressor arg1_ge_64 =
11763      new NISuppressor(0, RangeInt.GreaterEqual64.class);
11764  private static NISuppressor arg2_ge_64 =
11765      new NISuppressor(1, RangeInt.GreaterEqual64.class);
11766
11767  private static NISuppressor result_boolean =
11768      new NISuppressor(2, RangeInt.BooleanVal.class);
11769  private static NISuppressor arg1_boolean =
11770      new NISuppressor(0, RangeInt.BooleanVal.class);
11771  private static NISuppressor arg2_boolean =
11772      new NISuppressor(1, RangeInt.BooleanVal.class);
11773
11774  private static NISuppressor result_even =
11775      new NISuppressor(2, RangeInt.Even.class);
11776  private static NISuppressor arg1_even =
11777      new NISuppressor(0, RangeInt.Even.class);
11778  private static NISuppressor arg2_even =
11779      new NISuppressor(1, RangeInt.Even.class);
11780
11781  private static NISuppressor result_power2 =
11782      new NISuppressor(2, RangeInt.PowerOfTwo.class);
11783  private static NISuppressor arg1_power2 =
11784      new NISuppressor(0, RangeInt.PowerOfTwo.class);
11785  private static NISuppressor arg2_power2 =
11786      new NISuppressor(1, RangeInt.PowerOfTwo.class);
11787
11788  private static NISuppressor result_and0_arg1 =
11789      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
11790  private static NISuppressor result_and0_arg2 =
11791      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
11792  private static NISuppressor arg1_and0_arg2 =
11793      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
11794
11795  // The arguments to bitwise subset are backwards from what one
11796  // might expect.  The second argument is a subset of the first
11797  // argument
11798  private static NISuppressor arg1_bw_subset_arg2 =
11799      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
11800  private static NISuppressor arg2_bw_subset_arg1 =
11801      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
11802
11803  private static NISuppressor result_shift0_arg1 =
11804      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
11805  private static NISuppressor result_shift0_arg2 =
11806      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
11807  private static NISuppressor arg1_shift0_arg2 =
11808      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
11809
11810  private static NISuppressor arg2_divides_arg1 =
11811      new NISuppressor(0, 1, NumericInt.Divides.class);
11812  private static NISuppressor arg1_divides_arg2 =
11813      new NISuppressor(1, 0, NumericInt.Divides.class);
11814
11815  private static NISuppressor arg2_valid_shift =
11816      new NISuppressor(1, RangeInt.Bound0_63.class);
11817
11818    // gcd (0, y) == y
11819    // gcd (0, 0) == 0
11820    // gcd (1, y) == 1
11821
11822    private static NISuppressionSet suppressions =
11823        new NISuppressionSet(
11824          new NISuppression[] {
11825
11826            // (r == x) && (x == y) && (r == y) && (r >= 0)
11827            //    ==> r = Gcd (x, y)
11828            new NISuppression(result_eq_arg1, arg1_eq_arg2, result_eq_arg2,
11829                               result_ge_0, suppressee),
11830
11831            // (r == x) && (y == 0) && (r >= 0) ==> r = gcd (x, y)
11832            new NISuppression(result_eq_arg1, result_ge_0, arg2_eq_0, suppressee),
11833
11834            // (r == y) && (x == 0) && (r >= 0) ==> r = gcd (x, y)
11835            new NISuppression(result_eq_arg2, result_ge_0, arg1_eq_0, suppressee),
11836
11837            // (r == 1) && (y == 1)        ==> r = gcd (x, art2)
11838            new NISuppression(result_eq_1, arg2_eq_1, suppressee),
11839
11840            // (r == 1) && (x == 1)        ==> r = gcd (x, art2)
11841            new NISuppression(result_eq_1, arg1_eq_1, suppressee),
11842
11843            // (r == x) && (x divides y) && (r >= 0)
11844            new NISuppression(result_eq_arg1, arg1_divides_arg2, result_ge_0, suppressee),
11845
11846            // (r == y) && (y divides x) && (r >= 0)
11847            new NISuppression(result_eq_arg2, arg2_divides_arg1, result_ge_0, suppressee),
11848
11849            // (r == y) && (y boolean) && (y==0 ==> x==0)
11850            // 0 = gcd (x, 0) true when (x == 0)
11851            // 1 = gcd (x, 1) always true
11852            new NISuppression(result_eq_arg2, arg2_track0_arg1, arg2_boolean,
11853                               suppressee),
11854
11855            // (r == x) && (x boolean) && (x==0 ==> y==0)
11856            // 0 = gcd (0, y), true if (y == 0)
11857            // 1 = gcd (1, y), always true
11858            new NISuppression(result_eq_arg1, arg1_boolean, arg1_track0_arg2,
11859                               suppressee),
11860
11861          });
11862
11863  // Create a suppression factory for functionBinary
11864
11865}
11866
11867  // default is that it is not this function, overriden in the subclass
11868  @Pure
11869  public boolean isMod() {
11870    return false;
11871  }
11872
11873/**
11874 * Represents the invariant {@code x = Mod(y, z)} over three long
11875 * scalars. 
11876 */
11877public static class ModLong_xyz extends FunctionBinary {
11878  // We are Serializable, so we specify a version to allow changes to
11879  // method signatures without breaking serialization.  If you add or
11880  // remove fields, you should change this number to the current date.
11881  static final long serialVersionUID = 20031030L;
11882
11883  private static @Prototype ModLong_xyz proto = new @Prototype ModLong_xyz ();
11884
11885  /** Returns the prototype invariant for ModLong_xyz */
11886  public static @Prototype ModLong_xyz get_proto() {
11887    return proto;
11888  }
11889
11890  /** instantiate an invariant on the specified slice */
11891  @Override
11892  protected ModLong_xyz instantiate_dyn(@Prototype ModLong_xyz this, PptSlice slice) {
11893    return new ModLong_xyz (slice);
11894  }
11895
11896  private ModLong_xyz (PptSlice slice) {
11897    super(slice);
11898  }
11899
11900  public @Prototype ModLong_xyz () {
11901    super();
11902  }
11903
11904  private static String[] method_name = new String[] {"", " % ", ""};
11905
11906  @Override
11907  public String[] get_method_name(@GuardSatisfied ModLong_xyz this) {
11908    return method_name;
11909  }
11910
11911  private static int function_id = -1;
11912
11913  @Override
11914  public int get_function_id() {
11915    return function_id;
11916  }
11917
11918  @Override
11919  public void set_function_id(int function_id) {
11920    assert ModLong_xyz.function_id == -1;
11921    ModLong_xyz.function_id = function_id;
11922  }
11923
11924  private static int var_order = 1;
11925
11926  @Override
11927  public int get_var_order(@GuardSatisfied ModLong_xyz this) {
11928    return var_order;
11929  }
11930
11931  @Pure
11932  @Override
11933  public boolean is_symmetric() {
11934
11935      return false;
11936  }
11937
11938  @Override
11939
11940  public long func(long y, long z) {
11941
11942    return (y % z);
11943  }
11944
11945  @Override
11946  public InvariantStatus check_modified(long x, long y,
11947                                      long z, int count) {
11948    return check_ordered(x, y, z, count);
11949  }
11950
11951  @Override
11952  public InvariantStatus add_modified(long x, long y,
11953                                      long z, int count) {
11954    if (Debug.logDetail()) {
11955      log("result=%s, arg1=%s, arg2=%s", x, y, z);
11956    }
11957    return add_ordered(x, y, z, count);
11958  }
11959
11960  @Pure
11961  @Override
11962  public boolean isMod() {
11963    return true;
11964  }
11965
11966  /** Returns a list of non-instantiating suppressions for this invariant. */
11967  @Pure
11968  @Override
11969  public @Nullable NISuppressionSet get_ni_suppressions() {
11970    if (NIS.dkconfig_enabled && dkconfig_enabled) {
11971      return suppressions;
11972    } else {
11973      return null;
11974    }
11975  }
11976
11977  /** definition of this invariant (the suppressee) */
11978  private static NISuppressee suppressee = new NISuppressee(ModLong_xyz.class, 3);
11979
11980  // suppressor definitions (used below)
11981  private static NISuppressor result_eq_arg1 =
11982      new NISuppressor(0, 1, IntEqual.class);
11983  private static NISuppressor result_eq_arg2 =
11984      new NISuppressor(0, 2, IntEqual.class);
11985  private static NISuppressor arg1_eq_arg2 =
11986      new NISuppressor(1, 2, IntEqual.class);
11987
11988  private static NISuppressor result_lt_arg1 =
11989      new NISuppressor(0, 1, IntLessThan.class);
11990  private static NISuppressor result_lt_arg2 =
11991      new NISuppressor(0, 2, IntLessThan.class);
11992  private static NISuppressor arg1_lt_arg2 =
11993      new NISuppressor(1, 2, IntLessThan.class);
11994  private static NISuppressor arg2_lt_arg1 =
11995      new NISuppressor(2, 1, IntLessThan.class);
11996
11997  private static NISuppressor result_le_arg1 =
11998      new NISuppressor(0, 1, IntLessEqual.class);
11999  private static NISuppressor result_le_arg2 =
12000      new NISuppressor(0, 2, IntLessEqual.class);
12001  private static NISuppressor arg1_le_arg2 =
12002      new NISuppressor(1, 2, IntLessEqual.class);
12003  private static NISuppressor arg2_le_arg1 =
12004      new NISuppressor(2, 1, IntLessEqual.class);
12005
12006  private static NISuppressor result_track0_arg1 =
12007      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
12008  private static NISuppressor result_track0_arg2 =
12009      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
12010  private static NISuppressor arg1_track0_arg2 =
12011      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
12012  private static NISuppressor arg1_track0_result =
12013      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
12014  private static NISuppressor arg2_track0_result =
12015      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
12016  private static NISuppressor arg2_track0_arg1 =
12017      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
12018
12019  private static NISuppressor result_eq_1 =
12020      new NISuppressor(0, RangeInt.EqualOne.class);
12021  private static NISuppressor arg1_eq_1 =
12022      new NISuppressor(1, RangeInt.EqualOne.class);
12023  private static NISuppressor arg2_eq_1 =
12024      new NISuppressor(2, RangeInt.EqualOne.class);
12025
12026  private static NISuppressor result_eq_0 =
12027      new NISuppressor(0, RangeInt.EqualZero.class);
12028  private static NISuppressor arg1_eq_0 =
12029      new NISuppressor(1, RangeInt.EqualZero.class);
12030  private static NISuppressor arg2_eq_0 =
12031      new NISuppressor(2, RangeInt.EqualZero.class);
12032
12033  private static NISuppressor result_ne_0 =
12034      new NISuppressor(0, NonZero.class);
12035  private static NISuppressor arg1_ne_0 =
12036      new NISuppressor(1, NonZero.class);
12037  private static NISuppressor arg2_ne_0 =
12038      new NISuppressor(2, NonZero.class);
12039
12040  private static NISuppressor result_ge_0 =
12041      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
12042  private static NISuppressor arg1_ge_0 =
12043      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
12044  private static NISuppressor arg2_ge_0 =
12045      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
12046
12047  private static NISuppressor result_ge_64 =
12048      new NISuppressor(0, RangeInt.GreaterEqual64.class);
12049  private static NISuppressor arg1_ge_64 =
12050      new NISuppressor(1, RangeInt.GreaterEqual64.class);
12051  private static NISuppressor arg2_ge_64 =
12052      new NISuppressor(2, RangeInt.GreaterEqual64.class);
12053
12054  private static NISuppressor result_boolean =
12055      new NISuppressor(0, RangeInt.BooleanVal.class);
12056  private static NISuppressor arg1_boolean =
12057      new NISuppressor(1, RangeInt.BooleanVal.class);
12058  private static NISuppressor arg2_boolean =
12059      new NISuppressor(2, RangeInt.BooleanVal.class);
12060
12061  private static NISuppressor result_even =
12062      new NISuppressor(0, RangeInt.Even.class);
12063  private static NISuppressor arg1_even =
12064      new NISuppressor(1, RangeInt.Even.class);
12065  private static NISuppressor arg2_even =
12066      new NISuppressor(2, RangeInt.Even.class);
12067
12068  private static NISuppressor result_power2 =
12069      new NISuppressor(0, RangeInt.PowerOfTwo.class);
12070  private static NISuppressor arg1_power2 =
12071      new NISuppressor(1, RangeInt.PowerOfTwo.class);
12072  private static NISuppressor arg2_power2 =
12073      new NISuppressor(2, RangeInt.PowerOfTwo.class);
12074
12075  private static NISuppressor result_and0_arg1 =
12076      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
12077  private static NISuppressor result_and0_arg2 =
12078      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
12079  private static NISuppressor arg1_and0_arg2 =
12080      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
12081
12082  // The arguments to bitwise subset are backwards from what one
12083  // might expect.  The second argument is a subset of the first
12084  // argument
12085  private static NISuppressor arg1_bw_subset_arg2 =
12086      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
12087  private static NISuppressor arg2_bw_subset_arg1 =
12088      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
12089
12090  private static NISuppressor result_shift0_arg1 =
12091      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
12092  private static NISuppressor result_shift0_arg2 =
12093      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
12094  private static NISuppressor arg1_shift0_arg2 =
12095      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
12096
12097  private static NISuppressor arg2_divides_arg1 =
12098      new NISuppressor(1, 2, NumericInt.Divides.class);
12099  private static NISuppressor arg1_divides_arg2 =
12100      new NISuppressor(2, 1, NumericInt.Divides.class);
12101
12102  private static NISuppressor arg2_valid_shift =
12103      new NISuppressor(2, RangeInt.Bound0_63.class);
12104
12105    private static NISuppressionSet suppressions =
12106      new NISuppressionSet(
12107          new NISuppression[] {
12108            // anything mod 0 is undefined
12109            // (r == y) && (y < z) && (z != 0) && (r >= 0) ==> r = y % z
12110            new NISuppression(result_eq_arg1, arg1_lt_arg2, arg2_ne_0, result_ge_0, suppressee),
12111
12112            // (r == 0) && ((y % z) == 0)
12113            new NISuppression(result_eq_0, arg2_divides_arg1, suppressee),
12114
12115            // These are unnecessary as the divides invariant handles these
12116            // nicely.
12117            // (r == 0) && (z == 1)      ==> r = y % z
12118            // new NISuppression (result_eq_0, arg2_eq_1, suppressee),
12119
12120            // (r == 0) && (y == z)
12121            // new NISuppression (result_eq_0, arg1_eq_arg2, suppressee),
12122          });
12123
12124  // Create a suppression factory for functionBinary
12125
12126}
12127
12128/**
12129 * Represents the invariant {@code y = Mod(x, z)} over three long
12130 * scalars. 
12131 */
12132public static class ModLong_yxz extends FunctionBinary {
12133  // We are Serializable, so we specify a version to allow changes to
12134  // method signatures without breaking serialization.  If you add or
12135  // remove fields, you should change this number to the current date.
12136  static final long serialVersionUID = 20031030L;
12137
12138  private static @Prototype ModLong_yxz proto = new @Prototype ModLong_yxz ();
12139
12140  /** Returns the prototype invariant for ModLong_yxz */
12141  public static @Prototype ModLong_yxz get_proto() {
12142    return proto;
12143  }
12144
12145  /** instantiate an invariant on the specified slice */
12146  @Override
12147  protected ModLong_yxz instantiate_dyn(@Prototype ModLong_yxz this, PptSlice slice) {
12148    return new ModLong_yxz (slice);
12149  }
12150
12151  private ModLong_yxz (PptSlice slice) {
12152    super(slice);
12153  }
12154
12155  public @Prototype ModLong_yxz () {
12156    super();
12157  }
12158
12159  private static String[] method_name = new String[] {"", " % ", ""};
12160
12161  @Override
12162  public String[] get_method_name(@GuardSatisfied ModLong_yxz this) {
12163    return method_name;
12164  }
12165
12166  private static int function_id = -1;
12167
12168  @Override
12169  public int get_function_id() {
12170    return function_id;
12171  }
12172
12173  @Override
12174  public void set_function_id(int function_id) {
12175    assert ModLong_yxz.function_id == -1;
12176    ModLong_yxz.function_id = function_id;
12177  }
12178
12179  private static int var_order = 2;
12180
12181  @Override
12182  public int get_var_order(@GuardSatisfied ModLong_yxz this) {
12183    return var_order;
12184  }
12185
12186  @Pure
12187  @Override
12188  public boolean is_symmetric() {
12189
12190      return false;
12191  }
12192
12193  @Override
12194
12195  public long func(long x, long z) {
12196
12197    return (x % z);
12198  }
12199
12200  @Override
12201  public InvariantStatus check_modified(long x, long y,
12202                                      long z, int count) {
12203    return check_ordered(y, x, z, count);
12204  }
12205
12206  @Override
12207  public InvariantStatus add_modified(long x, long y,
12208                                      long z, int count) {
12209    if (Debug.logDetail()) {
12210      log("result=%s, arg1=%s, arg2=%s", y, x, z);
12211    }
12212    return add_ordered(y, x, z, count);
12213  }
12214
12215  @Pure
12216  @Override
12217  public boolean isMod() {
12218    return true;
12219  }
12220
12221  /** Returns a list of non-instantiating suppressions for this invariant. */
12222  @Pure
12223  @Override
12224  public @Nullable NISuppressionSet get_ni_suppressions() {
12225    if (NIS.dkconfig_enabled && dkconfig_enabled) {
12226      return suppressions;
12227    } else {
12228      return null;
12229    }
12230  }
12231
12232  /** definition of this invariant (the suppressee) */
12233  private static NISuppressee suppressee = new NISuppressee(ModLong_yxz.class, 3);
12234
12235  // suppressor definitions (used below)
12236  private static NISuppressor result_eq_arg1 =
12237      new NISuppressor(1, 0, IntEqual.class);
12238  private static NISuppressor result_eq_arg2 =
12239      new NISuppressor(1, 2, IntEqual.class);
12240  private static NISuppressor arg1_eq_arg2 =
12241      new NISuppressor(0, 2, IntEqual.class);
12242
12243  private static NISuppressor result_lt_arg1 =
12244      new NISuppressor(1, 0, IntLessThan.class);
12245  private static NISuppressor result_lt_arg2 =
12246      new NISuppressor(1, 2, IntLessThan.class);
12247  private static NISuppressor arg1_lt_arg2 =
12248      new NISuppressor(0, 2, IntLessThan.class);
12249  private static NISuppressor arg2_lt_arg1 =
12250      new NISuppressor(2, 0, IntLessThan.class);
12251
12252  private static NISuppressor result_le_arg1 =
12253      new NISuppressor(1, 0, IntLessEqual.class);
12254  private static NISuppressor result_le_arg2 =
12255      new NISuppressor(1, 2, IntLessEqual.class);
12256  private static NISuppressor arg1_le_arg2 =
12257      new NISuppressor(0, 2, IntLessEqual.class);
12258  private static NISuppressor arg2_le_arg1 =
12259      new NISuppressor(2, 0, IntLessEqual.class);
12260
12261  private static NISuppressor result_track0_arg1 =
12262      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
12263  private static NISuppressor result_track0_arg2 =
12264      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
12265  private static NISuppressor arg1_track0_arg2 =
12266      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
12267  private static NISuppressor arg1_track0_result =
12268      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
12269  private static NISuppressor arg2_track0_result =
12270      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
12271  private static NISuppressor arg2_track0_arg1 =
12272      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
12273
12274  private static NISuppressor result_eq_1 =
12275      new NISuppressor(1, RangeInt.EqualOne.class);
12276  private static NISuppressor arg1_eq_1 =
12277      new NISuppressor(0, RangeInt.EqualOne.class);
12278  private static NISuppressor arg2_eq_1 =
12279      new NISuppressor(2, RangeInt.EqualOne.class);
12280
12281  private static NISuppressor result_eq_0 =
12282      new NISuppressor(1, RangeInt.EqualZero.class);
12283  private static NISuppressor arg1_eq_0 =
12284      new NISuppressor(0, RangeInt.EqualZero.class);
12285  private static NISuppressor arg2_eq_0 =
12286      new NISuppressor(2, RangeInt.EqualZero.class);
12287
12288  private static NISuppressor result_ne_0 =
12289      new NISuppressor(1, NonZero.class);
12290  private static NISuppressor arg1_ne_0 =
12291      new NISuppressor(0, NonZero.class);
12292  private static NISuppressor arg2_ne_0 =
12293      new NISuppressor(2, NonZero.class);
12294
12295  private static NISuppressor result_ge_0 =
12296      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
12297  private static NISuppressor arg1_ge_0 =
12298      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
12299  private static NISuppressor arg2_ge_0 =
12300      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
12301
12302  private static NISuppressor result_ge_64 =
12303      new NISuppressor(1, RangeInt.GreaterEqual64.class);
12304  private static NISuppressor arg1_ge_64 =
12305      new NISuppressor(0, RangeInt.GreaterEqual64.class);
12306  private static NISuppressor arg2_ge_64 =
12307      new NISuppressor(2, RangeInt.GreaterEqual64.class);
12308
12309  private static NISuppressor result_boolean =
12310      new NISuppressor(1, RangeInt.BooleanVal.class);
12311  private static NISuppressor arg1_boolean =
12312      new NISuppressor(0, RangeInt.BooleanVal.class);
12313  private static NISuppressor arg2_boolean =
12314      new NISuppressor(2, RangeInt.BooleanVal.class);
12315
12316  private static NISuppressor result_even =
12317      new NISuppressor(1, RangeInt.Even.class);
12318  private static NISuppressor arg1_even =
12319      new NISuppressor(0, RangeInt.Even.class);
12320  private static NISuppressor arg2_even =
12321      new NISuppressor(2, RangeInt.Even.class);
12322
12323  private static NISuppressor result_power2 =
12324      new NISuppressor(1, RangeInt.PowerOfTwo.class);
12325  private static NISuppressor arg1_power2 =
12326      new NISuppressor(0, RangeInt.PowerOfTwo.class);
12327  private static NISuppressor arg2_power2 =
12328      new NISuppressor(2, RangeInt.PowerOfTwo.class);
12329
12330  private static NISuppressor result_and0_arg1 =
12331      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
12332  private static NISuppressor result_and0_arg2 =
12333      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
12334  private static NISuppressor arg1_and0_arg2 =
12335      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
12336
12337  // The arguments to bitwise subset are backwards from what one
12338  // might expect.  The second argument is a subset of the first
12339  // argument
12340  private static NISuppressor arg1_bw_subset_arg2 =
12341      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
12342  private static NISuppressor arg2_bw_subset_arg1 =
12343      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
12344
12345  private static NISuppressor result_shift0_arg1 =
12346      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
12347  private static NISuppressor result_shift0_arg2 =
12348      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
12349  private static NISuppressor arg1_shift0_arg2 =
12350      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
12351
12352  private static NISuppressor arg2_divides_arg1 =
12353      new NISuppressor(0, 2, NumericInt.Divides.class);
12354  private static NISuppressor arg1_divides_arg2 =
12355      new NISuppressor(2, 0, NumericInt.Divides.class);
12356
12357  private static NISuppressor arg2_valid_shift =
12358      new NISuppressor(2, RangeInt.Bound0_63.class);
12359
12360    private static NISuppressionSet suppressions =
12361      new NISuppressionSet(
12362          new NISuppression[] {
12363            // anything mod 0 is undefined
12364            // (r == x) && (x < z) && (z != 0) && (r >= 0) ==> r = x % z
12365            new NISuppression(result_eq_arg1, arg1_lt_arg2, arg2_ne_0, result_ge_0, suppressee),
12366
12367            // (r == 0) && ((x % z) == 0)
12368            new NISuppression(result_eq_0, arg2_divides_arg1, suppressee),
12369
12370            // These are unnecessary as the divides invariant handles these
12371            // nicely.
12372            // (r == 0) && (z == 1)      ==> r = x % z
12373            // new NISuppression (result_eq_0, arg2_eq_1, suppressee),
12374
12375            // (r == 0) && (x == z)
12376            // new NISuppression (result_eq_0, arg1_eq_arg2, suppressee),
12377          });
12378
12379  // Create a suppression factory for functionBinary
12380
12381}
12382
12383/**
12384 * Represents the invariant {@code z = Mod(x, y)} over three long
12385 * scalars. 
12386 */
12387public static class ModLong_zxy extends FunctionBinary {
12388  // We are Serializable, so we specify a version to allow changes to
12389  // method signatures without breaking serialization.  If you add or
12390  // remove fields, you should change this number to the current date.
12391  static final long serialVersionUID = 20031030L;
12392
12393  private static @Prototype ModLong_zxy proto = new @Prototype ModLong_zxy ();
12394
12395  /** Returns the prototype invariant for ModLong_zxy */
12396  public static @Prototype ModLong_zxy get_proto() {
12397    return proto;
12398  }
12399
12400  /** instantiate an invariant on the specified slice */
12401  @Override
12402  protected ModLong_zxy instantiate_dyn(@Prototype ModLong_zxy this, PptSlice slice) {
12403    return new ModLong_zxy (slice);
12404  }
12405
12406  private ModLong_zxy (PptSlice slice) {
12407    super(slice);
12408  }
12409
12410  public @Prototype ModLong_zxy () {
12411    super();
12412  }
12413
12414  private static String[] method_name = new String[] {"", " % ", ""};
12415
12416  @Override
12417  public String[] get_method_name(@GuardSatisfied ModLong_zxy this) {
12418    return method_name;
12419  }
12420
12421  private static int function_id = -1;
12422
12423  @Override
12424  public int get_function_id() {
12425    return function_id;
12426  }
12427
12428  @Override
12429  public void set_function_id(int function_id) {
12430    assert ModLong_zxy.function_id == -1;
12431    ModLong_zxy.function_id = function_id;
12432  }
12433
12434  private static int var_order = 3;
12435
12436  @Override
12437  public int get_var_order(@GuardSatisfied ModLong_zxy this) {
12438    return var_order;
12439  }
12440
12441  @Pure
12442  @Override
12443  public boolean is_symmetric() {
12444
12445      return false;
12446  }
12447
12448  @Override
12449
12450  public long func(long x, long y) {
12451
12452    return (x % y);
12453  }
12454
12455  @Override
12456  public InvariantStatus check_modified(long x, long y,
12457                                      long z, int count) {
12458    return check_ordered(z, x, y, count);
12459  }
12460
12461  @Override
12462  public InvariantStatus add_modified(long x, long y,
12463                                      long z, int count) {
12464    if (Debug.logDetail()) {
12465      log("result=%s, arg1=%s, arg2=%s", z, x, y);
12466    }
12467    return add_ordered(z, x, y, count);
12468  }
12469
12470  @Pure
12471  @Override
12472  public boolean isMod() {
12473    return true;
12474  }
12475
12476  /** Returns a list of non-instantiating suppressions for this invariant. */
12477  @Pure
12478  @Override
12479  public @Nullable NISuppressionSet get_ni_suppressions() {
12480    if (NIS.dkconfig_enabled && dkconfig_enabled) {
12481      return suppressions;
12482    } else {
12483      return null;
12484    }
12485  }
12486
12487  /** definition of this invariant (the suppressee) */
12488  private static NISuppressee suppressee = new NISuppressee(ModLong_zxy.class, 3);
12489
12490  // suppressor definitions (used below)
12491  private static NISuppressor result_eq_arg1 =
12492      new NISuppressor(2, 0, IntEqual.class);
12493  private static NISuppressor result_eq_arg2 =
12494      new NISuppressor(2, 1, IntEqual.class);
12495  private static NISuppressor arg1_eq_arg2 =
12496      new NISuppressor(0, 1, IntEqual.class);
12497
12498  private static NISuppressor result_lt_arg1 =
12499      new NISuppressor(2, 0, IntLessThan.class);
12500  private static NISuppressor result_lt_arg2 =
12501      new NISuppressor(2, 1, IntLessThan.class);
12502  private static NISuppressor arg1_lt_arg2 =
12503      new NISuppressor(0, 1, IntLessThan.class);
12504  private static NISuppressor arg2_lt_arg1 =
12505      new NISuppressor(1, 0, IntLessThan.class);
12506
12507  private static NISuppressor result_le_arg1 =
12508      new NISuppressor(2, 0, IntLessEqual.class);
12509  private static NISuppressor result_le_arg2 =
12510      new NISuppressor(2, 1, IntLessEqual.class);
12511  private static NISuppressor arg1_le_arg2 =
12512      new NISuppressor(0, 1, IntLessEqual.class);
12513  private static NISuppressor arg2_le_arg1 =
12514      new NISuppressor(1, 0, IntLessEqual.class);
12515
12516  private static NISuppressor result_track0_arg1 =
12517      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
12518  private static NISuppressor result_track0_arg2 =
12519      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
12520  private static NISuppressor arg1_track0_arg2 =
12521      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
12522  private static NISuppressor arg1_track0_result =
12523      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
12524  private static NISuppressor arg2_track0_result =
12525      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
12526  private static NISuppressor arg2_track0_arg1 =
12527      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
12528
12529  private static NISuppressor result_eq_1 =
12530      new NISuppressor(2, RangeInt.EqualOne.class);
12531  private static NISuppressor arg1_eq_1 =
12532      new NISuppressor(0, RangeInt.EqualOne.class);
12533  private static NISuppressor arg2_eq_1 =
12534      new NISuppressor(1, RangeInt.EqualOne.class);
12535
12536  private static NISuppressor result_eq_0 =
12537      new NISuppressor(2, RangeInt.EqualZero.class);
12538  private static NISuppressor arg1_eq_0 =
12539      new NISuppressor(0, RangeInt.EqualZero.class);
12540  private static NISuppressor arg2_eq_0 =
12541      new NISuppressor(1, RangeInt.EqualZero.class);
12542
12543  private static NISuppressor result_ne_0 =
12544      new NISuppressor(2, NonZero.class);
12545  private static NISuppressor arg1_ne_0 =
12546      new NISuppressor(0, NonZero.class);
12547  private static NISuppressor arg2_ne_0 =
12548      new NISuppressor(1, NonZero.class);
12549
12550  private static NISuppressor result_ge_0 =
12551      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
12552  private static NISuppressor arg1_ge_0 =
12553      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
12554  private static NISuppressor arg2_ge_0 =
12555      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
12556
12557  private static NISuppressor result_ge_64 =
12558      new NISuppressor(2, RangeInt.GreaterEqual64.class);
12559  private static NISuppressor arg1_ge_64 =
12560      new NISuppressor(0, RangeInt.GreaterEqual64.class);
12561  private static NISuppressor arg2_ge_64 =
12562      new NISuppressor(1, RangeInt.GreaterEqual64.class);
12563
12564  private static NISuppressor result_boolean =
12565      new NISuppressor(2, RangeInt.BooleanVal.class);
12566  private static NISuppressor arg1_boolean =
12567      new NISuppressor(0, RangeInt.BooleanVal.class);
12568  private static NISuppressor arg2_boolean =
12569      new NISuppressor(1, RangeInt.BooleanVal.class);
12570
12571  private static NISuppressor result_even =
12572      new NISuppressor(2, RangeInt.Even.class);
12573  private static NISuppressor arg1_even =
12574      new NISuppressor(0, RangeInt.Even.class);
12575  private static NISuppressor arg2_even =
12576      new NISuppressor(1, RangeInt.Even.class);
12577
12578  private static NISuppressor result_power2 =
12579      new NISuppressor(2, RangeInt.PowerOfTwo.class);
12580  private static NISuppressor arg1_power2 =
12581      new NISuppressor(0, RangeInt.PowerOfTwo.class);
12582  private static NISuppressor arg2_power2 =
12583      new NISuppressor(1, RangeInt.PowerOfTwo.class);
12584
12585  private static NISuppressor result_and0_arg1 =
12586      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
12587  private static NISuppressor result_and0_arg2 =
12588      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
12589  private static NISuppressor arg1_and0_arg2 =
12590      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
12591
12592  // The arguments to bitwise subset are backwards from what one
12593  // might expect.  The second argument is a subset of the first
12594  // argument
12595  private static NISuppressor arg1_bw_subset_arg2 =
12596      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
12597  private static NISuppressor arg2_bw_subset_arg1 =
12598      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
12599
12600  private static NISuppressor result_shift0_arg1 =
12601      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
12602  private static NISuppressor result_shift0_arg2 =
12603      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
12604  private static NISuppressor arg1_shift0_arg2 =
12605      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
12606
12607  private static NISuppressor arg2_divides_arg1 =
12608      new NISuppressor(0, 1, NumericInt.Divides.class);
12609  private static NISuppressor arg1_divides_arg2 =
12610      new NISuppressor(1, 0, NumericInt.Divides.class);
12611
12612  private static NISuppressor arg2_valid_shift =
12613      new NISuppressor(1, RangeInt.Bound0_63.class);
12614
12615    private static NISuppressionSet suppressions =
12616      new NISuppressionSet(
12617          new NISuppression[] {
12618            // anything mod 0 is undefined
12619            // (r == x) && (x < y) && (y != 0) && (r >= 0) ==> r = x % y
12620            new NISuppression(result_eq_arg1, arg1_lt_arg2, arg2_ne_0, result_ge_0, suppressee),
12621
12622            // (r == 0) && ((x % y) == 0)
12623            new NISuppression(result_eq_0, arg2_divides_arg1, suppressee),
12624
12625            // These are unnecessary as the divides invariant handles these
12626            // nicely.
12627            // (r == 0) && (y == 1)      ==> r = x % y
12628            // new NISuppression (result_eq_0, arg2_eq_1, suppressee),
12629
12630            // (r == 0) && (x == y)
12631            // new NISuppression (result_eq_0, arg1_eq_arg2, suppressee),
12632          });
12633
12634  // Create a suppression factory for functionBinary
12635
12636}
12637
12638/**
12639 * Represents the invariant {@code x = Mod(z, y)} over three long
12640 * scalars. 
12641 */
12642public static class ModLong_xzy extends FunctionBinary {
12643  // We are Serializable, so we specify a version to allow changes to
12644  // method signatures without breaking serialization.  If you add or
12645  // remove fields, you should change this number to the current date.
12646  static final long serialVersionUID = 20031030L;
12647
12648  private static @Prototype ModLong_xzy proto = new @Prototype ModLong_xzy ();
12649
12650  /** Returns the prototype invariant for ModLong_xzy */
12651  public static @Prototype ModLong_xzy get_proto() {
12652    return proto;
12653  }
12654
12655  /** instantiate an invariant on the specified slice */
12656  @Override
12657  protected ModLong_xzy instantiate_dyn(@Prototype ModLong_xzy this, PptSlice slice) {
12658    return new ModLong_xzy (slice);
12659  }
12660
12661  private ModLong_xzy (PptSlice slice) {
12662    super(slice);
12663  }
12664
12665  public @Prototype ModLong_xzy () {
12666    super();
12667  }
12668
12669  private static String[] method_name = new String[] {"", " % ", ""};
12670
12671  @Override
12672  public String[] get_method_name(@GuardSatisfied ModLong_xzy this) {
12673    return method_name;
12674  }
12675
12676  private static int function_id = -1;
12677
12678  @Override
12679  public int get_function_id() {
12680    return function_id;
12681  }
12682
12683  @Override
12684  public void set_function_id(int function_id) {
12685    assert ModLong_xzy.function_id == -1;
12686    ModLong_xzy.function_id = function_id;
12687  }
12688
12689  private static int var_order = 4;
12690
12691  @Override
12692  public int get_var_order(@GuardSatisfied ModLong_xzy this) {
12693    return var_order;
12694  }
12695
12696  @Pure
12697  @Override
12698  public boolean is_symmetric() {
12699
12700      return false;
12701  }
12702
12703  @Override
12704
12705  public long func(long z, long y) {
12706
12707    return (z % y);
12708  }
12709
12710  @Override
12711  public InvariantStatus check_modified(long x, long y,
12712                                      long z, int count) {
12713    return check_ordered(x, z, y, count);
12714  }
12715
12716  @Override
12717  public InvariantStatus add_modified(long x, long y,
12718                                      long z, int count) {
12719    if (Debug.logDetail()) {
12720      log("result=%s, arg1=%s, arg2=%s", x, z, y);
12721    }
12722    return add_ordered(x, z, y, count);
12723  }
12724
12725  @Pure
12726  @Override
12727  public boolean isMod() {
12728    return true;
12729  }
12730
12731  /** Returns a list of non-instantiating suppressions for this invariant. */
12732  @Pure
12733  @Override
12734  public @Nullable NISuppressionSet get_ni_suppressions() {
12735    if (NIS.dkconfig_enabled && dkconfig_enabled) {
12736      return suppressions;
12737    } else {
12738      return null;
12739    }
12740  }
12741
12742  /** definition of this invariant (the suppressee) */
12743  private static NISuppressee suppressee = new NISuppressee(ModLong_xzy.class, 3);
12744
12745  // suppressor definitions (used below)
12746  private static NISuppressor result_eq_arg1 =
12747      new NISuppressor(0, 2, IntEqual.class);
12748  private static NISuppressor result_eq_arg2 =
12749      new NISuppressor(0, 1, IntEqual.class);
12750  private static NISuppressor arg1_eq_arg2 =
12751      new NISuppressor(2, 1, IntEqual.class);
12752
12753  private static NISuppressor result_lt_arg1 =
12754      new NISuppressor(0, 2, IntLessThan.class);
12755  private static NISuppressor result_lt_arg2 =
12756      new NISuppressor(0, 1, IntLessThan.class);
12757  private static NISuppressor arg1_lt_arg2 =
12758      new NISuppressor(2, 1, IntLessThan.class);
12759  private static NISuppressor arg2_lt_arg1 =
12760      new NISuppressor(1, 2, IntLessThan.class);
12761
12762  private static NISuppressor result_le_arg1 =
12763      new NISuppressor(0, 2, IntLessEqual.class);
12764  private static NISuppressor result_le_arg2 =
12765      new NISuppressor(0, 1, IntLessEqual.class);
12766  private static NISuppressor arg1_le_arg2 =
12767      new NISuppressor(2, 1, IntLessEqual.class);
12768  private static NISuppressor arg2_le_arg1 =
12769      new NISuppressor(1, 2, IntLessEqual.class);
12770
12771  private static NISuppressor result_track0_arg1 =
12772      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
12773  private static NISuppressor result_track0_arg2 =
12774      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
12775  private static NISuppressor arg1_track0_arg2 =
12776      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
12777  private static NISuppressor arg1_track0_result =
12778      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
12779  private static NISuppressor arg2_track0_result =
12780      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
12781  private static NISuppressor arg2_track0_arg1 =
12782      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
12783
12784  private static NISuppressor result_eq_1 =
12785      new NISuppressor(0, RangeInt.EqualOne.class);
12786  private static NISuppressor arg1_eq_1 =
12787      new NISuppressor(2, RangeInt.EqualOne.class);
12788  private static NISuppressor arg2_eq_1 =
12789      new NISuppressor(1, RangeInt.EqualOne.class);
12790
12791  private static NISuppressor result_eq_0 =
12792      new NISuppressor(0, RangeInt.EqualZero.class);
12793  private static NISuppressor arg1_eq_0 =
12794      new NISuppressor(2, RangeInt.EqualZero.class);
12795  private static NISuppressor arg2_eq_0 =
12796      new NISuppressor(1, RangeInt.EqualZero.class);
12797
12798  private static NISuppressor result_ne_0 =
12799      new NISuppressor(0, NonZero.class);
12800  private static NISuppressor arg1_ne_0 =
12801      new NISuppressor(2, NonZero.class);
12802  private static NISuppressor arg2_ne_0 =
12803      new NISuppressor(1, NonZero.class);
12804
12805  private static NISuppressor result_ge_0 =
12806      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
12807  private static NISuppressor arg1_ge_0 =
12808      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
12809  private static NISuppressor arg2_ge_0 =
12810      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
12811
12812  private static NISuppressor result_ge_64 =
12813      new NISuppressor(0, RangeInt.GreaterEqual64.class);
12814  private static NISuppressor arg1_ge_64 =
12815      new NISuppressor(2, RangeInt.GreaterEqual64.class);
12816  private static NISuppressor arg2_ge_64 =
12817      new NISuppressor(1, RangeInt.GreaterEqual64.class);
12818
12819  private static NISuppressor result_boolean =
12820      new NISuppressor(0, RangeInt.BooleanVal.class);
12821  private static NISuppressor arg1_boolean =
12822      new NISuppressor(2, RangeInt.BooleanVal.class);
12823  private static NISuppressor arg2_boolean =
12824      new NISuppressor(1, RangeInt.BooleanVal.class);
12825
12826  private static NISuppressor result_even =
12827      new NISuppressor(0, RangeInt.Even.class);
12828  private static NISuppressor arg1_even =
12829      new NISuppressor(2, RangeInt.Even.class);
12830  private static NISuppressor arg2_even =
12831      new NISuppressor(1, RangeInt.Even.class);
12832
12833  private static NISuppressor result_power2 =
12834      new NISuppressor(0, RangeInt.PowerOfTwo.class);
12835  private static NISuppressor arg1_power2 =
12836      new NISuppressor(2, RangeInt.PowerOfTwo.class);
12837  private static NISuppressor arg2_power2 =
12838      new NISuppressor(1, RangeInt.PowerOfTwo.class);
12839
12840  private static NISuppressor result_and0_arg1 =
12841      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
12842  private static NISuppressor result_and0_arg2 =
12843      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
12844  private static NISuppressor arg1_and0_arg2 =
12845      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
12846
12847  // The arguments to bitwise subset are backwards from what one
12848  // might expect.  The second argument is a subset of the first
12849  // argument
12850  private static NISuppressor arg1_bw_subset_arg2 =
12851      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
12852  private static NISuppressor arg2_bw_subset_arg1 =
12853      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
12854
12855  private static NISuppressor result_shift0_arg1 =
12856      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
12857  private static NISuppressor result_shift0_arg2 =
12858      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
12859  private static NISuppressor arg1_shift0_arg2 =
12860      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
12861
12862  private static NISuppressor arg2_divides_arg1 =
12863      new NISuppressor(2, 1, NumericInt.Divides.class);
12864  private static NISuppressor arg1_divides_arg2 =
12865      new NISuppressor(1, 2, NumericInt.Divides.class);
12866
12867  private static NISuppressor arg2_valid_shift =
12868      new NISuppressor(1, RangeInt.Bound0_63.class);
12869
12870    private static NISuppressionSet suppressions =
12871      new NISuppressionSet(
12872          new NISuppression[] {
12873            // anything mod 0 is undefined
12874            // (r == z) && (z < y) && (y != 0) && (r >= 0) ==> r = z % y
12875            new NISuppression(result_eq_arg1, arg1_lt_arg2, arg2_ne_0, result_ge_0, suppressee),
12876
12877            // (r == 0) && ((z % y) == 0)
12878            new NISuppression(result_eq_0, arg2_divides_arg1, suppressee),
12879
12880            // These are unnecessary as the divides invariant handles these
12881            // nicely.
12882            // (r == 0) && (y == 1)      ==> r = z % y
12883            // new NISuppression (result_eq_0, arg2_eq_1, suppressee),
12884
12885            // (r == 0) && (z == y)
12886            // new NISuppression (result_eq_0, arg1_eq_arg2, suppressee),
12887          });
12888
12889  // Create a suppression factory for functionBinary
12890
12891}
12892
12893/**
12894 * Represents the invariant {@code y = Mod(z, x)} over three long
12895 * scalars. 
12896 */
12897public static class ModLong_yzx extends FunctionBinary {
12898  // We are Serializable, so we specify a version to allow changes to
12899  // method signatures without breaking serialization.  If you add or
12900  // remove fields, you should change this number to the current date.
12901  static final long serialVersionUID = 20031030L;
12902
12903  private static @Prototype ModLong_yzx proto = new @Prototype ModLong_yzx ();
12904
12905  /** Returns the prototype invariant for ModLong_yzx */
12906  public static @Prototype ModLong_yzx get_proto() {
12907    return proto;
12908  }
12909
12910  /** instantiate an invariant on the specified slice */
12911  @Override
12912  protected ModLong_yzx instantiate_dyn(@Prototype ModLong_yzx this, PptSlice slice) {
12913    return new ModLong_yzx (slice);
12914  }
12915
12916  private ModLong_yzx (PptSlice slice) {
12917    super(slice);
12918  }
12919
12920  public @Prototype ModLong_yzx () {
12921    super();
12922  }
12923
12924  private static String[] method_name = new String[] {"", " % ", ""};
12925
12926  @Override
12927  public String[] get_method_name(@GuardSatisfied ModLong_yzx this) {
12928    return method_name;
12929  }
12930
12931  private static int function_id = -1;
12932
12933  @Override
12934  public int get_function_id() {
12935    return function_id;
12936  }
12937
12938  @Override
12939  public void set_function_id(int function_id) {
12940    assert ModLong_yzx.function_id == -1;
12941    ModLong_yzx.function_id = function_id;
12942  }
12943
12944  private static int var_order = 5;
12945
12946  @Override
12947  public int get_var_order(@GuardSatisfied ModLong_yzx this) {
12948    return var_order;
12949  }
12950
12951  @Pure
12952  @Override
12953  public boolean is_symmetric() {
12954
12955      return false;
12956  }
12957
12958  @Override
12959
12960  public long func(long z, long x) {
12961
12962    return (z % x);
12963  }
12964
12965  @Override
12966  public InvariantStatus check_modified(long x, long y,
12967                                      long z, int count) {
12968    return check_ordered(y, z, x, count);
12969  }
12970
12971  @Override
12972  public InvariantStatus add_modified(long x, long y,
12973                                      long z, int count) {
12974    if (Debug.logDetail()) {
12975      log("result=%s, arg1=%s, arg2=%s", y, z, x);
12976    }
12977    return add_ordered(y, z, x, count);
12978  }
12979
12980  @Pure
12981  @Override
12982  public boolean isMod() {
12983    return true;
12984  }
12985
12986  /** Returns a list of non-instantiating suppressions for this invariant. */
12987  @Pure
12988  @Override
12989  public @Nullable NISuppressionSet get_ni_suppressions() {
12990    if (NIS.dkconfig_enabled && dkconfig_enabled) {
12991      return suppressions;
12992    } else {
12993      return null;
12994    }
12995  }
12996
12997  /** definition of this invariant (the suppressee) */
12998  private static NISuppressee suppressee = new NISuppressee(ModLong_yzx.class, 3);
12999
13000  // suppressor definitions (used below)
13001  private static NISuppressor result_eq_arg1 =
13002      new NISuppressor(1, 2, IntEqual.class);
13003  private static NISuppressor result_eq_arg2 =
13004      new NISuppressor(1, 0, IntEqual.class);
13005  private static NISuppressor arg1_eq_arg2 =
13006      new NISuppressor(2, 0, IntEqual.class);
13007
13008  private static NISuppressor result_lt_arg1 =
13009      new NISuppressor(1, 2, IntLessThan.class);
13010  private static NISuppressor result_lt_arg2 =
13011      new NISuppressor(1, 0, IntLessThan.class);
13012  private static NISuppressor arg1_lt_arg2 =
13013      new NISuppressor(2, 0, IntLessThan.class);
13014  private static NISuppressor arg2_lt_arg1 =
13015      new NISuppressor(0, 2, IntLessThan.class);
13016
13017  private static NISuppressor result_le_arg1 =
13018      new NISuppressor(1, 2, IntLessEqual.class);
13019  private static NISuppressor result_le_arg2 =
13020      new NISuppressor(1, 0, IntLessEqual.class);
13021  private static NISuppressor arg1_le_arg2 =
13022      new NISuppressor(2, 0, IntLessEqual.class);
13023  private static NISuppressor arg2_le_arg1 =
13024      new NISuppressor(0, 2, IntLessEqual.class);
13025
13026  private static NISuppressor result_track0_arg1 =
13027      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
13028  private static NISuppressor result_track0_arg2 =
13029      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
13030  private static NISuppressor arg1_track0_arg2 =
13031      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
13032  private static NISuppressor arg1_track0_result =
13033      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
13034  private static NISuppressor arg2_track0_result =
13035      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
13036  private static NISuppressor arg2_track0_arg1 =
13037      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
13038
13039  private static NISuppressor result_eq_1 =
13040      new NISuppressor(1, RangeInt.EqualOne.class);
13041  private static NISuppressor arg1_eq_1 =
13042      new NISuppressor(2, RangeInt.EqualOne.class);
13043  private static NISuppressor arg2_eq_1 =
13044      new NISuppressor(0, RangeInt.EqualOne.class);
13045
13046  private static NISuppressor result_eq_0 =
13047      new NISuppressor(1, RangeInt.EqualZero.class);
13048  private static NISuppressor arg1_eq_0 =
13049      new NISuppressor(2, RangeInt.EqualZero.class);
13050  private static NISuppressor arg2_eq_0 =
13051      new NISuppressor(0, RangeInt.EqualZero.class);
13052
13053  private static NISuppressor result_ne_0 =
13054      new NISuppressor(1, NonZero.class);
13055  private static NISuppressor arg1_ne_0 =
13056      new NISuppressor(2, NonZero.class);
13057  private static NISuppressor arg2_ne_0 =
13058      new NISuppressor(0, NonZero.class);
13059
13060  private static NISuppressor result_ge_0 =
13061      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
13062  private static NISuppressor arg1_ge_0 =
13063      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
13064  private static NISuppressor arg2_ge_0 =
13065      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
13066
13067  private static NISuppressor result_ge_64 =
13068      new NISuppressor(1, RangeInt.GreaterEqual64.class);
13069  private static NISuppressor arg1_ge_64 =
13070      new NISuppressor(2, RangeInt.GreaterEqual64.class);
13071  private static NISuppressor arg2_ge_64 =
13072      new NISuppressor(0, RangeInt.GreaterEqual64.class);
13073
13074  private static NISuppressor result_boolean =
13075      new NISuppressor(1, RangeInt.BooleanVal.class);
13076  private static NISuppressor arg1_boolean =
13077      new NISuppressor(2, RangeInt.BooleanVal.class);
13078  private static NISuppressor arg2_boolean =
13079      new NISuppressor(0, RangeInt.BooleanVal.class);
13080
13081  private static NISuppressor result_even =
13082      new NISuppressor(1, RangeInt.Even.class);
13083  private static NISuppressor arg1_even =
13084      new NISuppressor(2, RangeInt.Even.class);
13085  private static NISuppressor arg2_even =
13086      new NISuppressor(0, RangeInt.Even.class);
13087
13088  private static NISuppressor result_power2 =
13089      new NISuppressor(1, RangeInt.PowerOfTwo.class);
13090  private static NISuppressor arg1_power2 =
13091      new NISuppressor(2, RangeInt.PowerOfTwo.class);
13092  private static NISuppressor arg2_power2 =
13093      new NISuppressor(0, RangeInt.PowerOfTwo.class);
13094
13095  private static NISuppressor result_and0_arg1 =
13096      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
13097  private static NISuppressor result_and0_arg2 =
13098      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
13099  private static NISuppressor arg1_and0_arg2 =
13100      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
13101
13102  // The arguments to bitwise subset are backwards from what one
13103  // might expect.  The second argument is a subset of the first
13104  // argument
13105  private static NISuppressor arg1_bw_subset_arg2 =
13106      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
13107  private static NISuppressor arg2_bw_subset_arg1 =
13108      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
13109
13110  private static NISuppressor result_shift0_arg1 =
13111      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
13112  private static NISuppressor result_shift0_arg2 =
13113      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
13114  private static NISuppressor arg1_shift0_arg2 =
13115      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
13116
13117  private static NISuppressor arg2_divides_arg1 =
13118      new NISuppressor(2, 0, NumericInt.Divides.class);
13119  private static NISuppressor arg1_divides_arg2 =
13120      new NISuppressor(0, 2, NumericInt.Divides.class);
13121
13122  private static NISuppressor arg2_valid_shift =
13123      new NISuppressor(0, RangeInt.Bound0_63.class);
13124
13125    private static NISuppressionSet suppressions =
13126      new NISuppressionSet(
13127          new NISuppression[] {
13128            // anything mod 0 is undefined
13129            // (r == z) && (z < x) && (x != 0) && (r >= 0) ==> r = z % x
13130            new NISuppression(result_eq_arg1, arg1_lt_arg2, arg2_ne_0, result_ge_0, suppressee),
13131
13132            // (r == 0) && ((z % x) == 0)
13133            new NISuppression(result_eq_0, arg2_divides_arg1, suppressee),
13134
13135            // These are unnecessary as the divides invariant handles these
13136            // nicely.
13137            // (r == 0) && (x == 1)      ==> r = z % x
13138            // new NISuppression (result_eq_0, arg2_eq_1, suppressee),
13139
13140            // (r == 0) && (z == x)
13141            // new NISuppression (result_eq_0, arg1_eq_arg2, suppressee),
13142          });
13143
13144  // Create a suppression factory for functionBinary
13145
13146}
13147
13148/**
13149 * Represents the invariant {@code z = Mod(y, x)} over three long
13150 * scalars. 
13151 */
13152public static class ModLong_zyx extends FunctionBinary {
13153  // We are Serializable, so we specify a version to allow changes to
13154  // method signatures without breaking serialization.  If you add or
13155  // remove fields, you should change this number to the current date.
13156  static final long serialVersionUID = 20031030L;
13157
13158  private static @Prototype ModLong_zyx proto = new @Prototype ModLong_zyx ();
13159
13160  /** Returns the prototype invariant for ModLong_zyx */
13161  public static @Prototype ModLong_zyx get_proto() {
13162    return proto;
13163  }
13164
13165  /** instantiate an invariant on the specified slice */
13166  @Override
13167  protected ModLong_zyx instantiate_dyn(@Prototype ModLong_zyx this, PptSlice slice) {
13168    return new ModLong_zyx (slice);
13169  }
13170
13171  private ModLong_zyx (PptSlice slice) {
13172    super(slice);
13173  }
13174
13175  public @Prototype ModLong_zyx () {
13176    super();
13177  }
13178
13179  private static String[] method_name = new String[] {"", " % ", ""};
13180
13181  @Override
13182  public String[] get_method_name(@GuardSatisfied ModLong_zyx this) {
13183    return method_name;
13184  }
13185
13186  private static int function_id = -1;
13187
13188  @Override
13189  public int get_function_id() {
13190    return function_id;
13191  }
13192
13193  @Override
13194  public void set_function_id(int function_id) {
13195    assert ModLong_zyx.function_id == -1;
13196    ModLong_zyx.function_id = function_id;
13197  }
13198
13199  private static int var_order = 6;
13200
13201  @Override
13202  public int get_var_order(@GuardSatisfied ModLong_zyx this) {
13203    return var_order;
13204  }
13205
13206  @Pure
13207  @Override
13208  public boolean is_symmetric() {
13209
13210      return false;
13211  }
13212
13213  @Override
13214
13215  public long func(long y, long x) {
13216
13217    return (y % x);
13218  }
13219
13220  @Override
13221  public InvariantStatus check_modified(long x, long y,
13222                                      long z, int count) {
13223    return check_ordered(z, y, x, count);
13224  }
13225
13226  @Override
13227  public InvariantStatus add_modified(long x, long y,
13228                                      long z, int count) {
13229    if (Debug.logDetail()) {
13230      log("result=%s, arg1=%s, arg2=%s", z, y, x);
13231    }
13232    return add_ordered(z, y, x, count);
13233  }
13234
13235  @Pure
13236  @Override
13237  public boolean isMod() {
13238    return true;
13239  }
13240
13241  /** Returns a list of non-instantiating suppressions for this invariant. */
13242  @Pure
13243  @Override
13244  public @Nullable NISuppressionSet get_ni_suppressions() {
13245    if (NIS.dkconfig_enabled && dkconfig_enabled) {
13246      return suppressions;
13247    } else {
13248      return null;
13249    }
13250  }
13251
13252  /** definition of this invariant (the suppressee) */
13253  private static NISuppressee suppressee = new NISuppressee(ModLong_zyx.class, 3);
13254
13255  // suppressor definitions (used below)
13256  private static NISuppressor result_eq_arg1 =
13257      new NISuppressor(2, 1, IntEqual.class);
13258  private static NISuppressor result_eq_arg2 =
13259      new NISuppressor(2, 0, IntEqual.class);
13260  private static NISuppressor arg1_eq_arg2 =
13261      new NISuppressor(1, 0, IntEqual.class);
13262
13263  private static NISuppressor result_lt_arg1 =
13264      new NISuppressor(2, 1, IntLessThan.class);
13265  private static NISuppressor result_lt_arg2 =
13266      new NISuppressor(2, 0, IntLessThan.class);
13267  private static NISuppressor arg1_lt_arg2 =
13268      new NISuppressor(1, 0, IntLessThan.class);
13269  private static NISuppressor arg2_lt_arg1 =
13270      new NISuppressor(0, 1, IntLessThan.class);
13271
13272  private static NISuppressor result_le_arg1 =
13273      new NISuppressor(2, 1, IntLessEqual.class);
13274  private static NISuppressor result_le_arg2 =
13275      new NISuppressor(2, 0, IntLessEqual.class);
13276  private static NISuppressor arg1_le_arg2 =
13277      new NISuppressor(1, 0, IntLessEqual.class);
13278  private static NISuppressor arg2_le_arg1 =
13279      new NISuppressor(0, 1, IntLessEqual.class);
13280
13281  private static NISuppressor result_track0_arg1 =
13282      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
13283  private static NISuppressor result_track0_arg2 =
13284      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
13285  private static NISuppressor arg1_track0_arg2 =
13286      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
13287  private static NISuppressor arg1_track0_result =
13288      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
13289  private static NISuppressor arg2_track0_result =
13290      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
13291  private static NISuppressor arg2_track0_arg1 =
13292      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
13293
13294  private static NISuppressor result_eq_1 =
13295      new NISuppressor(2, RangeInt.EqualOne.class);
13296  private static NISuppressor arg1_eq_1 =
13297      new NISuppressor(1, RangeInt.EqualOne.class);
13298  private static NISuppressor arg2_eq_1 =
13299      new NISuppressor(0, RangeInt.EqualOne.class);
13300
13301  private static NISuppressor result_eq_0 =
13302      new NISuppressor(2, RangeInt.EqualZero.class);
13303  private static NISuppressor arg1_eq_0 =
13304      new NISuppressor(1, RangeInt.EqualZero.class);
13305  private static NISuppressor arg2_eq_0 =
13306      new NISuppressor(0, RangeInt.EqualZero.class);
13307
13308  private static NISuppressor result_ne_0 =
13309      new NISuppressor(2, NonZero.class);
13310  private static NISuppressor arg1_ne_0 =
13311      new NISuppressor(1, NonZero.class);
13312  private static NISuppressor arg2_ne_0 =
13313      new NISuppressor(0, NonZero.class);
13314
13315  private static NISuppressor result_ge_0 =
13316      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
13317  private static NISuppressor arg1_ge_0 =
13318      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
13319  private static NISuppressor arg2_ge_0 =
13320      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
13321
13322  private static NISuppressor result_ge_64 =
13323      new NISuppressor(2, RangeInt.GreaterEqual64.class);
13324  private static NISuppressor arg1_ge_64 =
13325      new NISuppressor(1, RangeInt.GreaterEqual64.class);
13326  private static NISuppressor arg2_ge_64 =
13327      new NISuppressor(0, RangeInt.GreaterEqual64.class);
13328
13329  private static NISuppressor result_boolean =
13330      new NISuppressor(2, RangeInt.BooleanVal.class);
13331  private static NISuppressor arg1_boolean =
13332      new NISuppressor(1, RangeInt.BooleanVal.class);
13333  private static NISuppressor arg2_boolean =
13334      new NISuppressor(0, RangeInt.BooleanVal.class);
13335
13336  private static NISuppressor result_even =
13337      new NISuppressor(2, RangeInt.Even.class);
13338  private static NISuppressor arg1_even =
13339      new NISuppressor(1, RangeInt.Even.class);
13340  private static NISuppressor arg2_even =
13341      new NISuppressor(0, RangeInt.Even.class);
13342
13343  private static NISuppressor result_power2 =
13344      new NISuppressor(2, RangeInt.PowerOfTwo.class);
13345  private static NISuppressor arg1_power2 =
13346      new NISuppressor(1, RangeInt.PowerOfTwo.class);
13347  private static NISuppressor arg2_power2 =
13348      new NISuppressor(0, RangeInt.PowerOfTwo.class);
13349
13350  private static NISuppressor result_and0_arg1 =
13351      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
13352  private static NISuppressor result_and0_arg2 =
13353      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
13354  private static NISuppressor arg1_and0_arg2 =
13355      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
13356
13357  // The arguments to bitwise subset are backwards from what one
13358  // might expect.  The second argument is a subset of the first
13359  // argument
13360  private static NISuppressor arg1_bw_subset_arg2 =
13361      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
13362  private static NISuppressor arg2_bw_subset_arg1 =
13363      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
13364
13365  private static NISuppressor result_shift0_arg1 =
13366      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
13367  private static NISuppressor result_shift0_arg2 =
13368      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
13369  private static NISuppressor arg1_shift0_arg2 =
13370      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
13371
13372  private static NISuppressor arg2_divides_arg1 =
13373      new NISuppressor(1, 0, NumericInt.Divides.class);
13374  private static NISuppressor arg1_divides_arg2 =
13375      new NISuppressor(0, 1, NumericInt.Divides.class);
13376
13377  private static NISuppressor arg2_valid_shift =
13378      new NISuppressor(0, RangeInt.Bound0_63.class);
13379
13380    private static NISuppressionSet suppressions =
13381      new NISuppressionSet(
13382          new NISuppression[] {
13383            // anything mod 0 is undefined
13384            // (r == y) && (y < x) && (x != 0) && (r >= 0) ==> r = y % x
13385            new NISuppression(result_eq_arg1, arg1_lt_arg2, arg2_ne_0, result_ge_0, suppressee),
13386
13387            // (r == 0) && ((y % x) == 0)
13388            new NISuppression(result_eq_0, arg2_divides_arg1, suppressee),
13389
13390            // These are unnecessary as the divides invariant handles these
13391            // nicely.
13392            // (r == 0) && (x == 1)      ==> r = y % x
13393            // new NISuppression (result_eq_0, arg2_eq_1, suppressee),
13394
13395            // (r == 0) && (y == x)
13396            // new NISuppression (result_eq_0, arg1_eq_arg2, suppressee),
13397          });
13398
13399  // Create a suppression factory for functionBinary
13400
13401}
13402
13403  // default is that it is not this function, overriden in the subclass
13404  @Pure
13405  public boolean isLshift() {
13406    return false;
13407  }
13408
13409/**
13410 * Represents the invariant {@code x = Lshift(y, z)} over three long
13411 * scalars. 
13412 */
13413public static class LshiftLong_xyz extends FunctionBinary {
13414  // We are Serializable, so we specify a version to allow changes to
13415  // method signatures without breaking serialization.  If you add or
13416  // remove fields, you should change this number to the current date.
13417  static final long serialVersionUID = 20031030L;
13418
13419    // z must be between arg2_bound[0] and arg2_bound[1] inclusive
13420    static int[] arg2_bound = {0, 63};
13421
13422  private static @Prototype LshiftLong_xyz proto = new @Prototype LshiftLong_xyz ();
13423
13424  /** Returns the prototype invariant for LshiftLong_xyz */
13425  public static @Prototype LshiftLong_xyz get_proto() {
13426    return proto;
13427  }
13428
13429  /** instantiate an invariant on the specified slice */
13430  @Override
13431  protected LshiftLong_xyz instantiate_dyn(@Prototype LshiftLong_xyz this, PptSlice slice) {
13432    return new LshiftLong_xyz (slice);
13433  }
13434
13435  private LshiftLong_xyz (PptSlice slice) {
13436    super(slice);
13437  }
13438
13439  public @Prototype LshiftLong_xyz () {
13440    super();
13441  }
13442
13443  private static String[] method_name = new String[] {"", " << ", ""};
13444
13445  @Override
13446  public String[] get_method_name(@GuardSatisfied LshiftLong_xyz this) {
13447    return method_name;
13448  }
13449
13450  private static int function_id = -1;
13451
13452  @Override
13453  public int get_function_id() {
13454    return function_id;
13455  }
13456
13457  @Override
13458  public void set_function_id(int function_id) {
13459    assert LshiftLong_xyz.function_id == -1;
13460    LshiftLong_xyz.function_id = function_id;
13461  }
13462
13463  private static int var_order = 1;
13464
13465  @Override
13466  public int get_var_order(@GuardSatisfied LshiftLong_xyz this) {
13467    return var_order;
13468  }
13469
13470  @Pure
13471  @Override
13472  public boolean is_symmetric() {
13473
13474      return false;
13475  }
13476
13477  @Override
13478
13479  public long func(long y, long z) {
13480
13481      if ((z < arg2_bound[0]) || (z > arg2_bound[1])) {
13482        throw new ArithmeticException("arg2 (" + z + ") out of range "
13483                                       + arg2_bound[0] + ".." + arg2_bound[1]);
13484      }
13485
13486    return (y << z);
13487  }
13488
13489  @Override
13490  public InvariantStatus check_modified(long x, long y,
13491                                      long z, int count) {
13492    return check_ordered(x, y, z, count);
13493  }
13494
13495  @Override
13496  public InvariantStatus add_modified(long x, long y,
13497                                      long z, int count) {
13498    if (Debug.logDetail()) {
13499      log("result=%s, arg1=%s, arg2=%s", x, y, z);
13500    }
13501    return add_ordered(x, y, z, count);
13502  }
13503
13504  @Pure
13505  @Override
13506  public boolean isLshift() {
13507    return true;
13508  }
13509
13510  /** Returns a list of non-instantiating suppressions for this invariant. */
13511  @Pure
13512  @Override
13513  public @Nullable NISuppressionSet get_ni_suppressions() {
13514    if (NIS.dkconfig_enabled && dkconfig_enabled) {
13515      return suppressions;
13516    } else {
13517      return null;
13518    }
13519  }
13520
13521  /** definition of this invariant (the suppressee) */
13522  private static NISuppressee suppressee = new NISuppressee(LshiftLong_xyz.class, 3);
13523
13524  // suppressor definitions (used below)
13525  private static NISuppressor result_eq_arg1 =
13526      new NISuppressor(0, 1, IntEqual.class);
13527  private static NISuppressor result_eq_arg2 =
13528      new NISuppressor(0, 2, IntEqual.class);
13529  private static NISuppressor arg1_eq_arg2 =
13530      new NISuppressor(1, 2, IntEqual.class);
13531
13532  private static NISuppressor result_lt_arg1 =
13533      new NISuppressor(0, 1, IntLessThan.class);
13534  private static NISuppressor result_lt_arg2 =
13535      new NISuppressor(0, 2, IntLessThan.class);
13536  private static NISuppressor arg1_lt_arg2 =
13537      new NISuppressor(1, 2, IntLessThan.class);
13538  private static NISuppressor arg2_lt_arg1 =
13539      new NISuppressor(2, 1, IntLessThan.class);
13540
13541  private static NISuppressor result_le_arg1 =
13542      new NISuppressor(0, 1, IntLessEqual.class);
13543  private static NISuppressor result_le_arg2 =
13544      new NISuppressor(0, 2, IntLessEqual.class);
13545  private static NISuppressor arg1_le_arg2 =
13546      new NISuppressor(1, 2, IntLessEqual.class);
13547  private static NISuppressor arg2_le_arg1 =
13548      new NISuppressor(2, 1, IntLessEqual.class);
13549
13550  private static NISuppressor result_track0_arg1 =
13551      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
13552  private static NISuppressor result_track0_arg2 =
13553      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
13554  private static NISuppressor arg1_track0_arg2 =
13555      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
13556  private static NISuppressor arg1_track0_result =
13557      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
13558  private static NISuppressor arg2_track0_result =
13559      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
13560  private static NISuppressor arg2_track0_arg1 =
13561      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
13562
13563  private static NISuppressor result_eq_1 =
13564      new NISuppressor(0, RangeInt.EqualOne.class);
13565  private static NISuppressor arg1_eq_1 =
13566      new NISuppressor(1, RangeInt.EqualOne.class);
13567  private static NISuppressor arg2_eq_1 =
13568      new NISuppressor(2, RangeInt.EqualOne.class);
13569
13570  private static NISuppressor result_eq_0 =
13571      new NISuppressor(0, RangeInt.EqualZero.class);
13572  private static NISuppressor arg1_eq_0 =
13573      new NISuppressor(1, RangeInt.EqualZero.class);
13574  private static NISuppressor arg2_eq_0 =
13575      new NISuppressor(2, RangeInt.EqualZero.class);
13576
13577  private static NISuppressor result_ne_0 =
13578      new NISuppressor(0, NonZero.class);
13579  private static NISuppressor arg1_ne_0 =
13580      new NISuppressor(1, NonZero.class);
13581  private static NISuppressor arg2_ne_0 =
13582      new NISuppressor(2, NonZero.class);
13583
13584  private static NISuppressor result_ge_0 =
13585      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
13586  private static NISuppressor arg1_ge_0 =
13587      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
13588  private static NISuppressor arg2_ge_0 =
13589      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
13590
13591  private static NISuppressor result_ge_64 =
13592      new NISuppressor(0, RangeInt.GreaterEqual64.class);
13593  private static NISuppressor arg1_ge_64 =
13594      new NISuppressor(1, RangeInt.GreaterEqual64.class);
13595  private static NISuppressor arg2_ge_64 =
13596      new NISuppressor(2, RangeInt.GreaterEqual64.class);
13597
13598  private static NISuppressor result_boolean =
13599      new NISuppressor(0, RangeInt.BooleanVal.class);
13600  private static NISuppressor arg1_boolean =
13601      new NISuppressor(1, RangeInt.BooleanVal.class);
13602  private static NISuppressor arg2_boolean =
13603      new NISuppressor(2, RangeInt.BooleanVal.class);
13604
13605  private static NISuppressor result_even =
13606      new NISuppressor(0, RangeInt.Even.class);
13607  private static NISuppressor arg1_even =
13608      new NISuppressor(1, RangeInt.Even.class);
13609  private static NISuppressor arg2_even =
13610      new NISuppressor(2, RangeInt.Even.class);
13611
13612  private static NISuppressor result_power2 =
13613      new NISuppressor(0, RangeInt.PowerOfTwo.class);
13614  private static NISuppressor arg1_power2 =
13615      new NISuppressor(1, RangeInt.PowerOfTwo.class);
13616  private static NISuppressor arg2_power2 =
13617      new NISuppressor(2, RangeInt.PowerOfTwo.class);
13618
13619  private static NISuppressor result_and0_arg1 =
13620      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
13621  private static NISuppressor result_and0_arg2 =
13622      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
13623  private static NISuppressor arg1_and0_arg2 =
13624      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
13625
13626  // The arguments to bitwise subset are backwards from what one
13627  // might expect.  The second argument is a subset of the first
13628  // argument
13629  private static NISuppressor arg1_bw_subset_arg2 =
13630      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
13631  private static NISuppressor arg2_bw_subset_arg1 =
13632      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
13633
13634  private static NISuppressor result_shift0_arg1 =
13635      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
13636  private static NISuppressor result_shift0_arg2 =
13637      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
13638  private static NISuppressor arg1_shift0_arg2 =
13639      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
13640
13641  private static NISuppressor arg2_divides_arg1 =
13642      new NISuppressor(1, 2, NumericInt.Divides.class);
13643  private static NISuppressor arg1_divides_arg2 =
13644      new NISuppressor(2, 1, NumericInt.Divides.class);
13645
13646  private static NISuppressor arg2_valid_shift =
13647      new NISuppressor(2, RangeInt.Bound0_63.class);
13648
13649    private static NISuppressionSet suppressions =
13650        new NISuppressionSet(
13651          new NISuppression[] {
13652
13653            // (r == y) && (z == 0) ==> r = y << z
13654            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
13655
13656            // (r == 0) && (y == 0) && (0 <= z <= 63)   ==> r = y << z
13657            new NISuppression(result_eq_0, arg1_eq_0, arg2_valid_shift,
13658                               suppressee),
13659
13660          });
13661
13662  // Create a suppression factory for functionBinary
13663
13664}
13665
13666/**
13667 * Represents the invariant {@code y = Lshift(x, z)} over three long
13668 * scalars. 
13669 */
13670public static class LshiftLong_yxz extends FunctionBinary {
13671  // We are Serializable, so we specify a version to allow changes to
13672  // method signatures without breaking serialization.  If you add or
13673  // remove fields, you should change this number to the current date.
13674  static final long serialVersionUID = 20031030L;
13675
13676    // z must be between arg2_bound[0] and arg2_bound[1] inclusive
13677    static int[] arg2_bound = {0, 63};
13678
13679  private static @Prototype LshiftLong_yxz proto = new @Prototype LshiftLong_yxz ();
13680
13681  /** Returns the prototype invariant for LshiftLong_yxz */
13682  public static @Prototype LshiftLong_yxz get_proto() {
13683    return proto;
13684  }
13685
13686  /** instantiate an invariant on the specified slice */
13687  @Override
13688  protected LshiftLong_yxz instantiate_dyn(@Prototype LshiftLong_yxz this, PptSlice slice) {
13689    return new LshiftLong_yxz (slice);
13690  }
13691
13692  private LshiftLong_yxz (PptSlice slice) {
13693    super(slice);
13694  }
13695
13696  public @Prototype LshiftLong_yxz () {
13697    super();
13698  }
13699
13700  private static String[] method_name = new String[] {"", " << ", ""};
13701
13702  @Override
13703  public String[] get_method_name(@GuardSatisfied LshiftLong_yxz this) {
13704    return method_name;
13705  }
13706
13707  private static int function_id = -1;
13708
13709  @Override
13710  public int get_function_id() {
13711    return function_id;
13712  }
13713
13714  @Override
13715  public void set_function_id(int function_id) {
13716    assert LshiftLong_yxz.function_id == -1;
13717    LshiftLong_yxz.function_id = function_id;
13718  }
13719
13720  private static int var_order = 2;
13721
13722  @Override
13723  public int get_var_order(@GuardSatisfied LshiftLong_yxz this) {
13724    return var_order;
13725  }
13726
13727  @Pure
13728  @Override
13729  public boolean is_symmetric() {
13730
13731      return false;
13732  }
13733
13734  @Override
13735
13736  public long func(long x, long z) {
13737
13738      if ((z < arg2_bound[0]) || (z > arg2_bound[1])) {
13739        throw new ArithmeticException("arg2 (" + z + ") out of range "
13740                                       + arg2_bound[0] + ".." + arg2_bound[1]);
13741      }
13742
13743    return (x << z);
13744  }
13745
13746  @Override
13747  public InvariantStatus check_modified(long x, long y,
13748                                      long z, int count) {
13749    return check_ordered(y, x, z, count);
13750  }
13751
13752  @Override
13753  public InvariantStatus add_modified(long x, long y,
13754                                      long z, int count) {
13755    if (Debug.logDetail()) {
13756      log("result=%s, arg1=%s, arg2=%s", y, x, z);
13757    }
13758    return add_ordered(y, x, z, count);
13759  }
13760
13761  @Pure
13762  @Override
13763  public boolean isLshift() {
13764    return true;
13765  }
13766
13767  /** Returns a list of non-instantiating suppressions for this invariant. */
13768  @Pure
13769  @Override
13770  public @Nullable NISuppressionSet get_ni_suppressions() {
13771    if (NIS.dkconfig_enabled && dkconfig_enabled) {
13772      return suppressions;
13773    } else {
13774      return null;
13775    }
13776  }
13777
13778  /** definition of this invariant (the suppressee) */
13779  private static NISuppressee suppressee = new NISuppressee(LshiftLong_yxz.class, 3);
13780
13781  // suppressor definitions (used below)
13782  private static NISuppressor result_eq_arg1 =
13783      new NISuppressor(1, 0, IntEqual.class);
13784  private static NISuppressor result_eq_arg2 =
13785      new NISuppressor(1, 2, IntEqual.class);
13786  private static NISuppressor arg1_eq_arg2 =
13787      new NISuppressor(0, 2, IntEqual.class);
13788
13789  private static NISuppressor result_lt_arg1 =
13790      new NISuppressor(1, 0, IntLessThan.class);
13791  private static NISuppressor result_lt_arg2 =
13792      new NISuppressor(1, 2, IntLessThan.class);
13793  private static NISuppressor arg1_lt_arg2 =
13794      new NISuppressor(0, 2, IntLessThan.class);
13795  private static NISuppressor arg2_lt_arg1 =
13796      new NISuppressor(2, 0, IntLessThan.class);
13797
13798  private static NISuppressor result_le_arg1 =
13799      new NISuppressor(1, 0, IntLessEqual.class);
13800  private static NISuppressor result_le_arg2 =
13801      new NISuppressor(1, 2, IntLessEqual.class);
13802  private static NISuppressor arg1_le_arg2 =
13803      new NISuppressor(0, 2, IntLessEqual.class);
13804  private static NISuppressor arg2_le_arg1 =
13805      new NISuppressor(2, 0, IntLessEqual.class);
13806
13807  private static NISuppressor result_track0_arg1 =
13808      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
13809  private static NISuppressor result_track0_arg2 =
13810      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
13811  private static NISuppressor arg1_track0_arg2 =
13812      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
13813  private static NISuppressor arg1_track0_result =
13814      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
13815  private static NISuppressor arg2_track0_result =
13816      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
13817  private static NISuppressor arg2_track0_arg1 =
13818      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
13819
13820  private static NISuppressor result_eq_1 =
13821      new NISuppressor(1, RangeInt.EqualOne.class);
13822  private static NISuppressor arg1_eq_1 =
13823      new NISuppressor(0, RangeInt.EqualOne.class);
13824  private static NISuppressor arg2_eq_1 =
13825      new NISuppressor(2, RangeInt.EqualOne.class);
13826
13827  private static NISuppressor result_eq_0 =
13828      new NISuppressor(1, RangeInt.EqualZero.class);
13829  private static NISuppressor arg1_eq_0 =
13830      new NISuppressor(0, RangeInt.EqualZero.class);
13831  private static NISuppressor arg2_eq_0 =
13832      new NISuppressor(2, RangeInt.EqualZero.class);
13833
13834  private static NISuppressor result_ne_0 =
13835      new NISuppressor(1, NonZero.class);
13836  private static NISuppressor arg1_ne_0 =
13837      new NISuppressor(0, NonZero.class);
13838  private static NISuppressor arg2_ne_0 =
13839      new NISuppressor(2, NonZero.class);
13840
13841  private static NISuppressor result_ge_0 =
13842      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
13843  private static NISuppressor arg1_ge_0 =
13844      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
13845  private static NISuppressor arg2_ge_0 =
13846      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
13847
13848  private static NISuppressor result_ge_64 =
13849      new NISuppressor(1, RangeInt.GreaterEqual64.class);
13850  private static NISuppressor arg1_ge_64 =
13851      new NISuppressor(0, RangeInt.GreaterEqual64.class);
13852  private static NISuppressor arg2_ge_64 =
13853      new NISuppressor(2, RangeInt.GreaterEqual64.class);
13854
13855  private static NISuppressor result_boolean =
13856      new NISuppressor(1, RangeInt.BooleanVal.class);
13857  private static NISuppressor arg1_boolean =
13858      new NISuppressor(0, RangeInt.BooleanVal.class);
13859  private static NISuppressor arg2_boolean =
13860      new NISuppressor(2, RangeInt.BooleanVal.class);
13861
13862  private static NISuppressor result_even =
13863      new NISuppressor(1, RangeInt.Even.class);
13864  private static NISuppressor arg1_even =
13865      new NISuppressor(0, RangeInt.Even.class);
13866  private static NISuppressor arg2_even =
13867      new NISuppressor(2, RangeInt.Even.class);
13868
13869  private static NISuppressor result_power2 =
13870      new NISuppressor(1, RangeInt.PowerOfTwo.class);
13871  private static NISuppressor arg1_power2 =
13872      new NISuppressor(0, RangeInt.PowerOfTwo.class);
13873  private static NISuppressor arg2_power2 =
13874      new NISuppressor(2, RangeInt.PowerOfTwo.class);
13875
13876  private static NISuppressor result_and0_arg1 =
13877      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
13878  private static NISuppressor result_and0_arg2 =
13879      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
13880  private static NISuppressor arg1_and0_arg2 =
13881      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
13882
13883  // The arguments to bitwise subset are backwards from what one
13884  // might expect.  The second argument is a subset of the first
13885  // argument
13886  private static NISuppressor arg1_bw_subset_arg2 =
13887      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
13888  private static NISuppressor arg2_bw_subset_arg1 =
13889      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
13890
13891  private static NISuppressor result_shift0_arg1 =
13892      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
13893  private static NISuppressor result_shift0_arg2 =
13894      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
13895  private static NISuppressor arg1_shift0_arg2 =
13896      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
13897
13898  private static NISuppressor arg2_divides_arg1 =
13899      new NISuppressor(0, 2, NumericInt.Divides.class);
13900  private static NISuppressor arg1_divides_arg2 =
13901      new NISuppressor(2, 0, NumericInt.Divides.class);
13902
13903  private static NISuppressor arg2_valid_shift =
13904      new NISuppressor(2, RangeInt.Bound0_63.class);
13905
13906    private static NISuppressionSet suppressions =
13907        new NISuppressionSet(
13908          new NISuppression[] {
13909
13910            // (r == x) && (z == 0) ==> r = x << z
13911            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
13912
13913            // (r == 0) && (x == 0) && (0 <= z <= 63)   ==> r = x << z
13914            new NISuppression(result_eq_0, arg1_eq_0, arg2_valid_shift,
13915                               suppressee),
13916
13917          });
13918
13919  // Create a suppression factory for functionBinary
13920
13921}
13922
13923/**
13924 * Represents the invariant {@code z = Lshift(x, y)} over three long
13925 * scalars. 
13926 */
13927public static class LshiftLong_zxy extends FunctionBinary {
13928  // We are Serializable, so we specify a version to allow changes to
13929  // method signatures without breaking serialization.  If you add or
13930  // remove fields, you should change this number to the current date.
13931  static final long serialVersionUID = 20031030L;
13932
13933    // y must be between arg2_bound[0] and arg2_bound[1] inclusive
13934    static int[] arg2_bound = {0, 63};
13935
13936  private static @Prototype LshiftLong_zxy proto = new @Prototype LshiftLong_zxy ();
13937
13938  /** Returns the prototype invariant for LshiftLong_zxy */
13939  public static @Prototype LshiftLong_zxy get_proto() {
13940    return proto;
13941  }
13942
13943  /** instantiate an invariant on the specified slice */
13944  @Override
13945  protected LshiftLong_zxy instantiate_dyn(@Prototype LshiftLong_zxy this, PptSlice slice) {
13946    return new LshiftLong_zxy (slice);
13947  }
13948
13949  private LshiftLong_zxy (PptSlice slice) {
13950    super(slice);
13951  }
13952
13953  public @Prototype LshiftLong_zxy () {
13954    super();
13955  }
13956
13957  private static String[] method_name = new String[] {"", " << ", ""};
13958
13959  @Override
13960  public String[] get_method_name(@GuardSatisfied LshiftLong_zxy this) {
13961    return method_name;
13962  }
13963
13964  private static int function_id = -1;
13965
13966  @Override
13967  public int get_function_id() {
13968    return function_id;
13969  }
13970
13971  @Override
13972  public void set_function_id(int function_id) {
13973    assert LshiftLong_zxy.function_id == -1;
13974    LshiftLong_zxy.function_id = function_id;
13975  }
13976
13977  private static int var_order = 3;
13978
13979  @Override
13980  public int get_var_order(@GuardSatisfied LshiftLong_zxy this) {
13981    return var_order;
13982  }
13983
13984  @Pure
13985  @Override
13986  public boolean is_symmetric() {
13987
13988      return false;
13989  }
13990
13991  @Override
13992
13993  public long func(long x, long y) {
13994
13995      if ((y < arg2_bound[0]) || (y > arg2_bound[1])) {
13996        throw new ArithmeticException("arg2 (" + y + ") out of range "
13997                                       + arg2_bound[0] + ".." + arg2_bound[1]);
13998      }
13999
14000    return (x << y);
14001  }
14002
14003  @Override
14004  public InvariantStatus check_modified(long x, long y,
14005                                      long z, int count) {
14006    return check_ordered(z, x, y, count);
14007  }
14008
14009  @Override
14010  public InvariantStatus add_modified(long x, long y,
14011                                      long z, int count) {
14012    if (Debug.logDetail()) {
14013      log("result=%s, arg1=%s, arg2=%s", z, x, y);
14014    }
14015    return add_ordered(z, x, y, count);
14016  }
14017
14018  @Pure
14019  @Override
14020  public boolean isLshift() {
14021    return true;
14022  }
14023
14024  /** Returns a list of non-instantiating suppressions for this invariant. */
14025  @Pure
14026  @Override
14027  public @Nullable NISuppressionSet get_ni_suppressions() {
14028    if (NIS.dkconfig_enabled && dkconfig_enabled) {
14029      return suppressions;
14030    } else {
14031      return null;
14032    }
14033  }
14034
14035  /** definition of this invariant (the suppressee) */
14036  private static NISuppressee suppressee = new NISuppressee(LshiftLong_zxy.class, 3);
14037
14038  // suppressor definitions (used below)
14039  private static NISuppressor result_eq_arg1 =
14040      new NISuppressor(2, 0, IntEqual.class);
14041  private static NISuppressor result_eq_arg2 =
14042      new NISuppressor(2, 1, IntEqual.class);
14043  private static NISuppressor arg1_eq_arg2 =
14044      new NISuppressor(0, 1, IntEqual.class);
14045
14046  private static NISuppressor result_lt_arg1 =
14047      new NISuppressor(2, 0, IntLessThan.class);
14048  private static NISuppressor result_lt_arg2 =
14049      new NISuppressor(2, 1, IntLessThan.class);
14050  private static NISuppressor arg1_lt_arg2 =
14051      new NISuppressor(0, 1, IntLessThan.class);
14052  private static NISuppressor arg2_lt_arg1 =
14053      new NISuppressor(1, 0, IntLessThan.class);
14054
14055  private static NISuppressor result_le_arg1 =
14056      new NISuppressor(2, 0, IntLessEqual.class);
14057  private static NISuppressor result_le_arg2 =
14058      new NISuppressor(2, 1, IntLessEqual.class);
14059  private static NISuppressor arg1_le_arg2 =
14060      new NISuppressor(0, 1, IntLessEqual.class);
14061  private static NISuppressor arg2_le_arg1 =
14062      new NISuppressor(1, 0, IntLessEqual.class);
14063
14064  private static NISuppressor result_track0_arg1 =
14065      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
14066  private static NISuppressor result_track0_arg2 =
14067      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
14068  private static NISuppressor arg1_track0_arg2 =
14069      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
14070  private static NISuppressor arg1_track0_result =
14071      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
14072  private static NISuppressor arg2_track0_result =
14073      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
14074  private static NISuppressor arg2_track0_arg1 =
14075      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
14076
14077  private static NISuppressor result_eq_1 =
14078      new NISuppressor(2, RangeInt.EqualOne.class);
14079  private static NISuppressor arg1_eq_1 =
14080      new NISuppressor(0, RangeInt.EqualOne.class);
14081  private static NISuppressor arg2_eq_1 =
14082      new NISuppressor(1, RangeInt.EqualOne.class);
14083
14084  private static NISuppressor result_eq_0 =
14085      new NISuppressor(2, RangeInt.EqualZero.class);
14086  private static NISuppressor arg1_eq_0 =
14087      new NISuppressor(0, RangeInt.EqualZero.class);
14088  private static NISuppressor arg2_eq_0 =
14089      new NISuppressor(1, RangeInt.EqualZero.class);
14090
14091  private static NISuppressor result_ne_0 =
14092      new NISuppressor(2, NonZero.class);
14093  private static NISuppressor arg1_ne_0 =
14094      new NISuppressor(0, NonZero.class);
14095  private static NISuppressor arg2_ne_0 =
14096      new NISuppressor(1, NonZero.class);
14097
14098  private static NISuppressor result_ge_0 =
14099      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
14100  private static NISuppressor arg1_ge_0 =
14101      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
14102  private static NISuppressor arg2_ge_0 =
14103      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
14104
14105  private static NISuppressor result_ge_64 =
14106      new NISuppressor(2, RangeInt.GreaterEqual64.class);
14107  private static NISuppressor arg1_ge_64 =
14108      new NISuppressor(0, RangeInt.GreaterEqual64.class);
14109  private static NISuppressor arg2_ge_64 =
14110      new NISuppressor(1, RangeInt.GreaterEqual64.class);
14111
14112  private static NISuppressor result_boolean =
14113      new NISuppressor(2, RangeInt.BooleanVal.class);
14114  private static NISuppressor arg1_boolean =
14115      new NISuppressor(0, RangeInt.BooleanVal.class);
14116  private static NISuppressor arg2_boolean =
14117      new NISuppressor(1, RangeInt.BooleanVal.class);
14118
14119  private static NISuppressor result_even =
14120      new NISuppressor(2, RangeInt.Even.class);
14121  private static NISuppressor arg1_even =
14122      new NISuppressor(0, RangeInt.Even.class);
14123  private static NISuppressor arg2_even =
14124      new NISuppressor(1, RangeInt.Even.class);
14125
14126  private static NISuppressor result_power2 =
14127      new NISuppressor(2, RangeInt.PowerOfTwo.class);
14128  private static NISuppressor arg1_power2 =
14129      new NISuppressor(0, RangeInt.PowerOfTwo.class);
14130  private static NISuppressor arg2_power2 =
14131      new NISuppressor(1, RangeInt.PowerOfTwo.class);
14132
14133  private static NISuppressor result_and0_arg1 =
14134      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
14135  private static NISuppressor result_and0_arg2 =
14136      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
14137  private static NISuppressor arg1_and0_arg2 =
14138      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
14139
14140  // The arguments to bitwise subset are backwards from what one
14141  // might expect.  The second argument is a subset of the first
14142  // argument
14143  private static NISuppressor arg1_bw_subset_arg2 =
14144      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
14145  private static NISuppressor arg2_bw_subset_arg1 =
14146      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
14147
14148  private static NISuppressor result_shift0_arg1 =
14149      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
14150  private static NISuppressor result_shift0_arg2 =
14151      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
14152  private static NISuppressor arg1_shift0_arg2 =
14153      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
14154
14155  private static NISuppressor arg2_divides_arg1 =
14156      new NISuppressor(0, 1, NumericInt.Divides.class);
14157  private static NISuppressor arg1_divides_arg2 =
14158      new NISuppressor(1, 0, NumericInt.Divides.class);
14159
14160  private static NISuppressor arg2_valid_shift =
14161      new NISuppressor(1, RangeInt.Bound0_63.class);
14162
14163    private static NISuppressionSet suppressions =
14164        new NISuppressionSet(
14165          new NISuppression[] {
14166
14167            // (r == x) && (y == 0) ==> r = x << y
14168            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
14169
14170            // (r == 0) && (x == 0) && (0 <= y <= 63)   ==> r = x << y
14171            new NISuppression(result_eq_0, arg1_eq_0, arg2_valid_shift,
14172                               suppressee),
14173
14174          });
14175
14176  // Create a suppression factory for functionBinary
14177
14178}
14179
14180/**
14181 * Represents the invariant {@code x = Lshift(z, y)} over three long
14182 * scalars. 
14183 */
14184public static class LshiftLong_xzy extends FunctionBinary {
14185  // We are Serializable, so we specify a version to allow changes to
14186  // method signatures without breaking serialization.  If you add or
14187  // remove fields, you should change this number to the current date.
14188  static final long serialVersionUID = 20031030L;
14189
14190    // y must be between arg2_bound[0] and arg2_bound[1] inclusive
14191    static int[] arg2_bound = {0, 63};
14192
14193  private static @Prototype LshiftLong_xzy proto = new @Prototype LshiftLong_xzy ();
14194
14195  /** Returns the prototype invariant for LshiftLong_xzy */
14196  public static @Prototype LshiftLong_xzy get_proto() {
14197    return proto;
14198  }
14199
14200  /** instantiate an invariant on the specified slice */
14201  @Override
14202  protected LshiftLong_xzy instantiate_dyn(@Prototype LshiftLong_xzy this, PptSlice slice) {
14203    return new LshiftLong_xzy (slice);
14204  }
14205
14206  private LshiftLong_xzy (PptSlice slice) {
14207    super(slice);
14208  }
14209
14210  public @Prototype LshiftLong_xzy () {
14211    super();
14212  }
14213
14214  private static String[] method_name = new String[] {"", " << ", ""};
14215
14216  @Override
14217  public String[] get_method_name(@GuardSatisfied LshiftLong_xzy this) {
14218    return method_name;
14219  }
14220
14221  private static int function_id = -1;
14222
14223  @Override
14224  public int get_function_id() {
14225    return function_id;
14226  }
14227
14228  @Override
14229  public void set_function_id(int function_id) {
14230    assert LshiftLong_xzy.function_id == -1;
14231    LshiftLong_xzy.function_id = function_id;
14232  }
14233
14234  private static int var_order = 4;
14235
14236  @Override
14237  public int get_var_order(@GuardSatisfied LshiftLong_xzy this) {
14238    return var_order;
14239  }
14240
14241  @Pure
14242  @Override
14243  public boolean is_symmetric() {
14244
14245      return false;
14246  }
14247
14248  @Override
14249
14250  public long func(long z, long y) {
14251
14252      if ((y < arg2_bound[0]) || (y > arg2_bound[1])) {
14253        throw new ArithmeticException("arg2 (" + y + ") out of range "
14254                                       + arg2_bound[0] + ".." + arg2_bound[1]);
14255      }
14256
14257    return (z << y);
14258  }
14259
14260  @Override
14261  public InvariantStatus check_modified(long x, long y,
14262                                      long z, int count) {
14263    return check_ordered(x, z, y, count);
14264  }
14265
14266  @Override
14267  public InvariantStatus add_modified(long x, long y,
14268                                      long z, int count) {
14269    if (Debug.logDetail()) {
14270      log("result=%s, arg1=%s, arg2=%s", x, z, y);
14271    }
14272    return add_ordered(x, z, y, count);
14273  }
14274
14275  @Pure
14276  @Override
14277  public boolean isLshift() {
14278    return true;
14279  }
14280
14281  /** Returns a list of non-instantiating suppressions for this invariant. */
14282  @Pure
14283  @Override
14284  public @Nullable NISuppressionSet get_ni_suppressions() {
14285    if (NIS.dkconfig_enabled && dkconfig_enabled) {
14286      return suppressions;
14287    } else {
14288      return null;
14289    }
14290  }
14291
14292  /** definition of this invariant (the suppressee) */
14293  private static NISuppressee suppressee = new NISuppressee(LshiftLong_xzy.class, 3);
14294
14295  // suppressor definitions (used below)
14296  private static NISuppressor result_eq_arg1 =
14297      new NISuppressor(0, 2, IntEqual.class);
14298  private static NISuppressor result_eq_arg2 =
14299      new NISuppressor(0, 1, IntEqual.class);
14300  private static NISuppressor arg1_eq_arg2 =
14301      new NISuppressor(2, 1, IntEqual.class);
14302
14303  private static NISuppressor result_lt_arg1 =
14304      new NISuppressor(0, 2, IntLessThan.class);
14305  private static NISuppressor result_lt_arg2 =
14306      new NISuppressor(0, 1, IntLessThan.class);
14307  private static NISuppressor arg1_lt_arg2 =
14308      new NISuppressor(2, 1, IntLessThan.class);
14309  private static NISuppressor arg2_lt_arg1 =
14310      new NISuppressor(1, 2, IntLessThan.class);
14311
14312  private static NISuppressor result_le_arg1 =
14313      new NISuppressor(0, 2, IntLessEqual.class);
14314  private static NISuppressor result_le_arg2 =
14315      new NISuppressor(0, 1, IntLessEqual.class);
14316  private static NISuppressor arg1_le_arg2 =
14317      new NISuppressor(2, 1, IntLessEqual.class);
14318  private static NISuppressor arg2_le_arg1 =
14319      new NISuppressor(1, 2, IntLessEqual.class);
14320
14321  private static NISuppressor result_track0_arg1 =
14322      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
14323  private static NISuppressor result_track0_arg2 =
14324      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
14325  private static NISuppressor arg1_track0_arg2 =
14326      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
14327  private static NISuppressor arg1_track0_result =
14328      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
14329  private static NISuppressor arg2_track0_result =
14330      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
14331  private static NISuppressor arg2_track0_arg1 =
14332      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
14333
14334  private static NISuppressor result_eq_1 =
14335      new NISuppressor(0, RangeInt.EqualOne.class);
14336  private static NISuppressor arg1_eq_1 =
14337      new NISuppressor(2, RangeInt.EqualOne.class);
14338  private static NISuppressor arg2_eq_1 =
14339      new NISuppressor(1, RangeInt.EqualOne.class);
14340
14341  private static NISuppressor result_eq_0 =
14342      new NISuppressor(0, RangeInt.EqualZero.class);
14343  private static NISuppressor arg1_eq_0 =
14344      new NISuppressor(2, RangeInt.EqualZero.class);
14345  private static NISuppressor arg2_eq_0 =
14346      new NISuppressor(1, RangeInt.EqualZero.class);
14347
14348  private static NISuppressor result_ne_0 =
14349      new NISuppressor(0, NonZero.class);
14350  private static NISuppressor arg1_ne_0 =
14351      new NISuppressor(2, NonZero.class);
14352  private static NISuppressor arg2_ne_0 =
14353      new NISuppressor(1, NonZero.class);
14354
14355  private static NISuppressor result_ge_0 =
14356      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
14357  private static NISuppressor arg1_ge_0 =
14358      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
14359  private static NISuppressor arg2_ge_0 =
14360      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
14361
14362  private static NISuppressor result_ge_64 =
14363      new NISuppressor(0, RangeInt.GreaterEqual64.class);
14364  private static NISuppressor arg1_ge_64 =
14365      new NISuppressor(2, RangeInt.GreaterEqual64.class);
14366  private static NISuppressor arg2_ge_64 =
14367      new NISuppressor(1, RangeInt.GreaterEqual64.class);
14368
14369  private static NISuppressor result_boolean =
14370      new NISuppressor(0, RangeInt.BooleanVal.class);
14371  private static NISuppressor arg1_boolean =
14372      new NISuppressor(2, RangeInt.BooleanVal.class);
14373  private static NISuppressor arg2_boolean =
14374      new NISuppressor(1, RangeInt.BooleanVal.class);
14375
14376  private static NISuppressor result_even =
14377      new NISuppressor(0, RangeInt.Even.class);
14378  private static NISuppressor arg1_even =
14379      new NISuppressor(2, RangeInt.Even.class);
14380  private static NISuppressor arg2_even =
14381      new NISuppressor(1, RangeInt.Even.class);
14382
14383  private static NISuppressor result_power2 =
14384      new NISuppressor(0, RangeInt.PowerOfTwo.class);
14385  private static NISuppressor arg1_power2 =
14386      new NISuppressor(2, RangeInt.PowerOfTwo.class);
14387  private static NISuppressor arg2_power2 =
14388      new NISuppressor(1, RangeInt.PowerOfTwo.class);
14389
14390  private static NISuppressor result_and0_arg1 =
14391      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
14392  private static NISuppressor result_and0_arg2 =
14393      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
14394  private static NISuppressor arg1_and0_arg2 =
14395      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
14396
14397  // The arguments to bitwise subset are backwards from what one
14398  // might expect.  The second argument is a subset of the first
14399  // argument
14400  private static NISuppressor arg1_bw_subset_arg2 =
14401      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
14402  private static NISuppressor arg2_bw_subset_arg1 =
14403      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
14404
14405  private static NISuppressor result_shift0_arg1 =
14406      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
14407  private static NISuppressor result_shift0_arg2 =
14408      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
14409  private static NISuppressor arg1_shift0_arg2 =
14410      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
14411
14412  private static NISuppressor arg2_divides_arg1 =
14413      new NISuppressor(2, 1, NumericInt.Divides.class);
14414  private static NISuppressor arg1_divides_arg2 =
14415      new NISuppressor(1, 2, NumericInt.Divides.class);
14416
14417  private static NISuppressor arg2_valid_shift =
14418      new NISuppressor(1, RangeInt.Bound0_63.class);
14419
14420    private static NISuppressionSet suppressions =
14421        new NISuppressionSet(
14422          new NISuppression[] {
14423
14424            // (r == z) && (y == 0) ==> r = z << y
14425            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
14426
14427            // (r == 0) && (z == 0) && (0 <= y <= 63)   ==> r = z << y
14428            new NISuppression(result_eq_0, arg1_eq_0, arg2_valid_shift,
14429                               suppressee),
14430
14431          });
14432
14433  // Create a suppression factory for functionBinary
14434
14435}
14436
14437/**
14438 * Represents the invariant {@code y = Lshift(z, x)} over three long
14439 * scalars. 
14440 */
14441public static class LshiftLong_yzx extends FunctionBinary {
14442  // We are Serializable, so we specify a version to allow changes to
14443  // method signatures without breaking serialization.  If you add or
14444  // remove fields, you should change this number to the current date.
14445  static final long serialVersionUID = 20031030L;
14446
14447    // x must be between arg2_bound[0] and arg2_bound[1] inclusive
14448    static int[] arg2_bound = {0, 63};
14449
14450  private static @Prototype LshiftLong_yzx proto = new @Prototype LshiftLong_yzx ();
14451
14452  /** Returns the prototype invariant for LshiftLong_yzx */
14453  public static @Prototype LshiftLong_yzx get_proto() {
14454    return proto;
14455  }
14456
14457  /** instantiate an invariant on the specified slice */
14458  @Override
14459  protected LshiftLong_yzx instantiate_dyn(@Prototype LshiftLong_yzx this, PptSlice slice) {
14460    return new LshiftLong_yzx (slice);
14461  }
14462
14463  private LshiftLong_yzx (PptSlice slice) {
14464    super(slice);
14465  }
14466
14467  public @Prototype LshiftLong_yzx () {
14468    super();
14469  }
14470
14471  private static String[] method_name = new String[] {"", " << ", ""};
14472
14473  @Override
14474  public String[] get_method_name(@GuardSatisfied LshiftLong_yzx this) {
14475    return method_name;
14476  }
14477
14478  private static int function_id = -1;
14479
14480  @Override
14481  public int get_function_id() {
14482    return function_id;
14483  }
14484
14485  @Override
14486  public void set_function_id(int function_id) {
14487    assert LshiftLong_yzx.function_id == -1;
14488    LshiftLong_yzx.function_id = function_id;
14489  }
14490
14491  private static int var_order = 5;
14492
14493  @Override
14494  public int get_var_order(@GuardSatisfied LshiftLong_yzx this) {
14495    return var_order;
14496  }
14497
14498  @Pure
14499  @Override
14500  public boolean is_symmetric() {
14501
14502      return false;
14503  }
14504
14505  @Override
14506
14507  public long func(long z, long x) {
14508
14509      if ((x < arg2_bound[0]) || (x > arg2_bound[1])) {
14510        throw new ArithmeticException("arg2 (" + x + ") out of range "
14511                                       + arg2_bound[0] + ".." + arg2_bound[1]);
14512      }
14513
14514    return (z << x);
14515  }
14516
14517  @Override
14518  public InvariantStatus check_modified(long x, long y,
14519                                      long z, int count) {
14520    return check_ordered(y, z, x, count);
14521  }
14522
14523  @Override
14524  public InvariantStatus add_modified(long x, long y,
14525                                      long z, int count) {
14526    if (Debug.logDetail()) {
14527      log("result=%s, arg1=%s, arg2=%s", y, z, x);
14528    }
14529    return add_ordered(y, z, x, count);
14530  }
14531
14532  @Pure
14533  @Override
14534  public boolean isLshift() {
14535    return true;
14536  }
14537
14538  /** Returns a list of non-instantiating suppressions for this invariant. */
14539  @Pure
14540  @Override
14541  public @Nullable NISuppressionSet get_ni_suppressions() {
14542    if (NIS.dkconfig_enabled && dkconfig_enabled) {
14543      return suppressions;
14544    } else {
14545      return null;
14546    }
14547  }
14548
14549  /** definition of this invariant (the suppressee) */
14550  private static NISuppressee suppressee = new NISuppressee(LshiftLong_yzx.class, 3);
14551
14552  // suppressor definitions (used below)
14553  private static NISuppressor result_eq_arg1 =
14554      new NISuppressor(1, 2, IntEqual.class);
14555  private static NISuppressor result_eq_arg2 =
14556      new NISuppressor(1, 0, IntEqual.class);
14557  private static NISuppressor arg1_eq_arg2 =
14558      new NISuppressor(2, 0, IntEqual.class);
14559
14560  private static NISuppressor result_lt_arg1 =
14561      new NISuppressor(1, 2, IntLessThan.class);
14562  private static NISuppressor result_lt_arg2 =
14563      new NISuppressor(1, 0, IntLessThan.class);
14564  private static NISuppressor arg1_lt_arg2 =
14565      new NISuppressor(2, 0, IntLessThan.class);
14566  private static NISuppressor arg2_lt_arg1 =
14567      new NISuppressor(0, 2, IntLessThan.class);
14568
14569  private static NISuppressor result_le_arg1 =
14570      new NISuppressor(1, 2, IntLessEqual.class);
14571  private static NISuppressor result_le_arg2 =
14572      new NISuppressor(1, 0, IntLessEqual.class);
14573  private static NISuppressor arg1_le_arg2 =
14574      new NISuppressor(2, 0, IntLessEqual.class);
14575  private static NISuppressor arg2_le_arg1 =
14576      new NISuppressor(0, 2, IntLessEqual.class);
14577
14578  private static NISuppressor result_track0_arg1 =
14579      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
14580  private static NISuppressor result_track0_arg2 =
14581      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
14582  private static NISuppressor arg1_track0_arg2 =
14583      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
14584  private static NISuppressor arg1_track0_result =
14585      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
14586  private static NISuppressor arg2_track0_result =
14587      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
14588  private static NISuppressor arg2_track0_arg1 =
14589      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
14590
14591  private static NISuppressor result_eq_1 =
14592      new NISuppressor(1, RangeInt.EqualOne.class);
14593  private static NISuppressor arg1_eq_1 =
14594      new NISuppressor(2, RangeInt.EqualOne.class);
14595  private static NISuppressor arg2_eq_1 =
14596      new NISuppressor(0, RangeInt.EqualOne.class);
14597
14598  private static NISuppressor result_eq_0 =
14599      new NISuppressor(1, RangeInt.EqualZero.class);
14600  private static NISuppressor arg1_eq_0 =
14601      new NISuppressor(2, RangeInt.EqualZero.class);
14602  private static NISuppressor arg2_eq_0 =
14603      new NISuppressor(0, RangeInt.EqualZero.class);
14604
14605  private static NISuppressor result_ne_0 =
14606      new NISuppressor(1, NonZero.class);
14607  private static NISuppressor arg1_ne_0 =
14608      new NISuppressor(2, NonZero.class);
14609  private static NISuppressor arg2_ne_0 =
14610      new NISuppressor(0, NonZero.class);
14611
14612  private static NISuppressor result_ge_0 =
14613      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
14614  private static NISuppressor arg1_ge_0 =
14615      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
14616  private static NISuppressor arg2_ge_0 =
14617      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
14618
14619  private static NISuppressor result_ge_64 =
14620      new NISuppressor(1, RangeInt.GreaterEqual64.class);
14621  private static NISuppressor arg1_ge_64 =
14622      new NISuppressor(2, RangeInt.GreaterEqual64.class);
14623  private static NISuppressor arg2_ge_64 =
14624      new NISuppressor(0, RangeInt.GreaterEqual64.class);
14625
14626  private static NISuppressor result_boolean =
14627      new NISuppressor(1, RangeInt.BooleanVal.class);
14628  private static NISuppressor arg1_boolean =
14629      new NISuppressor(2, RangeInt.BooleanVal.class);
14630  private static NISuppressor arg2_boolean =
14631      new NISuppressor(0, RangeInt.BooleanVal.class);
14632
14633  private static NISuppressor result_even =
14634      new NISuppressor(1, RangeInt.Even.class);
14635  private static NISuppressor arg1_even =
14636      new NISuppressor(2, RangeInt.Even.class);
14637  private static NISuppressor arg2_even =
14638      new NISuppressor(0, RangeInt.Even.class);
14639
14640  private static NISuppressor result_power2 =
14641      new NISuppressor(1, RangeInt.PowerOfTwo.class);
14642  private static NISuppressor arg1_power2 =
14643      new NISuppressor(2, RangeInt.PowerOfTwo.class);
14644  private static NISuppressor arg2_power2 =
14645      new NISuppressor(0, RangeInt.PowerOfTwo.class);
14646
14647  private static NISuppressor result_and0_arg1 =
14648      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
14649  private static NISuppressor result_and0_arg2 =
14650      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
14651  private static NISuppressor arg1_and0_arg2 =
14652      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
14653
14654  // The arguments to bitwise subset are backwards from what one
14655  // might expect.  The second argument is a subset of the first
14656  // argument
14657  private static NISuppressor arg1_bw_subset_arg2 =
14658      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
14659  private static NISuppressor arg2_bw_subset_arg1 =
14660      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
14661
14662  private static NISuppressor result_shift0_arg1 =
14663      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
14664  private static NISuppressor result_shift0_arg2 =
14665      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
14666  private static NISuppressor arg1_shift0_arg2 =
14667      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
14668
14669  private static NISuppressor arg2_divides_arg1 =
14670      new NISuppressor(2, 0, NumericInt.Divides.class);
14671  private static NISuppressor arg1_divides_arg2 =
14672      new NISuppressor(0, 2, NumericInt.Divides.class);
14673
14674  private static NISuppressor arg2_valid_shift =
14675      new NISuppressor(0, RangeInt.Bound0_63.class);
14676
14677    private static NISuppressionSet suppressions =
14678        new NISuppressionSet(
14679          new NISuppression[] {
14680
14681            // (r == z) && (x == 0) ==> r = z << x
14682            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
14683
14684            // (r == 0) && (z == 0) && (0 <= x <= 63)   ==> r = z << x
14685            new NISuppression(result_eq_0, arg1_eq_0, arg2_valid_shift,
14686                               suppressee),
14687
14688          });
14689
14690  // Create a suppression factory for functionBinary
14691
14692}
14693
14694/**
14695 * Represents the invariant {@code z = Lshift(y, x)} over three long
14696 * scalars. 
14697 */
14698public static class LshiftLong_zyx extends FunctionBinary {
14699  // We are Serializable, so we specify a version to allow changes to
14700  // method signatures without breaking serialization.  If you add or
14701  // remove fields, you should change this number to the current date.
14702  static final long serialVersionUID = 20031030L;
14703
14704    // x must be between arg2_bound[0] and arg2_bound[1] inclusive
14705    static int[] arg2_bound = {0, 63};
14706
14707  private static @Prototype LshiftLong_zyx proto = new @Prototype LshiftLong_zyx ();
14708
14709  /** Returns the prototype invariant for LshiftLong_zyx */
14710  public static @Prototype LshiftLong_zyx get_proto() {
14711    return proto;
14712  }
14713
14714  /** instantiate an invariant on the specified slice */
14715  @Override
14716  protected LshiftLong_zyx instantiate_dyn(@Prototype LshiftLong_zyx this, PptSlice slice) {
14717    return new LshiftLong_zyx (slice);
14718  }
14719
14720  private LshiftLong_zyx (PptSlice slice) {
14721    super(slice);
14722  }
14723
14724  public @Prototype LshiftLong_zyx () {
14725    super();
14726  }
14727
14728  private static String[] method_name = new String[] {"", " << ", ""};
14729
14730  @Override
14731  public String[] get_method_name(@GuardSatisfied LshiftLong_zyx this) {
14732    return method_name;
14733  }
14734
14735  private static int function_id = -1;
14736
14737  @Override
14738  public int get_function_id() {
14739    return function_id;
14740  }
14741
14742  @Override
14743  public void set_function_id(int function_id) {
14744    assert LshiftLong_zyx.function_id == -1;
14745    LshiftLong_zyx.function_id = function_id;
14746  }
14747
14748  private static int var_order = 6;
14749
14750  @Override
14751  public int get_var_order(@GuardSatisfied LshiftLong_zyx this) {
14752    return var_order;
14753  }
14754
14755  @Pure
14756  @Override
14757  public boolean is_symmetric() {
14758
14759      return false;
14760  }
14761
14762  @Override
14763
14764  public long func(long y, long x) {
14765
14766      if ((x < arg2_bound[0]) || (x > arg2_bound[1])) {
14767        throw new ArithmeticException("arg2 (" + x + ") out of range "
14768                                       + arg2_bound[0] + ".." + arg2_bound[1]);
14769      }
14770
14771    return (y << x);
14772  }
14773
14774  @Override
14775  public InvariantStatus check_modified(long x, long y,
14776                                      long z, int count) {
14777    return check_ordered(z, y, x, count);
14778  }
14779
14780  @Override
14781  public InvariantStatus add_modified(long x, long y,
14782                                      long z, int count) {
14783    if (Debug.logDetail()) {
14784      log("result=%s, arg1=%s, arg2=%s", z, y, x);
14785    }
14786    return add_ordered(z, y, x, count);
14787  }
14788
14789  @Pure
14790  @Override
14791  public boolean isLshift() {
14792    return true;
14793  }
14794
14795  /** Returns a list of non-instantiating suppressions for this invariant. */
14796  @Pure
14797  @Override
14798  public @Nullable NISuppressionSet get_ni_suppressions() {
14799    if (NIS.dkconfig_enabled && dkconfig_enabled) {
14800      return suppressions;
14801    } else {
14802      return null;
14803    }
14804  }
14805
14806  /** definition of this invariant (the suppressee) */
14807  private static NISuppressee suppressee = new NISuppressee(LshiftLong_zyx.class, 3);
14808
14809  // suppressor definitions (used below)
14810  private static NISuppressor result_eq_arg1 =
14811      new NISuppressor(2, 1, IntEqual.class);
14812  private static NISuppressor result_eq_arg2 =
14813      new NISuppressor(2, 0, IntEqual.class);
14814  private static NISuppressor arg1_eq_arg2 =
14815      new NISuppressor(1, 0, IntEqual.class);
14816
14817  private static NISuppressor result_lt_arg1 =
14818      new NISuppressor(2, 1, IntLessThan.class);
14819  private static NISuppressor result_lt_arg2 =
14820      new NISuppressor(2, 0, IntLessThan.class);
14821  private static NISuppressor arg1_lt_arg2 =
14822      new NISuppressor(1, 0, IntLessThan.class);
14823  private static NISuppressor arg2_lt_arg1 =
14824      new NISuppressor(0, 1, IntLessThan.class);
14825
14826  private static NISuppressor result_le_arg1 =
14827      new NISuppressor(2, 1, IntLessEqual.class);
14828  private static NISuppressor result_le_arg2 =
14829      new NISuppressor(2, 0, IntLessEqual.class);
14830  private static NISuppressor arg1_le_arg2 =
14831      new NISuppressor(1, 0, IntLessEqual.class);
14832  private static NISuppressor arg2_le_arg1 =
14833      new NISuppressor(0, 1, IntLessEqual.class);
14834
14835  private static NISuppressor result_track0_arg1 =
14836      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
14837  private static NISuppressor result_track0_arg2 =
14838      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
14839  private static NISuppressor arg1_track0_arg2 =
14840      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
14841  private static NISuppressor arg1_track0_result =
14842      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
14843  private static NISuppressor arg2_track0_result =
14844      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
14845  private static NISuppressor arg2_track0_arg1 =
14846      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
14847
14848  private static NISuppressor result_eq_1 =
14849      new NISuppressor(2, RangeInt.EqualOne.class);
14850  private static NISuppressor arg1_eq_1 =
14851      new NISuppressor(1, RangeInt.EqualOne.class);
14852  private static NISuppressor arg2_eq_1 =
14853      new NISuppressor(0, RangeInt.EqualOne.class);
14854
14855  private static NISuppressor result_eq_0 =
14856      new NISuppressor(2, RangeInt.EqualZero.class);
14857  private static NISuppressor arg1_eq_0 =
14858      new NISuppressor(1, RangeInt.EqualZero.class);
14859  private static NISuppressor arg2_eq_0 =
14860      new NISuppressor(0, RangeInt.EqualZero.class);
14861
14862  private static NISuppressor result_ne_0 =
14863      new NISuppressor(2, NonZero.class);
14864  private static NISuppressor arg1_ne_0 =
14865      new NISuppressor(1, NonZero.class);
14866  private static NISuppressor arg2_ne_0 =
14867      new NISuppressor(0, NonZero.class);
14868
14869  private static NISuppressor result_ge_0 =
14870      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
14871  private static NISuppressor arg1_ge_0 =
14872      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
14873  private static NISuppressor arg2_ge_0 =
14874      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
14875
14876  private static NISuppressor result_ge_64 =
14877      new NISuppressor(2, RangeInt.GreaterEqual64.class);
14878  private static NISuppressor arg1_ge_64 =
14879      new NISuppressor(1, RangeInt.GreaterEqual64.class);
14880  private static NISuppressor arg2_ge_64 =
14881      new NISuppressor(0, RangeInt.GreaterEqual64.class);
14882
14883  private static NISuppressor result_boolean =
14884      new NISuppressor(2, RangeInt.BooleanVal.class);
14885  private static NISuppressor arg1_boolean =
14886      new NISuppressor(1, RangeInt.BooleanVal.class);
14887  private static NISuppressor arg2_boolean =
14888      new NISuppressor(0, RangeInt.BooleanVal.class);
14889
14890  private static NISuppressor result_even =
14891      new NISuppressor(2, RangeInt.Even.class);
14892  private static NISuppressor arg1_even =
14893      new NISuppressor(1, RangeInt.Even.class);
14894  private static NISuppressor arg2_even =
14895      new NISuppressor(0, RangeInt.Even.class);
14896
14897  private static NISuppressor result_power2 =
14898      new NISuppressor(2, RangeInt.PowerOfTwo.class);
14899  private static NISuppressor arg1_power2 =
14900      new NISuppressor(1, RangeInt.PowerOfTwo.class);
14901  private static NISuppressor arg2_power2 =
14902      new NISuppressor(0, RangeInt.PowerOfTwo.class);
14903
14904  private static NISuppressor result_and0_arg1 =
14905      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
14906  private static NISuppressor result_and0_arg2 =
14907      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
14908  private static NISuppressor arg1_and0_arg2 =
14909      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
14910
14911  // The arguments to bitwise subset are backwards from what one
14912  // might expect.  The second argument is a subset of the first
14913  // argument
14914  private static NISuppressor arg1_bw_subset_arg2 =
14915      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
14916  private static NISuppressor arg2_bw_subset_arg1 =
14917      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
14918
14919  private static NISuppressor result_shift0_arg1 =
14920      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
14921  private static NISuppressor result_shift0_arg2 =
14922      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
14923  private static NISuppressor arg1_shift0_arg2 =
14924      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
14925
14926  private static NISuppressor arg2_divides_arg1 =
14927      new NISuppressor(1, 0, NumericInt.Divides.class);
14928  private static NISuppressor arg1_divides_arg2 =
14929      new NISuppressor(0, 1, NumericInt.Divides.class);
14930
14931  private static NISuppressor arg2_valid_shift =
14932      new NISuppressor(0, RangeInt.Bound0_63.class);
14933
14934    private static NISuppressionSet suppressions =
14935        new NISuppressionSet(
14936          new NISuppression[] {
14937
14938            // (r == y) && (x == 0) ==> r = y << x
14939            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
14940
14941            // (r == 0) && (y == 0) && (0 <= x <= 63)   ==> r = y << x
14942            new NISuppression(result_eq_0, arg1_eq_0, arg2_valid_shift,
14943                               suppressee),
14944
14945          });
14946
14947  // Create a suppression factory for functionBinary
14948
14949}
14950
14951  // default is that it is not this function, overriden in the subclass
14952  @Pure
14953  public boolean isRshiftSigned() {
14954    return false;
14955  }
14956
14957/**
14958 * Represents the invariant {@code x = RshiftSigned(y, z)} over three long
14959 * scalars. 
14960 */
14961public static class RshiftSignedLong_xyz extends FunctionBinary {
14962  // We are Serializable, so we specify a version to allow changes to
14963  // method signatures without breaking serialization.  If you add or
14964  // remove fields, you should change this number to the current date.
14965  static final long serialVersionUID = 20031030L;
14966
14967    // z must be between arg2_bound[0] and arg2_bound[1] inclusive
14968    static int[] arg2_bound = {0, 63};
14969
14970  private static @Prototype RshiftSignedLong_xyz proto = new @Prototype RshiftSignedLong_xyz ();
14971
14972  /** Returns the prototype invariant for RshiftSignedLong_xyz */
14973  public static @Prototype RshiftSignedLong_xyz get_proto() {
14974    return proto;
14975  }
14976
14977  /** instantiate an invariant on the specified slice */
14978  @Override
14979  protected RshiftSignedLong_xyz instantiate_dyn(@Prototype RshiftSignedLong_xyz this, PptSlice slice) {
14980    return new RshiftSignedLong_xyz (slice);
14981  }
14982
14983  private RshiftSignedLong_xyz (PptSlice slice) {
14984    super(slice);
14985  }
14986
14987  public @Prototype RshiftSignedLong_xyz () {
14988    super();
14989  }
14990
14991  private static String[] method_name = new String[] {"", " >> ", ""};
14992
14993  @Override
14994  public String[] get_method_name(@GuardSatisfied RshiftSignedLong_xyz this) {
14995    return method_name;
14996  }
14997
14998  private static int function_id = -1;
14999
15000  @Override
15001  public int get_function_id() {
15002    return function_id;
15003  }
15004
15005  @Override
15006  public void set_function_id(int function_id) {
15007    assert RshiftSignedLong_xyz.function_id == -1;
15008    RshiftSignedLong_xyz.function_id = function_id;
15009  }
15010
15011  private static int var_order = 1;
15012
15013  @Override
15014  public int get_var_order(@GuardSatisfied RshiftSignedLong_xyz this) {
15015    return var_order;
15016  }
15017
15018  @Pure
15019  @Override
15020  public boolean is_symmetric() {
15021
15022      return false;
15023  }
15024
15025  @Override
15026
15027  public long func(long y, long z) {
15028
15029      if ((z < arg2_bound[0]) || (z > arg2_bound[1])) {
15030        throw new ArithmeticException("arg2 (" + z + ") out of range "
15031                                       + arg2_bound[0] + ".." + arg2_bound[1]);
15032      }
15033
15034    return (y >> z);
15035  }
15036
15037  @Override
15038  public InvariantStatus check_modified(long x, long y,
15039                                      long z, int count) {
15040    return check_ordered(x, y, z, count);
15041  }
15042
15043  @Override
15044  public InvariantStatus add_modified(long x, long y,
15045                                      long z, int count) {
15046    if (Debug.logDetail()) {
15047      log("result=%s, arg1=%s, arg2=%s", x, y, z);
15048    }
15049    return add_ordered(x, y, z, count);
15050  }
15051
15052  @Pure
15053  @Override
15054  public boolean isRshiftSigned() {
15055    return true;
15056  }
15057
15058  /** Returns a list of non-instantiating suppressions for this invariant. */
15059  @Pure
15060  @Override
15061  public @Nullable NISuppressionSet get_ni_suppressions() {
15062    if (NIS.dkconfig_enabled && dkconfig_enabled) {
15063      return suppressions;
15064    } else {
15065      return null;
15066    }
15067  }
15068
15069  /** definition of this invariant (the suppressee) */
15070  private static NISuppressee suppressee = new NISuppressee(RshiftSignedLong_xyz.class, 3);
15071
15072  // suppressor definitions (used below)
15073  private static NISuppressor result_eq_arg1 =
15074      new NISuppressor(0, 1, IntEqual.class);
15075  private static NISuppressor result_eq_arg2 =
15076      new NISuppressor(0, 2, IntEqual.class);
15077  private static NISuppressor arg1_eq_arg2 =
15078      new NISuppressor(1, 2, IntEqual.class);
15079
15080  private static NISuppressor result_lt_arg1 =
15081      new NISuppressor(0, 1, IntLessThan.class);
15082  private static NISuppressor result_lt_arg2 =
15083      new NISuppressor(0, 2, IntLessThan.class);
15084  private static NISuppressor arg1_lt_arg2 =
15085      new NISuppressor(1, 2, IntLessThan.class);
15086  private static NISuppressor arg2_lt_arg1 =
15087      new NISuppressor(2, 1, IntLessThan.class);
15088
15089  private static NISuppressor result_le_arg1 =
15090      new NISuppressor(0, 1, IntLessEqual.class);
15091  private static NISuppressor result_le_arg2 =
15092      new NISuppressor(0, 2, IntLessEqual.class);
15093  private static NISuppressor arg1_le_arg2 =
15094      new NISuppressor(1, 2, IntLessEqual.class);
15095  private static NISuppressor arg2_le_arg1 =
15096      new NISuppressor(2, 1, IntLessEqual.class);
15097
15098  private static NISuppressor result_track0_arg1 =
15099      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
15100  private static NISuppressor result_track0_arg2 =
15101      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
15102  private static NISuppressor arg1_track0_arg2 =
15103      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
15104  private static NISuppressor arg1_track0_result =
15105      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
15106  private static NISuppressor arg2_track0_result =
15107      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
15108  private static NISuppressor arg2_track0_arg1 =
15109      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
15110
15111  private static NISuppressor result_eq_1 =
15112      new NISuppressor(0, RangeInt.EqualOne.class);
15113  private static NISuppressor arg1_eq_1 =
15114      new NISuppressor(1, RangeInt.EqualOne.class);
15115  private static NISuppressor arg2_eq_1 =
15116      new NISuppressor(2, RangeInt.EqualOne.class);
15117
15118  private static NISuppressor result_eq_0 =
15119      new NISuppressor(0, RangeInt.EqualZero.class);
15120  private static NISuppressor arg1_eq_0 =
15121      new NISuppressor(1, RangeInt.EqualZero.class);
15122  private static NISuppressor arg2_eq_0 =
15123      new NISuppressor(2, RangeInt.EqualZero.class);
15124
15125  private static NISuppressor result_ne_0 =
15126      new NISuppressor(0, NonZero.class);
15127  private static NISuppressor arg1_ne_0 =
15128      new NISuppressor(1, NonZero.class);
15129  private static NISuppressor arg2_ne_0 =
15130      new NISuppressor(2, NonZero.class);
15131
15132  private static NISuppressor result_ge_0 =
15133      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
15134  private static NISuppressor arg1_ge_0 =
15135      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
15136  private static NISuppressor arg2_ge_0 =
15137      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
15138
15139  private static NISuppressor result_ge_64 =
15140      new NISuppressor(0, RangeInt.GreaterEqual64.class);
15141  private static NISuppressor arg1_ge_64 =
15142      new NISuppressor(1, RangeInt.GreaterEqual64.class);
15143  private static NISuppressor arg2_ge_64 =
15144      new NISuppressor(2, RangeInt.GreaterEqual64.class);
15145
15146  private static NISuppressor result_boolean =
15147      new NISuppressor(0, RangeInt.BooleanVal.class);
15148  private static NISuppressor arg1_boolean =
15149      new NISuppressor(1, RangeInt.BooleanVal.class);
15150  private static NISuppressor arg2_boolean =
15151      new NISuppressor(2, RangeInt.BooleanVal.class);
15152
15153  private static NISuppressor result_even =
15154      new NISuppressor(0, RangeInt.Even.class);
15155  private static NISuppressor arg1_even =
15156      new NISuppressor(1, RangeInt.Even.class);
15157  private static NISuppressor arg2_even =
15158      new NISuppressor(2, RangeInt.Even.class);
15159
15160  private static NISuppressor result_power2 =
15161      new NISuppressor(0, RangeInt.PowerOfTwo.class);
15162  private static NISuppressor arg1_power2 =
15163      new NISuppressor(1, RangeInt.PowerOfTwo.class);
15164  private static NISuppressor arg2_power2 =
15165      new NISuppressor(2, RangeInt.PowerOfTwo.class);
15166
15167  private static NISuppressor result_and0_arg1 =
15168      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
15169  private static NISuppressor result_and0_arg2 =
15170      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
15171  private static NISuppressor arg1_and0_arg2 =
15172      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
15173
15174  // The arguments to bitwise subset are backwards from what one
15175  // might expect.  The second argument is a subset of the first
15176  // argument
15177  private static NISuppressor arg1_bw_subset_arg2 =
15178      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
15179  private static NISuppressor arg2_bw_subset_arg1 =
15180      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
15181
15182  private static NISuppressor result_shift0_arg1 =
15183      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
15184  private static NISuppressor result_shift0_arg2 =
15185      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
15186  private static NISuppressor arg1_shift0_arg2 =
15187      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
15188
15189  private static NISuppressor arg2_divides_arg1 =
15190      new NISuppressor(1, 2, NumericInt.Divides.class);
15191  private static NISuppressor arg1_divides_arg2 =
15192      new NISuppressor(2, 1, NumericInt.Divides.class);
15193
15194  private static NISuppressor arg2_valid_shift =
15195      new NISuppressor(2, RangeInt.Bound0_63.class);
15196
15197    private static NISuppressionSet suppressions =
15198        new NISuppressionSet(
15199          new NISuppression[] {
15200
15201            // (r == y) && (z == 0) ==> r = y >>> z
15202            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
15203
15204            // (r == 0) && (y == 0) && (0 <= z <= 63)   ==> r = y >>> z
15205            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
15206
15207            // (r == 0) && ((y >> z) == 0)
15208            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
15209
15210            // (r == 0) && (z >= y) && (y >= 0) && (z valid shift)
15211            // This suppression really ought to have 2**z >= y, but we
15212            // don't have that invariant.  This still might catch a lot of these.
15213            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
15214            //                   arg2_valid_shift, suppressee),
15215          });
15216
15217  // Create a suppression factory for functionBinary
15218
15219}
15220
15221/**
15222 * Represents the invariant {@code y = RshiftSigned(x, z)} over three long
15223 * scalars. 
15224 */
15225public static class RshiftSignedLong_yxz extends FunctionBinary {
15226  // We are Serializable, so we specify a version to allow changes to
15227  // method signatures without breaking serialization.  If you add or
15228  // remove fields, you should change this number to the current date.
15229  static final long serialVersionUID = 20031030L;
15230
15231    // z must be between arg2_bound[0] and arg2_bound[1] inclusive
15232    static int[] arg2_bound = {0, 63};
15233
15234  private static @Prototype RshiftSignedLong_yxz proto = new @Prototype RshiftSignedLong_yxz ();
15235
15236  /** Returns the prototype invariant for RshiftSignedLong_yxz */
15237  public static @Prototype RshiftSignedLong_yxz get_proto() {
15238    return proto;
15239  }
15240
15241  /** instantiate an invariant on the specified slice */
15242  @Override
15243  protected RshiftSignedLong_yxz instantiate_dyn(@Prototype RshiftSignedLong_yxz this, PptSlice slice) {
15244    return new RshiftSignedLong_yxz (slice);
15245  }
15246
15247  private RshiftSignedLong_yxz (PptSlice slice) {
15248    super(slice);
15249  }
15250
15251  public @Prototype RshiftSignedLong_yxz () {
15252    super();
15253  }
15254
15255  private static String[] method_name = new String[] {"", " >> ", ""};
15256
15257  @Override
15258  public String[] get_method_name(@GuardSatisfied RshiftSignedLong_yxz this) {
15259    return method_name;
15260  }
15261
15262  private static int function_id = -1;
15263
15264  @Override
15265  public int get_function_id() {
15266    return function_id;
15267  }
15268
15269  @Override
15270  public void set_function_id(int function_id) {
15271    assert RshiftSignedLong_yxz.function_id == -1;
15272    RshiftSignedLong_yxz.function_id = function_id;
15273  }
15274
15275  private static int var_order = 2;
15276
15277  @Override
15278  public int get_var_order(@GuardSatisfied RshiftSignedLong_yxz this) {
15279    return var_order;
15280  }
15281
15282  @Pure
15283  @Override
15284  public boolean is_symmetric() {
15285
15286      return false;
15287  }
15288
15289  @Override
15290
15291  public long func(long x, long z) {
15292
15293      if ((z < arg2_bound[0]) || (z > arg2_bound[1])) {
15294        throw new ArithmeticException("arg2 (" + z + ") out of range "
15295                                       + arg2_bound[0] + ".." + arg2_bound[1]);
15296      }
15297
15298    return (x >> z);
15299  }
15300
15301  @Override
15302  public InvariantStatus check_modified(long x, long y,
15303                                      long z, int count) {
15304    return check_ordered(y, x, z, count);
15305  }
15306
15307  @Override
15308  public InvariantStatus add_modified(long x, long y,
15309                                      long z, int count) {
15310    if (Debug.logDetail()) {
15311      log("result=%s, arg1=%s, arg2=%s", y, x, z);
15312    }
15313    return add_ordered(y, x, z, count);
15314  }
15315
15316  @Pure
15317  @Override
15318  public boolean isRshiftSigned() {
15319    return true;
15320  }
15321
15322  /** Returns a list of non-instantiating suppressions for this invariant. */
15323  @Pure
15324  @Override
15325  public @Nullable NISuppressionSet get_ni_suppressions() {
15326    if (NIS.dkconfig_enabled && dkconfig_enabled) {
15327      return suppressions;
15328    } else {
15329      return null;
15330    }
15331  }
15332
15333  /** definition of this invariant (the suppressee) */
15334  private static NISuppressee suppressee = new NISuppressee(RshiftSignedLong_yxz.class, 3);
15335
15336  // suppressor definitions (used below)
15337  private static NISuppressor result_eq_arg1 =
15338      new NISuppressor(1, 0, IntEqual.class);
15339  private static NISuppressor result_eq_arg2 =
15340      new NISuppressor(1, 2, IntEqual.class);
15341  private static NISuppressor arg1_eq_arg2 =
15342      new NISuppressor(0, 2, IntEqual.class);
15343
15344  private static NISuppressor result_lt_arg1 =
15345      new NISuppressor(1, 0, IntLessThan.class);
15346  private static NISuppressor result_lt_arg2 =
15347      new NISuppressor(1, 2, IntLessThan.class);
15348  private static NISuppressor arg1_lt_arg2 =
15349      new NISuppressor(0, 2, IntLessThan.class);
15350  private static NISuppressor arg2_lt_arg1 =
15351      new NISuppressor(2, 0, IntLessThan.class);
15352
15353  private static NISuppressor result_le_arg1 =
15354      new NISuppressor(1, 0, IntLessEqual.class);
15355  private static NISuppressor result_le_arg2 =
15356      new NISuppressor(1, 2, IntLessEqual.class);
15357  private static NISuppressor arg1_le_arg2 =
15358      new NISuppressor(0, 2, IntLessEqual.class);
15359  private static NISuppressor arg2_le_arg1 =
15360      new NISuppressor(2, 0, IntLessEqual.class);
15361
15362  private static NISuppressor result_track0_arg1 =
15363      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
15364  private static NISuppressor result_track0_arg2 =
15365      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
15366  private static NISuppressor arg1_track0_arg2 =
15367      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
15368  private static NISuppressor arg1_track0_result =
15369      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
15370  private static NISuppressor arg2_track0_result =
15371      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
15372  private static NISuppressor arg2_track0_arg1 =
15373      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
15374
15375  private static NISuppressor result_eq_1 =
15376      new NISuppressor(1, RangeInt.EqualOne.class);
15377  private static NISuppressor arg1_eq_1 =
15378      new NISuppressor(0, RangeInt.EqualOne.class);
15379  private static NISuppressor arg2_eq_1 =
15380      new NISuppressor(2, RangeInt.EqualOne.class);
15381
15382  private static NISuppressor result_eq_0 =
15383      new NISuppressor(1, RangeInt.EqualZero.class);
15384  private static NISuppressor arg1_eq_0 =
15385      new NISuppressor(0, RangeInt.EqualZero.class);
15386  private static NISuppressor arg2_eq_0 =
15387      new NISuppressor(2, RangeInt.EqualZero.class);
15388
15389  private static NISuppressor result_ne_0 =
15390      new NISuppressor(1, NonZero.class);
15391  private static NISuppressor arg1_ne_0 =
15392      new NISuppressor(0, NonZero.class);
15393  private static NISuppressor arg2_ne_0 =
15394      new NISuppressor(2, NonZero.class);
15395
15396  private static NISuppressor result_ge_0 =
15397      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
15398  private static NISuppressor arg1_ge_0 =
15399      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
15400  private static NISuppressor arg2_ge_0 =
15401      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
15402
15403  private static NISuppressor result_ge_64 =
15404      new NISuppressor(1, RangeInt.GreaterEqual64.class);
15405  private static NISuppressor arg1_ge_64 =
15406      new NISuppressor(0, RangeInt.GreaterEqual64.class);
15407  private static NISuppressor arg2_ge_64 =
15408      new NISuppressor(2, RangeInt.GreaterEqual64.class);
15409
15410  private static NISuppressor result_boolean =
15411      new NISuppressor(1, RangeInt.BooleanVal.class);
15412  private static NISuppressor arg1_boolean =
15413      new NISuppressor(0, RangeInt.BooleanVal.class);
15414  private static NISuppressor arg2_boolean =
15415      new NISuppressor(2, RangeInt.BooleanVal.class);
15416
15417  private static NISuppressor result_even =
15418      new NISuppressor(1, RangeInt.Even.class);
15419  private static NISuppressor arg1_even =
15420      new NISuppressor(0, RangeInt.Even.class);
15421  private static NISuppressor arg2_even =
15422      new NISuppressor(2, RangeInt.Even.class);
15423
15424  private static NISuppressor result_power2 =
15425      new NISuppressor(1, RangeInt.PowerOfTwo.class);
15426  private static NISuppressor arg1_power2 =
15427      new NISuppressor(0, RangeInt.PowerOfTwo.class);
15428  private static NISuppressor arg2_power2 =
15429      new NISuppressor(2, RangeInt.PowerOfTwo.class);
15430
15431  private static NISuppressor result_and0_arg1 =
15432      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
15433  private static NISuppressor result_and0_arg2 =
15434      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
15435  private static NISuppressor arg1_and0_arg2 =
15436      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
15437
15438  // The arguments to bitwise subset are backwards from what one
15439  // might expect.  The second argument is a subset of the first
15440  // argument
15441  private static NISuppressor arg1_bw_subset_arg2 =
15442      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
15443  private static NISuppressor arg2_bw_subset_arg1 =
15444      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
15445
15446  private static NISuppressor result_shift0_arg1 =
15447      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
15448  private static NISuppressor result_shift0_arg2 =
15449      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
15450  private static NISuppressor arg1_shift0_arg2 =
15451      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
15452
15453  private static NISuppressor arg2_divides_arg1 =
15454      new NISuppressor(0, 2, NumericInt.Divides.class);
15455  private static NISuppressor arg1_divides_arg2 =
15456      new NISuppressor(2, 0, NumericInt.Divides.class);
15457
15458  private static NISuppressor arg2_valid_shift =
15459      new NISuppressor(2, RangeInt.Bound0_63.class);
15460
15461    private static NISuppressionSet suppressions =
15462        new NISuppressionSet(
15463          new NISuppression[] {
15464
15465            // (r == x) && (z == 0) ==> r = x >>> z
15466            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
15467
15468            // (r == 0) && (x == 0) && (0 <= z <= 63)   ==> r = x >>> z
15469            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
15470
15471            // (r == 0) && ((x >> z) == 0)
15472            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
15473
15474            // (r == 0) && (z >= x) && (x >= 0) && (z valid shift)
15475            // This suppression really ought to have 2**z >= x, but we
15476            // don't have that invariant.  This still might catch a lot of these.
15477            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
15478            //                   arg2_valid_shift, suppressee),
15479          });
15480
15481  // Create a suppression factory for functionBinary
15482
15483}
15484
15485/**
15486 * Represents the invariant {@code z = RshiftSigned(x, y)} over three long
15487 * scalars. 
15488 */
15489public static class RshiftSignedLong_zxy extends FunctionBinary {
15490  // We are Serializable, so we specify a version to allow changes to
15491  // method signatures without breaking serialization.  If you add or
15492  // remove fields, you should change this number to the current date.
15493  static final long serialVersionUID = 20031030L;
15494
15495    // y must be between arg2_bound[0] and arg2_bound[1] inclusive
15496    static int[] arg2_bound = {0, 63};
15497
15498  private static @Prototype RshiftSignedLong_zxy proto = new @Prototype RshiftSignedLong_zxy ();
15499
15500  /** Returns the prototype invariant for RshiftSignedLong_zxy */
15501  public static @Prototype RshiftSignedLong_zxy get_proto() {
15502    return proto;
15503  }
15504
15505  /** instantiate an invariant on the specified slice */
15506  @Override
15507  protected RshiftSignedLong_zxy instantiate_dyn(@Prototype RshiftSignedLong_zxy this, PptSlice slice) {
15508    return new RshiftSignedLong_zxy (slice);
15509  }
15510
15511  private RshiftSignedLong_zxy (PptSlice slice) {
15512    super(slice);
15513  }
15514
15515  public @Prototype RshiftSignedLong_zxy () {
15516    super();
15517  }
15518
15519  private static String[] method_name = new String[] {"", " >> ", ""};
15520
15521  @Override
15522  public String[] get_method_name(@GuardSatisfied RshiftSignedLong_zxy this) {
15523    return method_name;
15524  }
15525
15526  private static int function_id = -1;
15527
15528  @Override
15529  public int get_function_id() {
15530    return function_id;
15531  }
15532
15533  @Override
15534  public void set_function_id(int function_id) {
15535    assert RshiftSignedLong_zxy.function_id == -1;
15536    RshiftSignedLong_zxy.function_id = function_id;
15537  }
15538
15539  private static int var_order = 3;
15540
15541  @Override
15542  public int get_var_order(@GuardSatisfied RshiftSignedLong_zxy this) {
15543    return var_order;
15544  }
15545
15546  @Pure
15547  @Override
15548  public boolean is_symmetric() {
15549
15550      return false;
15551  }
15552
15553  @Override
15554
15555  public long func(long x, long y) {
15556
15557      if ((y < arg2_bound[0]) || (y > arg2_bound[1])) {
15558        throw new ArithmeticException("arg2 (" + y + ") out of range "
15559                                       + arg2_bound[0] + ".." + arg2_bound[1]);
15560      }
15561
15562    return (x >> y);
15563  }
15564
15565  @Override
15566  public InvariantStatus check_modified(long x, long y,
15567                                      long z, int count) {
15568    return check_ordered(z, x, y, count);
15569  }
15570
15571  @Override
15572  public InvariantStatus add_modified(long x, long y,
15573                                      long z, int count) {
15574    if (Debug.logDetail()) {
15575      log("result=%s, arg1=%s, arg2=%s", z, x, y);
15576    }
15577    return add_ordered(z, x, y, count);
15578  }
15579
15580  @Pure
15581  @Override
15582  public boolean isRshiftSigned() {
15583    return true;
15584  }
15585
15586  /** Returns a list of non-instantiating suppressions for this invariant. */
15587  @Pure
15588  @Override
15589  public @Nullable NISuppressionSet get_ni_suppressions() {
15590    if (NIS.dkconfig_enabled && dkconfig_enabled) {
15591      return suppressions;
15592    } else {
15593      return null;
15594    }
15595  }
15596
15597  /** definition of this invariant (the suppressee) */
15598  private static NISuppressee suppressee = new NISuppressee(RshiftSignedLong_zxy.class, 3);
15599
15600  // suppressor definitions (used below)
15601  private static NISuppressor result_eq_arg1 =
15602      new NISuppressor(2, 0, IntEqual.class);
15603  private static NISuppressor result_eq_arg2 =
15604      new NISuppressor(2, 1, IntEqual.class);
15605  private static NISuppressor arg1_eq_arg2 =
15606      new NISuppressor(0, 1, IntEqual.class);
15607
15608  private static NISuppressor result_lt_arg1 =
15609      new NISuppressor(2, 0, IntLessThan.class);
15610  private static NISuppressor result_lt_arg2 =
15611      new NISuppressor(2, 1, IntLessThan.class);
15612  private static NISuppressor arg1_lt_arg2 =
15613      new NISuppressor(0, 1, IntLessThan.class);
15614  private static NISuppressor arg2_lt_arg1 =
15615      new NISuppressor(1, 0, IntLessThan.class);
15616
15617  private static NISuppressor result_le_arg1 =
15618      new NISuppressor(2, 0, IntLessEqual.class);
15619  private static NISuppressor result_le_arg2 =
15620      new NISuppressor(2, 1, IntLessEqual.class);
15621  private static NISuppressor arg1_le_arg2 =
15622      new NISuppressor(0, 1, IntLessEqual.class);
15623  private static NISuppressor arg2_le_arg1 =
15624      new NISuppressor(1, 0, IntLessEqual.class);
15625
15626  private static NISuppressor result_track0_arg1 =
15627      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
15628  private static NISuppressor result_track0_arg2 =
15629      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
15630  private static NISuppressor arg1_track0_arg2 =
15631      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
15632  private static NISuppressor arg1_track0_result =
15633      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
15634  private static NISuppressor arg2_track0_result =
15635      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
15636  private static NISuppressor arg2_track0_arg1 =
15637      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
15638
15639  private static NISuppressor result_eq_1 =
15640      new NISuppressor(2, RangeInt.EqualOne.class);
15641  private static NISuppressor arg1_eq_1 =
15642      new NISuppressor(0, RangeInt.EqualOne.class);
15643  private static NISuppressor arg2_eq_1 =
15644      new NISuppressor(1, RangeInt.EqualOne.class);
15645
15646  private static NISuppressor result_eq_0 =
15647      new NISuppressor(2, RangeInt.EqualZero.class);
15648  private static NISuppressor arg1_eq_0 =
15649      new NISuppressor(0, RangeInt.EqualZero.class);
15650  private static NISuppressor arg2_eq_0 =
15651      new NISuppressor(1, RangeInt.EqualZero.class);
15652
15653  private static NISuppressor result_ne_0 =
15654      new NISuppressor(2, NonZero.class);
15655  private static NISuppressor arg1_ne_0 =
15656      new NISuppressor(0, NonZero.class);
15657  private static NISuppressor arg2_ne_0 =
15658      new NISuppressor(1, NonZero.class);
15659
15660  private static NISuppressor result_ge_0 =
15661      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
15662  private static NISuppressor arg1_ge_0 =
15663      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
15664  private static NISuppressor arg2_ge_0 =
15665      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
15666
15667  private static NISuppressor result_ge_64 =
15668      new NISuppressor(2, RangeInt.GreaterEqual64.class);
15669  private static NISuppressor arg1_ge_64 =
15670      new NISuppressor(0, RangeInt.GreaterEqual64.class);
15671  private static NISuppressor arg2_ge_64 =
15672      new NISuppressor(1, RangeInt.GreaterEqual64.class);
15673
15674  private static NISuppressor result_boolean =
15675      new NISuppressor(2, RangeInt.BooleanVal.class);
15676  private static NISuppressor arg1_boolean =
15677      new NISuppressor(0, RangeInt.BooleanVal.class);
15678  private static NISuppressor arg2_boolean =
15679      new NISuppressor(1, RangeInt.BooleanVal.class);
15680
15681  private static NISuppressor result_even =
15682      new NISuppressor(2, RangeInt.Even.class);
15683  private static NISuppressor arg1_even =
15684      new NISuppressor(0, RangeInt.Even.class);
15685  private static NISuppressor arg2_even =
15686      new NISuppressor(1, RangeInt.Even.class);
15687
15688  private static NISuppressor result_power2 =
15689      new NISuppressor(2, RangeInt.PowerOfTwo.class);
15690  private static NISuppressor arg1_power2 =
15691      new NISuppressor(0, RangeInt.PowerOfTwo.class);
15692  private static NISuppressor arg2_power2 =
15693      new NISuppressor(1, RangeInt.PowerOfTwo.class);
15694
15695  private static NISuppressor result_and0_arg1 =
15696      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
15697  private static NISuppressor result_and0_arg2 =
15698      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
15699  private static NISuppressor arg1_and0_arg2 =
15700      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
15701
15702  // The arguments to bitwise subset are backwards from what one
15703  // might expect.  The second argument is a subset of the first
15704  // argument
15705  private static NISuppressor arg1_bw_subset_arg2 =
15706      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
15707  private static NISuppressor arg2_bw_subset_arg1 =
15708      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
15709
15710  private static NISuppressor result_shift0_arg1 =
15711      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
15712  private static NISuppressor result_shift0_arg2 =
15713      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
15714  private static NISuppressor arg1_shift0_arg2 =
15715      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
15716
15717  private static NISuppressor arg2_divides_arg1 =
15718      new NISuppressor(0, 1, NumericInt.Divides.class);
15719  private static NISuppressor arg1_divides_arg2 =
15720      new NISuppressor(1, 0, NumericInt.Divides.class);
15721
15722  private static NISuppressor arg2_valid_shift =
15723      new NISuppressor(1, RangeInt.Bound0_63.class);
15724
15725    private static NISuppressionSet suppressions =
15726        new NISuppressionSet(
15727          new NISuppression[] {
15728
15729            // (r == x) && (y == 0) ==> r = x >>> y
15730            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
15731
15732            // (r == 0) && (x == 0) && (0 <= y <= 63)   ==> r = x >>> y
15733            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
15734
15735            // (r == 0) && ((x >> y) == 0)
15736            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
15737
15738            // (r == 0) && (y >= x) && (x >= 0) && (y valid shift)
15739            // This suppression really ought to have 2**y >= x, but we
15740            // don't have that invariant.  This still might catch a lot of these.
15741            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
15742            //                   arg2_valid_shift, suppressee),
15743          });
15744
15745  // Create a suppression factory for functionBinary
15746
15747}
15748
15749/**
15750 * Represents the invariant {@code x = RshiftSigned(z, y)} over three long
15751 * scalars. 
15752 */
15753public static class RshiftSignedLong_xzy extends FunctionBinary {
15754  // We are Serializable, so we specify a version to allow changes to
15755  // method signatures without breaking serialization.  If you add or
15756  // remove fields, you should change this number to the current date.
15757  static final long serialVersionUID = 20031030L;
15758
15759    // y must be between arg2_bound[0] and arg2_bound[1] inclusive
15760    static int[] arg2_bound = {0, 63};
15761
15762  private static @Prototype RshiftSignedLong_xzy proto = new @Prototype RshiftSignedLong_xzy ();
15763
15764  /** Returns the prototype invariant for RshiftSignedLong_xzy */
15765  public static @Prototype RshiftSignedLong_xzy get_proto() {
15766    return proto;
15767  }
15768
15769  /** instantiate an invariant on the specified slice */
15770  @Override
15771  protected RshiftSignedLong_xzy instantiate_dyn(@Prototype RshiftSignedLong_xzy this, PptSlice slice) {
15772    return new RshiftSignedLong_xzy (slice);
15773  }
15774
15775  private RshiftSignedLong_xzy (PptSlice slice) {
15776    super(slice);
15777  }
15778
15779  public @Prototype RshiftSignedLong_xzy () {
15780    super();
15781  }
15782
15783  private static String[] method_name = new String[] {"", " >> ", ""};
15784
15785  @Override
15786  public String[] get_method_name(@GuardSatisfied RshiftSignedLong_xzy this) {
15787    return method_name;
15788  }
15789
15790  private static int function_id = -1;
15791
15792  @Override
15793  public int get_function_id() {
15794    return function_id;
15795  }
15796
15797  @Override
15798  public void set_function_id(int function_id) {
15799    assert RshiftSignedLong_xzy.function_id == -1;
15800    RshiftSignedLong_xzy.function_id = function_id;
15801  }
15802
15803  private static int var_order = 4;
15804
15805  @Override
15806  public int get_var_order(@GuardSatisfied RshiftSignedLong_xzy this) {
15807    return var_order;
15808  }
15809
15810  @Pure
15811  @Override
15812  public boolean is_symmetric() {
15813
15814      return false;
15815  }
15816
15817  @Override
15818
15819  public long func(long z, long y) {
15820
15821      if ((y < arg2_bound[0]) || (y > arg2_bound[1])) {
15822        throw new ArithmeticException("arg2 (" + y + ") out of range "
15823                                       + arg2_bound[0] + ".." + arg2_bound[1]);
15824      }
15825
15826    return (z >> y);
15827  }
15828
15829  @Override
15830  public InvariantStatus check_modified(long x, long y,
15831                                      long z, int count) {
15832    return check_ordered(x, z, y, count);
15833  }
15834
15835  @Override
15836  public InvariantStatus add_modified(long x, long y,
15837                                      long z, int count) {
15838    if (Debug.logDetail()) {
15839      log("result=%s, arg1=%s, arg2=%s", x, z, y);
15840    }
15841    return add_ordered(x, z, y, count);
15842  }
15843
15844  @Pure
15845  @Override
15846  public boolean isRshiftSigned() {
15847    return true;
15848  }
15849
15850  /** Returns a list of non-instantiating suppressions for this invariant. */
15851  @Pure
15852  @Override
15853  public @Nullable NISuppressionSet get_ni_suppressions() {
15854    if (NIS.dkconfig_enabled && dkconfig_enabled) {
15855      return suppressions;
15856    } else {
15857      return null;
15858    }
15859  }
15860
15861  /** definition of this invariant (the suppressee) */
15862  private static NISuppressee suppressee = new NISuppressee(RshiftSignedLong_xzy.class, 3);
15863
15864  // suppressor definitions (used below)
15865  private static NISuppressor result_eq_arg1 =
15866      new NISuppressor(0, 2, IntEqual.class);
15867  private static NISuppressor result_eq_arg2 =
15868      new NISuppressor(0, 1, IntEqual.class);
15869  private static NISuppressor arg1_eq_arg2 =
15870      new NISuppressor(2, 1, IntEqual.class);
15871
15872  private static NISuppressor result_lt_arg1 =
15873      new NISuppressor(0, 2, IntLessThan.class);
15874  private static NISuppressor result_lt_arg2 =
15875      new NISuppressor(0, 1, IntLessThan.class);
15876  private static NISuppressor arg1_lt_arg2 =
15877      new NISuppressor(2, 1, IntLessThan.class);
15878  private static NISuppressor arg2_lt_arg1 =
15879      new NISuppressor(1, 2, IntLessThan.class);
15880
15881  private static NISuppressor result_le_arg1 =
15882      new NISuppressor(0, 2, IntLessEqual.class);
15883  private static NISuppressor result_le_arg2 =
15884      new NISuppressor(0, 1, IntLessEqual.class);
15885  private static NISuppressor arg1_le_arg2 =
15886      new NISuppressor(2, 1, IntLessEqual.class);
15887  private static NISuppressor arg2_le_arg1 =
15888      new NISuppressor(1, 2, IntLessEqual.class);
15889
15890  private static NISuppressor result_track0_arg1 =
15891      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
15892  private static NISuppressor result_track0_arg2 =
15893      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
15894  private static NISuppressor arg1_track0_arg2 =
15895      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
15896  private static NISuppressor arg1_track0_result =
15897      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
15898  private static NISuppressor arg2_track0_result =
15899      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
15900  private static NISuppressor arg2_track0_arg1 =
15901      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
15902
15903  private static NISuppressor result_eq_1 =
15904      new NISuppressor(0, RangeInt.EqualOne.class);
15905  private static NISuppressor arg1_eq_1 =
15906      new NISuppressor(2, RangeInt.EqualOne.class);
15907  private static NISuppressor arg2_eq_1 =
15908      new NISuppressor(1, RangeInt.EqualOne.class);
15909
15910  private static NISuppressor result_eq_0 =
15911      new NISuppressor(0, RangeInt.EqualZero.class);
15912  private static NISuppressor arg1_eq_0 =
15913      new NISuppressor(2, RangeInt.EqualZero.class);
15914  private static NISuppressor arg2_eq_0 =
15915      new NISuppressor(1, RangeInt.EqualZero.class);
15916
15917  private static NISuppressor result_ne_0 =
15918      new NISuppressor(0, NonZero.class);
15919  private static NISuppressor arg1_ne_0 =
15920      new NISuppressor(2, NonZero.class);
15921  private static NISuppressor arg2_ne_0 =
15922      new NISuppressor(1, NonZero.class);
15923
15924  private static NISuppressor result_ge_0 =
15925      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
15926  private static NISuppressor arg1_ge_0 =
15927      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
15928  private static NISuppressor arg2_ge_0 =
15929      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
15930
15931  private static NISuppressor result_ge_64 =
15932      new NISuppressor(0, RangeInt.GreaterEqual64.class);
15933  private static NISuppressor arg1_ge_64 =
15934      new NISuppressor(2, RangeInt.GreaterEqual64.class);
15935  private static NISuppressor arg2_ge_64 =
15936      new NISuppressor(1, RangeInt.GreaterEqual64.class);
15937
15938  private static NISuppressor result_boolean =
15939      new NISuppressor(0, RangeInt.BooleanVal.class);
15940  private static NISuppressor arg1_boolean =
15941      new NISuppressor(2, RangeInt.BooleanVal.class);
15942  private static NISuppressor arg2_boolean =
15943      new NISuppressor(1, RangeInt.BooleanVal.class);
15944
15945  private static NISuppressor result_even =
15946      new NISuppressor(0, RangeInt.Even.class);
15947  private static NISuppressor arg1_even =
15948      new NISuppressor(2, RangeInt.Even.class);
15949  private static NISuppressor arg2_even =
15950      new NISuppressor(1, RangeInt.Even.class);
15951
15952  private static NISuppressor result_power2 =
15953      new NISuppressor(0, RangeInt.PowerOfTwo.class);
15954  private static NISuppressor arg1_power2 =
15955      new NISuppressor(2, RangeInt.PowerOfTwo.class);
15956  private static NISuppressor arg2_power2 =
15957      new NISuppressor(1, RangeInt.PowerOfTwo.class);
15958
15959  private static NISuppressor result_and0_arg1 =
15960      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
15961  private static NISuppressor result_and0_arg2 =
15962      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
15963  private static NISuppressor arg1_and0_arg2 =
15964      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
15965
15966  // The arguments to bitwise subset are backwards from what one
15967  // might expect.  The second argument is a subset of the first
15968  // argument
15969  private static NISuppressor arg1_bw_subset_arg2 =
15970      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
15971  private static NISuppressor arg2_bw_subset_arg1 =
15972      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
15973
15974  private static NISuppressor result_shift0_arg1 =
15975      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
15976  private static NISuppressor result_shift0_arg2 =
15977      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
15978  private static NISuppressor arg1_shift0_arg2 =
15979      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
15980
15981  private static NISuppressor arg2_divides_arg1 =
15982      new NISuppressor(2, 1, NumericInt.Divides.class);
15983  private static NISuppressor arg1_divides_arg2 =
15984      new NISuppressor(1, 2, NumericInt.Divides.class);
15985
15986  private static NISuppressor arg2_valid_shift =
15987      new NISuppressor(1, RangeInt.Bound0_63.class);
15988
15989    private static NISuppressionSet suppressions =
15990        new NISuppressionSet(
15991          new NISuppression[] {
15992
15993            // (r == z) && (y == 0) ==> r = z >>> y
15994            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
15995
15996            // (r == 0) && (z == 0) && (0 <= y <= 63)   ==> r = z >>> y
15997            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
15998
15999            // (r == 0) && ((z >> y) == 0)
16000            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
16001
16002            // (r == 0) && (y >= z) && (z >= 0) && (y valid shift)
16003            // This suppression really ought to have 2**y >= z, but we
16004            // don't have that invariant.  This still might catch a lot of these.
16005            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
16006            //                   arg2_valid_shift, suppressee),
16007          });
16008
16009  // Create a suppression factory for functionBinary
16010
16011}
16012
16013/**
16014 * Represents the invariant {@code y = RshiftSigned(z, x)} over three long
16015 * scalars. 
16016 */
16017public static class RshiftSignedLong_yzx extends FunctionBinary {
16018  // We are Serializable, so we specify a version to allow changes to
16019  // method signatures without breaking serialization.  If you add or
16020  // remove fields, you should change this number to the current date.
16021  static final long serialVersionUID = 20031030L;
16022
16023    // x must be between arg2_bound[0] and arg2_bound[1] inclusive
16024    static int[] arg2_bound = {0, 63};
16025
16026  private static @Prototype RshiftSignedLong_yzx proto = new @Prototype RshiftSignedLong_yzx ();
16027
16028  /** Returns the prototype invariant for RshiftSignedLong_yzx */
16029  public static @Prototype RshiftSignedLong_yzx get_proto() {
16030    return proto;
16031  }
16032
16033  /** instantiate an invariant on the specified slice */
16034  @Override
16035  protected RshiftSignedLong_yzx instantiate_dyn(@Prototype RshiftSignedLong_yzx this, PptSlice slice) {
16036    return new RshiftSignedLong_yzx (slice);
16037  }
16038
16039  private RshiftSignedLong_yzx (PptSlice slice) {
16040    super(slice);
16041  }
16042
16043  public @Prototype RshiftSignedLong_yzx () {
16044    super();
16045  }
16046
16047  private static String[] method_name = new String[] {"", " >> ", ""};
16048
16049  @Override
16050  public String[] get_method_name(@GuardSatisfied RshiftSignedLong_yzx this) {
16051    return method_name;
16052  }
16053
16054  private static int function_id = -1;
16055
16056  @Override
16057  public int get_function_id() {
16058    return function_id;
16059  }
16060
16061  @Override
16062  public void set_function_id(int function_id) {
16063    assert RshiftSignedLong_yzx.function_id == -1;
16064    RshiftSignedLong_yzx.function_id = function_id;
16065  }
16066
16067  private static int var_order = 5;
16068
16069  @Override
16070  public int get_var_order(@GuardSatisfied RshiftSignedLong_yzx this) {
16071    return var_order;
16072  }
16073
16074  @Pure
16075  @Override
16076  public boolean is_symmetric() {
16077
16078      return false;
16079  }
16080
16081  @Override
16082
16083  public long func(long z, long x) {
16084
16085      if ((x < arg2_bound[0]) || (x > arg2_bound[1])) {
16086        throw new ArithmeticException("arg2 (" + x + ") out of range "
16087                                       + arg2_bound[0] + ".." + arg2_bound[1]);
16088      }
16089
16090    return (z >> x);
16091  }
16092
16093  @Override
16094  public InvariantStatus check_modified(long x, long y,
16095                                      long z, int count) {
16096    return check_ordered(y, z, x, count);
16097  }
16098
16099  @Override
16100  public InvariantStatus add_modified(long x, long y,
16101                                      long z, int count) {
16102    if (Debug.logDetail()) {
16103      log("result=%s, arg1=%s, arg2=%s", y, z, x);
16104    }
16105    return add_ordered(y, z, x, count);
16106  }
16107
16108  @Pure
16109  @Override
16110  public boolean isRshiftSigned() {
16111    return true;
16112  }
16113
16114  /** Returns a list of non-instantiating suppressions for this invariant. */
16115  @Pure
16116  @Override
16117  public @Nullable NISuppressionSet get_ni_suppressions() {
16118    if (NIS.dkconfig_enabled && dkconfig_enabled) {
16119      return suppressions;
16120    } else {
16121      return null;
16122    }
16123  }
16124
16125  /** definition of this invariant (the suppressee) */
16126  private static NISuppressee suppressee = new NISuppressee(RshiftSignedLong_yzx.class, 3);
16127
16128  // suppressor definitions (used below)
16129  private static NISuppressor result_eq_arg1 =
16130      new NISuppressor(1, 2, IntEqual.class);
16131  private static NISuppressor result_eq_arg2 =
16132      new NISuppressor(1, 0, IntEqual.class);
16133  private static NISuppressor arg1_eq_arg2 =
16134      new NISuppressor(2, 0, IntEqual.class);
16135
16136  private static NISuppressor result_lt_arg1 =
16137      new NISuppressor(1, 2, IntLessThan.class);
16138  private static NISuppressor result_lt_arg2 =
16139      new NISuppressor(1, 0, IntLessThan.class);
16140  private static NISuppressor arg1_lt_arg2 =
16141      new NISuppressor(2, 0, IntLessThan.class);
16142  private static NISuppressor arg2_lt_arg1 =
16143      new NISuppressor(0, 2, IntLessThan.class);
16144
16145  private static NISuppressor result_le_arg1 =
16146      new NISuppressor(1, 2, IntLessEqual.class);
16147  private static NISuppressor result_le_arg2 =
16148      new NISuppressor(1, 0, IntLessEqual.class);
16149  private static NISuppressor arg1_le_arg2 =
16150      new NISuppressor(2, 0, IntLessEqual.class);
16151  private static NISuppressor arg2_le_arg1 =
16152      new NISuppressor(0, 2, IntLessEqual.class);
16153
16154  private static NISuppressor result_track0_arg1 =
16155      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
16156  private static NISuppressor result_track0_arg2 =
16157      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
16158  private static NISuppressor arg1_track0_arg2 =
16159      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
16160  private static NISuppressor arg1_track0_result =
16161      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
16162  private static NISuppressor arg2_track0_result =
16163      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
16164  private static NISuppressor arg2_track0_arg1 =
16165      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
16166
16167  private static NISuppressor result_eq_1 =
16168      new NISuppressor(1, RangeInt.EqualOne.class);
16169  private static NISuppressor arg1_eq_1 =
16170      new NISuppressor(2, RangeInt.EqualOne.class);
16171  private static NISuppressor arg2_eq_1 =
16172      new NISuppressor(0, RangeInt.EqualOne.class);
16173
16174  private static NISuppressor result_eq_0 =
16175      new NISuppressor(1, RangeInt.EqualZero.class);
16176  private static NISuppressor arg1_eq_0 =
16177      new NISuppressor(2, RangeInt.EqualZero.class);
16178  private static NISuppressor arg2_eq_0 =
16179      new NISuppressor(0, RangeInt.EqualZero.class);
16180
16181  private static NISuppressor result_ne_0 =
16182      new NISuppressor(1, NonZero.class);
16183  private static NISuppressor arg1_ne_0 =
16184      new NISuppressor(2, NonZero.class);
16185  private static NISuppressor arg2_ne_0 =
16186      new NISuppressor(0, NonZero.class);
16187
16188  private static NISuppressor result_ge_0 =
16189      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
16190  private static NISuppressor arg1_ge_0 =
16191      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
16192  private static NISuppressor arg2_ge_0 =
16193      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
16194
16195  private static NISuppressor result_ge_64 =
16196      new NISuppressor(1, RangeInt.GreaterEqual64.class);
16197  private static NISuppressor arg1_ge_64 =
16198      new NISuppressor(2, RangeInt.GreaterEqual64.class);
16199  private static NISuppressor arg2_ge_64 =
16200      new NISuppressor(0, RangeInt.GreaterEqual64.class);
16201
16202  private static NISuppressor result_boolean =
16203      new NISuppressor(1, RangeInt.BooleanVal.class);
16204  private static NISuppressor arg1_boolean =
16205      new NISuppressor(2, RangeInt.BooleanVal.class);
16206  private static NISuppressor arg2_boolean =
16207      new NISuppressor(0, RangeInt.BooleanVal.class);
16208
16209  private static NISuppressor result_even =
16210      new NISuppressor(1, RangeInt.Even.class);
16211  private static NISuppressor arg1_even =
16212      new NISuppressor(2, RangeInt.Even.class);
16213  private static NISuppressor arg2_even =
16214      new NISuppressor(0, RangeInt.Even.class);
16215
16216  private static NISuppressor result_power2 =
16217      new NISuppressor(1, RangeInt.PowerOfTwo.class);
16218  private static NISuppressor arg1_power2 =
16219      new NISuppressor(2, RangeInt.PowerOfTwo.class);
16220  private static NISuppressor arg2_power2 =
16221      new NISuppressor(0, RangeInt.PowerOfTwo.class);
16222
16223  private static NISuppressor result_and0_arg1 =
16224      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
16225  private static NISuppressor result_and0_arg2 =
16226      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
16227  private static NISuppressor arg1_and0_arg2 =
16228      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
16229
16230  // The arguments to bitwise subset are backwards from what one
16231  // might expect.  The second argument is a subset of the first
16232  // argument
16233  private static NISuppressor arg1_bw_subset_arg2 =
16234      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
16235  private static NISuppressor arg2_bw_subset_arg1 =
16236      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
16237
16238  private static NISuppressor result_shift0_arg1 =
16239      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
16240  private static NISuppressor result_shift0_arg2 =
16241      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
16242  private static NISuppressor arg1_shift0_arg2 =
16243      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
16244
16245  private static NISuppressor arg2_divides_arg1 =
16246      new NISuppressor(2, 0, NumericInt.Divides.class);
16247  private static NISuppressor arg1_divides_arg2 =
16248      new NISuppressor(0, 2, NumericInt.Divides.class);
16249
16250  private static NISuppressor arg2_valid_shift =
16251      new NISuppressor(0, RangeInt.Bound0_63.class);
16252
16253    private static NISuppressionSet suppressions =
16254        new NISuppressionSet(
16255          new NISuppression[] {
16256
16257            // (r == z) && (x == 0) ==> r = z >>> x
16258            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
16259
16260            // (r == 0) && (z == 0) && (0 <= x <= 63)   ==> r = z >>> x
16261            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
16262
16263            // (r == 0) && ((z >> x) == 0)
16264            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
16265
16266            // (r == 0) && (x >= z) && (z >= 0) && (x valid shift)
16267            // This suppression really ought to have 2**x >= z, but we
16268            // don't have that invariant.  This still might catch a lot of these.
16269            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
16270            //                   arg2_valid_shift, suppressee),
16271          });
16272
16273  // Create a suppression factory for functionBinary
16274
16275}
16276
16277/**
16278 * Represents the invariant {@code z = RshiftSigned(y, x)} over three long
16279 * scalars. 
16280 */
16281public static class RshiftSignedLong_zyx extends FunctionBinary {
16282  // We are Serializable, so we specify a version to allow changes to
16283  // method signatures without breaking serialization.  If you add or
16284  // remove fields, you should change this number to the current date.
16285  static final long serialVersionUID = 20031030L;
16286
16287    // x must be between arg2_bound[0] and arg2_bound[1] inclusive
16288    static int[] arg2_bound = {0, 63};
16289
16290  private static @Prototype RshiftSignedLong_zyx proto = new @Prototype RshiftSignedLong_zyx ();
16291
16292  /** Returns the prototype invariant for RshiftSignedLong_zyx */
16293  public static @Prototype RshiftSignedLong_zyx get_proto() {
16294    return proto;
16295  }
16296
16297  /** instantiate an invariant on the specified slice */
16298  @Override
16299  protected RshiftSignedLong_zyx instantiate_dyn(@Prototype RshiftSignedLong_zyx this, PptSlice slice) {
16300    return new RshiftSignedLong_zyx (slice);
16301  }
16302
16303  private RshiftSignedLong_zyx (PptSlice slice) {
16304    super(slice);
16305  }
16306
16307  public @Prototype RshiftSignedLong_zyx () {
16308    super();
16309  }
16310
16311  private static String[] method_name = new String[] {"", " >> ", ""};
16312
16313  @Override
16314  public String[] get_method_name(@GuardSatisfied RshiftSignedLong_zyx this) {
16315    return method_name;
16316  }
16317
16318  private static int function_id = -1;
16319
16320  @Override
16321  public int get_function_id() {
16322    return function_id;
16323  }
16324
16325  @Override
16326  public void set_function_id(int function_id) {
16327    assert RshiftSignedLong_zyx.function_id == -1;
16328    RshiftSignedLong_zyx.function_id = function_id;
16329  }
16330
16331  private static int var_order = 6;
16332
16333  @Override
16334  public int get_var_order(@GuardSatisfied RshiftSignedLong_zyx this) {
16335    return var_order;
16336  }
16337
16338  @Pure
16339  @Override
16340  public boolean is_symmetric() {
16341
16342      return false;
16343  }
16344
16345  @Override
16346
16347  public long func(long y, long x) {
16348
16349      if ((x < arg2_bound[0]) || (x > arg2_bound[1])) {
16350        throw new ArithmeticException("arg2 (" + x + ") out of range "
16351                                       + arg2_bound[0] + ".." + arg2_bound[1]);
16352      }
16353
16354    return (y >> x);
16355  }
16356
16357  @Override
16358  public InvariantStatus check_modified(long x, long y,
16359                                      long z, int count) {
16360    return check_ordered(z, y, x, count);
16361  }
16362
16363  @Override
16364  public InvariantStatus add_modified(long x, long y,
16365                                      long z, int count) {
16366    if (Debug.logDetail()) {
16367      log("result=%s, arg1=%s, arg2=%s", z, y, x);
16368    }
16369    return add_ordered(z, y, x, count);
16370  }
16371
16372  @Pure
16373  @Override
16374  public boolean isRshiftSigned() {
16375    return true;
16376  }
16377
16378  /** Returns a list of non-instantiating suppressions for this invariant. */
16379  @Pure
16380  @Override
16381  public @Nullable NISuppressionSet get_ni_suppressions() {
16382    if (NIS.dkconfig_enabled && dkconfig_enabled) {
16383      return suppressions;
16384    } else {
16385      return null;
16386    }
16387  }
16388
16389  /** definition of this invariant (the suppressee) */
16390  private static NISuppressee suppressee = new NISuppressee(RshiftSignedLong_zyx.class, 3);
16391
16392  // suppressor definitions (used below)
16393  private static NISuppressor result_eq_arg1 =
16394      new NISuppressor(2, 1, IntEqual.class);
16395  private static NISuppressor result_eq_arg2 =
16396      new NISuppressor(2, 0, IntEqual.class);
16397  private static NISuppressor arg1_eq_arg2 =
16398      new NISuppressor(1, 0, IntEqual.class);
16399
16400  private static NISuppressor result_lt_arg1 =
16401      new NISuppressor(2, 1, IntLessThan.class);
16402  private static NISuppressor result_lt_arg2 =
16403      new NISuppressor(2, 0, IntLessThan.class);
16404  private static NISuppressor arg1_lt_arg2 =
16405      new NISuppressor(1, 0, IntLessThan.class);
16406  private static NISuppressor arg2_lt_arg1 =
16407      new NISuppressor(0, 1, IntLessThan.class);
16408
16409  private static NISuppressor result_le_arg1 =
16410      new NISuppressor(2, 1, IntLessEqual.class);
16411  private static NISuppressor result_le_arg2 =
16412      new NISuppressor(2, 0, IntLessEqual.class);
16413  private static NISuppressor arg1_le_arg2 =
16414      new NISuppressor(1, 0, IntLessEqual.class);
16415  private static NISuppressor arg2_le_arg1 =
16416      new NISuppressor(0, 1, IntLessEqual.class);
16417
16418  private static NISuppressor result_track0_arg1 =
16419      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
16420  private static NISuppressor result_track0_arg2 =
16421      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
16422  private static NISuppressor arg1_track0_arg2 =
16423      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
16424  private static NISuppressor arg1_track0_result =
16425      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
16426  private static NISuppressor arg2_track0_result =
16427      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
16428  private static NISuppressor arg2_track0_arg1 =
16429      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
16430
16431  private static NISuppressor result_eq_1 =
16432      new NISuppressor(2, RangeInt.EqualOne.class);
16433  private static NISuppressor arg1_eq_1 =
16434      new NISuppressor(1, RangeInt.EqualOne.class);
16435  private static NISuppressor arg2_eq_1 =
16436      new NISuppressor(0, RangeInt.EqualOne.class);
16437
16438  private static NISuppressor result_eq_0 =
16439      new NISuppressor(2, RangeInt.EqualZero.class);
16440  private static NISuppressor arg1_eq_0 =
16441      new NISuppressor(1, RangeInt.EqualZero.class);
16442  private static NISuppressor arg2_eq_0 =
16443      new NISuppressor(0, RangeInt.EqualZero.class);
16444
16445  private static NISuppressor result_ne_0 =
16446      new NISuppressor(2, NonZero.class);
16447  private static NISuppressor arg1_ne_0 =
16448      new NISuppressor(1, NonZero.class);
16449  private static NISuppressor arg2_ne_0 =
16450      new NISuppressor(0, NonZero.class);
16451
16452  private static NISuppressor result_ge_0 =
16453      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
16454  private static NISuppressor arg1_ge_0 =
16455      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
16456  private static NISuppressor arg2_ge_0 =
16457      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
16458
16459  private static NISuppressor result_ge_64 =
16460      new NISuppressor(2, RangeInt.GreaterEqual64.class);
16461  private static NISuppressor arg1_ge_64 =
16462      new NISuppressor(1, RangeInt.GreaterEqual64.class);
16463  private static NISuppressor arg2_ge_64 =
16464      new NISuppressor(0, RangeInt.GreaterEqual64.class);
16465
16466  private static NISuppressor result_boolean =
16467      new NISuppressor(2, RangeInt.BooleanVal.class);
16468  private static NISuppressor arg1_boolean =
16469      new NISuppressor(1, RangeInt.BooleanVal.class);
16470  private static NISuppressor arg2_boolean =
16471      new NISuppressor(0, RangeInt.BooleanVal.class);
16472
16473  private static NISuppressor result_even =
16474      new NISuppressor(2, RangeInt.Even.class);
16475  private static NISuppressor arg1_even =
16476      new NISuppressor(1, RangeInt.Even.class);
16477  private static NISuppressor arg2_even =
16478      new NISuppressor(0, RangeInt.Even.class);
16479
16480  private static NISuppressor result_power2 =
16481      new NISuppressor(2, RangeInt.PowerOfTwo.class);
16482  private static NISuppressor arg1_power2 =
16483      new NISuppressor(1, RangeInt.PowerOfTwo.class);
16484  private static NISuppressor arg2_power2 =
16485      new NISuppressor(0, RangeInt.PowerOfTwo.class);
16486
16487  private static NISuppressor result_and0_arg1 =
16488      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
16489  private static NISuppressor result_and0_arg2 =
16490      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
16491  private static NISuppressor arg1_and0_arg2 =
16492      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
16493
16494  // The arguments to bitwise subset are backwards from what one
16495  // might expect.  The second argument is a subset of the first
16496  // argument
16497  private static NISuppressor arg1_bw_subset_arg2 =
16498      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
16499  private static NISuppressor arg2_bw_subset_arg1 =
16500      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
16501
16502  private static NISuppressor result_shift0_arg1 =
16503      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
16504  private static NISuppressor result_shift0_arg2 =
16505      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
16506  private static NISuppressor arg1_shift0_arg2 =
16507      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
16508
16509  private static NISuppressor arg2_divides_arg1 =
16510      new NISuppressor(1, 0, NumericInt.Divides.class);
16511  private static NISuppressor arg1_divides_arg2 =
16512      new NISuppressor(0, 1, NumericInt.Divides.class);
16513
16514  private static NISuppressor arg2_valid_shift =
16515      new NISuppressor(0, RangeInt.Bound0_63.class);
16516
16517    private static NISuppressionSet suppressions =
16518        new NISuppressionSet(
16519          new NISuppression[] {
16520
16521            // (r == y) && (x == 0) ==> r = y >>> x
16522            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
16523
16524            // (r == 0) && (y == 0) && (0 <= x <= 63)   ==> r = y >>> x
16525            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
16526
16527            // (r == 0) && ((y >> x) == 0)
16528            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
16529
16530            // (r == 0) && (x >= y) && (y >= 0) && (x valid shift)
16531            // This suppression really ought to have 2**x >= y, but we
16532            // don't have that invariant.  This still might catch a lot of these.
16533            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
16534            //                   arg2_valid_shift, suppressee),
16535          });
16536
16537  // Create a suppression factory for functionBinary
16538
16539}
16540
16541  // default is that it is not this function, overriden in the subclass
16542  @Pure
16543  public boolean isRshiftUnsigned() {
16544    return false;
16545  }
16546
16547/**
16548 * Represents the invariant {@code x = RshiftUnsigned(y, z)} over three long
16549 * scalars. 
16550 */
16551public static class RshiftUnsignedLong_xyz extends FunctionBinary {
16552  // We are Serializable, so we specify a version to allow changes to
16553  // method signatures without breaking serialization.  If you add or
16554  // remove fields, you should change this number to the current date.
16555  static final long serialVersionUID = 20031030L;
16556
16557    // z must be between arg2_bound[0] and arg2_bound[1] inclusive
16558    static int[] arg2_bound = {0, 63};
16559
16560  private static @Prototype RshiftUnsignedLong_xyz proto = new @Prototype RshiftUnsignedLong_xyz ();
16561
16562  /** Returns the prototype invariant for RshiftUnsignedLong_xyz */
16563  public static @Prototype RshiftUnsignedLong_xyz get_proto() {
16564    return proto;
16565  }
16566
16567  /** instantiate an invariant on the specified slice */
16568  @Override
16569  protected RshiftUnsignedLong_xyz instantiate_dyn(@Prototype RshiftUnsignedLong_xyz this, PptSlice slice) {
16570    return new RshiftUnsignedLong_xyz (slice);
16571  }
16572
16573  private RshiftUnsignedLong_xyz (PptSlice slice) {
16574    super(slice);
16575  }
16576
16577  public @Prototype RshiftUnsignedLong_xyz () {
16578    super();
16579  }
16580
16581  private static String[] method_name = new String[] {"", " >>> ", ""};
16582
16583  @Override
16584  public String[] get_method_name(@GuardSatisfied RshiftUnsignedLong_xyz this) {
16585    return method_name;
16586  }
16587
16588  private static int function_id = -1;
16589
16590  @Override
16591  public int get_function_id() {
16592    return function_id;
16593  }
16594
16595  @Override
16596  public void set_function_id(int function_id) {
16597    assert RshiftUnsignedLong_xyz.function_id == -1;
16598    RshiftUnsignedLong_xyz.function_id = function_id;
16599  }
16600
16601  private static int var_order = 1;
16602
16603  @Override
16604  public int get_var_order(@GuardSatisfied RshiftUnsignedLong_xyz this) {
16605    return var_order;
16606  }
16607
16608  @Pure
16609  @Override
16610  public boolean is_symmetric() {
16611
16612      return false;
16613  }
16614
16615  @Override
16616
16617  @SuppressWarnings("signedness:shift.unsigned") // RshiftUnsigned treats y as unsigned, though we do not know how the program under test treats it
16618
16619  public long func(long y, long z) {
16620
16621      if ((z < arg2_bound[0]) || (z > arg2_bound[1])) {
16622        throw new ArithmeticException("arg2 (" + z + ") out of range "
16623                                       + arg2_bound[0] + ".." + arg2_bound[1]);
16624      }
16625
16626    return (y >>> z);
16627  }
16628
16629  @Override
16630  public InvariantStatus check_modified(long x, long y,
16631                                      long z, int count) {
16632    return check_ordered(x, y, z, count);
16633  }
16634
16635  @Override
16636  public InvariantStatus add_modified(long x, long y,
16637                                      long z, int count) {
16638    if (Debug.logDetail()) {
16639      log("result=%s, arg1=%s, arg2=%s", x, y, z);
16640    }
16641    return add_ordered(x, y, z, count);
16642  }
16643
16644  @Pure
16645  @Override
16646  public boolean isRshiftUnsigned() {
16647    return true;
16648  }
16649
16650  /** Returns a list of non-instantiating suppressions for this invariant. */
16651  @Pure
16652  @Override
16653  public @Nullable NISuppressionSet get_ni_suppressions() {
16654    if (NIS.dkconfig_enabled && dkconfig_enabled) {
16655      return suppressions;
16656    } else {
16657      return null;
16658    }
16659  }
16660
16661  /** definition of this invariant (the suppressee) */
16662  private static NISuppressee suppressee = new NISuppressee(RshiftUnsignedLong_xyz.class, 3);
16663
16664  // suppressor definitions (used below)
16665  private static NISuppressor result_eq_arg1 =
16666      new NISuppressor(0, 1, IntEqual.class);
16667  private static NISuppressor result_eq_arg2 =
16668      new NISuppressor(0, 2, IntEqual.class);
16669  private static NISuppressor arg1_eq_arg2 =
16670      new NISuppressor(1, 2, IntEqual.class);
16671
16672  private static NISuppressor result_lt_arg1 =
16673      new NISuppressor(0, 1, IntLessThan.class);
16674  private static NISuppressor result_lt_arg2 =
16675      new NISuppressor(0, 2, IntLessThan.class);
16676  private static NISuppressor arg1_lt_arg2 =
16677      new NISuppressor(1, 2, IntLessThan.class);
16678  private static NISuppressor arg2_lt_arg1 =
16679      new NISuppressor(2, 1, IntLessThan.class);
16680
16681  private static NISuppressor result_le_arg1 =
16682      new NISuppressor(0, 1, IntLessEqual.class);
16683  private static NISuppressor result_le_arg2 =
16684      new NISuppressor(0, 2, IntLessEqual.class);
16685  private static NISuppressor arg1_le_arg2 =
16686      new NISuppressor(1, 2, IntLessEqual.class);
16687  private static NISuppressor arg2_le_arg1 =
16688      new NISuppressor(2, 1, IntLessEqual.class);
16689
16690  private static NISuppressor result_track0_arg1 =
16691      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
16692  private static NISuppressor result_track0_arg2 =
16693      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
16694  private static NISuppressor arg1_track0_arg2 =
16695      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
16696  private static NISuppressor arg1_track0_result =
16697      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
16698  private static NISuppressor arg2_track0_result =
16699      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
16700  private static NISuppressor arg2_track0_arg1 =
16701      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
16702
16703  private static NISuppressor result_eq_1 =
16704      new NISuppressor(0, RangeInt.EqualOne.class);
16705  private static NISuppressor arg1_eq_1 =
16706      new NISuppressor(1, RangeInt.EqualOne.class);
16707  private static NISuppressor arg2_eq_1 =
16708      new NISuppressor(2, RangeInt.EqualOne.class);
16709
16710  private static NISuppressor result_eq_0 =
16711      new NISuppressor(0, RangeInt.EqualZero.class);
16712  private static NISuppressor arg1_eq_0 =
16713      new NISuppressor(1, RangeInt.EqualZero.class);
16714  private static NISuppressor arg2_eq_0 =
16715      new NISuppressor(2, RangeInt.EqualZero.class);
16716
16717  private static NISuppressor result_ne_0 =
16718      new NISuppressor(0, NonZero.class);
16719  private static NISuppressor arg1_ne_0 =
16720      new NISuppressor(1, NonZero.class);
16721  private static NISuppressor arg2_ne_0 =
16722      new NISuppressor(2, NonZero.class);
16723
16724  private static NISuppressor result_ge_0 =
16725      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
16726  private static NISuppressor arg1_ge_0 =
16727      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
16728  private static NISuppressor arg2_ge_0 =
16729      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
16730
16731  private static NISuppressor result_ge_64 =
16732      new NISuppressor(0, RangeInt.GreaterEqual64.class);
16733  private static NISuppressor arg1_ge_64 =
16734      new NISuppressor(1, RangeInt.GreaterEqual64.class);
16735  private static NISuppressor arg2_ge_64 =
16736      new NISuppressor(2, RangeInt.GreaterEqual64.class);
16737
16738  private static NISuppressor result_boolean =
16739      new NISuppressor(0, RangeInt.BooleanVal.class);
16740  private static NISuppressor arg1_boolean =
16741      new NISuppressor(1, RangeInt.BooleanVal.class);
16742  private static NISuppressor arg2_boolean =
16743      new NISuppressor(2, RangeInt.BooleanVal.class);
16744
16745  private static NISuppressor result_even =
16746      new NISuppressor(0, RangeInt.Even.class);
16747  private static NISuppressor arg1_even =
16748      new NISuppressor(1, RangeInt.Even.class);
16749  private static NISuppressor arg2_even =
16750      new NISuppressor(2, RangeInt.Even.class);
16751
16752  private static NISuppressor result_power2 =
16753      new NISuppressor(0, RangeInt.PowerOfTwo.class);
16754  private static NISuppressor arg1_power2 =
16755      new NISuppressor(1, RangeInt.PowerOfTwo.class);
16756  private static NISuppressor arg2_power2 =
16757      new NISuppressor(2, RangeInt.PowerOfTwo.class);
16758
16759  private static NISuppressor result_and0_arg1 =
16760      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
16761  private static NISuppressor result_and0_arg2 =
16762      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
16763  private static NISuppressor arg1_and0_arg2 =
16764      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
16765
16766  // The arguments to bitwise subset are backwards from what one
16767  // might expect.  The second argument is a subset of the first
16768  // argument
16769  private static NISuppressor arg1_bw_subset_arg2 =
16770      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
16771  private static NISuppressor arg2_bw_subset_arg1 =
16772      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
16773
16774  private static NISuppressor result_shift0_arg1 =
16775      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
16776  private static NISuppressor result_shift0_arg2 =
16777      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
16778  private static NISuppressor arg1_shift0_arg2 =
16779      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
16780
16781  private static NISuppressor arg2_divides_arg1 =
16782      new NISuppressor(1, 2, NumericInt.Divides.class);
16783  private static NISuppressor arg1_divides_arg2 =
16784      new NISuppressor(2, 1, NumericInt.Divides.class);
16785
16786  private static NISuppressor arg2_valid_shift =
16787      new NISuppressor(2, RangeInt.Bound0_63.class);
16788
16789    private static NISuppressionSet suppressions =
16790        new NISuppressionSet(
16791          new NISuppression[] {
16792
16793            // (r == y) && (z == 0) ==> r = y >>> z
16794            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
16795
16796            // (r == 0) && (y == 0) && (z valid shift) ==> r = y >>> z
16797            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
16798
16799            // (r == 0) && ((y >> z) == 0)
16800            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
16801
16802            // (r == 0) && (z >= y) && (y >= 0) && (z valid shift)
16803            // This suppression really ought to have 2**z >= y, but we
16804            // don't have that suppression.  This still might catch a lot of these.
16805            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
16806            //                   arg2_valid_shift, suppressee),
16807          });
16808
16809  // Create a suppression factory for functionBinary
16810
16811}
16812
16813/**
16814 * Represents the invariant {@code y = RshiftUnsigned(x, z)} over three long
16815 * scalars. 
16816 */
16817public static class RshiftUnsignedLong_yxz extends FunctionBinary {
16818  // We are Serializable, so we specify a version to allow changes to
16819  // method signatures without breaking serialization.  If you add or
16820  // remove fields, you should change this number to the current date.
16821  static final long serialVersionUID = 20031030L;
16822
16823    // z must be between arg2_bound[0] and arg2_bound[1] inclusive
16824    static int[] arg2_bound = {0, 63};
16825
16826  private static @Prototype RshiftUnsignedLong_yxz proto = new @Prototype RshiftUnsignedLong_yxz ();
16827
16828  /** Returns the prototype invariant for RshiftUnsignedLong_yxz */
16829  public static @Prototype RshiftUnsignedLong_yxz get_proto() {
16830    return proto;
16831  }
16832
16833  /** instantiate an invariant on the specified slice */
16834  @Override
16835  protected RshiftUnsignedLong_yxz instantiate_dyn(@Prototype RshiftUnsignedLong_yxz this, PptSlice slice) {
16836    return new RshiftUnsignedLong_yxz (slice);
16837  }
16838
16839  private RshiftUnsignedLong_yxz (PptSlice slice) {
16840    super(slice);
16841  }
16842
16843  public @Prototype RshiftUnsignedLong_yxz () {
16844    super();
16845  }
16846
16847  private static String[] method_name = new String[] {"", " >>> ", ""};
16848
16849  @Override
16850  public String[] get_method_name(@GuardSatisfied RshiftUnsignedLong_yxz this) {
16851    return method_name;
16852  }
16853
16854  private static int function_id = -1;
16855
16856  @Override
16857  public int get_function_id() {
16858    return function_id;
16859  }
16860
16861  @Override
16862  public void set_function_id(int function_id) {
16863    assert RshiftUnsignedLong_yxz.function_id == -1;
16864    RshiftUnsignedLong_yxz.function_id = function_id;
16865  }
16866
16867  private static int var_order = 2;
16868
16869  @Override
16870  public int get_var_order(@GuardSatisfied RshiftUnsignedLong_yxz this) {
16871    return var_order;
16872  }
16873
16874  @Pure
16875  @Override
16876  public boolean is_symmetric() {
16877
16878      return false;
16879  }
16880
16881  @Override
16882
16883  @SuppressWarnings("signedness:shift.unsigned") // RshiftUnsigned treats x as unsigned, though we do not know how the program under test treats it
16884
16885  public long func(long x, long z) {
16886
16887      if ((z < arg2_bound[0]) || (z > arg2_bound[1])) {
16888        throw new ArithmeticException("arg2 (" + z + ") out of range "
16889                                       + arg2_bound[0] + ".." + arg2_bound[1]);
16890      }
16891
16892    return (x >>> z);
16893  }
16894
16895  @Override
16896  public InvariantStatus check_modified(long x, long y,
16897                                      long z, int count) {
16898    return check_ordered(y, x, z, count);
16899  }
16900
16901  @Override
16902  public InvariantStatus add_modified(long x, long y,
16903                                      long z, int count) {
16904    if (Debug.logDetail()) {
16905      log("result=%s, arg1=%s, arg2=%s", y, x, z);
16906    }
16907    return add_ordered(y, x, z, count);
16908  }
16909
16910  @Pure
16911  @Override
16912  public boolean isRshiftUnsigned() {
16913    return true;
16914  }
16915
16916  /** Returns a list of non-instantiating suppressions for this invariant. */
16917  @Pure
16918  @Override
16919  public @Nullable NISuppressionSet get_ni_suppressions() {
16920    if (NIS.dkconfig_enabled && dkconfig_enabled) {
16921      return suppressions;
16922    } else {
16923      return null;
16924    }
16925  }
16926
16927  /** definition of this invariant (the suppressee) */
16928  private static NISuppressee suppressee = new NISuppressee(RshiftUnsignedLong_yxz.class, 3);
16929
16930  // suppressor definitions (used below)
16931  private static NISuppressor result_eq_arg1 =
16932      new NISuppressor(1, 0, IntEqual.class);
16933  private static NISuppressor result_eq_arg2 =
16934      new NISuppressor(1, 2, IntEqual.class);
16935  private static NISuppressor arg1_eq_arg2 =
16936      new NISuppressor(0, 2, IntEqual.class);
16937
16938  private static NISuppressor result_lt_arg1 =
16939      new NISuppressor(1, 0, IntLessThan.class);
16940  private static NISuppressor result_lt_arg2 =
16941      new NISuppressor(1, 2, IntLessThan.class);
16942  private static NISuppressor arg1_lt_arg2 =
16943      new NISuppressor(0, 2, IntLessThan.class);
16944  private static NISuppressor arg2_lt_arg1 =
16945      new NISuppressor(2, 0, IntLessThan.class);
16946
16947  private static NISuppressor result_le_arg1 =
16948      new NISuppressor(1, 0, IntLessEqual.class);
16949  private static NISuppressor result_le_arg2 =
16950      new NISuppressor(1, 2, IntLessEqual.class);
16951  private static NISuppressor arg1_le_arg2 =
16952      new NISuppressor(0, 2, IntLessEqual.class);
16953  private static NISuppressor arg2_le_arg1 =
16954      new NISuppressor(2, 0, IntLessEqual.class);
16955
16956  private static NISuppressor result_track0_arg1 =
16957      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
16958  private static NISuppressor result_track0_arg2 =
16959      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
16960  private static NISuppressor arg1_track0_arg2 =
16961      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
16962  private static NISuppressor arg1_track0_result =
16963      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
16964  private static NISuppressor arg2_track0_result =
16965      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
16966  private static NISuppressor arg2_track0_arg1 =
16967      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
16968
16969  private static NISuppressor result_eq_1 =
16970      new NISuppressor(1, RangeInt.EqualOne.class);
16971  private static NISuppressor arg1_eq_1 =
16972      new NISuppressor(0, RangeInt.EqualOne.class);
16973  private static NISuppressor arg2_eq_1 =
16974      new NISuppressor(2, RangeInt.EqualOne.class);
16975
16976  private static NISuppressor result_eq_0 =
16977      new NISuppressor(1, RangeInt.EqualZero.class);
16978  private static NISuppressor arg1_eq_0 =
16979      new NISuppressor(0, RangeInt.EqualZero.class);
16980  private static NISuppressor arg2_eq_0 =
16981      new NISuppressor(2, RangeInt.EqualZero.class);
16982
16983  private static NISuppressor result_ne_0 =
16984      new NISuppressor(1, NonZero.class);
16985  private static NISuppressor arg1_ne_0 =
16986      new NISuppressor(0, NonZero.class);
16987  private static NISuppressor arg2_ne_0 =
16988      new NISuppressor(2, NonZero.class);
16989
16990  private static NISuppressor result_ge_0 =
16991      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
16992  private static NISuppressor arg1_ge_0 =
16993      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
16994  private static NISuppressor arg2_ge_0 =
16995      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
16996
16997  private static NISuppressor result_ge_64 =
16998      new NISuppressor(1, RangeInt.GreaterEqual64.class);
16999  private static NISuppressor arg1_ge_64 =
17000      new NISuppressor(0, RangeInt.GreaterEqual64.class);
17001  private static NISuppressor arg2_ge_64 =
17002      new NISuppressor(2, RangeInt.GreaterEqual64.class);
17003
17004  private static NISuppressor result_boolean =
17005      new NISuppressor(1, RangeInt.BooleanVal.class);
17006  private static NISuppressor arg1_boolean =
17007      new NISuppressor(0, RangeInt.BooleanVal.class);
17008  private static NISuppressor arg2_boolean =
17009      new NISuppressor(2, RangeInt.BooleanVal.class);
17010
17011  private static NISuppressor result_even =
17012      new NISuppressor(1, RangeInt.Even.class);
17013  private static NISuppressor arg1_even =
17014      new NISuppressor(0, RangeInt.Even.class);
17015  private static NISuppressor arg2_even =
17016      new NISuppressor(2, RangeInt.Even.class);
17017
17018  private static NISuppressor result_power2 =
17019      new NISuppressor(1, RangeInt.PowerOfTwo.class);
17020  private static NISuppressor arg1_power2 =
17021      new NISuppressor(0, RangeInt.PowerOfTwo.class);
17022  private static NISuppressor arg2_power2 =
17023      new NISuppressor(2, RangeInt.PowerOfTwo.class);
17024
17025  private static NISuppressor result_and0_arg1 =
17026      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
17027  private static NISuppressor result_and0_arg2 =
17028      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
17029  private static NISuppressor arg1_and0_arg2 =
17030      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
17031
17032  // The arguments to bitwise subset are backwards from what one
17033  // might expect.  The second argument is a subset of the first
17034  // argument
17035  private static NISuppressor arg1_bw_subset_arg2 =
17036      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
17037  private static NISuppressor arg2_bw_subset_arg1 =
17038      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
17039
17040  private static NISuppressor result_shift0_arg1 =
17041      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
17042  private static NISuppressor result_shift0_arg2 =
17043      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
17044  private static NISuppressor arg1_shift0_arg2 =
17045      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
17046
17047  private static NISuppressor arg2_divides_arg1 =
17048      new NISuppressor(0, 2, NumericInt.Divides.class);
17049  private static NISuppressor arg1_divides_arg2 =
17050      new NISuppressor(2, 0, NumericInt.Divides.class);
17051
17052  private static NISuppressor arg2_valid_shift =
17053      new NISuppressor(2, RangeInt.Bound0_63.class);
17054
17055    private static NISuppressionSet suppressions =
17056        new NISuppressionSet(
17057          new NISuppression[] {
17058
17059            // (r == x) && (z == 0) ==> r = x >>> z
17060            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
17061
17062            // (r == 0) && (x == 0) && (z valid shift) ==> r = x >>> z
17063            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
17064
17065            // (r == 0) && ((x >> z) == 0)
17066            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
17067
17068            // (r == 0) && (z >= x) && (x >= 0) && (z valid shift)
17069            // This suppression really ought to have 2**z >= x, but we
17070            // don't have that suppression.  This still might catch a lot of these.
17071            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
17072            //                   arg2_valid_shift, suppressee),
17073          });
17074
17075  // Create a suppression factory for functionBinary
17076
17077}
17078
17079/**
17080 * Represents the invariant {@code z = RshiftUnsigned(x, y)} over three long
17081 * scalars. 
17082 */
17083public static class RshiftUnsignedLong_zxy extends FunctionBinary {
17084  // We are Serializable, so we specify a version to allow changes to
17085  // method signatures without breaking serialization.  If you add or
17086  // remove fields, you should change this number to the current date.
17087  static final long serialVersionUID = 20031030L;
17088
17089    // y must be between arg2_bound[0] and arg2_bound[1] inclusive
17090    static int[] arg2_bound = {0, 63};
17091
17092  private static @Prototype RshiftUnsignedLong_zxy proto = new @Prototype RshiftUnsignedLong_zxy ();
17093
17094  /** Returns the prototype invariant for RshiftUnsignedLong_zxy */
17095  public static @Prototype RshiftUnsignedLong_zxy get_proto() {
17096    return proto;
17097  }
17098
17099  /** instantiate an invariant on the specified slice */
17100  @Override
17101  protected RshiftUnsignedLong_zxy instantiate_dyn(@Prototype RshiftUnsignedLong_zxy this, PptSlice slice) {
17102    return new RshiftUnsignedLong_zxy (slice);
17103  }
17104
17105  private RshiftUnsignedLong_zxy (PptSlice slice) {
17106    super(slice);
17107  }
17108
17109  public @Prototype RshiftUnsignedLong_zxy () {
17110    super();
17111  }
17112
17113  private static String[] method_name = new String[] {"", " >>> ", ""};
17114
17115  @Override
17116  public String[] get_method_name(@GuardSatisfied RshiftUnsignedLong_zxy this) {
17117    return method_name;
17118  }
17119
17120  private static int function_id = -1;
17121
17122  @Override
17123  public int get_function_id() {
17124    return function_id;
17125  }
17126
17127  @Override
17128  public void set_function_id(int function_id) {
17129    assert RshiftUnsignedLong_zxy.function_id == -1;
17130    RshiftUnsignedLong_zxy.function_id = function_id;
17131  }
17132
17133  private static int var_order = 3;
17134
17135  @Override
17136  public int get_var_order(@GuardSatisfied RshiftUnsignedLong_zxy this) {
17137    return var_order;
17138  }
17139
17140  @Pure
17141  @Override
17142  public boolean is_symmetric() {
17143
17144      return false;
17145  }
17146
17147  @Override
17148
17149  @SuppressWarnings("signedness:shift.unsigned") // RshiftUnsigned treats x as unsigned, though we do not know how the program under test treats it
17150
17151  public long func(long x, long y) {
17152
17153      if ((y < arg2_bound[0]) || (y > arg2_bound[1])) {
17154        throw new ArithmeticException("arg2 (" + y + ") out of range "
17155                                       + arg2_bound[0] + ".." + arg2_bound[1]);
17156      }
17157
17158    return (x >>> y);
17159  }
17160
17161  @Override
17162  public InvariantStatus check_modified(long x, long y,
17163                                      long z, int count) {
17164    return check_ordered(z, x, y, count);
17165  }
17166
17167  @Override
17168  public InvariantStatus add_modified(long x, long y,
17169                                      long z, int count) {
17170    if (Debug.logDetail()) {
17171      log("result=%s, arg1=%s, arg2=%s", z, x, y);
17172    }
17173    return add_ordered(z, x, y, count);
17174  }
17175
17176  @Pure
17177  @Override
17178  public boolean isRshiftUnsigned() {
17179    return true;
17180  }
17181
17182  /** Returns a list of non-instantiating suppressions for this invariant. */
17183  @Pure
17184  @Override
17185  public @Nullable NISuppressionSet get_ni_suppressions() {
17186    if (NIS.dkconfig_enabled && dkconfig_enabled) {
17187      return suppressions;
17188    } else {
17189      return null;
17190    }
17191  }
17192
17193  /** definition of this invariant (the suppressee) */
17194  private static NISuppressee suppressee = new NISuppressee(RshiftUnsignedLong_zxy.class, 3);
17195
17196  // suppressor definitions (used below)
17197  private static NISuppressor result_eq_arg1 =
17198      new NISuppressor(2, 0, IntEqual.class);
17199  private static NISuppressor result_eq_arg2 =
17200      new NISuppressor(2, 1, IntEqual.class);
17201  private static NISuppressor arg1_eq_arg2 =
17202      new NISuppressor(0, 1, IntEqual.class);
17203
17204  private static NISuppressor result_lt_arg1 =
17205      new NISuppressor(2, 0, IntLessThan.class);
17206  private static NISuppressor result_lt_arg2 =
17207      new NISuppressor(2, 1, IntLessThan.class);
17208  private static NISuppressor arg1_lt_arg2 =
17209      new NISuppressor(0, 1, IntLessThan.class);
17210  private static NISuppressor arg2_lt_arg1 =
17211      new NISuppressor(1, 0, IntLessThan.class);
17212
17213  private static NISuppressor result_le_arg1 =
17214      new NISuppressor(2, 0, IntLessEqual.class);
17215  private static NISuppressor result_le_arg2 =
17216      new NISuppressor(2, 1, IntLessEqual.class);
17217  private static NISuppressor arg1_le_arg2 =
17218      new NISuppressor(0, 1, IntLessEqual.class);
17219  private static NISuppressor arg2_le_arg1 =
17220      new NISuppressor(1, 0, IntLessEqual.class);
17221
17222  private static NISuppressor result_track0_arg1 =
17223      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
17224  private static NISuppressor result_track0_arg2 =
17225      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
17226  private static NISuppressor arg1_track0_arg2 =
17227      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
17228  private static NISuppressor arg1_track0_result =
17229      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
17230  private static NISuppressor arg2_track0_result =
17231      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
17232  private static NISuppressor arg2_track0_arg1 =
17233      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
17234
17235  private static NISuppressor result_eq_1 =
17236      new NISuppressor(2, RangeInt.EqualOne.class);
17237  private static NISuppressor arg1_eq_1 =
17238      new NISuppressor(0, RangeInt.EqualOne.class);
17239  private static NISuppressor arg2_eq_1 =
17240      new NISuppressor(1, RangeInt.EqualOne.class);
17241
17242  private static NISuppressor result_eq_0 =
17243      new NISuppressor(2, RangeInt.EqualZero.class);
17244  private static NISuppressor arg1_eq_0 =
17245      new NISuppressor(0, RangeInt.EqualZero.class);
17246  private static NISuppressor arg2_eq_0 =
17247      new NISuppressor(1, RangeInt.EqualZero.class);
17248
17249  private static NISuppressor result_ne_0 =
17250      new NISuppressor(2, NonZero.class);
17251  private static NISuppressor arg1_ne_0 =
17252      new NISuppressor(0, NonZero.class);
17253  private static NISuppressor arg2_ne_0 =
17254      new NISuppressor(1, NonZero.class);
17255
17256  private static NISuppressor result_ge_0 =
17257      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
17258  private static NISuppressor arg1_ge_0 =
17259      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
17260  private static NISuppressor arg2_ge_0 =
17261      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
17262
17263  private static NISuppressor result_ge_64 =
17264      new NISuppressor(2, RangeInt.GreaterEqual64.class);
17265  private static NISuppressor arg1_ge_64 =
17266      new NISuppressor(0, RangeInt.GreaterEqual64.class);
17267  private static NISuppressor arg2_ge_64 =
17268      new NISuppressor(1, RangeInt.GreaterEqual64.class);
17269
17270  private static NISuppressor result_boolean =
17271      new NISuppressor(2, RangeInt.BooleanVal.class);
17272  private static NISuppressor arg1_boolean =
17273      new NISuppressor(0, RangeInt.BooleanVal.class);
17274  private static NISuppressor arg2_boolean =
17275      new NISuppressor(1, RangeInt.BooleanVal.class);
17276
17277  private static NISuppressor result_even =
17278      new NISuppressor(2, RangeInt.Even.class);
17279  private static NISuppressor arg1_even =
17280      new NISuppressor(0, RangeInt.Even.class);
17281  private static NISuppressor arg2_even =
17282      new NISuppressor(1, RangeInt.Even.class);
17283
17284  private static NISuppressor result_power2 =
17285      new NISuppressor(2, RangeInt.PowerOfTwo.class);
17286  private static NISuppressor arg1_power2 =
17287      new NISuppressor(0, RangeInt.PowerOfTwo.class);
17288  private static NISuppressor arg2_power2 =
17289      new NISuppressor(1, RangeInt.PowerOfTwo.class);
17290
17291  private static NISuppressor result_and0_arg1 =
17292      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
17293  private static NISuppressor result_and0_arg2 =
17294      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
17295  private static NISuppressor arg1_and0_arg2 =
17296      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
17297
17298  // The arguments to bitwise subset are backwards from what one
17299  // might expect.  The second argument is a subset of the first
17300  // argument
17301  private static NISuppressor arg1_bw_subset_arg2 =
17302      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
17303  private static NISuppressor arg2_bw_subset_arg1 =
17304      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
17305
17306  private static NISuppressor result_shift0_arg1 =
17307      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
17308  private static NISuppressor result_shift0_arg2 =
17309      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
17310  private static NISuppressor arg1_shift0_arg2 =
17311      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
17312
17313  private static NISuppressor arg2_divides_arg1 =
17314      new NISuppressor(0, 1, NumericInt.Divides.class);
17315  private static NISuppressor arg1_divides_arg2 =
17316      new NISuppressor(1, 0, NumericInt.Divides.class);
17317
17318  private static NISuppressor arg2_valid_shift =
17319      new NISuppressor(1, RangeInt.Bound0_63.class);
17320
17321    private static NISuppressionSet suppressions =
17322        new NISuppressionSet(
17323          new NISuppression[] {
17324
17325            // (r == x) && (y == 0) ==> r = x >>> y
17326            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
17327
17328            // (r == 0) && (x == 0) && (y valid shift) ==> r = x >>> y
17329            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
17330
17331            // (r == 0) && ((x >> y) == 0)
17332            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
17333
17334            // (r == 0) && (y >= x) && (x >= 0) && (y valid shift)
17335            // This suppression really ought to have 2**y >= x, but we
17336            // don't have that suppression.  This still might catch a lot of these.
17337            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
17338            //                   arg2_valid_shift, suppressee),
17339          });
17340
17341  // Create a suppression factory for functionBinary
17342
17343}
17344
17345/**
17346 * Represents the invariant {@code x = RshiftUnsigned(z, y)} over three long
17347 * scalars. 
17348 */
17349public static class RshiftUnsignedLong_xzy extends FunctionBinary {
17350  // We are Serializable, so we specify a version to allow changes to
17351  // method signatures without breaking serialization.  If you add or
17352  // remove fields, you should change this number to the current date.
17353  static final long serialVersionUID = 20031030L;
17354
17355    // y must be between arg2_bound[0] and arg2_bound[1] inclusive
17356    static int[] arg2_bound = {0, 63};
17357
17358  private static @Prototype RshiftUnsignedLong_xzy proto = new @Prototype RshiftUnsignedLong_xzy ();
17359
17360  /** Returns the prototype invariant for RshiftUnsignedLong_xzy */
17361  public static @Prototype RshiftUnsignedLong_xzy get_proto() {
17362    return proto;
17363  }
17364
17365  /** instantiate an invariant on the specified slice */
17366  @Override
17367  protected RshiftUnsignedLong_xzy instantiate_dyn(@Prototype RshiftUnsignedLong_xzy this, PptSlice slice) {
17368    return new RshiftUnsignedLong_xzy (slice);
17369  }
17370
17371  private RshiftUnsignedLong_xzy (PptSlice slice) {
17372    super(slice);
17373  }
17374
17375  public @Prototype RshiftUnsignedLong_xzy () {
17376    super();
17377  }
17378
17379  private static String[] method_name = new String[] {"", " >>> ", ""};
17380
17381  @Override
17382  public String[] get_method_name(@GuardSatisfied RshiftUnsignedLong_xzy this) {
17383    return method_name;
17384  }
17385
17386  private static int function_id = -1;
17387
17388  @Override
17389  public int get_function_id() {
17390    return function_id;
17391  }
17392
17393  @Override
17394  public void set_function_id(int function_id) {
17395    assert RshiftUnsignedLong_xzy.function_id == -1;
17396    RshiftUnsignedLong_xzy.function_id = function_id;
17397  }
17398
17399  private static int var_order = 4;
17400
17401  @Override
17402  public int get_var_order(@GuardSatisfied RshiftUnsignedLong_xzy this) {
17403    return var_order;
17404  }
17405
17406  @Pure
17407  @Override
17408  public boolean is_symmetric() {
17409
17410      return false;
17411  }
17412
17413  @Override
17414
17415  @SuppressWarnings("signedness:shift.unsigned") // RshiftUnsigned treats z as unsigned, though we do not know how the program under test treats it
17416
17417  public long func(long z, long y) {
17418
17419      if ((y < arg2_bound[0]) || (y > arg2_bound[1])) {
17420        throw new ArithmeticException("arg2 (" + y + ") out of range "
17421                                       + arg2_bound[0] + ".." + arg2_bound[1]);
17422      }
17423
17424    return (z >>> y);
17425  }
17426
17427  @Override
17428  public InvariantStatus check_modified(long x, long y,
17429                                      long z, int count) {
17430    return check_ordered(x, z, y, count);
17431  }
17432
17433  @Override
17434  public InvariantStatus add_modified(long x, long y,
17435                                      long z, int count) {
17436    if (Debug.logDetail()) {
17437      log("result=%s, arg1=%s, arg2=%s", x, z, y);
17438    }
17439    return add_ordered(x, z, y, count);
17440  }
17441
17442  @Pure
17443  @Override
17444  public boolean isRshiftUnsigned() {
17445    return true;
17446  }
17447
17448  /** Returns a list of non-instantiating suppressions for this invariant. */
17449  @Pure
17450  @Override
17451  public @Nullable NISuppressionSet get_ni_suppressions() {
17452    if (NIS.dkconfig_enabled && dkconfig_enabled) {
17453      return suppressions;
17454    } else {
17455      return null;
17456    }
17457  }
17458
17459  /** definition of this invariant (the suppressee) */
17460  private static NISuppressee suppressee = new NISuppressee(RshiftUnsignedLong_xzy.class, 3);
17461
17462  // suppressor definitions (used below)
17463  private static NISuppressor result_eq_arg1 =
17464      new NISuppressor(0, 2, IntEqual.class);
17465  private static NISuppressor result_eq_arg2 =
17466      new NISuppressor(0, 1, IntEqual.class);
17467  private static NISuppressor arg1_eq_arg2 =
17468      new NISuppressor(2, 1, IntEqual.class);
17469
17470  private static NISuppressor result_lt_arg1 =
17471      new NISuppressor(0, 2, IntLessThan.class);
17472  private static NISuppressor result_lt_arg2 =
17473      new NISuppressor(0, 1, IntLessThan.class);
17474  private static NISuppressor arg1_lt_arg2 =
17475      new NISuppressor(2, 1, IntLessThan.class);
17476  private static NISuppressor arg2_lt_arg1 =
17477      new NISuppressor(1, 2, IntLessThan.class);
17478
17479  private static NISuppressor result_le_arg1 =
17480      new NISuppressor(0, 2, IntLessEqual.class);
17481  private static NISuppressor result_le_arg2 =
17482      new NISuppressor(0, 1, IntLessEqual.class);
17483  private static NISuppressor arg1_le_arg2 =
17484      new NISuppressor(2, 1, IntLessEqual.class);
17485  private static NISuppressor arg2_le_arg1 =
17486      new NISuppressor(1, 2, IntLessEqual.class);
17487
17488  private static NISuppressor result_track0_arg1 =
17489      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
17490  private static NISuppressor result_track0_arg2 =
17491      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
17492  private static NISuppressor arg1_track0_arg2 =
17493      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
17494  private static NISuppressor arg1_track0_result =
17495      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
17496  private static NISuppressor arg2_track0_result =
17497      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
17498  private static NISuppressor arg2_track0_arg1 =
17499      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
17500
17501  private static NISuppressor result_eq_1 =
17502      new NISuppressor(0, RangeInt.EqualOne.class);
17503  private static NISuppressor arg1_eq_1 =
17504      new NISuppressor(2, RangeInt.EqualOne.class);
17505  private static NISuppressor arg2_eq_1 =
17506      new NISuppressor(1, RangeInt.EqualOne.class);
17507
17508  private static NISuppressor result_eq_0 =
17509      new NISuppressor(0, RangeInt.EqualZero.class);
17510  private static NISuppressor arg1_eq_0 =
17511      new NISuppressor(2, RangeInt.EqualZero.class);
17512  private static NISuppressor arg2_eq_0 =
17513      new NISuppressor(1, RangeInt.EqualZero.class);
17514
17515  private static NISuppressor result_ne_0 =
17516      new NISuppressor(0, NonZero.class);
17517  private static NISuppressor arg1_ne_0 =
17518      new NISuppressor(2, NonZero.class);
17519  private static NISuppressor arg2_ne_0 =
17520      new NISuppressor(1, NonZero.class);
17521
17522  private static NISuppressor result_ge_0 =
17523      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
17524  private static NISuppressor arg1_ge_0 =
17525      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
17526  private static NISuppressor arg2_ge_0 =
17527      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
17528
17529  private static NISuppressor result_ge_64 =
17530      new NISuppressor(0, RangeInt.GreaterEqual64.class);
17531  private static NISuppressor arg1_ge_64 =
17532      new NISuppressor(2, RangeInt.GreaterEqual64.class);
17533  private static NISuppressor arg2_ge_64 =
17534      new NISuppressor(1, RangeInt.GreaterEqual64.class);
17535
17536  private static NISuppressor result_boolean =
17537      new NISuppressor(0, RangeInt.BooleanVal.class);
17538  private static NISuppressor arg1_boolean =
17539      new NISuppressor(2, RangeInt.BooleanVal.class);
17540  private static NISuppressor arg2_boolean =
17541      new NISuppressor(1, RangeInt.BooleanVal.class);
17542
17543  private static NISuppressor result_even =
17544      new NISuppressor(0, RangeInt.Even.class);
17545  private static NISuppressor arg1_even =
17546      new NISuppressor(2, RangeInt.Even.class);
17547  private static NISuppressor arg2_even =
17548      new NISuppressor(1, RangeInt.Even.class);
17549
17550  private static NISuppressor result_power2 =
17551      new NISuppressor(0, RangeInt.PowerOfTwo.class);
17552  private static NISuppressor arg1_power2 =
17553      new NISuppressor(2, RangeInt.PowerOfTwo.class);
17554  private static NISuppressor arg2_power2 =
17555      new NISuppressor(1, RangeInt.PowerOfTwo.class);
17556
17557  private static NISuppressor result_and0_arg1 =
17558      new NISuppressor(0, 2, NumericInt.BitwiseAndZero.class);
17559  private static NISuppressor result_and0_arg2 =
17560      new NISuppressor(0, 1, NumericInt.BitwiseAndZero.class);
17561  private static NISuppressor arg1_and0_arg2 =
17562      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
17563
17564  // The arguments to bitwise subset are backwards from what one
17565  // might expect.  The second argument is a subset of the first
17566  // argument
17567  private static NISuppressor arg1_bw_subset_arg2 =
17568      new NISuppressor(1, 2, NumericInt.BitwiseSubset.class);
17569  private static NISuppressor arg2_bw_subset_arg1 =
17570      new NISuppressor(2, 1, NumericInt.BitwiseSubset.class);
17571
17572  private static NISuppressor result_shift0_arg1 =
17573      new NISuppressor(0, 2, NumericInt.ShiftZero.class);
17574  private static NISuppressor result_shift0_arg2 =
17575      new NISuppressor(0, 1, NumericInt.ShiftZero.class);
17576  private static NISuppressor arg1_shift0_arg2 =
17577      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
17578
17579  private static NISuppressor arg2_divides_arg1 =
17580      new NISuppressor(2, 1, NumericInt.Divides.class);
17581  private static NISuppressor arg1_divides_arg2 =
17582      new NISuppressor(1, 2, NumericInt.Divides.class);
17583
17584  private static NISuppressor arg2_valid_shift =
17585      new NISuppressor(1, RangeInt.Bound0_63.class);
17586
17587    private static NISuppressionSet suppressions =
17588        new NISuppressionSet(
17589          new NISuppression[] {
17590
17591            // (r == z) && (y == 0) ==> r = z >>> y
17592            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
17593
17594            // (r == 0) && (z == 0) && (y valid shift) ==> r = z >>> y
17595            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
17596
17597            // (r == 0) && ((z >> y) == 0)
17598            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
17599
17600            // (r == 0) && (y >= z) && (z >= 0) && (y valid shift)
17601            // This suppression really ought to have 2**y >= z, but we
17602            // don't have that suppression.  This still might catch a lot of these.
17603            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
17604            //                   arg2_valid_shift, suppressee),
17605          });
17606
17607  // Create a suppression factory for functionBinary
17608
17609}
17610
17611/**
17612 * Represents the invariant {@code y = RshiftUnsigned(z, x)} over three long
17613 * scalars. 
17614 */
17615public static class RshiftUnsignedLong_yzx extends FunctionBinary {
17616  // We are Serializable, so we specify a version to allow changes to
17617  // method signatures without breaking serialization.  If you add or
17618  // remove fields, you should change this number to the current date.
17619  static final long serialVersionUID = 20031030L;
17620
17621    // x must be between arg2_bound[0] and arg2_bound[1] inclusive
17622    static int[] arg2_bound = {0, 63};
17623
17624  private static @Prototype RshiftUnsignedLong_yzx proto = new @Prototype RshiftUnsignedLong_yzx ();
17625
17626  /** Returns the prototype invariant for RshiftUnsignedLong_yzx */
17627  public static @Prototype RshiftUnsignedLong_yzx get_proto() {
17628    return proto;
17629  }
17630
17631  /** instantiate an invariant on the specified slice */
17632  @Override
17633  protected RshiftUnsignedLong_yzx instantiate_dyn(@Prototype RshiftUnsignedLong_yzx this, PptSlice slice) {
17634    return new RshiftUnsignedLong_yzx (slice);
17635  }
17636
17637  private RshiftUnsignedLong_yzx (PptSlice slice) {
17638    super(slice);
17639  }
17640
17641  public @Prototype RshiftUnsignedLong_yzx () {
17642    super();
17643  }
17644
17645  private static String[] method_name = new String[] {"", " >>> ", ""};
17646
17647  @Override
17648  public String[] get_method_name(@GuardSatisfied RshiftUnsignedLong_yzx this) {
17649    return method_name;
17650  }
17651
17652  private static int function_id = -1;
17653
17654  @Override
17655  public int get_function_id() {
17656    return function_id;
17657  }
17658
17659  @Override
17660  public void set_function_id(int function_id) {
17661    assert RshiftUnsignedLong_yzx.function_id == -1;
17662    RshiftUnsignedLong_yzx.function_id = function_id;
17663  }
17664
17665  private static int var_order = 5;
17666
17667  @Override
17668  public int get_var_order(@GuardSatisfied RshiftUnsignedLong_yzx this) {
17669    return var_order;
17670  }
17671
17672  @Pure
17673  @Override
17674  public boolean is_symmetric() {
17675
17676      return false;
17677  }
17678
17679  @Override
17680
17681  @SuppressWarnings("signedness:shift.unsigned") // RshiftUnsigned treats z as unsigned, though we do not know how the program under test treats it
17682
17683  public long func(long z, long x) {
17684
17685      if ((x < arg2_bound[0]) || (x > arg2_bound[1])) {
17686        throw new ArithmeticException("arg2 (" + x + ") out of range "
17687                                       + arg2_bound[0] + ".." + arg2_bound[1]);
17688      }
17689
17690    return (z >>> x);
17691  }
17692
17693  @Override
17694  public InvariantStatus check_modified(long x, long y,
17695                                      long z, int count) {
17696    return check_ordered(y, z, x, count);
17697  }
17698
17699  @Override
17700  public InvariantStatus add_modified(long x, long y,
17701                                      long z, int count) {
17702    if (Debug.logDetail()) {
17703      log("result=%s, arg1=%s, arg2=%s", y, z, x);
17704    }
17705    return add_ordered(y, z, x, count);
17706  }
17707
17708  @Pure
17709  @Override
17710  public boolean isRshiftUnsigned() {
17711    return true;
17712  }
17713
17714  /** Returns a list of non-instantiating suppressions for this invariant. */
17715  @Pure
17716  @Override
17717  public @Nullable NISuppressionSet get_ni_suppressions() {
17718    if (NIS.dkconfig_enabled && dkconfig_enabled) {
17719      return suppressions;
17720    } else {
17721      return null;
17722    }
17723  }
17724
17725  /** definition of this invariant (the suppressee) */
17726  private static NISuppressee suppressee = new NISuppressee(RshiftUnsignedLong_yzx.class, 3);
17727
17728  // suppressor definitions (used below)
17729  private static NISuppressor result_eq_arg1 =
17730      new NISuppressor(1, 2, IntEqual.class);
17731  private static NISuppressor result_eq_arg2 =
17732      new NISuppressor(1, 0, IntEqual.class);
17733  private static NISuppressor arg1_eq_arg2 =
17734      new NISuppressor(2, 0, IntEqual.class);
17735
17736  private static NISuppressor result_lt_arg1 =
17737      new NISuppressor(1, 2, IntLessThan.class);
17738  private static NISuppressor result_lt_arg2 =
17739      new NISuppressor(1, 0, IntLessThan.class);
17740  private static NISuppressor arg1_lt_arg2 =
17741      new NISuppressor(2, 0, IntLessThan.class);
17742  private static NISuppressor arg2_lt_arg1 =
17743      new NISuppressor(0, 2, IntLessThan.class);
17744
17745  private static NISuppressor result_le_arg1 =
17746      new NISuppressor(1, 2, IntLessEqual.class);
17747  private static NISuppressor result_le_arg2 =
17748      new NISuppressor(1, 0, IntLessEqual.class);
17749  private static NISuppressor arg1_le_arg2 =
17750      new NISuppressor(2, 0, IntLessEqual.class);
17751  private static NISuppressor arg2_le_arg1 =
17752      new NISuppressor(0, 2, IntLessEqual.class);
17753
17754  private static NISuppressor result_track0_arg1 =
17755      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
17756  private static NISuppressor result_track0_arg2 =
17757      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
17758  private static NISuppressor arg1_track0_arg2 =
17759      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
17760  private static NISuppressor arg1_track0_result =
17761      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
17762  private static NISuppressor arg2_track0_result =
17763      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
17764  private static NISuppressor arg2_track0_arg1 =
17765      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
17766
17767  private static NISuppressor result_eq_1 =
17768      new NISuppressor(1, RangeInt.EqualOne.class);
17769  private static NISuppressor arg1_eq_1 =
17770      new NISuppressor(2, RangeInt.EqualOne.class);
17771  private static NISuppressor arg2_eq_1 =
17772      new NISuppressor(0, RangeInt.EqualOne.class);
17773
17774  private static NISuppressor result_eq_0 =
17775      new NISuppressor(1, RangeInt.EqualZero.class);
17776  private static NISuppressor arg1_eq_0 =
17777      new NISuppressor(2, RangeInt.EqualZero.class);
17778  private static NISuppressor arg2_eq_0 =
17779      new NISuppressor(0, RangeInt.EqualZero.class);
17780
17781  private static NISuppressor result_ne_0 =
17782      new NISuppressor(1, NonZero.class);
17783  private static NISuppressor arg1_ne_0 =
17784      new NISuppressor(2, NonZero.class);
17785  private static NISuppressor arg2_ne_0 =
17786      new NISuppressor(0, NonZero.class);
17787
17788  private static NISuppressor result_ge_0 =
17789      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
17790  private static NISuppressor arg1_ge_0 =
17791      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
17792  private static NISuppressor arg2_ge_0 =
17793      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
17794
17795  private static NISuppressor result_ge_64 =
17796      new NISuppressor(1, RangeInt.GreaterEqual64.class);
17797  private static NISuppressor arg1_ge_64 =
17798      new NISuppressor(2, RangeInt.GreaterEqual64.class);
17799  private static NISuppressor arg2_ge_64 =
17800      new NISuppressor(0, RangeInt.GreaterEqual64.class);
17801
17802  private static NISuppressor result_boolean =
17803      new NISuppressor(1, RangeInt.BooleanVal.class);
17804  private static NISuppressor arg1_boolean =
17805      new NISuppressor(2, RangeInt.BooleanVal.class);
17806  private static NISuppressor arg2_boolean =
17807      new NISuppressor(0, RangeInt.BooleanVal.class);
17808
17809  private static NISuppressor result_even =
17810      new NISuppressor(1, RangeInt.Even.class);
17811  private static NISuppressor arg1_even =
17812      new NISuppressor(2, RangeInt.Even.class);
17813  private static NISuppressor arg2_even =
17814      new NISuppressor(0, RangeInt.Even.class);
17815
17816  private static NISuppressor result_power2 =
17817      new NISuppressor(1, RangeInt.PowerOfTwo.class);
17818  private static NISuppressor arg1_power2 =
17819      new NISuppressor(2, RangeInt.PowerOfTwo.class);
17820  private static NISuppressor arg2_power2 =
17821      new NISuppressor(0, RangeInt.PowerOfTwo.class);
17822
17823  private static NISuppressor result_and0_arg1 =
17824      new NISuppressor(1, 2, NumericInt.BitwiseAndZero.class);
17825  private static NISuppressor result_and0_arg2 =
17826      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
17827  private static NISuppressor arg1_and0_arg2 =
17828      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
17829
17830  // The arguments to bitwise subset are backwards from what one
17831  // might expect.  The second argument is a subset of the first
17832  // argument
17833  private static NISuppressor arg1_bw_subset_arg2 =
17834      new NISuppressor(0, 2, NumericInt.BitwiseSubset.class);
17835  private static NISuppressor arg2_bw_subset_arg1 =
17836      new NISuppressor(2, 0, NumericInt.BitwiseSubset.class);
17837
17838  private static NISuppressor result_shift0_arg1 =
17839      new NISuppressor(1, 2, NumericInt.ShiftZero.class);
17840  private static NISuppressor result_shift0_arg2 =
17841      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
17842  private static NISuppressor arg1_shift0_arg2 =
17843      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
17844
17845  private static NISuppressor arg2_divides_arg1 =
17846      new NISuppressor(2, 0, NumericInt.Divides.class);
17847  private static NISuppressor arg1_divides_arg2 =
17848      new NISuppressor(0, 2, NumericInt.Divides.class);
17849
17850  private static NISuppressor arg2_valid_shift =
17851      new NISuppressor(0, RangeInt.Bound0_63.class);
17852
17853    private static NISuppressionSet suppressions =
17854        new NISuppressionSet(
17855          new NISuppression[] {
17856
17857            // (r == z) && (x == 0) ==> r = z >>> x
17858            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
17859
17860            // (r == 0) && (z == 0) && (x valid shift) ==> r = z >>> x
17861            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
17862
17863            // (r == 0) && ((z >> x) == 0)
17864            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
17865
17866            // (r == 0) && (x >= z) && (z >= 0) && (x valid shift)
17867            // This suppression really ought to have 2**x >= z, but we
17868            // don't have that suppression.  This still might catch a lot of these.
17869            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
17870            //                   arg2_valid_shift, suppressee),
17871          });
17872
17873  // Create a suppression factory for functionBinary
17874
17875}
17876
17877/**
17878 * Represents the invariant {@code z = RshiftUnsigned(y, x)} over three long
17879 * scalars. 
17880 */
17881public static class RshiftUnsignedLong_zyx extends FunctionBinary {
17882  // We are Serializable, so we specify a version to allow changes to
17883  // method signatures without breaking serialization.  If you add or
17884  // remove fields, you should change this number to the current date.
17885  static final long serialVersionUID = 20031030L;
17886
17887    // x must be between arg2_bound[0] and arg2_bound[1] inclusive
17888    static int[] arg2_bound = {0, 63};
17889
17890  private static @Prototype RshiftUnsignedLong_zyx proto = new @Prototype RshiftUnsignedLong_zyx ();
17891
17892  /** Returns the prototype invariant for RshiftUnsignedLong_zyx */
17893  public static @Prototype RshiftUnsignedLong_zyx get_proto() {
17894    return proto;
17895  }
17896
17897  /** instantiate an invariant on the specified slice */
17898  @Override
17899  protected RshiftUnsignedLong_zyx instantiate_dyn(@Prototype RshiftUnsignedLong_zyx this, PptSlice slice) {
17900    return new RshiftUnsignedLong_zyx (slice);
17901  }
17902
17903  private RshiftUnsignedLong_zyx (PptSlice slice) {
17904    super(slice);
17905  }
17906
17907  public @Prototype RshiftUnsignedLong_zyx () {
17908    super();
17909  }
17910
17911  private static String[] method_name = new String[] {"", " >>> ", ""};
17912
17913  @Override
17914  public String[] get_method_name(@GuardSatisfied RshiftUnsignedLong_zyx this) {
17915    return method_name;
17916  }
17917
17918  private static int function_id = -1;
17919
17920  @Override
17921  public int get_function_id() {
17922    return function_id;
17923  }
17924
17925  @Override
17926  public void set_function_id(int function_id) {
17927    assert RshiftUnsignedLong_zyx.function_id == -1;
17928    RshiftUnsignedLong_zyx.function_id = function_id;
17929  }
17930
17931  private static int var_order = 6;
17932
17933  @Override
17934  public int get_var_order(@GuardSatisfied RshiftUnsignedLong_zyx this) {
17935    return var_order;
17936  }
17937
17938  @Pure
17939  @Override
17940  public boolean is_symmetric() {
17941
17942      return false;
17943  }
17944
17945  @Override
17946
17947  @SuppressWarnings("signedness:shift.unsigned") // RshiftUnsigned treats y as unsigned, though we do not know how the program under test treats it
17948
17949  public long func(long y, long x) {
17950
17951      if ((x < arg2_bound[0]) || (x > arg2_bound[1])) {
17952        throw new ArithmeticException("arg2 (" + x + ") out of range "
17953                                       + arg2_bound[0] + ".." + arg2_bound[1]);
17954      }
17955
17956    return (y >>> x);
17957  }
17958
17959  @Override
17960  public InvariantStatus check_modified(long x, long y,
17961                                      long z, int count) {
17962    return check_ordered(z, y, x, count);
17963  }
17964
17965  @Override
17966  public InvariantStatus add_modified(long x, long y,
17967                                      long z, int count) {
17968    if (Debug.logDetail()) {
17969      log("result=%s, arg1=%s, arg2=%s", z, y, x);
17970    }
17971    return add_ordered(z, y, x, count);
17972  }
17973
17974  @Pure
17975  @Override
17976  public boolean isRshiftUnsigned() {
17977    return true;
17978  }
17979
17980  /** Returns a list of non-instantiating suppressions for this invariant. */
17981  @Pure
17982  @Override
17983  public @Nullable NISuppressionSet get_ni_suppressions() {
17984    if (NIS.dkconfig_enabled && dkconfig_enabled) {
17985      return suppressions;
17986    } else {
17987      return null;
17988    }
17989  }
17990
17991  /** definition of this invariant (the suppressee) */
17992  private static NISuppressee suppressee = new NISuppressee(RshiftUnsignedLong_zyx.class, 3);
17993
17994  // suppressor definitions (used below)
17995  private static NISuppressor result_eq_arg1 =
17996      new NISuppressor(2, 1, IntEqual.class);
17997  private static NISuppressor result_eq_arg2 =
17998      new NISuppressor(2, 0, IntEqual.class);
17999  private static NISuppressor arg1_eq_arg2 =
18000      new NISuppressor(1, 0, IntEqual.class);
18001
18002  private static NISuppressor result_lt_arg1 =
18003      new NISuppressor(2, 1, IntLessThan.class);
18004  private static NISuppressor result_lt_arg2 =
18005      new NISuppressor(2, 0, IntLessThan.class);
18006  private static NISuppressor arg1_lt_arg2 =
18007      new NISuppressor(1, 0, IntLessThan.class);
18008  private static NISuppressor arg2_lt_arg1 =
18009      new NISuppressor(0, 1, IntLessThan.class);
18010
18011  private static NISuppressor result_le_arg1 =
18012      new NISuppressor(2, 1, IntLessEqual.class);
18013  private static NISuppressor result_le_arg2 =
18014      new NISuppressor(2, 0, IntLessEqual.class);
18015  private static NISuppressor arg1_le_arg2 =
18016      new NISuppressor(1, 0, IntLessEqual.class);
18017  private static NISuppressor arg2_le_arg1 =
18018      new NISuppressor(0, 1, IntLessEqual.class);
18019
18020  private static NISuppressor result_track0_arg1 =
18021      new NISuppressor(2, 1, NumericInt.ZeroTrack.class);
18022  private static NISuppressor result_track0_arg2 =
18023      new NISuppressor(2, 0, NumericInt.ZeroTrack.class);
18024  private static NISuppressor arg1_track0_arg2 =
18025      new NISuppressor(1, 0, NumericInt.ZeroTrack.class);
18026  private static NISuppressor arg1_track0_result =
18027      new NISuppressor(1, 2, NumericInt.ZeroTrack.class);
18028  private static NISuppressor arg2_track0_result =
18029      new NISuppressor(0, 2, NumericInt.ZeroTrack.class);
18030  private static NISuppressor arg2_track0_arg1 =
18031      new NISuppressor(0, 1, NumericInt.ZeroTrack.class);
18032
18033  private static NISuppressor result_eq_1 =
18034      new NISuppressor(2, RangeInt.EqualOne.class);
18035  private static NISuppressor arg1_eq_1 =
18036      new NISuppressor(1, RangeInt.EqualOne.class);
18037  private static NISuppressor arg2_eq_1 =
18038      new NISuppressor(0, RangeInt.EqualOne.class);
18039
18040  private static NISuppressor result_eq_0 =
18041      new NISuppressor(2, RangeInt.EqualZero.class);
18042  private static NISuppressor arg1_eq_0 =
18043      new NISuppressor(1, RangeInt.EqualZero.class);
18044  private static NISuppressor arg2_eq_0 =
18045      new NISuppressor(0, RangeInt.EqualZero.class);
18046
18047  private static NISuppressor result_ne_0 =
18048      new NISuppressor(2, NonZero.class);
18049  private static NISuppressor arg1_ne_0 =
18050      new NISuppressor(1, NonZero.class);
18051  private static NISuppressor arg2_ne_0 =
18052      new NISuppressor(0, NonZero.class);
18053
18054  private static NISuppressor result_ge_0 =
18055      new NISuppressor(2, RangeInt.GreaterEqualZero.class);
18056  private static NISuppressor arg1_ge_0 =
18057      new NISuppressor(1, RangeInt.GreaterEqualZero.class);
18058  private static NISuppressor arg2_ge_0 =
18059      new NISuppressor(0, RangeInt.GreaterEqualZero.class);
18060
18061  private static NISuppressor result_ge_64 =
18062      new NISuppressor(2, RangeInt.GreaterEqual64.class);
18063  private static NISuppressor arg1_ge_64 =
18064      new NISuppressor(1, RangeInt.GreaterEqual64.class);
18065  private static NISuppressor arg2_ge_64 =
18066      new NISuppressor(0, RangeInt.GreaterEqual64.class);
18067
18068  private static NISuppressor result_boolean =
18069      new NISuppressor(2, RangeInt.BooleanVal.class);
18070  private static NISuppressor arg1_boolean =
18071      new NISuppressor(1, RangeInt.BooleanVal.class);
18072  private static NISuppressor arg2_boolean =
18073      new NISuppressor(0, RangeInt.BooleanVal.class);
18074
18075  private static NISuppressor result_even =
18076      new NISuppressor(2, RangeInt.Even.class);
18077  private static NISuppressor arg1_even =
18078      new NISuppressor(1, RangeInt.Even.class);
18079  private static NISuppressor arg2_even =
18080      new NISuppressor(0, RangeInt.Even.class);
18081
18082  private static NISuppressor result_power2 =
18083      new NISuppressor(2, RangeInt.PowerOfTwo.class);
18084  private static NISuppressor arg1_power2 =
18085      new NISuppressor(1, RangeInt.PowerOfTwo.class);
18086  private static NISuppressor arg2_power2 =
18087      new NISuppressor(0, RangeInt.PowerOfTwo.class);
18088
18089  private static NISuppressor result_and0_arg1 =
18090      new NISuppressor(2, 1, NumericInt.BitwiseAndZero.class);
18091  private static NISuppressor result_and0_arg2 =
18092      new NISuppressor(2, 0, NumericInt.BitwiseAndZero.class);
18093  private static NISuppressor arg1_and0_arg2 =
18094      new NISuppressor(1, 0, NumericInt.BitwiseAndZero.class);
18095
18096  // The arguments to bitwise subset are backwards from what one
18097  // might expect.  The second argument is a subset of the first
18098  // argument
18099  private static NISuppressor arg1_bw_subset_arg2 =
18100      new NISuppressor(0, 1, NumericInt.BitwiseSubset.class);
18101  private static NISuppressor arg2_bw_subset_arg1 =
18102      new NISuppressor(1, 0, NumericInt.BitwiseSubset.class);
18103
18104  private static NISuppressor result_shift0_arg1 =
18105      new NISuppressor(2, 1, NumericInt.ShiftZero.class);
18106  private static NISuppressor result_shift0_arg2 =
18107      new NISuppressor(2, 0, NumericInt.ShiftZero.class);
18108  private static NISuppressor arg1_shift0_arg2 =
18109      new NISuppressor(1, 0, NumericInt.ShiftZero.class);
18110
18111  private static NISuppressor arg2_divides_arg1 =
18112      new NISuppressor(1, 0, NumericInt.Divides.class);
18113  private static NISuppressor arg1_divides_arg2 =
18114      new NISuppressor(0, 1, NumericInt.Divides.class);
18115
18116  private static NISuppressor arg2_valid_shift =
18117      new NISuppressor(0, RangeInt.Bound0_63.class);
18118
18119    private static NISuppressionSet suppressions =
18120        new NISuppressionSet(
18121          new NISuppression[] {
18122
18123            // (r == y) && (x == 0) ==> r = y >>> x
18124            new NISuppression(result_eq_arg1, arg2_eq_0, suppressee),
18125
18126            // (r == 0) && (y == 0) && (x valid shift) ==> r = y >>> x
18127            // new NISuppression (result_eq_0, arg1_eq_0, arg2_valid_shift, suppressee),
18128
18129            // (r == 0) && ((y >> x) == 0)
18130            new NISuppression(result_eq_0, arg1_shift0_arg2, suppressee),
18131
18132            // (r == 0) && (x >= y) && (y >= 0) && (x valid shift)
18133            // This suppression really ought to have 2**x >= y, but we
18134            // don't have that suppression.  This still might catch a lot of these.
18135            // new NISuppression (result_eq_0, arg1_le_arg2, arg1_ge_0,
18136            //                   arg2_valid_shift, suppressee),
18137          });
18138
18139  // Create a suppression factory for functionBinary
18140
18141}
18142
18143}