@@ -45,42 +45,26 @@ jobs:
4545  get_runner :
4646    runs-on : ${{ inputs.runner }} 
4747    outputs :
48-       test_host : ${{ steps.runner-info.outputs.test_host }} 
49-       test_user : ${{ steps.runner-info.outputs.test_user }} 
50-       test_group : ${{ steps.runner-info.outputs.test_group }} 
48+       runner_id : ${{ steps.runner-info.outputs.runner_id }} 
49+       user_id : ${{ steps.runner-info.outputs.user_id }} 
50+       render_id : ${{ steps.runner-info.outputs.render_id }} 
51+       hostname : ${{ steps.runner-info.outputs.hostname }} 
5152    steps :
52-       - name : Get runner info 
53+       - name : Checkout torch-xpu-ops 
54+         uses : actions/checkout@v4 
55+       - name : Get runner 
5356        id : runner-info 
54-         run : | 
55-           # get test runner 
56-           echo "test_host=${RUNNER_NAME}" |tee -a ${GITHUB_OUTPUT} 
57-           echo "test_user=$(id -u)" |tee -a ${GITHUB_OUTPUT} 
58-           echo "test_group=$(getent group render |cut -d: -f3)" |tee -a ${GITHUB_OUTPUT} 
59-           # show host info 
60-           cat /etc/os-release 
61-           uname -a 
62-           source /opt/intel/oneapi/setvars.sh 
63-           sycl-ls 
64-           dpkg -l |grep -E 'libigc-dev|libze-dev|level-zero-dev' 
65- name : Cleanup workspace 
66-         if : ${{ always() }} 
67-         run : | 
68-           # clean docker cache 
69-           docker stop $(docker ps -aq) || true  
70-           docker system prune -af || true  
71-           # clean files 
72-           ls -al 
73-           sudo find ./ |grep -v "^\./$" |xargs sudo rm -rf 
57+         uses : ./.github/actions/get-runner 
7458
7559  biisect-search :
7660    needs : get_runner 
77-     runs-on : ${{ needs.get_runner.outputs.test_host  }} 
61+     runs-on : ${{ needs.get_runner.outputs.runner_id  }} 
7862    container :
7963      image : mengfeili/intel-pvc-driver:1146-1136 
8064      volumes :
8165        - ${{ github.workspace }}:${{ github.workspace }} 
8266      options : --device=/dev/mem --device=/dev/dri --group-add video --privileged --shm-size=8g 
83-               -u ${{ needs.get_runner.outputs.test_user  }}: ${{ needs.get_runner.outputs.test_group  }} 
67+               -u ${{ needs.get_runner.outputs.user_id  }} --group-add  ${{ needs.get_runner.outputs.render_id  }} 
8468      env :
8569        AGENT_TOOLSDIRECTORY : /tmp/xpu-tool 
8670        SEARCH_COMMITS : ${{ inputs.search_commits }} 
@@ -95,33 +79,19 @@ jobs:
9579       HF_TOKEN : ${{ secrets.HUGGING_FACE_HUB_TOKEN }} 
9680       HUGGING_FACE_HUB_TOKEN : ${{ secrets.HUGGING_FACE_HUB_TOKEN }} 
9781    steps :
98-       - name : Check runner 
99-         run : | 
100-           ls -al 
101-           sudo find ./ |grep -v "^\./$" |xargs sudo rm -rf 
102-           sudo rm -rf /tmp/xpu-tool 
103- name : Setup python-${{ inputs.python }} 
104-         uses : actions/setup-python@v5 
82+       - name : Checkout torch-xpu-ops 
83+         uses : actions/checkout@v4 
10584        with :
106-           python-version : ${{ inputs.python }} 
107-       - name : Check runner 
108-         run : | 
109-           hostname && whoami && id 
110-           clinfo --list 
111-           gcc -v && g++ -v 
112-           which python && which pip 
113-           python -V 
114-           pip install -U pip wheel setuptools 
115-           pip list 
116-           uname -a 
117-           dpkg -l |grep -E 'libigc-dev|libze-dev|level-zero-dev' 
118-           pip install cmake ninja pandas psutil scipy requests pybind11 
119-           mkdir gs-logs gs-search 
120-           echo "Status,Acc,Perf,PyTorch,Torch-xpu-ops" > gs-logs/summary.csv 
85+           path : gs-scripts 
86+       - name : Prepare test env 
87+         uses : ./gs-scripts/.github/actions/linux-testenv 
88+         with :
89+           pytorch : nightly_wheel 
90+           python : ${{ inputs.python }} 
12191      - name : Install oneAPI DLE 
12292        if : ${{ inputs.oneapi != 'installed' }} 
12393        run : | 
124-           rm -rf ~/intel ~/.intel /tmp /intel 
94+           rm -rf ~/intel ~/.intel ${HOME} /intel 
12595          if [ "${{ inputs.oneapi }}" == "2025.1" ];then 
12696            ONEAPI_URL="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/3435dc45-055e-4f7a-86b1-779931772404/intel-deep-learning-essentials-2025.1.3.7_offline.sh" 
12797          elif [ "${{ inputs.oneapi }}" == "2025.2" ];then 
@@ -130,42 +100,42 @@ jobs:
130100            ONEAPI_URL="${{ inputs.oneapi }}" 
131101          fi 
132102          wget -q -O oneapi.sh "${ONEAPI_URL}" 
133-           bash oneapi.sh -a -s --eula accept --action install --install-dir /tmp/intel/oneapi 
134-           echo "XPU_ONEAPI_PATH=/tmp/intel/oneapi" >> ${GITHUB_ENV} 
135- name : Checkout torch-xpu-ops 
136-         uses : actions/checkout@v4 
137-         with :
138-           path : gs-scripts 
139-       - name : Prepare source code 
103+           bash oneapi.sh -a -s --eula accept --action install --install-dir ${HOME}/intel/oneapi 
104+           echo "XPU_ONEAPI_PATH=${HOME}/intel/oneapi" >> ${GITHUB_ENV} 
105+ 
106+ name : Summary file 
140107        run : | 
141-           git clone https://github.com/pytorch/pytorch gs-pytorch 
142-           cd gs-pytorch 
108+           mkdir -p gs-logs 
109+           echo "Status,Acc,Perf,PyTorch,Torch-xpu-ops" > gs-logs/summary.csv 
110+ name : Get latest versions 
111+         run : | 
112+           cd pytorch 
143113          LATEST_PT_COMMIT="$(git rev-parse HEAD)" 
144-           cd .. 
145-           git clone https://github.com/intel/torch-xpu-ops gs-torch-xpu-ops 
146-           cd gs-torch-xpu-ops 
114+           cd third_party/torch-xpu-ops 
147115          LATEST_XPU_COMMIT="$(git rev-parse HEAD)" 
148-           cd .. 
149116          echo "LATEST_PT_COMMIT=${LATEST_PT_COMMIT}" >> ${GITHUB_ENV} 
150117          echo "LATEST_XPU_COMMIT=${LATEST_XPU_COMMIT}" >> ${GITHUB_ENV} 
151118name : Prepare test env 
152119        run : | 
153-           pip install -U torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/xpu 
154120          if [[ "${{ inputs.search_case }}" == *"benchmarks/dynamo/huggingface.py"* ]];then 
155-             pip install transformers==4.44.2  
121+             pip install transformers 
156122          elif [[ "${{ inputs.search_case }}" == *"benchmarks/dynamo/timm_models.py"* ]];then 
157-             pip install --no-deps git+https://github.com/huggingface/[email protected]  158-             pip install $(curl -sSL https://raw.githubusercontent.com/huggingface/pytorch-image-models/v1.0.14/requirements.txt | grep -vE torch) 
123+             pip install timm 
159124          elif [[ "${{ inputs.search_case }}" == *"benchmarks/dynamo/torchbench.py"* ]];then 
160125            model_name="$(echo ${{ inputs.search_case }} |sed 's+.*\--only *++;s/ .*//')" 
161126            git clone https://github.com/pytorch/benchmark gs-benchmark 
162127            cd gs-benchmark 
128+             pip install -r requirements.txt 
163129            echo "PYTHONPATH=${PWD}:${PYTHONPATH}" >> ${GITHUB_ENV} 
164130            python install.py ${model_name} 
165-           else 
166-             pip install -r gs-pytorch/.ci/docker/requirements-ci.txt 
131+             cd .. 
167132          fi 
168-           pip uninstall -y torch && pip uninstall -y torch 
133+           pip uninstall -y torchvision torchaudio 
134+           git clone https://github.com/pytorch/vision gs-vision 
135+           cd gs-vision 
136+           python setup.py install 
137+           cd .. 
138+           pip uninstall -y torch 
169139name : Bisect search pytorch 
170140        if : ${{ contains(inputs.search_commits, 'pytorch') }} 
171141        run : | 
@@ -186,7 +156,7 @@ jobs:
186156                  > ${{ github.workspace }}/gs-logs/search-${new_commit}-${LATEST_XPU_COMMIT}.log 2>&1 && echo $? || echo $?)" 
187157          new_result="$(tail -n 1 ${{ github.workspace }}/gs-search/result.csv)" 
188158          if [ "${old_status}" != "${new_status}" ];then 
189-             cd gs- pytorch 
159+             cd pytorch 
190160            git reset --hard 
191161            rsync -avz --delete ${{ github.workspace }}/gs-scripts/ gs-scripts/ 
192162            git bisect start ${new_commit} ${old_commit} 
@@ -219,7 +189,7 @@ jobs:
219189                  > ${{ github.workspace }}/gs-logs/search-${LATEST_PT_COMMIT}-${new_commit}.log && echo $? || echo $?)" 
220190          new_result="$(tail -n 1 ${{ github.workspace }}/gs-search/result.csv)" 
221191          if [ "${old_status}" != "${new_status}" ];then 
222-             cd gs- pytorch 
192+             cd pytorch 
223193            git reset --hard 
224194            rsync -avz --delete ${{ github.workspace }}/gs-scripts/ gs-scripts/ 
225195            git bisect start ${new_commit} ${old_commit} 
0 commit comments