Skip to content

[tvm-ffi] Add new port 0.1.16, update dlpack to 1.4 - #54810

Merged
Billy O'Neal (BillyONeal) merged 8 commits into
microsoft:masterfrom
miyanyan:add-tvm-ffi
Nov 21, 2026
Merged

Billy O'Neal (BillyONeal) merged 8 commits into
microsoft:masterfrom
miyanyan:add-tvm-ffi

Conversation

@miyanyan

@miyanyan miyan (miyanyan) commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

Add Apache TVM FFI 0.1.16, an open ABI and FFI for machine learning systems.

Project maturity: v0.1.0 was released on 2025-10-21, and this is an official Apache TVM component.

Naming: tvm-ffi matches the upstream repository and documented project name. The repository and official documentation appear among the first results for tvm-ffi C++. The search-result screenshot requested below is not attached, so that checklist item remains unchecked; Repology indexing has not been verified.

  • Changes comply with the maintainer guide.
  • The packaged project is mature and ready for broad sharing with vcpkg users
    • Has a release at least 6 months old or 6 months of demonstrated public development
    • Is an official component of something else meeting that criteria
    • Some other reason (please explain)
  • The packaged project shows strong association with the chosen port name. Check this box if at least one of the following criteria is met:
  • Optional dependencies of the build are all controlled by the port. A dependency is controlled if it is declared an unconditional dependency in vcpkg.json, or explicitly disabled through patches or build system arguments such as CMAKE_DISABLE_FIND_PACKAGE_Xxx or VCPKG_LOCK_FIND_PACKAGE
  • The versioning scheme in vcpkg.json matches what upstream says.
  • The license declaration in vcpkg.json matches what upstream says.
  • The installed as the "copyright" file matches what upstream says.
  • The source code of the component installed comes from an authoritative source.
  • The generated "usage text" is brief and accurate. See adding-usage for context. Don't add a usage file if the automatically generated usage is correct.
  • The version database is fixed by rerunning ./vcpkg x-add-version --all and committing the result.
  • Exactly one version is added in each modified versions file.

Copilot AI balanced review requested due to automatic review settings November 1, 2026 09:25

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The manifest permits unsupported x64-windows-static and UWP configurations; add support restrictions and regenerate the version database entry.

1 open issue
What changed in this PR

Adds Apache TVM FFI 0.1.15 to vcpkg, providing its shared C/C++ runtime for machine learning systems.

Changes:

  • Uses vcpkg’s dlpack dependency and disables Python bindings, tests, and bundled libbacktrace.
  • Exports CMake targets, adjusts installation layout, and packages LICENSE and NOTICE.
  • Registers the new port in the version database.

Validation here was limited to source inspection; builds and consumer examples were not rerun.

File Description
versions/​t-/​tvm-ffi.json Records the initial port version and tree.
versions/​baseline.json Adds the 0.1.15 baseline.
ports/​tvm-ffi/​vcpkg.json Declares package metadata and dependencies.
ports/​tvm-ffi/​portfile.cmake Configures and packages the shared runtime.
ports/​tvm-ffi/​cmake-install.patch Exports CMake targets and adjusts installed contents.

Review effort: Balanced

Comment thread ports/tvm-ffi/vcpkg.json Resolved

@vicroms Victor Romero (vicroms) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fails to build on x86-windows with C3861 for _InterlockedIncrement64 at line 263 and _InterlockedDecrement64 at line 320.

Comment thread ports/tvm-ffi/vcpkg.json Resolved
@vicroms
Victor Romero (vicroms) marked this pull request as draft November 2, 2026 23:10
Tianqi Chen (tqchen) pushed a commit to apache/tvm-ffi that referenced this pull request Nov 4, 2026
Another issue found in microsoft/vcpkg#54810

build error on 32bit:
```
D:\b\tvm-ffi\src\v0.1.15-e4904dcca0.clean\include\tvm/ffi/object.h(263): error C3861: '_InterlockedIncrement64': identifier not found
D:\b\tvm-ffi\src\v0.1.15-e4904dcca0.clean\include\tvm/ffi/object.h(320): error C3861: '_InterlockedDecrement64': identifier not found
```

Use the Windows SDK `InterlockedIncrement64` and
`InterlockedDecrement64` wrappers, which support both 32-bit x86 and
64-bit x64 targets. On x86, they use a compare-exchange loop; on x64,
they map directly to the corresponding intrinsics.
@miyanyan

Copy link
Copy Markdown
Contributor Author

let's wait for 0.1.16

@miyanyan miyan (miyanyan) changed the title [tvm-ffi] Add new port 0.1.15 [tvm-ffi] Add new port 0.1.16 Nov 12, 2026
@miyanyan miyan (miyanyan) changed the title [tvm-ffi] Add new port 0.1.16 [tvm-ffi] Add new port 0.1.16, update dlpack to 1.4 Nov 12, 2026
@miyanyan
miyan (miyanyan) marked this pull request as ready for review November 13, 2026 01:15

@vicroms Victor Romero (vicroms) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please merge miyanyan#14 to fix static consumers on Windows.

@vicroms
Victor Romero (vicroms) marked this pull request as draft November 18, 2026 00:10
@BillyONeal

Copy link
Copy Markdown
Member
image

GPT 6.2 Sol made me file dmlc/dlpack#197

Thanks for the new port and the updates!

@BillyONeal
Billy O'Neal (BillyONeal) merged commit 2dd73bd into microsoft:master Nov 21, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants