-
Couldn't load subscription status.
- Fork 700
Bump pinned PT commit to 20250616 and mirror torch/standalone to ExecuTorch #11791
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
Closed
Closed
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
aafc798
Bump pinned PT commit to 20250617 and mirror torch/standalone to Exec…
swolchok c16a48b
roll back a day to 0616 on "Bump pinned PT commit to 20250617 and mir…
swolchok e597789
upgrade cmake on "Bump pinned PT commit to 20250616 and mirror torch/…
swolchok 7669c51
rebase on "Bump pinned PT commit to 20250616 and mirror torch/standal…
swolchok 973e62f
remove conda hack per devinfra on "Bump pinned PT commit to 20250616 …
swolchok 417cede
scope hack to non-aarch64 on "Bump pinned PT commit to 20250616 and m…
swolchok 5e8be91
Update on "Bump pinned PT commit to 20250616 and mirror torch/standal…
swolchok File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1 @@ | ||
| 5616fa4a68718ead203314a3467f7dd9547153ae | ||
| c620d0b5c7e8679413d620624725471223ce8359 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,4 @@ | ||
| cmake=3.26.4 | ||
| cmake=3.31.2 | ||
| ninja=1.10.2 | ||
| libuv | ||
| llvm-openmp | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| load(":targets.bzl", "define_common_targets") | ||
|
|
||
| oncall("executorch") | ||
|
|
||
| define_common_targets() |
87 changes: 87 additions & 0 deletions
87
runtime/core/portable_type/c10/torch/standalone/macros/Export.h
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,87 @@ | ||
| #pragma once | ||
|
|
||
| /* Header file to define the common scaffolding for exported symbols. | ||
| * | ||
| * Export is by itself a quite tricky situation to deal with, and if you are | ||
| * hitting this file, make sure you start with the background here: | ||
| * - Linux: https://gcc.gnu.org/wiki/Visibility | ||
| * - Windows: | ||
| * https://docs.microsoft.com/en-us/cpp/cpp/dllexport-dllimport?view=vs-2017 | ||
| * | ||
| * Do NOT include this file directly. Instead, use c10/macros/Macros.h | ||
| */ | ||
|
|
||
| // You do not need to edit this part of file unless you are changing the core | ||
| // pytorch export abstractions. | ||
| // | ||
| // This part defines the C10 core export and import macros. This is controlled | ||
| // by whether we are building shared libraries or not, which is determined | ||
| // during build time and codified in c10/core/cmake_macros.h. | ||
| // When the library is built as a shared lib, EXPORT and IMPORT will contain | ||
| // visibility attributes. If it is being built as a static lib, then EXPORT | ||
| // and IMPORT basically have no effect. | ||
|
|
||
| // As a rule of thumb, you should almost NEVER mix static and shared builds for | ||
| // libraries that depend on c10. AKA, if c10 is built as a static library, we | ||
| // recommend everything dependent on c10 to be built statically. If c10 is built | ||
| // as a shared library, everything dependent on it should be built as shared. In | ||
| // the PyTorch project, all native libraries shall use the macro | ||
| // C10_BUILD_SHARED_LIB to check whether pytorch is building shared or static | ||
| // libraries. | ||
|
|
||
| // For build systems that do not directly depend on CMake and directly build | ||
| // from the source directory (such as Buck), one may not have a cmake_macros.h | ||
| // file at all. In this case, the build system is responsible for providing | ||
| // correct macro definitions corresponding to the cmake_macros.h.in file. | ||
| // | ||
| // In such scenarios, one should define the macro | ||
| // C10_USING_CUSTOM_GENERATED_MACROS | ||
| // to inform this header that it does not need to include the cmake_macros.h | ||
| // file. | ||
|
|
||
| #ifdef _WIN32 | ||
| #define C10_HIDDEN | ||
| #if defined(C10_BUILD_SHARED_LIBS) | ||
| #define C10_EXPORT __declspec(dllexport) | ||
| #define C10_IMPORT __declspec(dllimport) | ||
| #else | ||
| #define C10_EXPORT | ||
| #define C10_IMPORT | ||
| #endif | ||
| #else // _WIN32 | ||
| #if defined(__GNUC__) | ||
| #define C10_EXPORT __attribute__((__visibility__("default"))) | ||
| #define C10_HIDDEN __attribute__((__visibility__("hidden"))) | ||
| #else // defined(__GNUC__) | ||
| #define C10_EXPORT | ||
| #define C10_HIDDEN | ||
| #endif // defined(__GNUC__) | ||
| #define C10_IMPORT C10_EXPORT | ||
| #endif // _WIN32 | ||
|
|
||
| #ifdef NO_EXPORT | ||
| #undef C10_EXPORT | ||
| #define C10_EXPORT | ||
| #endif | ||
|
|
||
| // Definition of an adaptive XX_API macro, that depends on whether you are | ||
| // building the library itself or not, routes to XX_EXPORT and XX_IMPORT. | ||
| // Basically, you will need to do this for each shared library that you are | ||
| // building, and the instruction is as follows: assuming that you are building | ||
| // a library called libawesome.so. You should: | ||
| // (1) for your cmake target (usually done by "add_library(awesome, ...)"), | ||
| // define a macro called AWESOME_BUILD_MAIN_LIB using | ||
| // target_compile_options. | ||
| // (2) define the AWESOME_API macro similar to the one below. | ||
| // And in the source file of your awesome library, use AWESOME_API to | ||
| // annotate public symbols. | ||
|
|
||
| // Here, for the C10 library, we will define the macro C10_API for both import | ||
| // and export. | ||
|
|
||
| // This one is being used by libc10.so | ||
| #ifdef C10_BUILD_MAIN_LIB | ||
| #define C10_API C10_EXPORT | ||
| #else | ||
| #define C10_API C10_IMPORT | ||
| #endif |
14 changes: 14 additions & 0 deletions
14
runtime/core/portable_type/c10/torch/standalone/targets.bzl
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime") | ||
|
|
||
| def define_common_targets(): | ||
| """Defines targets that should be shared between fbcode and xplat. | ||
|
|
||
| The directory containing this targets.bzl file should also contain both | ||
| TARGETS and BUCK files that call this function. | ||
| """ | ||
|
|
||
| runtime.cxx_library( | ||
| name = "torch_standalone_headers", | ||
| exported_headers = glob(["**/*.h"]), | ||
| header_namespace = "torch/standalone", | ||
| ) |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we add if
[[ $(uname -m) != "aarch64" ]]around this call ?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done (but with single brackets because I didn't see this comment first)