st/mesa: Skip serializing driver_cache_blob if it exists
authorJordan Justen <jordan.l.justen@intel.com>
Thu, 19 Apr 2018 23:14:28 +0000 (16:14 -0700)
committerJordan Justen <jordan.l.justen@intel.com>
Tue, 10 Jul 2018 06:02:32 +0000 (23:02 -0700)
Previously the mesa core code would not call to serialize the
driver_cache_blob if it existed. We will update it to always call to
serialize the driver_cache_blob meaning we should avoid re-serializing
it under mesa/state_tracker.

Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
src/mesa/state_tracker/st_shader_cache.c

index 17f84180cae3b395a81e8daf267c6032fbcd7e1b..3f8d2d110ce8fce5d116d60388d947b7e9f3884d 100644 (file)
@@ -74,6 +74,9 @@ static void
 st_serialise_ir_program(struct gl_context *ctx, struct gl_program *prog,
                         bool nir)
 {
+   if (prog->driver_cache_blob)
+      return;
+
    struct blob blob;
    blob_init(&blob);