• Home
  • Raw
  • Download

Lines Matching refs:prog

460    parcel_out_uniform_storage(struct gl_shader_program *prog,  in parcel_out_uniform_storage()  argument
465 : prog(prog), map(map), uniforms(uniforms), in parcel_out_uniform_storage()
513 prog->data->ShaderStorageBlocks : prog->data->UniformBlocks; in set_and_process()
515 prog->data->NumShaderStorageBlocks : prog->data->NumUniformBlocks; in set_and_process()
723 prog->_LinkedShaders[shader_type]->Program->sh.ImageAccess[i] = access; in handle_images()
736 prog->_LinkedShaders[shader_type]->Program->sh.NumSubroutineUniforms++; in handle_subroutines()
927 struct gl_shader_program *prog; member in parcel_out_uniform_storage
1161 find_empty_block(struct gl_shader_program *prog, in find_empty_block() argument
1167 &prog->EmptyUniformLocations) { in find_empty_block()
1190 struct gl_shader_program *prog) in link_setup_uniform_remap_tables() argument
1192 unsigned total_entries = prog->NumExplicitUniformLocations; in link_setup_uniform_remap_tables()
1193 unsigned empty_locs = prog->NumUniformRemapTable - total_entries; in link_setup_uniform_remap_tables()
1196 for (unsigned i = 0; i < prog->data->NumUniformStorage; i++) { in link_setup_uniform_remap_tables()
1197 if (prog->data->UniformStorage[i].type->is_subroutine() || in link_setup_uniform_remap_tables()
1198 prog->data->UniformStorage[i].is_shader_storage) in link_setup_uniform_remap_tables()
1201 if (prog->data->UniformStorage[i].remap_location != in link_setup_uniform_remap_tables()
1205 MAX2(1, prog->data->UniformStorage[i].array_elements); in link_setup_uniform_remap_tables()
1210 prog->data->UniformStorage[i].remap_location + j; in link_setup_uniform_remap_tables()
1211 assert(prog->UniformRemapTable[element_loc] == in link_setup_uniform_remap_tables()
1213 prog->UniformRemapTable[element_loc] = in link_setup_uniform_remap_tables()
1214 &prog->data->UniformStorage[i]; in link_setup_uniform_remap_tables()
1220 for (unsigned i = 0; i < prog->data->NumUniformStorage; i++) { in link_setup_uniform_remap_tables()
1222 if (prog->data->UniformStorage[i].type->is_subroutine() || in link_setup_uniform_remap_tables()
1223 prog->data->UniformStorage[i].is_shader_storage) in link_setup_uniform_remap_tables()
1227 if (prog->data->UniformStorage[i].builtin) in link_setup_uniform_remap_tables()
1231 if (prog->data->UniformStorage[i].remap_location != UNMAPPED_UNIFORM_LOC) in link_setup_uniform_remap_tables()
1236 MAX2(1, prog->data->UniformStorage[i].array_elements); in link_setup_uniform_remap_tables()
1242 chosen_location = find_empty_block(prog, &prog->data->UniformStorage[i]); in link_setup_uniform_remap_tables()
1250 chosen_location = prog->NumUniformRemapTable; in link_setup_uniform_remap_tables()
1253 prog->UniformRemapTable = in link_setup_uniform_remap_tables()
1254 reralloc(prog, in link_setup_uniform_remap_tables()
1255 prog->UniformRemapTable, in link_setup_uniform_remap_tables()
1257 prog->NumUniformRemapTable + entries); in link_setup_uniform_remap_tables()
1258 prog->NumUniformRemapTable += entries; in link_setup_uniform_remap_tables()
1263 prog->UniformRemapTable[chosen_location + j] = in link_setup_uniform_remap_tables()
1264 &prog->data->UniformStorage[i]; in link_setup_uniform_remap_tables()
1267 prog->data->UniformStorage[i].remap_location = chosen_location; in link_setup_uniform_remap_tables()
1275 linker_error(prog, "count of uniform locations > MAX_UNIFORM_LOCATIONS" in link_setup_uniform_remap_tables()
1281 for (unsigned i = 0; i < prog->data->NumUniformStorage; i++) { in link_setup_uniform_remap_tables()
1282 if (!prog->data->UniformStorage[i].type->is_subroutine()) in link_setup_uniform_remap_tables()
1285 if (prog->data->UniformStorage[i].remap_location == UNMAPPED_UNIFORM_LOC) in link_setup_uniform_remap_tables()
1290 MAX2(1, prog->data->UniformStorage[i].array_elements); in link_setup_uniform_remap_tables()
1292 unsigned mask = prog->data->linked_stages; in link_setup_uniform_remap_tables()
1295 struct gl_program *p = prog->_LinkedShaders[j]->Program; in link_setup_uniform_remap_tables()
1297 if (!prog->data->UniformStorage[i].opaque[j].active) in link_setup_uniform_remap_tables()
1303 prog->data->UniformStorage[i].remap_location + k; in link_setup_uniform_remap_tables()
1307 &prog->data->UniformStorage[i]; in link_setup_uniform_remap_tables()
1313 for (unsigned i = 0; i < prog->data->NumUniformStorage; i++) { in link_setup_uniform_remap_tables()
1314 if (!prog->data->UniformStorage[i].type->is_subroutine()) in link_setup_uniform_remap_tables()
1317 if (prog->data->UniformStorage[i].remap_location != in link_setup_uniform_remap_tables()
1322 MAX2(1, prog->data->UniformStorage[i].array_elements); in link_setup_uniform_remap_tables()
1324 unsigned mask = prog->data->linked_stages; in link_setup_uniform_remap_tables()
1327 struct gl_program *p = prog->_LinkedShaders[j]->Program; in link_setup_uniform_remap_tables()
1329 if (!prog->data->UniformStorage[i].opaque[j].active) in link_setup_uniform_remap_tables()
1340 &prog->data->UniformStorage[i]; in link_setup_uniform_remap_tables()
1342 prog->data->UniformStorage[i].remap_location = in link_setup_uniform_remap_tables()
1351 struct gl_shader_program *prog, in link_assign_uniform_storage() argument
1356 if (prog->data->NumUniformStorage == 0) in link_assign_uniform_storage()
1362 if (prog->data->UniformStorage == NULL) { in link_assign_uniform_storage()
1363 prog->data->UniformStorage = rzalloc_array(prog->data, in link_assign_uniform_storage()
1365 prog->data->NumUniformStorage); in link_assign_uniform_storage()
1366 data = rzalloc_array(prog->data->UniformStorage, in link_assign_uniform_storage()
1368 prog->data->UniformDataDefaults = in link_assign_uniform_storage()
1369 rzalloc_array(prog->data->UniformStorage, in link_assign_uniform_storage()
1372 data = prog->data->UniformDataSlots; in link_assign_uniform_storage()
1379 parcel_out_uniform_storage parcel(prog, prog->UniformHash, in link_assign_uniform_storage()
1380 prog->data->UniformStorage, data, in link_assign_uniform_storage()
1384 struct gl_linked_shader *shader = prog->_LinkedShaders[i]; in link_assign_uniform_storage()
1434 for (unsigned i = 0; i < prog->data->NumUniformStorage; i++) { in link_assign_uniform_storage()
1435 assert(prog->data->UniformStorage[i].storage != NULL || in link_assign_uniform_storage()
1436 prog->data->UniformStorage[i].builtin || in link_assign_uniform_storage()
1437 prog->data->UniformStorage[i].is_shader_storage || in link_assign_uniform_storage()
1438 prog->data->UniformStorage[i].block_index != -1); in link_assign_uniform_storage()
1444 link_setup_uniform_remap_tables(ctx, prog); in link_assign_uniform_storage()
1447 prog->data->NumUniformDataSlots = num_data_slots; in link_assign_uniform_storage()
1448 prog->data->UniformDataSlots = data; in link_assign_uniform_storage()
1450 link_set_uniform_initializers(prog, boolean_true); in link_assign_uniform_storage()
1454 link_assign_uniform_locations(struct gl_shader_program *prog, in link_assign_uniform_locations() argument
1457 ralloc_free(prog->data->UniformStorage); in link_assign_uniform_locations()
1458 prog->data->UniformStorage = NULL; in link_assign_uniform_locations()
1459 prog->data->NumUniformStorage = 0; in link_assign_uniform_locations()
1461 if (prog->UniformHash != NULL) { in link_assign_uniform_locations()
1462 prog->UniformHash->clear(); in link_assign_uniform_locations()
1464 prog->UniformHash = new string_to_uint_map; in link_assign_uniform_locations()
1475 count_uniform_size uniform_size(prog->UniformHash, hiddenUniforms, in link_assign_uniform_locations()
1478 struct gl_linked_shader *sh = prog->_LinkedShaders[i]; in link_assign_uniform_locations()
1510 prog->data->NumUniformStorage = uniform_size.num_active_uniforms; in link_assign_uniform_locations()
1511 prog->data->NumHiddenUniforms = uniform_size.num_hidden_uniforms; in link_assign_uniform_locations()
1517 link_assign_uniform_storage(ctx, prog, uniform_size.num_values); in link_assign_uniform_locations()