anv: Add an anv_physical_device field to anv_device
[mesa.git] / src / intel / vulkan / tests / state_pool.c
index cb0e403f495e7e85ac30d960975633e766dede40..be844e0498f799644bd30aab93809adccdec38d8 100644 (file)
@@ -21,6 +21,8 @@
  * IN THE SOFTWARE.
  */
 
+#undef NDEBUG
+
 #include <pthread.h>
 
 #include "anv_private.h"
 
 int main(int argc, char **argv)
 {
-   struct anv_instance instance;
+   struct anv_physical_device physical_device = { };
    struct anv_device device = {
-      .instance = &instance,
+      .physical = &physical_device,
    };
    struct anv_state_pool state_pool;
 
    pthread_mutex_init(&device.mutex, NULL);
+   anv_bo_cache_init(&device.bo_cache);
 
    for (unsigned i = 0; i < NUM_RUNS; i++) {
-      anv_state_pool_init(&state_pool, &device, 4096, 256, 0);
+      anv_state_pool_init(&state_pool, &device, 4096, 256);
 
       /* Grab one so a zero offset is impossible */
       anv_state_pool_alloc(&state_pool, 16, 16);