Automate pod arg implementation decision (#575)
Contributes to #529
* Decision made on a per-kernel basis
* New pass assigns metadata to kernels
* passes use that metadata through new utliities to get the right
ArgKinds
* currently only decides based on command line options (so NFC)
* Refactored layout validation into new files
* Refactored some global push constant methods
* new enum for how pod args are implemented
* kGlobalPushConstant will be implemented in the future
* added new metadata to test that required it
* changed arg kind utility to take the arg instead of just the type
* Priorities per-kernel push constants then ubo then ssbo
* checks for compatibility
* Added new variant of isValidExplicitLayout that checks the whole
struct
diff --git a/lib/Compiler.cpp b/lib/Compiler.cpp
index 0b1a6ce..1971b26 100644
--- a/lib/Compiler.cpp
+++ b/lib/Compiler.cpp
@@ -603,6 +603,7 @@
pm->add(clspv::createZeroInitializeAllocasPass());
pm->add(clspv::createAddFunctionAttributesPass());
+ pm->add(clspv::createAutoPodArgsPass());
pm->add(clspv::createDeclarePushConstantsPass());
pm->add(clspv::createDefineOpenCLWorkItemBuiltinsPass());