-
Notifications
You must be signed in to change notification settings - Fork 25.6k
Set default compiler differently according to platform #43890
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
Conversation
…pytorch#43800) Summary: Pull Request resolved: pytorch#43800 1. Move fbcode related coverage code to fb/ folder and add TARGETS so that we can use buck run to run the tool and solved the import probelm. 2. Write `README.md` to give users guidance about the tool Test Plan: On devserver: ``` buck run //caffe2/fb/code_coverage/tool:coverage -- //caffe2/c10: ``` More examples in README.md Differential Revision: D23404988 fbshipit-source-id: 61d6b48904a1e0db9fd262bdfac0890cea951762
Summary: Check the result of GCC coverage in OSS is reasonable and ready to ship. The amount of executable lines are not the same between `gcc` and `clang` because of the following reasons: * Lines following are counted in `clang` but not in `gcc`: 1. empty line or line with only “{” or “}” 3. some comments are counted in clang but not in gcc 5. `#define ...` -- not supported by gcc according to official documentation * Besides, a statement that explains to more than one line will be counted as only one executable line in gcc, but several lines in clang ## Advantage of `gcc` coverage 1. Much faster - code coverage tool runtime is onle **4 min** (*ammazzzing!!*) by `gcc`, compared to **3 hours!!** by `clang`, to analyze all the tests' artifacts 2. Use less disk - `Clang`'s artifacts will take as large as 170G, but `GCC` is 980M Besides, also update `README.md`. Test Plan: Compare the result in OSS `clang` and OSS `gcc` with the same command: ``` python oss_coverage.py --run-only atest test_nn.py --interested-folder=aten ``` ---- # GCC **Summary** > time: 0:15:45 summary percentage: 44.85% **Report and Log** [File Coverage Report](P140825162) [Line Coverage Report](P140825196) [Log](P140825385) ------ # CLANG **Summary** > time: 0:21:35 summary percentage: 44.08% **Report and Log** [File Coverage Report](P140825845) [Line Coverage Report](P140825923) [Log](P140825950) Differential Revision: D23416772 fbshipit-source-id: 475099fddfba8967f88b51a5653639b6c2fac335
…onsistent with other arguments Summary: 1. rename input argunment `interested-folder` to `interest-only` -- be consistent with `run-only`, `coverage-only` and be shorted Test Plan: Test on devserver and linux docker. Differential Revision: D23417338 fbshipit-source-id: 454aad06929550325468236d70671ba889ef2b8e
Summary: set `gcc` as default compiler type in oss, and `clang` as default compiler type in fbcode Test Plan: test locally Differential Revision: D23420034 fbshipit-source-id: 7e3c3231dbfeadd3c6e08d165be45d25b0f22ecc
This pull request was exported from Phabricator. Differential Revision: D23420034 |
💊 CI failures summary and remediationsAs of commit a7586b1 (more details on the Dr. CI page):
🚧 1 ongoing upstream failure:These were probably caused by upstream breakages that are not fixed yet: 🚧 5 fixed upstream failures:These were probably caused by upstream breakages that were already fixed.
Please rebase on the
|
This pull request has been merged in 49e979b. |
Summary: set
gcc
as default compiler type in oss, andclang
as default compiler type in fbcodeTest Plan: test locally
Differential Revision: D23420034