File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -548,8 +548,8 @@ slog show_infor_text_2 "$show_infor_text_2"
548548<group>
549549<action icon="' ` urlpng cpu` ' " warning="' $project_text_13 ' " shell="hidden" >
550550<title>' $project_text_12 ' </title>
551- <param name="use_cpu " label="' $option_text ' " option-sh="seq 1 $(nproc --all)" value-sh="glog use_cpu" />
552- <set>slog use_cpu "$use_cpu "</set>
551+ <param name="use_cpus " label="' $option_text ' " option-sh="seq 1 $(nproc --all)" value-sh="glog use_cpu" />
552+ <set>slog use_cpu "$use_cpus "</set>
553553</action>
554554</group>'
555555}
Original file line number Diff line number Diff line change 7979
8080# Giới hạn cpu
8181if command -v taskset & > /dev/null; then
82- max_cpu =" $( nproc --all) "
83- use_cpu =" $( slog use_cpu $max_cpu ) "
84- if [ -n " $use_cpu " ] && [ " $use_cpu " -lt $max_cpu ]; then
85- mask =$(( (1 << use_cpu ) - 1 ))
86- mask_hex =" $( printf " %x" " $mask " ) "
87- taskset -p " $mask_hex " $$ & > /dev/null
82+ max_cpukkk =" $( nproc --all) "
83+ use_cpukkk =" $( glog use_cpu $max_cpukkk ) "
84+ if [ -n " $use_cpukkk " ] && [ " $use_cpukkk " -lt $max_cpukkk ]; then
85+ maskkkk =$(( (1 << use_cpukkk ) - 1 ))
86+ mask_hexkkkk =" $( printf " %x" " $maskkkk " ) "
87+ taskset -p " $mask_hexkkkk " $$ & > /dev/null
8888 fi
8989fi
9090
You can’t perform that action at this time.
0 commit comments