61 lines
1.3 KiB
Bash
Executable File
61 lines
1.3 KiB
Bash
Executable File
#!/bin/bash
|
|
|
|
SEND_THREAD_NUM=1
|
|
tmp_fifofile="/tmp/$$.fifo" # 脚本运行的当前进程ID号作为文件名
|
|
mkfifo "$tmp_fifofile" # 新建一个随机fifo管道文件
|
|
exec 6<>"$tmp_fifofile" # 定义文件描述符6指向这个fifo管道文件
|
|
rm $tmp_fifofile
|
|
for i in $(seq 1 $SEND_THREAD_NUM)
|
|
do
|
|
echo # for循环 往 fifo管道文件中写入 $SEND_THREAD_NUM 个空行
|
|
done >&6
|
|
|
|
CUTOFF_TIME=3600
|
|
|
|
instance1="/pub/data/chenzh/data/sat2022"
|
|
|
|
res_sat1="./exp-result"
|
|
|
|
res_no="./unused"
|
|
#####################################################
|
|
|
|
ulimit -t 3600
|
|
|
|
all_datas=($instance1)
|
|
res_dir=($res_sat1)
|
|
for((i=0;i<${#all_datas[*]};i++))
|
|
do
|
|
instance=${all_datas[$i]}
|
|
res_solver_ins=${res_dir[$i]}
|
|
if [ ! -d "$res_solver_ins" ]; then
|
|
mkdir -p $res_solver_ins
|
|
fi
|
|
for dir_file in `cat $instance/all.txt`
|
|
do
|
|
file=$dir_file
|
|
echo $file
|
|
touch $res_solver_ins/$file
|
|
read -u 6
|
|
{
|
|
cd /home/qianyh/projects/Light
|
|
mpirun -np 9 --allow-run-as-root ./light -i $instance/$file --share=1 --threads=32 --times=$CUTOFF_TIME
|
|
echo >&6
|
|
} >$res_solver_ins/$file &
|
|
done
|
|
done
|
|
|
|
# res_solver_ins=$res_no
|
|
# if [ ! -d "$res_solver_ins" ]; then
|
|
# mkdir -p $res_solver_ins
|
|
# fi
|
|
# for((i=0;i<96;i++))
|
|
# do
|
|
# read -u 6
|
|
# {
|
|
# cd /home/chenzh/solvers/sota/kissat-MAB/build
|
|
# ./kissat /home/chenzh/data/hard_cnfs/49.cnf
|
|
# echo >&6
|
|
# } >$res_solver_ins/$i &
|
|
# done
|
|
|
|
exit 0 |