Program: 35751
Project: 35751
Buggy source:
private boolean route(BlockBuffer buffer,Net net,Net.Terminal source,Net.Terminal dest,boolean reverse){
  if (source.x == dest.x && source.y == dest.y && source.z == dest.z) {
    return true;
  }
  HashMap<Long,Node> explored=new HashMap<Long,Node>();
  PriorityQueue<Node> queue=new PriorityQueue<Node>();
  queue.add(new Node(0,new Net.Wire(source.x,source.y,source.z,false,0),null));
  int count=0;
  while (!queue.isEmpty()) {
    Node node=queue.remove();
    if (isDest(node.wire.x,node.wire.y,node.wire.z,buffer,net,dest)) {
      commitRoute(buffer,net,node);
      return true;
    }
    boolean needRepeater=false;
    count++;
    if (count == 1000) {
      log2("String_Node_Str");
      commitRoute(buffer,net,node);
      return true;
    }
    if (queue.size() > 2000000) {
      log2("String_Node_Str");
      return false;
    }
    for (int i=0; i < 12; i++) {
      int x=node.wire.x;
      int y=node.wire.y;
      int z=node.wire.z;
switch (i) {
case 0:
        x++;
      break;
case 1:
    x--;
  break;
case 2:
z++;
break;
case 3:
z--;
break;
case 4:
if (needRepeater) {
break;
}
x++;
y++;
break;
case 5:
x--;
y++;
break;
case 6:
z++;
y++;
break;
case 7:
z--;
y++;
break;
case 8:
x++;
y--;
break;
case 9:
x--;
y--;
break;
case 10:
z++;
y--;
break;
case 11:
z--;
y--;
break;
}
if (y != node.wire.y && isDest(x,y,z,buffer,net,dest)) {
break;
}
if (canPlaceWire(buffer,net,node,dest,x,y,z)) {
int g;
if (i >= 4) {
g=1;
}
 else {
g=1;
}
long hash=getCoordinateHash(buffer,x,y,z);
Node child=explored.get(hash);
if (child != null) {
if (child.cost > node.cost + g) {
queue.remove(child);
child.cost=node.cost + g;
queue.add(child);
}
}
 else {
child=new Node(node.cost + g,new Wire(x,y,z,false,0),node);
queue.add(child);
explored.put(hash,child);
}
}
}
}
return false;
}

Fixed version (ground truth):
private boolean route(BlockBuffer buffer,Net net,Net.Terminal source,Net.Terminal dest,boolean reverse){
  if (source.x == dest.x && source.y == dest.y && source.z == dest.z) {
    return true;
  }
  HashMap<Long,Node> explored=new HashMap<Long,Node>();
  PriorityQueue<Node> queue=new PriorityQueue<Node>();
  queue.add(new Node(0,new Net.Wire(source.x,source.y,source.z,false,0),null));
  int count=0;
  while (!queue.isEmpty()) {
    Node node=queue.remove();
    if (isDest(node.wire.x,node.wire.y,node.wire.z,buffer,net,dest)) {
      commitRoute(buffer,net,node,true);
      return true;
    }
    boolean needRepeater=false;
    for (int i=0; i < 12; i++) {
      int x=node.wire.x;
      int y=node.wire.y;
      int z=node.wire.z;
switch (i) {
case 0:
        x++;
      break;
case 1:
    x--;
  break;
case 2:
z++;
break;
case 3:
z--;
break;
case 4:
if (needRepeater) {
break;
}
x++;
y++;
break;
case 5:
x--;
y++;
break;
case 6:
z++;
y++;
break;
case 7:
z--;
y++;
break;
case 8:
x++;
y--;
break;
case 9:
x--;
y--;
break;
case 10:
z++;
y--;
break;
case 11:
z--;
y--;
break;
}
boolean good;
if (isDest(x,y,z,buffer,net,dest)) {
if (y != node.wire.y) {
break;
}
 else {
good=true;
}
}
 else {
good=canPlaceWire(buffer,net,node,dest,x,y,z);
}
if (good) {
int g;
if (i >= 4) {
g=1;
}
 else {
g=1;
}
if (count == debugCutoff) {
buffer.setBlock(x,y,z,Blocks.dirt,0);
}
long hash=getCoordinateHash(buffer,x,y,z);
Node child=explored.get(hash);
if (child != null) {
if (child.cost > node.cost + g) {
queue.remove(child);
child.cost=node.cost + g;
queue.add(child);
}
}
 else {
child=new Node(node.cost + g,new Wire(x,y,z,false,0),node);
queue.add(child);
explored.put(hash,child);
}
}
}
count++;
if (count > debugCutoff) {
log2("String_Node_Str" + node.cost);
commitRoute(buffer,net,node,false);
return true;
}
if (queue.size() > 2000000) {
log2("String_Node_Str");
return false;
}
}
log2("String_Node_Str" + count + "String_Node_Str");
return false;
}