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
How to use c/aquery to find the dependents of an anon_target #615
Comments
I've needed this too in the past and haven't found a good solution. Unfortunately, there's none that's super obvious to me, neither of cquery or aquery is really the appropriate tool here. I'll bring it up in the team's core sync meeting on Monday and see if anyone has any ideas |
From the discussion yesterday: We weren't really sure what to do. There was some talk of adding The best idea so far is a |
Thanks for discussing on your side. I am in favor of a potential analysis-query. I think our use case is probably different from Meta's in that we often find ourselves making many (dozens) of distinct binaries from slightly different sets of objects but with significant sharing. One use case today is building ~15 firmware binaries with maybe 70% of files shared on average for a ~100 translation unit binary. This means the naive build without anonymous targets has 1500 .o actions. The anonymous targets build today is more like ~500. Then we also run e.g. several linters over those source files, which we also do anonymously and delivers similar extreme gains. We are still working on scaling this but it's not difficult for me to imagine this same average ratio (70%) holding but for other bigger projects with ~10^2 configurations and O(10^2) source files. A full, capable query flavor would be far and away the best option in my mind here. It's not so much a rare debug event for this usage pattern as a common daily occurrence. |
@JakobDegen Wondering if you have any more thoughts on the anon_target query stuff |
Given a situation where I have multiple named non-anon targets depending on the same anon_target, is there a way I can find what all those non-anon targets are? I think what I'm looking for are the rdeps of some covering target universe over those named targets on that anon_target. But whenever I try to use an anon target in a query, like something like this:
buck2 says:
The text was updated successfully, but these errors were encountered: