[RFC] layers: Split parts of core_validation out#848
[RFC] layers: Split parts of core_validation out#848mark-lunarg merged 2 commits intoKhronosGroup:masterfrom
Conversation
|
This is great, and it's been on the list forever (some attempts were made -- buffer_validation, descriptor_sets, etc.,). Once the android build is sorted, this seems like a great direction. Can you share what kind of granularity you are looking toward -- for example, should drawdispatch eventually contain more CV stuff, or would there be LOTS of smaller files? Maybe a super-rough outline of what the next few files would be and what they might contain. Also, I think it's fine if we just call it cv_drawdispatch.cpp instead of core_validation_drawdispatch.cpp, maybe @tobine could weigh in here. I can also go back and rename the other CV files to match. Thanks @JasperNV... |
|
I don't have any specific goals for granularity -- I figured splitting up the current core_validation.cpp into around 7-8 files seemed about right given its current size. I was imagining one file per important API concept, grouped as needed -- I'll dig into the Android build issue. |
e7670ab to
951c4e1
Compare
This is a bikeshed proposal. Currently, core_validation.cpp is a single file that is over 12,000 lines long. It takes a long time to compile, can be exhausting to navigate, and some tools like IntelliSense can have issues with its large size. Splitting it into multiple files isn't a panacea for the above issues, but a small step towards a larger goal. Here, I do drawdispatch as a simple example to show the idea itself and build approval. It was small and self-contained and relatively conflict-free. If this is well-received, I will do the work myself to help split core_validation.cpp into multiple more files.
951c4e1 to
7eef5eb
Compare
|
Android build issues have been fixed |
|
Quick ping on this? |
|
This is fine by me, but I'd like the filename changed from core_validation_drawdispatch to just drawdispatch. Is there more stuff planned to go into this file? |
|
Nope. The motivation behind the name was to make it clear this was part of the core validation layer, not the other layers, since there's also the thread-safety, object-tracker, stateless-validation layers, etc. I am not married to the name, so I'll change it. |
|
Renamed to drawdispatch.cpp |
|
For a little extra context, in a month or two there will no longer a core_validation layer. There is a CoreChecks validation object, so that might be better, or maybe just cc_ or something instead. I really like the idea, and it's cool if we come up with a scheme that we can use for all of them, but at that time we should rename the other files as well to get the same advantage. |
|
Ah, that makes sense then. Any public documentation I can see about the proposed new structure for the layers? |
|
The white-paper is in final review now and should be available in next week's SDK. Most of it you can already see in the source -- the old layers have all been converted to |
|
Passed internal CI, good to go! |
This is a bikeshed proposal. Currently, core_validation.cpp is a single
file that is over 12,000 lines long. It takes a long time to compile,
can be exhausting to navigate, and some tools like IntelliSense can have
issues with its large size. Splitting it into multiple files isn't a
panacea for the above issues, but a small step towards a larger goal.
Here, I do drawdispatch as a simple example to show the idea itself and
build approval. It was small and self-contained and relatively
conflict-free. If this is well-received, I will do the work myself to
help split core_validation.cpp into multiple more files.