nus-yam/ex-repair huggingface dataset:
Program: 100103
Project: 100103
Buggy source:
@SuppressWarnings("String_Node_Str") public AbstractRootMethod getLanguageRoot(Atom language){
  if (!languageRoots.containsKey(language)) {
    AbstractRootMethod languageRoot=roots.get(language,this);
    CGNode languageRootNode=findOrCreateNode(languageRoot,Everywhere.EVERYWHERE);
    languageRootNodes.add(languageRootNode);
    CallSiteReference site=CallSiteReference.make(1,languageRoot.getReference(),IInvokeInstruction.Dispatch.STATIC);
    CGNode fakeRootNode=getFakeRootNode();
    CrossLanguageFakeRoot fakeRootMethod=(CrossLanguageFakeRoot)fakeRootNode.getMethod();
    site=fakeRootMethod.addInvocationInternal(new int[0],site).getCallSite();
    fakeRootNode.addTarget(site,languageRootNode);
    languageRoots.put(language,languageRoot);
  }
  return (AbstractRootMethod)languageRoots.get(language);
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") public AbstractRootMethod getLanguageRoot(Atom language){
  if (!languageRoots.containsKey(language)) {
    AbstractRootMethod languageRoot=roots.get(language,this);
    CGNode languageRootNode=null;
    try {
      languageRootNode=findOrCreateNode(languageRoot,Everywhere.EVERYWHERE);
    }
 catch (    CancelException e) {
      e.printStackTrace();
      Assertions.UNREACHABLE();
    }
    languageRootNodes.add(languageRootNode);
    CallSiteReference site=CallSiteReference.make(1,languageRoot.getReference(),IInvokeInstruction.Dispatch.STATIC);
    CGNode fakeRootNode=getFakeRootNode();
    CrossLanguageFakeRoot fakeRootMethod=(CrossLanguageFakeRoot)fakeRootNode.getMethod();
    site=fakeRootMethod.addInvocationInternal(new int[0],site).getCallSite();
    fakeRootNode.addTarget(site,languageRootNode);
    languageRoots.put(language,languageRoot);
  }
  return (AbstractRootMethod)languageRoots.get(language);
}
Program: 100105
Project: 100105
Buggy source:
protected void addCtorInvokeInstruction(final TypeReference T,int alloc){
  MethodReference init=MethodReference.findOrCreate(T,MethodReference.initAtom,MethodReference.defaultInitDesc);
  CallSiteReference site=CallSiteReference.make(getCallSiteForType(T),init,IInvokeInstruction.Dispatch.SPECIAL);
  int[] params=new int[1];
  params[0]=alloc;
  int exc=getExceptionsForType(T);
  SSAInvokeInstruction s=new SSAInvokeInstruction(params,exc,site);
  calls.add(s);
  allInstructions.add(s);
}

Fixed version (ground truth):
/** 
 * Add an instruction to invoke the default constructor on the object of value number alloc of type t.
 */
protected void addCtorInvokeInstruction(final TypeReference t,int alloc){
  MethodReference init=MethodReference.findOrCreate(t,MethodReference.initAtom,MethodReference.defaultInitDesc);
  CallSiteReference site=CallSiteReference.make(getCallSiteForType(t),init,IInvokeInstruction.Dispatch.SPECIAL);
  int[] params=new int[1];
  params[0]=alloc;
  int exc=getExceptionsForType(t);
  SSAInvokeInstruction s=new SSAInvokeInstruction(params,exc,site);
  calls.add(s);
  allInstructions.add(s);
}
Program: 100106
Project: 100106
Buggy source:
/** 
 * @param T
 * @return value number of the newly allocated object
 */
protected int addStatementsForConcreteSimpleType(final TypeReference T){
}

Fixed version (ground truth):
/** 
 * @param t type of object to allocate
 * @return value number of the newly allocated object
 */
protected int addStatementsForConcreteSimpleType(final TypeReference t){
}
Program: 100107
Project: 100107
Buggy source:
/** 
 * Set up a method summary which allocates and returns an instance of concrete type T.
 * @param T
 */
private void addStatementsForConcreteType(final TypeReference T){
  int alloc=addStatementsForConcreteSimpleType(T);
  if (alloc == -1) {
    return;
  }
  if (T.isArrayType()) {
    MethodReference init=MethodReference.findOrCreate(T,MethodReference.initAtom,MethodReference.defaultInitDesc);
    CallSiteReference site=CallSiteReference.make(getCallSiteForType(T),init,IInvokeInstruction.Dispatch.SPECIAL);
    int[] params=new int[1];
    params[0]=alloc;
    int exc=getExceptionsForType(T);
    SSAInvokeInstruction s=new SSAInvokeInstruction(params,exc,site);
    calls.add(s);
    allInstructions.add(s);
  }
}

Fixed version (ground truth):
/** 
 * Set up a method summary which allocates and returns an instance of concrete type T.
 * @param T
 */
private void addStatementsForConcreteType(final TypeReference T){
  int alloc=addStatementsForConcreteSimpleType(T);
  if (alloc == -1) {
    return;
  }
  if (T.isArrayType()) {
    MethodReference init=MethodReference.findOrCreate(T,MethodReference.initAtom,MethodReference.defaultInitDesc);
    CallSiteReference site=CallSiteReference.make(getCallSiteForType(T),init,IInvokeInstruction.Dispatch.SPECIAL);
    int[] params=new int[1];
    params[0]=alloc;
    int exc=getExceptionsForType(T);
    SSAInvokeInstruction s=new SSAInvokeInstruction(params,exc,site);
    calls.add(s);
    allInstructions.add(s);
  }
 else {
  }
}
Program: 100109
Project: 100109
Buggy source:
public boolean understands(CGNode node){
  if (node == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  if (!(node.getContext() instanceof ReceiverInstanceContext)) {
    return false;
  }
  return node.getMethod().getReference().equals(METHOD_INVOKE) || node.getMethod().getReference().equals(CTOR_NEW_INSTANCE);
}

Fixed version (ground truth):
public boolean understands(CGNode node){
  if (node == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  if (!(node.getContext() instanceof ReceiverInstanceContext)) {
    return false;
  }
  ReceiverInstanceContext r=(ReceiverInstanceContext)node.getContext();
  if (!(r.getReceiver() instanceof ConstantKey)) {
    return false;
  }
  return node.getMethod().getReference().equals(METHOD_INVOKE) || node.getMethod().getReference().equals(CTOR_NEW_INSTANCE);
}
Program: 100111
Project: 100111
Buggy source:
/** 
 * This object may understand a dispatch to Constructor.newInstance().
 */
public boolean mayUnderstand(CGNode caller,CallSiteReference site,IMethod targetMethod,InstanceKey instance){
  if (targetMethod.getReference().equals(ReflectiveInvocationInterpreter.METHOD_INVOKE) || isConstructorConstant(instance) && targetMethod.getReference().equals(ReflectiveInvocationInterpreter.CTOR_NEW_INSTANCE)) {
    return true;
  }
  return false;
}

Fixed version (ground truth):
/** 
 * This object may understand a dispatch to Constructor.newInstance().
 */
public boolean mayUnderstand(CGNode caller,CallSiteReference site,IMethod targetMethod,InstanceKey instance){
  if (instance instanceof ConstantKey) {
    if (targetMethod.getReference().equals(ReflectiveInvocationInterpreter.METHOD_INVOKE) || isConstructorConstant(instance) && targetMethod.getReference().equals(ReflectiveInvocationInterpreter.CTOR_NEW_INSTANCE)) {
      return true;
    }
  }
  return false;
}
Program: 100112
Project: 100112
Buggy source:
/** 
 * Walk through the instructions and compute basic block boundaries.
 */
private void makeBasicBlocks(){
  SSAInstruction[] instructions=(SSAInstruction[])getInstructions();
  final boolean[] r=new boolean[instructions.length];
  r[0]=true;
  BranchVisitor branchVisitor=makeBranchVisitor(r);
  PEIVisitor peiVisitor=makePEIVisitor(r);
  for (int i=0; i < instructions.length; i++) {
    if (instructions[i] != null) {
      branchVisitor.setIndex(i);
      instructions[i].visit(branchVisitor);
      peiVisitor.setIndex(i);
      instructions[i].visit(peiVisitor);
    }
  }
  BasicBlock b=null;
  for (int i=0; i < r.length; i++) {
    if (r[i]) {
      b=new BasicBlock(i);
      addNode(b);
      if (DEBUG) {
        Trace.println("String_Node_Str" + b);
      }
    }
    i2block[i]=b;
  }
  BasicBlock exit=new BasicBlock(-1);
  if (DEBUG) {
    Trace.println("String_Node_Str" + exit);
  }
  addNode(exit);
}

Fixed version (ground truth):
/** 
 * Walk through the instructions and compute basic block boundaries.
 */
private void makeBasicBlocks(){
  SSAInstruction[] instructions=(SSAInstruction[])getInstructions();
  final boolean[] r=new boolean[instructions.length];
  r[0]=true;
  BranchVisitor branchVisitor=makeBranchVisitor(r);
  PEIVisitor peiVisitor=makePEIVisitor(r);
  for (int i=0; i < instructions.length; i++) {
    if (instructions[i] != null) {
      branchVisitor.setIndex(i);
      instructions[i].visit(branchVisitor);
      peiVisitor.setIndex(i);
      instructions[i].visit(peiVisitor);
    }
  }
  BasicBlock b=null;
  for (int i=0; i < r.length; i++) {
    if (r[i]) {
      b=new BasicBlock(i);
      addNode(b);
      int j=i;
      while (instructions[j] instanceof SSAPhiInstruction) {
        b.addPhi((SSAPhiInstruction)instructions[j]);
        j++;
      }
      if (DEBUG) {
        Trace.println("String_Node_Str" + b);
      }
    }
    i2block[i]=b;
  }
  BasicBlock exit=new BasicBlock(-1);
  if (DEBUG) {
    Trace.println("String_Node_Str" + exit);
  }
  addNode(exit);
  clearPhis(instructions);
}
Program: 100113
Project: 100113
Buggy source:
@Override public void visitGoto(SSAGotoInstruction instruction){
  Assertions.UNREACHABLE("String_Node_Str");
  breakBasicBlock();
}

Fixed version (ground truth):
@Override public void visitGoto(SSAGotoInstruction instruction){
  Assertions.UNREACHABLE("String_Node_Str");
  breakBasicBlock(index);
}
Program: 100114
Project: 100114
Buggy source:
/** 
 * TODO: we do not yet support induced CFGS with exception handlers.
 * @param instructions
 * @throws IllegalArgumentException  if instructions is null
 */
public InducedCFG(SSAInstruction[] instructions,IMethod method,Context context){
  super(method);
  if (instructions == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  this.context=context;
  this.instructions=instructions;
  if (DEBUG) {
    Trace.println("String_Node_Str" + method);
  }
  i2block=new BasicBlock[instructions.length];
  if (instructions.length == 0) {
    makeEmptyBlocks();
  }
 else {
    makeBasicBlocks();
  }
  init();
  computeEdges();
  if (DEBUG) {
    try {
      GraphIntegrity.check(this);
    }
 catch (    UnsoundGraphException e) {
      e.printStackTrace();
      Assertions.UNREACHABLE();
    }
  }
}

Fixed version (ground truth):
/** 
 * TODO: we do not yet support induced CFGS with exception handlers. NOTE: SIDE EFFECT!!! ... nulls out phi instructions in the instruction array!
 * @throws IllegalArgumentException if instructions is null
 */
public InducedCFG(SSAInstruction[] instructions,IMethod method,Context context){
  super(method);
  if (instructions == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  this.context=context;
  this.instructions=instructions;
  if (DEBUG) {
    Trace.println("String_Node_Str" + method);
  }
  i2block=new BasicBlock[instructions.length];
  if (instructions.length == 0) {
    makeEmptyBlocks();
  }
 else {
    makeBasicBlocks();
  }
  init();
  computeEdges();
  if (DEBUG) {
    try {
      GraphIntegrity.check(this);
    }
 catch (    UnsoundGraphException e) {
      e.printStackTrace();
      Assertions.UNREACHABLE();
    }
  }
}
Program: 100115
Project: 100115
Buggy source:
@Override public void visitReturn(SSAReturnInstruction instruction){
  breakBasicBlock();
}

Fixed version (ground truth):
@Override public void visitReturn(SSAReturnInstruction instruction){
  breakBasicBlock(index);
}
Program: 100116
Project: 100116
Buggy source:
@Override public void visitConditionalBranch(SSAConditionalBranchInstruction instruction){
  Assertions.UNREACHABLE("String_Node_Str");
  breakBasicBlock();
}

Fixed version (ground truth):
@Override public void visitConditionalBranch(SSAConditionalBranchInstruction instruction){
  Assertions.UNREACHABLE("String_Node_Str");
  breakBasicBlock(index);
}
Program: 100117
Project: 100117
Buggy source:
public InducedCFG makeControlFlowGraph(){
  return new InducedCFG(getStatements(),this,Everywhere.EVERYWHERE);
}

Fixed version (ground truth):
/** 
 * Create an   {@link InducedCFG} from an instruction array.NOTE: SIDE EFFECT!!! ... nulls out phi instructions in the instruction array!
 */
public InducedCFG makeControlFlowGraph(SSAInstruction[] instructions){
  return new InducedCFG(instructions,this,Everywhere.EVERYWHERE);
}
Program: 100118
Project: 100118
Buggy source:
@Override public IR makeIR(SSAOptions options){
  SSAInstruction instrs[]=getStatements(options);
  Map<Integer,ConstantValue> constants=null;
  if (valueNumberForConstantOne > -1) {
    constants=HashMapFactory.make(1);
    constants.put(new Integer(valueNumberForConstantOne),new ConstantValue(new Integer(1)));
  }
  return new SyntheticIR(this,Everywhere.EVERYWHERE,makeControlFlowGraph(),instrs,options,constants);
}

Fixed version (ground truth):
@Override public IR makeIR(SSAOptions options){
  SSAInstruction instrs[]=getStatements(options);
  Map<Integer,ConstantValue> constants=null;
  if (valueNumberForConstantOne > -1) {
    constants=HashMapFactory.make(1);
    constants.put(new Integer(valueNumberForConstantOne),new ConstantValue(new Integer(1)));
  }
  InducedCFG cfg=makeControlFlowGraph(instrs);
  return new SyntheticIR(this,Everywhere.EVERYWHERE,cfg,instrs,options,constants);
}
Program: 100119
Project: 100119
Buggy source:
@Override public IR makeIR(SSAOptions options){
  SSAInstruction instrs[]=getStatements(options);
  return new SyntheticIR(this,Everywhere.EVERYWHERE,makeControlFlowGraph(),instrs,options,summary.getConstants());
}

Fixed version (ground truth):
@Override public IR makeIR(SSAOptions options){
  SSAInstruction instrs[]=getStatements(options);
  return new SyntheticIR(this,Everywhere.EVERYWHERE,makeControlFlowGraph(instrs),instrs,options,summary.getConstants());
}
Program: 100120
Project: 100120
Buggy source:
/** 
 * Creates the union of two ordinal sets.
 * @param A ordinal set a
 * @param B ordinal set b
 * @return union of a and b
 * @throws IllegalArgumentException iff A or B is null
 */
public static <T>OrdinalSet<T> unify(OrdinalSet<T> A,OrdinalSet<T> B){
  if (A == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  if (B == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  if (Assertions.verifyAssertions) {
    if (A.size() != 0 && B.size() != 0) {
      Assertions._assert(A.mapping.equals(B.mapping));
    }
  }
  if (A.S != null && B.S == null) {
    return new OrdinalSet<T>(A.S,A.mapping);
  }
 else   if (A.S == null && B.S != null) {
    return new OrdinalSet<T>(B.S,B.mapping);
  }
  IntSet union=A.S.union(B.S);
  return new OrdinalSet<T>(union,A.mapping);
}

Fixed version (ground truth):
/** 
 * Creates the union of two ordinal sets.
 * @param A ordinal set a
 * @param B ordinal set b
 * @return union of a and b
 * @throws IllegalArgumentException iff A or B is null
 */
public static <T>OrdinalSet<T> unify(OrdinalSet<T> A,OrdinalSet<T> B){
  if (A == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  if (B == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  if (Assertions.verifyAssertions) {
    if (A.size() != 0 && B.size() != 0) {
      Assertions._assert(A.mapping.equals(B.mapping));
    }
  }
  if (A.S == null) {
    return (B.S == null) ? OrdinalSet.<T>empty() : new OrdinalSet<T>(B.S,B.mapping);
  }
 else   if (B.S == null) {
    return (A.S == null) ? OrdinalSet.<T>empty() : new OrdinalSet<T>(A.S,A.mapping);
  }
  IntSet union=A.S.union(B.S);
  return new OrdinalSet<T>(union,A.mapping);
}
Program: 100121
Project: 100121
Buggy source:
protected void addInstruction(final TypeReference T,SSAInstruction instr,boolean isAllocation){
  if (isAllocation) {
    if (types.contains(T))     return;
  }
  types.add(T);
  allInstructions.add(instr);
  if (isAllocation)   allocations.add(instr);
}

Fixed version (ground truth):
protected void addInstruction(final TypeReference T,SSAInstruction instr,boolean isAllocation){
  if (isAllocation) {
    if (typesAllocated.contains(T)) {
      return;
    }
 else {
      typesAllocated.add(T);
    }
  }
  allInstructions.add(instr);
  if (isAllocation) {
    allocations.add(instr);
  }
}
Program: 100122
Project: 100122
Buggy source:
/** 
 * @param type
 * @return a TypeAbstraction object representing this type. We just useConeTypes by default, since we don't propagate information allowing us to distinguish between points and cones yet.
 */
protected TypeAbstraction typeRef2TypeAbstraction(IClassHierarchy cha,TypeReference type){
  IClass klass=cha.lookupClass(type);
  if (klass != null) {
    return new ConeType(klass);
  }
  Assertions.UNREACHABLE(type.toString());
  return null;
}

Fixed version (ground truth):
/** 
 * @param type
 * @return a TypeAbstraction object representing this type. We just use ConeTypes by default, since we don't propagateinformation allowing us to distinguish between points and cones yet.
 */
protected TypeAbstraction typeRef2TypeAbstraction(IClassHierarchy cha,TypeReference type){
  IClass klass=cha.lookupClass(type);
  if (klass != null) {
    return new ConeType(klass);
  }
  Assertions.UNREACHABLE(type.toString());
  return null;
}
Program: 100123
Project: 100123
Buggy source:
protected int addStatementsForConcreteSimpleType(final TypeReference T){
  if (types.contains(T))   return -1;
  types.add(T);
  if (DEBUG) {
    Trace.println("String_Node_Str" + T);
  }
  NewSiteReference ref=NewSiteReference.make(getNewSiteForType(T),T);
  int alloc=getLocalForType(T);
  SSANewInstruction a=new SSANewInstruction(alloc,ref);
  if (DEBUG) {
    Trace.println("String_Node_Str" + a);
  }
  addInstruction(T,a,true);
  SSAReturnInstruction r=new SSAReturnInstruction(alloc,false);
  addInstruction(T,r,false);
  return alloc;
}

Fixed version (ground truth):
/** 
 * @param T
 * @return value number of the newly allocated object
 */
protected int addStatementsForConcreteSimpleType(final TypeReference T){
}
Program: 100125
Project: 100125
Buggy source:
private void addStatementsForSetOfTypes(Iterator it){
  if (!it.hasNext()) {
    SSAReturnInstruction r=new SSAReturnInstruction(nextLocal,false);
    allInstructions.add(r);
  }
  for (; it.hasNext(); ) {
    IClass klass=(IClass)it.next();
    TypeReference T=klass.getReference();
    if (klass.isAbstract() || types.contains(T)) {
      continue;
    }
    types.add(T);
    int i=getLocalForType(T);
    NewSiteReference ref=NewSiteReference.make(getNewSiteForType(T),T);
    SSANewInstruction a=null;
    if (T.isArrayType()) {
      int[] sizes=new int[T.getDimensionality()];
      initValueNumberForConstantOne();
      Arrays.fill(sizes,valueNumberForConstantOne);
      a=new SSANewInstruction(i,ref,sizes);
    }
 else {
      a=new SSANewInstruction(i,ref);
    }
    allocations.add(a);
    allInstructions.add(a);
    SSAReturnInstruction r=new SSAReturnInstruction(i,false);
    allInstructions.add(r);
    MethodReference init=MethodReference.findOrCreate(T,MethodReference.initAtom,MethodReference.defaultInitDesc);
    CallSiteReference site=CallSiteReference.make(getCallSiteForType(T),init,IInvokeInstruction.Dispatch.SPECIAL);
    int[] params=new int[1];
    params[0]=i;
    SSAInvokeInstruction s=new SSAInvokeInstruction(params,getExceptionsForType(T),site);
    calls.add(s);
    allInstructions.add(s);
  }
}

Fixed version (ground truth):
private void addStatementsForSetOfTypes(Iterator it){
  if (!it.hasNext()) {
    SSAReturnInstruction r=new SSAReturnInstruction(nextLocal,false);
    allInstructions.add(r);
  }
  for (; it.hasNext(); ) {
    IClass klass=(IClass)it.next();
    TypeReference T=klass.getReference();
    if (klass.isAbstract() || typesAllocated.contains(T)) {
      continue;
    }
    typesAllocated.add(T);
    int i=getLocalForType(T);
    NewSiteReference ref=NewSiteReference.make(getNewSiteForType(T),T);
    SSANewInstruction a=null;
    if (T.isArrayType()) {
      int[] sizes=new int[T.getDimensionality()];
      initValueNumberForConstantOne();
      Arrays.fill(sizes,valueNumberForConstantOne);
      a=new SSANewInstruction(i,ref,sizes);
    }
 else {
      a=new SSANewInstruction(i,ref);
    }
    allocations.add(a);
    allInstructions.add(a);
    SSAReturnInstruction r=new SSAReturnInstruction(i,false);
    allInstructions.add(r);
    MethodReference init=MethodReference.findOrCreate(T,MethodReference.initAtom,MethodReference.defaultInitDesc);
    CallSiteReference site=CallSiteReference.make(getCallSiteForType(T),init,IInvokeInstruction.Dispatch.SPECIAL);
    int[] params=new int[1];
    params[0]=i;
    SSAInvokeInstruction s=new SSAInvokeInstruction(params,getExceptionsForType(T),site);
    calls.add(s);
    allInstructions.add(s);
  }
}
Program: 100126
Project: 100126
Buggy source:
/** 
 * Solve the set of dataflow graph. <p> PRECONDITION: graph is set up
 * @return true iff the evaluation of some equation caused a change in thevalue of some variable.
 */
@SuppressWarnings("String_Node_Str") public boolean solve(IProgressMonitor monitor) throws CancelException {
  boolean globalChange=false;
  if (firstSolve) {
    initForFirstSolve();
  }
  while (!workList.isEmpty()) {
    MonitorUtil.worked(monitor,1);
    orderStatements();
    AbstractStatement s=workList.takeStatement();
    if (DEBUG) {
      Trace.println("String_Node_Str" + s);
    }
    byte code=s.evaluate();
    if (verbose) {
      nEvaluated++;
      if (nEvaluated % getVerboseInterval() == 0) {
        performVerboseAction();
      }
      if (nEvaluated % getPeriodicMaintainInterval() == 0) {
        periodicMaintenance();
      }
    }
    if (DEBUG) {
      Trace.println("String_Node_Str" + s + "String_Node_Str"+ isChanged(code));
    }
    if (isChanged(code)) {
      globalChange=true;
      updateWorkList(s);
    }
    if (isFixed(code)) {
      removeStatement(s);
    }
  }
  return globalChange;
}

Fixed version (ground truth):
/** 
 * Solve the set of dataflow graph. <p> PRECONDITION: graph is set up
 * @return true iff the evaluation of some equation caused a change in thevalue of some variable.
 */
@SuppressWarnings("String_Node_Str") public boolean solve(IProgressMonitor monitor) throws CancelException {
  boolean globalChange=false;
  if (firstSolve) {
    initForFirstSolve();
  }
  while (!workList.isEmpty()) {
    MonitorUtil.throwExceptionIfCanceled(monitor);
    orderStatements();
    AbstractStatement s=workList.takeStatement();
    if (DEBUG) {
      Trace.println("String_Node_Str" + s);
    }
    byte code=s.evaluate();
    if (verbose) {
      nEvaluated++;
      if (nEvaluated % getVerboseInterval() == 0) {
        performVerboseAction();
      }
      if (nEvaluated % getPeriodicMaintainInterval() == 0) {
        periodicMaintenance();
      }
    }
    if (DEBUG) {
      Trace.println("String_Node_Str" + s + "String_Node_Str"+ isChanged(code));
    }
    if (isChanged(code)) {
      globalChange=true;
      updateWorkList(s);
    }
    if (isFixed(code)) {
      removeStatement(s);
    }
  }
  return globalChange;
}
Program: 100127
Project: 100127
Buggy source:
/** 
 * @return a set of ConcreteTypeKeys that represent the exceptions the PEI may throw.
 */
public InstanceKey getInstanceKeyForPEI(CGNode node,ProgramCounter peiLoc,TypeReference type){
  return new ConcreteTypeKey(cha.lookupClass(type));
}

Fixed version (ground truth):
/** 
 * @return a set of ConcreteTypeKeys that represent the exceptions the PEI may throw.
 */
public InstanceKey getInstanceKeyForPEI(CGNode node,ProgramCounter peiLoc,TypeReference type){
  IClass klass=cha.lookupClass(type);
  if (klass == null) {
    return null;
  }
  return new ConcreteTypeKey(cha.lookupClass(type));
}
Program: 100129
Project: 100129
Buggy source:
/** 
 * Usage: GVSlice -appJar [jar file name] -mainClass [main class] -srcCaller [method name] -srcCallee [method name] -dd [data dependence options] -cd [control dependence options] -dir [forward|backward] <ul> <li> "jar file name" should be something like "c:/temp/testdata/java_cup.jar" <li> "main class" should beshould be something like "c:/temp/testdata/java_cup.jar" <li> "method name" should be the name of a method. This takes a slice from the statement that calls "srcCallee" from "srcCaller" <li> "data dependence options" can be one of "-full", "-no_base_ptrs", "-no_base_no_heap", "-no_heap", "-no_base_no_heap_no_cast", or "-none".
 * @throws CancelException
 * @throws IllegalArgumentException
 * @see com.ibm.wala.ipa.slicer.Slicer.DataDependenceOptions <li> "control dependence options" can be "-full" or "-none" <li> the -dir argument tells whether to compute a forwards or backwards slice. </ul>
 */
public static void main(String[] args) throws WalaException, IllegalArgumentException, CancelException {
  run(args);
}

Fixed version (ground truth):
/** 
 * Usage: GVSlice -appJar [jar file name] -mainClass [main class] -srcCaller [method name] -srcCallee [method name] -dd [data dependence options] -cd [control dependence options] -dir [forward|backward] <ul> <li> "jar file name" should be something like "c:/temp/testdata/java_cup.jar" <li> "main class" should beshould be something like "c:/temp/testdata/java_cup.jar" <li> "method name" should be the name of a method. This takes a slice from the statement that calls "srcCallee" from "srcCaller" <li> "data dependence options" can be one of "-full", "-no_base_ptrs", "-no_base_no_heap", "-no_heap", "-no_base_no_heap_no_cast", or "-none".
 * @throws CancelException
 * @throws IllegalArgumentException
 * @throws IOException 
 * @see com.ibm.wala.ipa.slicer.Slicer.DataDependenceOptions <li> "control dependence options" can be "-full" or "-none" <li> the -dir argument tells whether to compute a forwards or backwards slice. </ul>
 */
public static void main(String[] args) throws WalaException, IllegalArgumentException, CancelException, IOException {
  run(args);
}
Program: 100131
Project: 100131
Buggy source:
@Override public void visitPut(SSAPutInstruction instruction){
  IField f=pa.getClassHierarchy().resolveField(instruction.getDeclaredField());
  if (f != null) {
    if (instruction.isStatic()) {
      result.add(h.getPointerKeyForStaticField(f));
    }
 else {
      PointerKey ref=h.getPointerKeyForLocal(n,instruction.getRef());
      for (      InstanceKey i : pa.getPointsToSet(ref)) {
        result.add(h.getPointerKeyForInstanceField(i,f));
      }
    }
  }
}

Fixed version (ground truth):
@Override public void visitPut(SSAPutInstruction instruction){
  IField f=pa.getClassHierarchy().resolveField(instruction.getDeclaredField());
  if (f != null) {
    if (instruction.isStatic()) {
      result.add(h.getPointerKeyForStaticField(f));
    }
 else {
      PointerKey ref=h.getPointerKeyForLocal(n,instruction.getRef());
      if (ref != null) {
        for (        InstanceKey i : pa.getPointsToSet(ref)) {
          result.add(h.getPointerKeyForInstanceField(i,f));
        }
      }
    }
  }
}
Program: 100133
Project: 100133
Buggy source:
/** 
 * If the   {@link CallSiteReference} invokes Class.forName(s) and s is a string constant, return a{@link JavaTypeContext} representing the type named by s, if we can resolve it in the {@link IClassHierarchy}.
 * @see com.ibm.wala.ipa.callgraph.ContextSelector#getCalleeTarget(com.ibm.wala.ipa.callgraph.CGNode,com.ibm.wala.classLoader.CallSiteReference,com.ibm.wala.classLoader.IMethod,com.ibm.wala.ipa.callgraph.propagation.InstanceKey)
 */
public Context getCalleeTarget(CGNode caller,CallSiteReference site,IMethod callee,InstanceKey receiver){
  if (callee.equals(forNameMethod)) {
    IR ir=caller.getIR();
    SymbolTable symbolTable=ir.getSymbolTable();
    SSAAbstractInvokeInstruction[] invokeInstructions=caller.getIR().getCalls(site);
    if (invokeInstructions.length != 1) {
      return null;
    }
    int use=invokeInstructions[0].getUse(0);
    if (symbolTable.isStringConstant(use)) {
      String className=StringStuff.deployment2CanonicalTypeString(symbolTable.getStringValue(use));
      TypeReference t=TypeReference.findOrCreate(caller.getMethod().getDeclaringClass().getClassLoader().getReference(),className);
      IClass klass=caller.getClassHierarchy().lookupClass(t);
      if (klass != null) {
        return new JavaTypeContext(new PointType(klass));
      }
    }
  }
  return null;
}

Fixed version (ground truth):
/** 
 * If the   {@link CallSiteReference} invokes Class.forName(s) and s is a string constant, return a{@link JavaTypeContext} representing the type named by s, if we can resolve it in the {@link IClassHierarchy}.
 * @see com.ibm.wala.ipa.callgraph.ContextSelector#getCalleeTarget(com.ibm.wala.ipa.callgraph.CGNode,com.ibm.wala.classLoader.CallSiteReference,com.ibm.wala.classLoader.IMethod,com.ibm.wala.ipa.callgraph.propagation.InstanceKey)
 */
public Context getCalleeTarget(CGNode caller,CallSiteReference site,IMethod callee,InstanceKey receiver){
  if (callee.getReference().equals(ForNameContextInterpreter.FOR_NAME_REF)) {
    IR ir=caller.getIR();
    SymbolTable symbolTable=ir.getSymbolTable();
    SSAAbstractInvokeInstruction[] invokeInstructions=caller.getIR().getCalls(site);
    if (invokeInstructions.length != 1) {
      return null;
    }
    int use=invokeInstructions[0].getUse(0);
    if (symbolTable.isStringConstant(use)) {
      String className=StringStuff.deployment2CanonicalTypeString(symbolTable.getStringValue(use));
      TypeReference t=TypeReference.findOrCreate(caller.getMethod().getDeclaringClass().getClassLoader().getReference(),className);
      IClass klass=caller.getClassHierarchy().lookupClass(t);
      if (klass != null) {
        return new JavaTypeContext(new PointType(klass));
      }
    }
  }
  return null;
}
Program: 100134
Project: 100134
Buggy source:
public ForNameContextSelector(final IClassHierarchy cha){
}

Fixed version (ground truth):
public ForNameContextSelector(){
}
Program: 100135
Project: 100135
Buggy source:
/** 
 * This object may understand a dispatch to Class.forName(s) when s is a string constant.
 */
public boolean mayUnderstand(CGNode caller,CallSiteReference site,IMethod targetMethod,InstanceKey instance){
  if (targetMethod.equals(forNameMethod)) {
    IR ir=caller.getIR();
    SymbolTable symbolTable=ir.getSymbolTable();
    SSAAbstractInvokeInstruction[] invokeInstructions=caller.getIR().getCalls(site);
    if (invokeInstructions.length != 1) {
      return false;
    }
    int use=invokeInstructions[0].getUse(0);
    if (symbolTable.isStringConstant(use)) {
      return true;
    }
  }
  return false;
}

Fixed version (ground truth):
/** 
 * This object may understand a dispatch to Class.forName(s) when s is a string constant.
 */
public boolean mayUnderstand(CGNode caller,CallSiteReference site,IMethod targetMethod,InstanceKey instance){
  if (targetMethod.getReference().equals(ForNameContextInterpreter.FOR_NAME_REF)) {
    IR ir=caller.getIR();
    SymbolTable symbolTable=ir.getSymbolTable();
    SSAAbstractInvokeInstruction[] invokeInstructions=caller.getIR().getCalls(site);
    if (invokeInstructions.length != 1) {
      return false;
    }
    int use=invokeInstructions[0].getUse(0);
    if (symbolTable.isStringConstant(use)) {
      return true;
    }
  }
  return false;
}
Program: 100136
Project: 100136
Buggy source:
/** 
 * First check "forName" logic, then factory logic.
 */
private ReflectionContextSelector(IClassHierarchy cha,MethodTargetSelector methodTargetSelector){
  super(new ForNameContextSelector(cha),new FactoryContextSelector(cha,methodTargetSelector));
}

Fixed version (ground truth):
/** 
 * First check "forName" logic, then factory logic.
 */
private ReflectionContextSelector(IClassHierarchy cha,MethodTargetSelector methodTargetSelector){
  super(new ForNameContextSelector(),new FactoryContextSelector(cha,methodTargetSelector));
}
Program: 100137
Project: 100137
Buggy source:
@Override public void visitLoadClass(SSALoadClassInstruction instruction){
  PointerKey def=getPointerKeyForLocal(instruction.getDef());
  InstanceKey iKey=getInstanceKeyForClassObject(instruction.getLoadedClass());
  if (!contentsAreInvariant(symbolTable,du,instruction.getDef())) {
    system.newConstraint(def,iKey);
  }
 else {
    system.findOrCreateIndexForInstanceKey(iKey);
    system.recordImplicitPointsToSet(def);
  }
}

Fixed version (ground truth):
@Override public void visitLoadClass(SSALoadClassInstruction instruction){
  PointerKey def=getPointerKeyForLocal(instruction.getDef());
  InstanceKey iKey=getInstanceKeyForClassObject(instruction.getLoadedClass());
  IClass klass=getClassHierarchy().lookupClass(instruction.getLoadedClass());
  if (klass != null) {
    processClassInitializer(klass);
  }
  if (!contentsAreInvariant(symbolTable,du,instruction.getDef())) {
    system.newConstraint(def,iKey);
  }
 else {
    system.findOrCreateIndexForInstanceKey(iKey);
    system.recordImplicitPointsToSet(def);
  }
}
Program: 100138
Project: 100138
Buggy source:
/** 
 * Does m represent a static factory method we know about from the standard libraries, that we usually wish to model with one level of call-string context?
 */
public static boolean isWellKnownStaticFactory(MethodReference m){
  if (m.getDeclaringClass().equals(TypeReference.JavaLangSystem)) {
    if (m.getName().toString().equals("String_Node_Str")) {
      return true;
    }
  }
  if (m.equals(synthArraycopy)) {
    return true;
  }
  if (m.equals(ArraysAsList)) {
    return true;
  }
  if (m.equals(ArraysCopyOfRange)) {
    return true;
  }
  if (m.equals(ArraysCopyOf)) {
    return true;
  }
  if (m.equals(ArraysCopyOf2)) {
    return true;
  }
  if (m.equals(StringValueOf)) {
    return true;
  }
  return false;
}

Fixed version (ground truth):
/** 
 * Does m represent a static factory method we know about from the standard libraries, that we usually wish to model with one level of call-string context?
 */
public static boolean isWellKnownStaticFactory(MethodReference m){
  if (m.getDeclaringClass().equals(TypeReference.JavaLangSystem)) {
    if (m.getName().toString().equals("String_Node_Str")) {
      return true;
    }
  }
  if (m.equals(synthArraycopy)) {
    return true;
  }
  if (m.equals(ArraysAsList)) {
    return true;
  }
  if (m.equals(ArraysCopyOfRange)) {
    return true;
  }
  if (m.equals(ArraysCopyOf)) {
    return true;
  }
  if (m.equals(ArraysCopyOf2)) {
    return true;
  }
  if (m.equals(StringValueOf)) {
    return true;
  }
  if (m.equals(HashtableNewEntry)) {
    return true;
  }
  return false;
}
Program: 100139
Project: 100139
Buggy source:
/** 
 * Create nodes in the graph corresponding to in/out parameter passing for a call instruction
 */
private void addParamPassingStatements(int callIndex,Map<CGNode,OrdinalSet<PointerKey>> ref){
  SSAAbstractInvokeInstruction call=(SSAAbstractInvokeInstruction)node.getIR().getInstructions()[callIndex];
  Collection<Statement> params=MapUtil.findOrCreateSet(callerParamStatements,call.getCallSite());
  Collection<Statement> rets=MapUtil.findOrCreateSet(callerReturnStatements,call.getCallSite());
  for (int j=0; j < call.getNumberOfUses(); j++) {
    Statement st=new ParamCaller(node,callIndex,call.getUse(j));
    delegate.addNode(st);
    params.add(st);
  }
  if (!call.getDeclaredResultType().equals(TypeReference.Void)) {
    Statement st=new NormalReturnCaller(node,callIndex);
    delegate.addNode(st);
    rets.add(st);
  }
{
    if (!dOptions.isIgnoreExceptions()) {
      Statement st=new ExceptionalReturnCaller(node,callIndex);
      delegate.addNode(st);
      rets.add(st);
    }
  }
  if (!dOptions.isIgnoreHeap()) {
    OrdinalSet<PointerKey> uref=unionHeapLocations(cg,node,call,ref);
    for (    PointerKey p : uref) {
      Statement st=new HeapStatement.HeapParamCaller(node,callIndex,p);
      delegate.addNode(st);
      params.add(st);
    }
    OrdinalSet<PointerKey> umod=unionHeapLocations(cg,node,call,mod);
    for (    PointerKey p : umod) {
      Statement st=new HeapStatement.HeapReturnCaller(node,callIndex,p);
      delegate.addNode(st);
      rets.add(st);
    }
  }
}

Fixed version (ground truth):
/** 
 * Create nodes in the graph corresponding to in/out parameter passing for a call instruction
 */
private void addParamPassingStatements(int callIndex,Map<CGNode,OrdinalSet<PointerKey>> ref,IR ir){
  SSAAbstractInvokeInstruction call=(SSAAbstractInvokeInstruction)ir.getInstructions()[callIndex];
  Collection<Statement> params=MapUtil.findOrCreateSet(callerParamStatements,call.getCallSite());
  Collection<Statement> rets=MapUtil.findOrCreateSet(callerReturnStatements,call.getCallSite());
  for (int j=0; j < call.getNumberOfUses(); j++) {
    Statement st=new ParamCaller(node,callIndex,call.getUse(j));
    delegate.addNode(st);
    params.add(st);
  }
  if (!call.getDeclaredResultType().equals(TypeReference.Void)) {
    Statement st=new NormalReturnCaller(node,callIndex);
    delegate.addNode(st);
    rets.add(st);
  }
{
    if (!dOptions.isIgnoreExceptions()) {
      Statement st=new ExceptionalReturnCaller(node,callIndex);
      delegate.addNode(st);
      rets.add(st);
    }
  }
  if (!dOptions.isIgnoreHeap()) {
    OrdinalSet<PointerKey> uref=unionHeapLocations(cg,node,call,ref);
    for (    PointerKey p : uref) {
      Statement st=new HeapStatement.HeapParamCaller(node,callIndex,p);
      delegate.addNode(st);
      params.add(st);
    }
    OrdinalSet<PointerKey> umod=unionHeapLocations(cg,node,call,mod);
    for (    PointerKey p : umod) {
      Statement st=new HeapStatement.HeapReturnCaller(node,callIndex,p);
      delegate.addNode(st);
      rets.add(st);
    }
  }
}
Program: 100140
Project: 100140
Buggy source:
/** 
 * Create all data dependence edges in this PDG. Scalar dependences are taken from SSA def-use information. Heap dependences are computed by a reaching defs analysis.
 * @param pa
 * @param mod
 */
private void createScalarDataDependenceEdges(){
}

Fixed version (ground truth):
/** 
 * Create all data dependence edges in this PDG. Scalar dependences are taken from SSA def-use information. Heap dependences are computed by a reaching defs analysis.
 * @param pa
 * @param mod
 */
private void createScalarDataDependenceEdges(IR ir,Map<SSAInstruction,Integer> instructionIndices){
}
Program: 100141
Project: 100141
Buggy source:
/** 
 * Create nodes in the graph corresponding to "normal" (bytecode) instructions
 */
private Collection<SSAInstruction> createNormalStatements(IR ir,Map<CGNode,OrdinalSet<PointerKey>> ref){
  Collection<SSAInstruction> visited=HashSetFactory.make();
  SSAInstruction[] instructions=ir.getInstructions();
  for (int i=0; i < instructions.length; i++) {
    SSAInstruction s=instructions[i];
    if (s instanceof SSAGetCaughtExceptionInstruction) {
      continue;
    }
    if (s != null) {
      delegate.addNode(new NormalStatement(node,i));
      visited.add(s);
    }
    if (s instanceof SSAAbstractInvokeInstruction) {
      addParamPassingStatements(i,ref);
    }
  }
  return visited;
}

Fixed version (ground truth):
/** 
 * Create nodes in the graph corresponding to "normal" (bytecode) instructions
 */
private Collection<SSAInstruction> createNormalStatements(IR ir,Map<CGNode,OrdinalSet<PointerKey>> ref){
  Collection<SSAInstruction> visited=HashSetFactory.make();
  SSAInstruction[] instructions=ir.getInstructions();
  for (int i=0; i < instructions.length; i++) {
    SSAInstruction s=instructions[i];
    if (s instanceof SSAGetCaughtExceptionInstruction) {
      continue;
    }
    if (s != null) {
      delegate.addNode(new NormalStatement(node,i));
      visited.add(s);
    }
    if (s instanceof SSAAbstractInvokeInstruction) {
      addParamPassingStatements(i,ref,ir);
    }
  }
  return visited;
}
Program: 100142
Project: 100142
Buggy source:
/** 
 * Create all nodes in this PDG. Each node is a Statement.
 * @param dOptions
 */
private void createNodes(Map<CGNode,OrdinalSet<PointerKey>> ref,ControlDependenceOptions cOptions){
  IR ir=node.getIR();
  if (ir != null) {
    Collection<SSAInstruction> visited=createNormalStatements(ir,ref);
    createSpecialStatements(ir,visited);
  }
  createCalleeParams(ref);
  createReturnStatements();
  delegate.addNode(new MethodEntryStatement(node));
  delegate.addNode(new MethodExitStatement(node));
}

Fixed version (ground truth):
/** 
 * Create all nodes in this PDG. Each node is a Statement.
 */
private void createNodes(Map<CGNode,OrdinalSet<PointerKey>> ref,ControlDependenceOptions cOptions,IR ir){
  if (ir != null) {
    Collection<SSAInstruction> visited=createNormalStatements(ir,ref);
    createSpecialStatements(ir,visited);
  }
  createCalleeParams(ref);
  createReturnStatements();
  delegate.addNode(new MethodEntryStatement(node));
  delegate.addNode(new MethodExitStatement(node));
}
Program: 100143
Project: 100143
Buggy source:
private void createScalarEdges(ControlDependenceOptions cOptions){
  createScalarDataDependenceEdges();
  createControlDependenceEdges(cOptions);
}

Fixed version (ground truth):
private void createScalarEdges(ControlDependenceOptions cOptions,IR ir,Map<SSAInstruction,Integer> instructionIndices){
  createScalarDataDependenceEdges(ir,instructionIndices);
  createControlDependenceEdges(cOptions,ir,instructionIndices);
}
Program: 100144
Project: 100144
Buggy source:
public static synchronized Statement ssaInstruction2Statement(CGNode node,SSAInstruction s,Map<SSAInstruction,Integer> instructionIndices){
}

Fixed version (ground truth):
public static synchronized Statement ssaInstruction2Statement(CGNode node,SSAInstruction s,Map<SSAInstruction,Integer> instructionIndices,IR ir){
}
Program: 100145
Project: 100145
Buggy source:
/** 
 * Create all control dependence edges in this PDG.
 */
private void createControlDependenceEdges(ControlDependenceOptions cOptions){
}

Fixed version (ground truth):
/** 
 * Create all control dependence edges in this PDG.
 */
private void createControlDependenceEdges(ControlDependenceOptions cOptions,IR ir,Map<SSAInstruction,Integer> instructionIndices){
}
Program: 100146
Project: 100146
Buggy source:
private void populate(){
  if (!isPopulated) {
    isPopulated=true;
    instructionIndices=computeInstructionIndices(node.getIR());
    createNodes(ref,cOptions);
    createScalarEdges(cOptions);
  }
}

Fixed version (ground truth):
/** 
 * WARNING: Since we're using a   {@link HashMap} of {@link SSAInstruction}s, and equals() of   {@link SSAInstruction}assumes a canonical representative for each instruction, we <bf>must</bf> ensure that we use the same IR object throughout initialization!!
 */
private void populate(){
  if (!isPopulated) {
    IR ir=node.getIR();
    isPopulated=true;
    Map<SSAInstruction,Integer> instructionIndices=computeInstructionIndices(ir);
    createNodes(ref,cOptions,ir);
    createScalarEdges(cOptions,ir,instructionIndices);
  }
}
Program: 100149
Project: 100149
Buggy source:
public void testReflect1() throws WalaException, IllegalArgumentException, CancelException, IOException {
  AnalysisScope scope=CallGraphTestUtil.makeJ2SEAnalysisScope(TestConstants.WALA_TESTDATA,"String_Node_Str");
  ClassHierarchy cha=ClassHierarchy.make(scope);
  Iterable<Entrypoint> entrypoints=com.ibm.wala.ipa.callgraph.impl.Util.makeMainEntrypoints(scope,cha,TestConstants.REFLECT1_MAIN);
  AnalysisOptions options=CallGraphTestUtil.makeAnalysisOptions(scope,entrypoints);
  Warnings.clear();
  CallGraphTest.doCallGraphs(options,new AnalysisCache(),cha,scope,useShortProfile(),false);
  for (Iterator<Warning> it=Warnings.iterator(); it.hasNext(); ) {
    Warning w=(Warning)it.next();
    if (w.toString().indexOf("String_Node_Str") > 0) {
      continue;
    }
    if (w.toString().indexOf("String_Node_Str") >= 0) {
      assertTrue(w.toString(),false);
    }
  }
}

Fixed version (ground truth):
/** 
 * test that when analyzing Reflect1.main(), there is no warning about "Integer".
 */
public void testReflect1() throws WalaException, IllegalArgumentException, CancelException, IOException {
  AnalysisScope scope=CallGraphTestUtil.makeJ2SEAnalysisScope(TestConstants.WALA_TESTDATA,"String_Node_Str");
  ClassHierarchy cha=ClassHierarchy.make(scope);
  Iterable<Entrypoint> entrypoints=com.ibm.wala.ipa.callgraph.impl.Util.makeMainEntrypoints(scope,cha,TestConstants.REFLECT1_MAIN);
  AnalysisOptions options=CallGraphTestUtil.makeAnalysisOptions(scope,entrypoints);
  Warnings.clear();
  CallGraphTest.doCallGraphs(options,new AnalysisCache(),cha,scope,useShortProfile(),false);
  for (Iterator<Warning> it=Warnings.iterator(); it.hasNext(); ) {
    Warning w=(Warning)it.next();
    if (w.toString().indexOf("String_Node_Str") > 0) {
      continue;
    }
    if (w.toString().indexOf("String_Node_Str") >= 0) {
      assertTrue(w.toString(),false);
    }
  }
}
Program: 100150
Project: 100150
Buggy source:
/** 
 * handle possible updated flow in both directions for a call parameter
 * @param src
 * @param dst
 */
private void repropCallArg(PointerKeyAndState src,PointerKeyAndState dst,IFlowLabel dstToSrcLabel){
  for (  PointerKeyAndState srcToHandle : matchingPToQueried(dst,src.getPointerKey(),dstToSrcLabel)) {
    handleCopy(srcToHandle,dst,dstToSrcLabel.bar());
  }
  IntSet trackedSet=find(pkToTrackedSet,dst);
  if (!trackedSet.isEmpty()) {
    if (findOrCreate(pkToTrackedSet,src).addAll(trackedSet)) {
      addToTrackedPToWorklist(src);
    }
  }
}

Fixed version (ground truth):
/** 
 * handle possible updated flow in both directions for a call parameter
 * @param src
 * @param dst
 */
private void repropCallArg(PointerKeyAndState src,PointerKeyAndState dst,IFlowLabel dstToSrcLabel){
  if (DEBUG) {
  }
  for (  PointerKeyAndState srcToHandle : matchingPToQueried(dst,src.getPointerKey(),dstToSrcLabel)) {
    handleCopy(srcToHandle,dst,dstToSrcLabel.bar());
  }
  for (  PointerKeyAndState dstToHandle : matchingTrackedQueried(src,dst.getPointerKey(),dstToSrcLabel)) {
    IntSet trackedSet=find(pkToTrackedSet,dstToHandle);
    if (!trackedSet.isEmpty()) {
      if (findOrCreate(pkToTrackedSet,src).addAll(trackedSet)) {
        addToTrackedPToWorklist(src);
      }
    }
  }
}
Program: 100151
Project: 100151
Buggy source:
/** 
 * @return the points-to set of <code>pk</code>, or <code>null</code> ifthe points-to set can't be computed in the allocated budget
 */
public Collection<InstanceKey> getPointsTo(PointerKey pk){
  return getPointsTo(pk,Predicate.<Collection<InstanceKey>>falsePred()).snd;
}

Fixed version (ground truth):
/** 
 * @return the points-to set of <code>pk</code>, or <code>null</code> if the points-to set can't be computed inthe allocated budget
 */
public Collection<InstanceKey> getPointsTo(PointerKey pk){
  return getPointsTo(pk,Predicate.<Collection<InstanceKey>>falsePred()).snd;
}
Program: 100152
Project: 100152
Buggy source:
private void propagateToCallee(){
  if (caller.getIR() == null) {
    return;
  }
  g.addSubgraphForNode(caller);
  SSAAbstractInvokeInstruction[] callInstrs=ir.getCalls(call);
  for (int i=0; i < callInstrs.length; i++) {
    SSAAbstractInvokeInstruction callInstr=callInstrs[i];
    PointerKey actualPk=heapModel.getPointerKeyForLocal(caller,callInstr.getUse(paramPos));
    if (Assertions.verifyAssertions) {
      Assertions._assert(g.containsNode(actualPk));
      Assertions._assert(g.containsNode(localPk));
    }
    handler.handle(curPkAndState,actualPk,paramLabel);
  }
}

Fixed version (ground truth):
private void propagateToCallee(){
  g.addSubgraphForNode(caller);
  SSAAbstractInvokeInstruction[] callInstrs=ir.getCalls(call);
  for (int i=0; i < callInstrs.length; i++) {
    SSAAbstractInvokeInstruction callInstr=callInstrs[i];
    PointerKey actualPk=heapModel.getPointerKeyForLocal(caller,callInstr.getUse(paramPos));
    if (Assertions.verifyAssertions) {
      Assertions._assert(g.containsNode(actualPk));
      Assertions._assert(g.containsNode(localPk));
    }
    handler.handle(curPkAndState,actualPk,paramLabel);
  }
}