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

swiftTypeCheckTimes and swiftFunctionTimes only appearing for main application target #100

Closed
birwin93 opened this issue Aug 31, 2020 · 7 comments

Comments

@birwin93
Copy link
Contributor

birwin93 commented Aug 31, 2020

Using xclogparser v0.2.18

I've been playing around with using -Xfrontend -debug-time-expression-type-checking -Xfrontend -debug-time-function-bodies to analyze what functions and type checkers are slowing down our build times.

I've noticed that only the source files in the main application target seem to have swiftTypeCheckTimes and swiftFunctionTimes populated. All the source files in our dynamic frameworks and static libraries don't though. I've confirmed those targets are also built with the correct compiler flags, and that the method/typechecks + durations are in the build logs in xcode.

Any ideas? Thanks!

@birwin93
Copy link
Contributor Author

It does look like the information is also in the output from running xclogparser dump

@ecamacho
Copy link
Collaborator

ecamacho commented Sep 1, 2020

Hi! do you have an xcactivitylog to reproduce the error? If you can't provide one, can you share the overall structure of your project to try to mimic it?

@birwin93
Copy link
Contributor Author

birwin93 commented Sep 1, 2020

Thank you for the quick reply!

Unfortunately I can't share our xcactivitylog. But general structure:

  • App target (iOS 11 min)
  • Internal Dependencies:
    - static libs
    - dynamic frameworks
  • External Dependencies:
    - Carthage
    - a few pre-compiled frameworks

Not sure if it matters, but we use XcodeGen as well

Let me know if you need anymore info!

@birwin93
Copy link
Contributor Author

birwin93 commented Sep 1, 2020

Hmmmm I actually created a sample project to try and get an xcactivitylog with a similar setup and it worked fine. Must be something weird in our setup. May also just be a complexity issue since our repo is pretty large with tons of chained dependencies.

FWIW some of our dynamic frameworks have objective c code in them, if that matters.

@birwin93
Copy link
Contributor Author

birwin93 commented Sep 1, 2020

I might try to clone XCLogParser and see if I can figure out what's not working. Any hints on where in the codebase to focus on?

@birwin93
Copy link
Contributor Author

birwin93 commented Sep 2, 2020

Did some more digging. Turns out being in frameworks was a red herring. Ended up being related to spaces in file paths. Put up a PR here to fix: #102

@ecamacho
Copy link
Collaborator

ecamacho commented Sep 2, 2020

Thank you for the PR!

@ecamacho ecamacho closed this as completed Sep 2, 2020
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

No branches or pull requests

2 participants