Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

metal lowbit kernels: replace ATEN by USE_ATEN #1263

Merged
merged 1 commit into from
Nov 12, 2024
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
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
* This file is generated by gen_metal_shader_lib.py
*/

#ifdef ATEN
#ifdef USE_ATEN
using namespace at::native::mps;
#else
#include <torchao/experimental/kernels/mps/src/OperationUtils.h>
Expand Down
2 changes: 1 addition & 1 deletion torchao/experimental/kernels/mps/src/lowbit.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
#include <fstream>
#include <sstream>

#ifdef ATEN
#ifdef USE_ATEN
#include <ATen/native/mps/OperationUtils.h>
using namespace at::native::mps;
inline void finalize_block(MPSStream* mpsStream) {}
Expand Down
2 changes: 1 addition & 1 deletion torchao/experimental/ops/mps/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
name="torchao_mps_ops",
sources=["register.mm"],
include_dirs=[os.getenv("TORCHAO_ROOT")],
extra_compile_args=["-DATEN=1"],
extra_compile_args=["-DUSE_ATEN=1"],
),
],
cmdclass={"build_ext": BuildExtension},
Expand Down
Loading