Run python setup.py bdist_wheel --verbose and fix the errors.
- User
Run
python setup.py bdist_wheel --verboseand fix the errors. - Assistant
The wheel build now succeeds. The original failure was an MSVC-only incomplete-type issue in Proton:
PhaseStore<Tree>andPhaseStore<Trace>were being instantiated fromSession.cppwhileTreeData::TreeandTraceData::Tracewere still only forward-declared.- I moved those private nested type definitions into internal headers:
third_party/proton/csrc/include/Data/TreeDataInternal.handthird_party/proton/csrc/include/Data/TraceDataInternal.h - I updated
third_party/proton/csrc/lib/Data/TreeData.cppandthird_party/proton/csrc/lib/Data/TraceData.cppto include the new internal headers instead of defining the nested classes inline in the.cppfiles - I included the same internal headers in
third_party/proton/csrc/lib/Session/Session.cppso MSVC sees complete types before constructingTreeData/TraceData - That fixes the
std::make_unique<T>()failure insidePhaseStorewithout changing the publicTreeData/TraceDatainterfaces
I re-ran
python setup.py bdist_wheel --verbose, and it completed successfully.Latest wheel:
dist/triton_windows-3.6.0+git368461c6-cp312-cp312-win_amd64.whl
There is also an older wheel still present:
dist/triton_windows-3.6.0+git35114221-cp312-cp312-win_amd64.whl
Natural next steps:
- Install the new wheel with
pip install --force-reinstall dist/triton_windows-3.6.0+git368461c6-cp312-cp312-win_amd64.whl - If you want, I can also clean up the old wheel or make a commit with this fix
- I moved those private nested type definitions into internal headers:
- User
I've put this change in the
tmpbranch and reverted it in the current branch. As we're maintaining a fork, can we minimize the diff of this change and avoid creating new files? - Assistant
Yes — I reduced it to a no-new-files patch and kept the headers unchanged.
- The fix now lives entirely in
third_party/proton/csrc/lib/Session/Session.cpp:11,third_party/proton/csrc/lib/Data/TreeData.cpp:916, andthird_party/proton/csrc/lib/Data/TraceData.cpp:538 - Instead of making
Session.cppincludeTreeData.h/TraceData.hand instantiate those types directly,Session.cppnow calls small helper functions declared locally and defined in the corresponding.cppfiles - That keeps
TreeData::Treeand hidden where they already live, so MSVC no longer tries to instantiate / from
- The fix now lives entirely in