Skip to content

Commit a93f3de

Browse files
committed
Merge remote-tracking branch 'upstream/master' into remove-chain_matmul
2 parents 8c21b97 + 89d6f3e commit a93f3de

2,580 files changed

Lines changed: 201811 additions & 89851 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.bazelrc

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
1-
build --copt=--std=c++14
1+
build --cxxopt=--std=c++14
22
build --copt=-I.
3+
# Bazel does not support including its cc_library targets as system
4+
# headers. We work around this for generated code
5+
# (e.g. c10/macros/cmake_macros.h) by making the generated directory a
6+
# system include path.
37
build --copt=-isystem --copt bazel-out/k8-fastbuild/bin
8+
build --copt=-isystem --copt bazel-out/darwin-fastbuild/bin
49
build --experimental_ui_max_stdouterr_bytes=2048576
510

611
# Configuration to disable tty features for environments like CI
@@ -12,6 +17,9 @@ build:no-tty --show_progress_rate_limit 10
1217
build:gpu --define=cuda=true
1318
# define a separate build folder for faster switching between configs
1419
build:gpu --platform_suffix=-gpu
20+
# See the note on the config-less build for details about why we are
21+
# doing this. We must also do it for the "-gpu" platform suffix.
22+
build --copt=-isystem --copt=bazel-out/k8-fastbuild-gpu/bin
1523
# rules_cuda configuration
1624
build:gpu --@rules_cuda//cuda:enable_cuda
1725
build:gpu --@rules_cuda//cuda:cuda_targets=sm_52

.circleci/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -71,9 +71,9 @@ A **binary configuration** is a collection of
7171
* release or nightly
7272
* releases are stable, nightlies are beta and built every night
7373
* python version
74-
* linux: 3.5m, 3.6m 3.7m (mu is wide unicode or something like that. It usually doesn't matter but you should know that it exists)
75-
* macos: 3.6, 3.7, 3.8
76-
* windows: 3.6, 3.7, 3.8
74+
* linux: 3.7m (mu is wide unicode or something like that. It usually doesn't matter but you should know that it exists)
75+
* macos: 3.7, 3.8
76+
* windows: 3.7, 3.8
7777
* cpu version
7878
* cpu, cuda 9.0, cuda 10.0
7979
* The supported cuda versions occasionally change
@@ -428,7 +428,7 @@ docker run \
428428
# possibly need are in .circleci/scripts/binary_populate_env.sh
429429
# You should probably always export at least these 3 variables
430430
export PACKAGE_TYPE=conda
431-
export DESIRED_PYTHON=3.6
431+
export DESIRED_PYTHON=3.7
432432
export DESIRED_CUDA=cpu
433433

434434
# Call the entrypoint
@@ -476,7 +476,7 @@ conda activate binary
476476
# possibly need are in .circleci/scripts/binary_populate_env.sh
477477
# You should probably always export at least these 3 variables
478478
export PACKAGE_TYPE=conda
479-
export DESIRED_PYTHON=3.6
479+
export DESIRED_PYTHON=3.7
480480
export DESIRED_CUDA=cpu
481481

482482
# Call the entrypoint you want

.circleci/cimodel/data/binary_build_data.py

Lines changed: 0 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -30,49 +30,7 @@ def get_processor_arch_name(gpu_version):
3030
"cu" + gpu_version.strip("cuda") if gpu_version.startswith("cuda") else gpu_version
3131
)
3232

33-
LINUX_PACKAGE_VARIANTS = OrderedDict(
34-
manywheel=[
35-
"3.6m",
36-
"3.7m",
37-
"3.8m",
38-
"3.9m"
39-
],
40-
conda=dimensions.STANDARD_PYTHON_VERSIONS,
41-
libtorch=[
42-
"3.7m",
43-
],
44-
)
45-
4633
CONFIG_TREE_DATA = OrderedDict(
47-
linux=(dimensions.GPU_VERSIONS, LINUX_PACKAGE_VARIANTS),
48-
macos=([None], OrderedDict(
49-
wheel=dimensions.STANDARD_PYTHON_VERSIONS,
50-
conda=dimensions.STANDARD_PYTHON_VERSIONS,
51-
libtorch=[
52-
"3.7",
53-
],
54-
)),
55-
macos_arm64=([None], OrderedDict(
56-
wheel=[
57-
"3.8",
58-
"3.9",
59-
],
60-
conda=[
61-
"3.8",
62-
"3.9",
63-
],
64-
)),
65-
windows=(
66-
# Stop building Win+CU102, see https://github.com/pytorch/pytorch/issues/65648
67-
[v for v in dimensions.GPU_VERSIONS if v not in dimensions.ROCM_VERSION_LABELS and v != "cuda102"],
68-
OrderedDict(
69-
wheel=dimensions.STANDARD_PYTHON_VERSIONS,
70-
conda=dimensions.STANDARD_PYTHON_VERSIONS,
71-
libtorch=[
72-
"3.7",
73-
],
74-
)
75-
),
7634
)
7735

7836
# GCC config variants:

.circleci/cimodel/data/dimensions.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,13 @@
22

33
CUDA_VERSIONS = [
44
"102",
5-
"111",
65
"113",
76
"115",
87
]
98

109
ROCM_VERSIONS = [
11-
"4.1",
12-
"4.2",
1310
"4.3.1",
11+
"4.5.2",
1412
]
1513

1614
ROCM_VERSION_LABELS = ["rocm" + v for v in ROCM_VERSIONS]
@@ -20,5 +18,6 @@
2018
STANDARD_PYTHON_VERSIONS = [
2119
"3.7",
2220
"3.8",
23-
"3.9"
21+
"3.9",
22+
"3.10"
2423
]

.circleci/cimodel/data/pytorch_build_definitions.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -334,13 +334,12 @@ def instantiate_configs(only_slow_gradcheck):
334334
build_only=build_only,
335335
)
336336

337-
# run docs builds on "pytorch-linux-xenial-py3.6-gcc5.4". Docs builds
337+
# run docs builds on "pytorch-linux-xenial-py3.7-gcc5.4". Docs builds
338338
# should run on a CPU-only build that runs on all PRs.
339-
# XXX should this be updated to a more modern build? Projects are
340-
# beginning to drop python3.6
339+
# XXX should this be updated to a more modern build?
341340
if (
342341
distro_name == "xenial"
343-
and fc.find_prop("pyver") == "3.6"
342+
and fc.find_prop("pyver") == "3.7"
344343
and cuda_version is None
345344
and parallel_backend is None
346345
and not is_vulkan
Lines changed: 103 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,103 @@
1+
import cimodel.data.simple.util.branch_filters as branch_filters
2+
from cimodel.data.simple.util.docker_constants import (
3+
DOCKER_IMAGE_NDK, DOCKER_REQUIREMENT_NDK
4+
)
5+
6+
7+
class AndroidJob:
8+
def __init__(self,
9+
variant,
10+
template_name,
11+
is_master_only=True):
12+
13+
self.variant = variant
14+
self.template_name = template_name
15+
self.is_master_only = is_master_only
16+
17+
def gen_tree(self):
18+
19+
base_name_parts = [
20+
"pytorch",
21+
"linux",
22+
"xenial",
23+
"py3",
24+
"clang5",
25+
"android",
26+
"ndk",
27+
"r19c",
28+
] + self.variant + [
29+
"build",
30+
]
31+
32+
full_job_name = "_".join(base_name_parts)
33+
build_env_name = "-".join(base_name_parts)
34+
35+
props_dict = {
36+
"name": full_job_name,
37+
"build_environment": "\"{}\"".format(build_env_name),
38+
"docker_image": "\"{}\"".format(DOCKER_IMAGE_NDK),
39+
"requires": [DOCKER_REQUIREMENT_NDK]
40+
}
41+
42+
if self.is_master_only:
43+
props_dict["filters"] = branch_filters.gen_filter_dict(branch_filters.NON_PR_BRANCH_LIST)
44+
45+
return [{self.template_name: props_dict}]
46+
47+
48+
class AndroidGradleJob:
49+
def __init__(self,
50+
job_name,
51+
template_name,
52+
dependencies,
53+
is_master_only=True,
54+
is_pr_only=False,
55+
extra_props=tuple()):
56+
57+
self.job_name = job_name
58+
self.template_name = template_name
59+
self.dependencies = dependencies
60+
self.is_master_only = is_master_only
61+
self.is_pr_only = is_pr_only
62+
self.extra_props = dict(extra_props)
63+
64+
def gen_tree(self):
65+
66+
props_dict = {
67+
"name": self.job_name,
68+
"requires": self.dependencies,
69+
}
70+
71+
if self.is_master_only:
72+
props_dict["filters"] = branch_filters.gen_filter_dict(branch_filters.NON_PR_BRANCH_LIST)
73+
elif self.is_pr_only:
74+
props_dict["filters"] = branch_filters.gen_filter_dict(branch_filters.PR_BRANCH_LIST)
75+
if self.extra_props:
76+
props_dict.update(self.extra_props)
77+
78+
return [{self.template_name: props_dict}]
79+
80+
81+
WORKFLOW_DATA = [
82+
AndroidJob(["x86_32"], "pytorch_linux_build", is_master_only=False),
83+
AndroidJob(["x86_64"], "pytorch_linux_build"),
84+
AndroidJob(["arm", "v7a"], "pytorch_linux_build"),
85+
AndroidJob(["arm", "v8a"], "pytorch_linux_build"),
86+
AndroidGradleJob(
87+
"pytorch-linux-xenial-py3-clang5-android-ndk-r19c-gradle-build-x86_32",
88+
"pytorch_android_gradle_build-x86_32",
89+
["pytorch_linux_xenial_py3_clang5_android_ndk_r19c_x86_32_build"],
90+
is_master_only=False,
91+
is_pr_only=True),
92+
AndroidGradleJob(
93+
"pytorch-linux-xenial-py3-clang5-android-ndk-r19c-gradle-build",
94+
"pytorch_android_gradle_build",
95+
["pytorch_linux_xenial_py3_clang5_android_ndk_r19c_x86_32_build",
96+
"pytorch_linux_xenial_py3_clang5_android_ndk_r19c_x86_64_build",
97+
"pytorch_linux_xenial_py3_clang5_android_ndk_r19c_arm_v7a_build",
98+
"pytorch_linux_xenial_py3_clang5_android_ndk_r19c_arm_v8a_build"]),
99+
]
100+
101+
102+
def get_workflow_jobs():
103+
return [item.gen_tree() for item in WORKFLOW_DATA]

.circleci/cimodel/data/simple/bazel_definitions.py

Lines changed: 0 additions & 69 deletions
This file was deleted.

0 commit comments

Comments
 (0)