-
Notifications
You must be signed in to change notification settings - Fork 21.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update on "Add correct __all__ for torch.distributed and torch.cuda s…
…ubmodules" [ghstack-poisoned]
- Loading branch information
Showing
1,160 changed files
with
68,755 additions
and
42,769 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
#!/bin/bash | ||
|
||
set -ex | ||
|
||
# "install" hipMAGMA into /opt/rocm/magma by copying after build | ||
git clone https://bitbucket.org/icl/magma.git | ||
pushd magma | ||
# Fixes memory leaks of magma found while executing linalg UTs | ||
git checkout 5959b8783e45f1809812ed96ae762f38ee701972 | ||
cp make.inc-examples/make.inc.hip-gcc-mkl make.inc | ||
echo 'LIBDIR += -L$(MKLROOT)/lib' >> make.inc | ||
echo 'LIB += -Wl,--enable-new-dtags -Wl,--rpath,/opt/rocm/lib -Wl,--rpath,$(MKLROOT)/lib -Wl,--rpath,/opt/rocm/magma/lib' >> make.inc | ||
echo 'DEVCCFLAGS += --gpu-max-threads-per-block=256' >> make.inc | ||
export PATH="${PATH}:/opt/rocm/bin" | ||
if [[ -n "$PYTORCH_ROCM_ARCH" ]]; then | ||
amdgpu_targets=`echo $PYTORCH_ROCM_ARCH | sed 's/;/ /g'` | ||
else | ||
amdgpu_targets=`rocm_agent_enumerator | grep -v gfx000 | sort -u | xargs` | ||
fi | ||
for arch in $amdgpu_targets; do | ||
echo "DEVCCFLAGS += --amdgpu-target=$arch" >> make.inc | ||
done | ||
# hipcc with openmp flag may cause isnan() on __device__ not to be found; depending on context, compiler may attempt to match with host definition | ||
sed -i 's/^FOPENMP/#FOPENMP/g' make.inc | ||
make -f make.gen.hipMAGMA -j $(nproc) | ||
LANG=C.UTF-8 make lib/libmagma.so -j $(nproc) MKLROOT=/opt/conda | ||
make testing/testing_dgemm -j $(nproc) MKLROOT=/opt/conda | ||
popd | ||
mv magma /opt/rocm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,19 @@ | ||
#!/bin/bash | ||
set -ex -o pipefail | ||
|
||
if ! [ "$IOS_PLATFORM" == "SIMULATOR" ]; then | ||
exit 0 | ||
fi | ||
|
||
echo "" | ||
echo "DIR: $(pwd)" | ||
PROJ_ROOT=/Users/distiller/project | ||
cd ${PROJ_ROOT}/ios/TestApp | ||
# install fastlane | ||
sudo gem install bundler && bundle install | ||
# install certificates | ||
echo "${IOS_CERT_KEY_2022}" >> cert.txt | ||
base64 --decode cert.txt -o Certificates.p12 | ||
rm cert.txt | ||
bundle exec fastlane install_root_cert | ||
bundle exec fastlane install_dev_cert | ||
# install the provisioning profile | ||
PROFILE=PyTorch_CI_2022.mobileprovision | ||
PROVISIONING_PROFILES=~/Library/MobileDevice/Provisioning\ Profiles | ||
mkdir -pv "${PROVISIONING_PROFILES}" | ||
cd "${PROVISIONING_PROFILES}" | ||
echo "${IOS_SIGN_KEY_2022}" >> cert.txt | ||
base64 --decode cert.txt -o ${PROFILE} | ||
rm cert.txt | ||
# run the ruby build script | ||
if ! [ -x "$(command -v xcodebuild)" ]; then | ||
echo 'Error: xcodebuild is not installed.' | ||
exit 1 | ||
fi | ||
PROFILE=PyTorch_CI_2022 | ||
ruby ${PROJ_ROOT}/scripts/xcode_build.rb -i ${PROJ_ROOT}/build_ios/install -x ${PROJ_ROOT}/ios/TestApp/TestApp.xcodeproj -p ${IOS_PLATFORM} -c ${PROFILE} -t ${IOS_DEV_TEAM_ID} | ||
ruby ${PROJ_ROOT}/scripts/xcode_build.rb -i ${PROJ_ROOT}/build_ios/install -x ${PROJ_ROOT}/ios/TestApp/TestApp.xcodeproj -p ${IOS_PLATFORM} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.