Skip to content
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

[llvm] Cache llvm runtime bitcode to reduce start up time in dev mode #1144

Merged
merged 6 commits into from
Jun 6, 2020

Conversation

archibate
Copy link
Collaborator

Related issue = close #875

I hate debugging script in dev mode, just because this huge long start up time compiling bitcode everytime I restart..

[Click here for the format server]

@archibate
Copy link
Collaborator Author

archibate commented Jun 4, 2020

Feel free to say no without a reason if you don't like this, just give me a walk around to disable these redundant compiling process..
Btw, guess what, I found that I'm becoming the most frequent commiter this week according to https://github.com/taichi-dev/taichi/pulse...

@yuanming-hu
Copy link
Member

Feel free to say no without a reason if you don't like this, just give me a walk around to disable these redundant compiling process..

I think maybe we can add an environment variable TI_CACHE_RUNTIME_BITCODE to control this? By default, it shouldn't be cached. Improving your development experience is important, but we also want to simplify the workflow for people who don't care about start up time.

Btw, guess what, I found that I'm becoming the most frequent commiter this week according to https://github.com/taichi-dev/taichi/pulse...

Thanks for everything you have done for Taichi :-)

@yuanming-hu yuanming-hu changed the title [llvm] cache llvm runtime bitcode to reduce start up time in dev mode [llvm] Cache llvm runtime bitcode to reduce start up time in dev mode Jun 4, 2020
@archibate
Copy link
Collaborator Author

TI_CACHE_RUNTIME_BITCODE

I'm fine with this approach. But why we neeed compile rtbc each time restart? Can we just let Makefile care this?

@archibate archibate requested review from yuanming-hu and Rullec and removed request for yuanming-hu June 5, 2020 03:06
@archibate archibate added llvm LLVM backend and removed skip ci labels Jun 5, 2020
@archibate
Copy link
Collaborator Author

Done, btw, I found no test about @ (matmul) in linalg, is this intensional? Also note that z = z @ w seems to fail due to l-value problems.

@archibate
Copy link
Collaborator Author

May I merge this now? I suck the compile time so much that I have to watch bilibili before a program starts, please approve me asap if you feel everything is ok now.

Copy link
Member

@yuanming-hu yuanming-hu left a comment

Choose a reason for hiding this comment

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

Thanks. Please feel free to merge once the wording suggestions are applied.

Done, btw, I found no test about @ (matmul) in linalg, is this intensional? Also note that z = z @ w seems to fail due to l-value problems.

Thanks for reporting this! We should add tests and make z = z @ w work.

docs/global_settings.rst Outdated Show resolved Hide resolved
docs/global_settings.rst Outdated Show resolved Hide resolved
docs/global_settings.rst Outdated Show resolved Hide resolved
Co-authored-by: Yuanming Hu <yuanming-hu@users.noreply.github.com>
@archibate archibate merged commit a345d5b into taichi-dev:master Jun 6, 2020
@k-ye
Copy link
Member

k-ye commented Jun 6, 2020

@archibate
Copy link
Collaborator Author

Sorry for breaking CI! Maybe I shouldn't add [skip ci] on the last commit of before merge...
Any idea why <filesystem> is not found on OS X? It should be supported since C++17 according to https://en.cppreference.com/w/cpp/header/filesystem, or OS X doesn't support C++17 yet?

@k-ye
Copy link
Member

k-ye commented Jun 6, 2020

Hmm, my feeling is that it's a Travis CI problem, maybe their clang is stuck at a super old version? Currently the master branch compiles just fine on my local env.

I found this post (https://stackoverflow.com/a/49600206/12003165): <filesystem> used to be in <experimental/filesystem>, so maybe we need to use that on Mac?

Maybe I shouldn't add [skip ci] on the last commit of before merge...

+1...

@Rullec
Copy link
Contributor

Rullec commented Jun 6, 2020 via email

@k-ye
Copy link
Member

k-ye commented Jun 7, 2020

It seems that
this header can only be used directly on macOS 10.15 Catalina, instead of
my 10.14 Mojave. It's fully about the version.

Thanks for the info. Yeah I saw that Travis CI is stilling using XCode 10.3, which only covers up to Mac 10.14.6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
llvm LLVM backend
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[misc] Cache compiled runtime bitcode runtime_x64.bc
5 participants