Skip to content

Commit ffb9824

Browse files
suofacebook-github-bot
authored andcommitted
fold monarch_meta_extension into monarch_hyperactor (#476)
Summary: Pull Request resolved: #476 Kill the separate meta-only extension and fold it into the main monarch_extension, using conditional compilation to gate it. This eliminates an extra crate/shared object from our codebase. ghstack-source-id: 295034950 exported-using-ghexport Reviewed By: colin2328 Differential Revision: D77972861 fbshipit-source-id: 380d0ddfbac860b02f0b83f841d11c151ada9cd9
1 parent 6700cc1 commit ffb9824

File tree

3 files changed

+14
-24
lines changed

3 files changed

+14
-24
lines changed

monarch_extension/src/lib.rs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,17 @@ pub fn mod_init(module: &Bound<'_, PyModule>) -> PyResult<()> {
189189
"monarch_extension.blocking",
190190
)?)?;
191191

192+
#[cfg(fbcode_build)]
193+
{
194+
monarch_hyperactor::meta::alloc::register_python_bindings(&get_or_add_new_module(
195+
module,
196+
"monarch_hyperactor.meta.alloc",
197+
)?)?;
198+
monarch_hyperactor::meta::alloc_mock::register_python_bindings(&get_or_add_new_module(
199+
module,
200+
"monarch_hyperactor.meta.alloc_mock",
201+
)?)?;
202+
}
192203
// Add feature detection function
193204
module.add_function(wrap_pyfunction!(has_tensor_engine, module)?)?;
194205

monarch_hyperactor/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,6 @@ pub mod proc_mesh;
2121
pub mod runtime;
2222
pub mod selection;
2323
pub mod shape;
24+
25+
#[cfg(fbcode_build)]
26+
pub mod meta;

monarch_meta_extension/Cargo.toml

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

0 commit comments

Comments
 (0)