tenstorrent / tt-metal

:metal: TT-NN operator library, and TT-Metalium low level kernel programming model.
Apache License 2.0
396 stars 49 forks source link

Create nightly hermetic build + test with `TT_FROM_PRECOMPILED` turned OFF after changes to run silicon tests in docker #12122

Closed tt-rkim closed 4 days ago

tt-rkim commented 2 weeks ago

We should ensure hermetic builds still work with no options like this for the sake of completeness.

cc: @ttmchiou @TT-billteng @dimitri-tenstorrent

TT-billteng commented 1 week ago

what does TT_FROM_PRECOMPILED control?

dimitri-tenstorrent commented 1 week ago

It is the flag that check if setup.py will run make install or use the pre-built binaries. Here is the code: https://github.com/tenstorrent/tt-metal/pull/12165/files#diff-60f61ab7a8d1910d86d9fda2261620314edcae5894d5aaa236b821c7256badd7

TT-billteng commented 1 week ago

is setup.py typically responsible for building C++ (if a project has C++)? If not, we should consider having setup.py take care of python side only

tt-rkim commented 1 week ago

The intention of setup.py in Python land is to be able to build a project + its extensions . In setup.py, we call cmake build ..., which originally does the full build and copies the binding binaries into the right places.

This means setup.py is supposed to be able to build the full and working project from scratch. In the eager-package job, we call pip install without -e, which triggers the full build. That's why when we do pip install -e . in our dev virtualenv, this is all skipped.

tt-rkim commented 4 days ago

This is now done and we have a new workflow that tests this on schedule: https://github.com/tenstorrent/tt-metal/actions/workflows/build-and-test-wheels.yaml