waitpid $pid, 0 == $pid or die $!;
die "$oldbatch $?" if $?;
unlink "b$oldbatch" or die "$oldbatch $!";
- print STDERR "check completed $oldbatch [$pid] #$cpu\n";
+# print STDERR "check completed $oldbatch [$pid] #$cpu\n";
push @freecpus, $cpu;
}
close $file or die $!;
- print STDERR "check closing $batch ($count)\n";
+# print STDERR "check closing $batch ($count)\n";
await_task unless @freecpus;
exec qw(eatmydata git update-ref --stdin);
die $!;
}
- print STDERR "check spawned $batch ($count) [$pid] #$cpu\n";
+# print STDERR "check spawned $batch ($count) [$pid] #$cpu\n";
push @tasks, [ $pid, $cpu, $batch ];
$batch++;
$file = undef;
$file ||= new IO::File "b$batch", ">" or die $!;
chomp;
print $file "delete refs/tags/$_\n" or die $!;
- $count++ < 100000 or complete_batch;
+ $count++ < 1000 or complete_batch;
}
#print STDERR "FOO\n";
STDIN->error and die $!;
complete_batch();
await_task while @tasks;
+ print STDERR "check happy all done\n";
'