Skip to content

Conversation

@driazati
Copy link
Member

@driazati driazati commented May 10, 2022

This adds /opt/sccache to the PATH of each of the CI docker images so when cmake looks for a C compiler it will pick up the sccache wrapper by default. This fixes some issues where compiler invocations weren't being run though sccache. With this approach the invoker doesn't need to do anything specific to set up sccache.

This will require a follow up PR to update the Docker images and remove some of the sccache logic in task_build.py

cc @Mousius @areusch

This adds `/opt/sccache` to the PATH of each of the CI docker images so when cmake looks for a C compiler it will pick up the sccache wrapper by default. This fixes some issues where compiler invocations weren't being run though sccache. With this approach the invoker doesn't need to do anything specific to set up sccache.

This will require a follow up PR to update the Docker images and remove some of the sccache logic in `task_build.py`
@driazati driazati marked this pull request as ready for review May 11, 2022 14:56
@areusch
Copy link
Contributor

areusch commented May 11, 2022

just confirming--we can disable this when doing a local build, correct? what's the mechanism by which we do that?

@driazati
Copy link
Member Author

driazati commented May 11, 2022

You can disable it by setting the compiler in the cmake config as usual (CMAKE_CXX_COMPILER) to a full path, sccache also works locally though

@areusch
Copy link
Contributor

areusch commented May 11, 2022

right, will this make the default tests/scripts/ci.py take up a bunch of disk though by making a local sccache?

@areusch
Copy link
Contributor

areusch commented May 11, 2022

we discussed a bit, this is expected to populate .cache which is shared across pip/matplotlib/etc. the unintuitive thing here is that the tvm root is the homedir in the docker images, but that's not unique to this tool even if it would tend to invoke it. @driazati suggested a warning message or ci.py clean command, we can revisit if folks complain. sccache will limit to 10GB disk now.

@areusch areusch merged commit 775457c into apache:main May 11, 2022
mehrdadh pushed a commit to mehrdadh/tvm that referenced this pull request May 16, 2022
This adds `/opt/sccache` to the PATH of each of the CI docker images so when cmake looks for a C compiler it will pick up the sccache wrapper by default. This fixes some issues where compiler invocations weren't being run though sccache. With this approach the invoker doesn't need to do anything specific to set up sccache.

This will require a follow up PR to update the Docker images and remove some of the sccache logic in `task_build.py`

Co-authored-by: driazati <[email protected]>
shtinsa pushed a commit to Deelvin/tvm that referenced this pull request May 17, 2022
This adds `/opt/sccache` to the PATH of each of the CI docker images so when cmake looks for a C compiler it will pick up the sccache wrapper by default. This fixes some issues where compiler invocations weren't being run though sccache. With this approach the invoker doesn't need to do anything specific to set up sccache.

This will require a follow up PR to update the Docker images and remove some of the sccache logic in `task_build.py`

Co-authored-by: driazati <[email protected]>
shingjan pushed a commit to shingjan/tvm that referenced this pull request May 17, 2022
This adds `/opt/sccache` to the PATH of each of the CI docker images so when cmake looks for a C compiler it will pick up the sccache wrapper by default. This fixes some issues where compiler invocations weren't being run though sccache. With this approach the invoker doesn't need to do anything specific to set up sccache.

This will require a follow up PR to update the Docker images and remove some of the sccache logic in `task_build.py`

Co-authored-by: driazati <[email protected]>
SebastianBoblest pushed a commit to SebastianBoblest/tvm that referenced this pull request May 27, 2022
This adds `/opt/sccache` to the PATH of each of the CI docker images so when cmake looks for a C compiler it will pick up the sccache wrapper by default. This fixes some issues where compiler invocations weren't being run though sccache. With this approach the invoker doesn't need to do anything specific to set up sccache.

This will require a follow up PR to update the Docker images and remove some of the sccache logic in `task_build.py`

Co-authored-by: driazati <[email protected]>
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.

2 participants