diff --git a/backends/vulkan/runtime/api/containers/Tensor.h b/backends/vulkan/runtime/api/containers/Tensor.h index 30c243aedd5..83c714bbc90 100644 --- a/backends/vulkan/runtime/api/containers/Tensor.h +++ b/backends/vulkan/runtime/api/containers/Tensor.h @@ -549,11 +549,11 @@ class vTensor final { return sizes_; } - inline const int64_t size(size_t dim) const { + inline int64_t size(size_t dim) const { return sizes().at(dim); } - inline const int64_t dim() const { + inline int64_t dim() const { return sizes_.size(); } diff --git a/extension/data_loader/mman.h b/extension/data_loader/mman.h index 9d3ee4be5aa..1d8df959692 100644 --- a/extension/data_loader/mman.h +++ b/extension/data_loader/mman.h @@ -81,9 +81,13 @@ ET_INLINE void fcntl_rdadvise_apple(int fd, size_t file_size) { #else +#ifndef NOMINMAX #define NOMINMAX #include #undef NOMINMAX +#else +#include +#endif #include #include diff --git a/extension/data_loader/mman_windows.cpp b/extension/data_loader/mman_windows.cpp index 9bc655a7827..67e211c4ca4 100644 --- a/extension/data_loader/mman_windows.cpp +++ b/extension/data_loader/mman_windows.cpp @@ -23,9 +23,13 @@ #include #include #include +#ifndef NOMINMAX #define NOMINMAX #include #undef NOMINMAX +#else +#include +#endif #ifndef STATUS_SECTION_TOO_BIG #define STATUS_SECTION_TOO_BIG 0xC0000040L diff --git a/runtime/core/portable_type/c10/c10/targets.bzl b/runtime/core/portable_type/c10/c10/targets.bzl index 4c49232ae5c..675c04f97a1 100644 --- a/runtime/core/portable_type/c10/c10/targets.bzl +++ b/runtime/core/portable_type/c10/c10/targets.bzl @@ -81,9 +81,10 @@ def define_common_targets(): "ovr_config//build_mode:arvr_mode[enabled]": select({ "DEFAULT": ["fbsource//xplat/caffe2:ovrsource_aten_Config.h"], # ovrsource_aten_Config.h is an oxx_static_library that only - # works on OVR-native platforms. On Android, it produces no - # outputs, so use the xplat variant instead. + # works on OVR-native platforms. On Android and the Windows + # host, it produces no outputs, so use the xplat variant. "ovr_config//os:android": ["fbsource//xplat/caffe2:generated_aten_config_header"], + "ovr_config//os:windows": ["fbsource//xplat/caffe2:generated_aten_config_header"], }), }) + get_sleef_deps(), fbcode_exported_deps = ([