Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion python/tvm/contrib/cc.py
Original file line number Diff line number Diff line change
Expand Up @@ -372,8 +372,11 @@ def _linux_compile(


def _windows_compile(output, objects, options, cwd=None, ccache_env=None):
cmd = ["clang"]
compiler = os.getenv("TVM_WIN_CC", default="clang")
win_target = os.getenv("TVM_WIN_TARGET", default="x86_64")
cmd = [compiler]
cmd += ["-O2"]
cmd += ["--target=" + win_target]

if output.endswith(".so") or output.endswith(".dll"):
cmd += ["-shared"]
Expand Down
15 changes: 11 additions & 4 deletions python/tvm/dlight/gpu/gemv.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""A rule for GEMV and DecodeGEMV."""
Expand Down Expand Up @@ -478,7 +478,9 @@ def apply(
TS, TR = 8, 64
else:
TS, TR = 1, 64
elif target.kind.name == "opencl" and "android" in str(target.host):
elif target.kind.name == "opencl" and (
("android" in str(target.host)) or ("adreno" in str(target.attrs))
):
TAG_S, TAG_R = "threadIdx.x", "threadIdx.y"
VEC_C = 8
LOAD_V_SHARED = False
Expand Down Expand Up @@ -686,7 +688,9 @@ def apply(
DEC_PACK = 8
SCALE_PACK = 4

if target.kind.name == "opencl" and "android" in str(target.host):
if target.kind.name == "opencl" and (
("android" in str(target.host)) or ("adreno" in str(target.attrs))
):
TAG_S, TAG_R = "threadIdx.x", "threadIdx.y"
VEC_C = 8
UNROLL = 8
Expand Down Expand Up @@ -756,7 +760,10 @@ def sch_outer_reduction_fallback( # pylint: disable=too-many-arguments, invalid
):
"""Schedule the outer reduction block."""
# NOTE: Only Android is supported so far
if not (target.kind.name == "opencl" and "android" in str(target.host)):
if not (
target.kind.name == "opencl"
and (("android" in str(target.host)) or ("adreno" in str(target.attrs)))
):
return None
batch, s, r, c = sch.get_loops(block)
len_s = get_extent(sch, s)
Expand Down