struct draw_stage *stage;
render = i915_vbuf_render_create(i915);
- if(!render)
+ if (!render)
return NULL;
stage = draw_vbuf_stage(i915->draw, render);
- if(!stage) {
+ if (!stage) {
render->destroy(render);
return NULL;
}
{
struct llvmpipe_context *llvmpipe = llvmpipe_context(pipe);
- if(!blend_color)
+ if (!blend_color)
return;
if(memcmp(&llvmpipe->blend_color, blend_color, sizeof *blend_color) == 0)
{
struct llvmpipe_context *llvmpipe = llvmpipe_context(pipe);
- if(!stencil_ref)
+ if (!stencil_ref)
return;
if(memcmp(&llvmpipe->stencil_ref, stencil_ref, sizeof *stencil_ref) == 0)
char module_name[64];
variant = CALLOC_STRUCT(lp_fragment_shader_variant);
- if(!variant)
+ if (!variant)
return NULL;
util_snprintf(module_name, sizeof(module_name), "fs%u_variant%u",
}
#endif
- if(fp) {
+ if (fp) {
/* Warm up the caches */
test_some(0, NULL, 100);
else
success = test_all(verbose, fp);
- if(fp)
+ if (fp)
fclose(fp);
return success ? 0 : 1;
struct lp_llvm_sampler_soa *sampler;
sampler = CALLOC_STRUCT(lp_llvm_sampler_soa);
- if(!sampler)
+ if (!sampler)
return NULL;
sampler->base.destroy = lp_llvm_sampler_soa_destroy;
struct llvmpipe_resource *buffer;
buffer = CALLOC_STRUCT(llvmpipe_resource);
- if(!buffer)
+ if (!buffer)
return NULL;
pipe_reference_init(&buffer->base.reference, 1);
out:
tgsi_parse_free(&parse);
- if(fpc)
+ if (fpc)
{
FREE(fpc->r_temp);
FREE(fpc->r_imm);
out:
tgsi_parse_free(&parse);
- if(vpc) {
+ if (vpc) {
util_dynarray_fini(&vpc->label_relocs);
util_dynarray_fini(&vpc->loop_stack);
FREE(vpc->r_temp);
for (i = 0; i < max_slots; ++i) {
struct r600_bytecode_alu *alu = slots[i];
- if(!alu)
+ if (!alu)
continue;
if (is_alu_64bit_inst(bc, alu))
{
struct rbug_resource *rb_resource;
- if(!resource)
+ if (!resource)
goto error;
assert(resource->screen == rb_screen->screen);
rb_resource = CALLOC_STRUCT(rbug_resource);
- if(!rb_resource)
+ if (!rb_resource)
goto error;
memcpy(&rb_resource->base, resource, sizeof(struct pipe_resource));
{
struct rbug_surface *rb_surface;
- if(!surface)
+ if (!surface)
goto error;
assert(surface->texture == rb_resource->resource);
rb_surface = CALLOC_STRUCT(rbug_surface);
- if(!rb_surface)
+ if (!rb_surface)
goto error;
memcpy(&rb_surface->base, surface, sizeof(struct pipe_surface));
{
struct rbug_transfer *rb_transfer;
- if(!transfer)
+ if (!transfer)
goto error;
assert(transfer->resource == rb_resource->resource);
rb_transfer = CALLOC_STRUCT(rbug_transfer);
- if(!rb_transfer)
+ if (!rb_transfer)
goto error;
memcpy(&rb_transfer->base, transfer, sizeof(struct pipe_transfer));
{
struct trace_resource *tr_res;
- if(!resource)
+ if (!resource)
return NULL;
tr_res = trace_resource(resource);
struct trace_screen *tr_scr = trace_screen(tr_ctx->base.screen);
struct trace_surface *tr_surf;
- if(!surface)
+ if (!surface)
return NULL;
assert(surface->texture);
pipe->flush(pipe, fence, flags);
- if(fence)
+ if (fence)
trace_dump_ret(ptr, *fence);
trace_dump_call_end();
{
struct trace_context *tr_ctx;
- if(!pipe)
+ if (!pipe)
goto error1;
if(!trace_enabled())
goto error1;
tr_ctx = CALLOC_STRUCT(trace_context);
- if(!tr_ctx)
+ if (!tr_ctx)
goto error1;
tr_ctx->base.priv = pipe->priv; /* expose wrapped priv data */
void
trace_dump_trace_flush(void)
{
- if(stream) {
+ if (stream) {
fflush(stream);
}
}
static void
trace_dump_trace_close(void)
{
- if(stream) {
+ if (stream) {
trace_dump_writes("</trace>\n");
if (close_stream) {
fclose(stream);
const char *filename;
filename = debug_get_option("GALLIUM_TRACE", NULL);
- if(!filename)
+ if (!filename)
return FALSE;
- if(!stream) {
+ if (!stream) {
if (strcmp(filename, "stderr") == 0) {
close_stream = FALSE;
if (!trace_dumping_enabled_locked())
return;
- if(!templat) {
+ if (!templat) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!box) {
+ if (!box) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
if (!trace_dumping_enabled_locked())
return;
- if(!state) {
+ if (!state) {
trace_dump_null();
return;
}
trace_dump_call_begin("", "pipe_screen_create");
tr_scr = CALLOC_STRUCT(trace_screen);
- if(!tr_scr)
+ if (!tr_scr)
goto error2;
tr_scr->base.destroy = trace_screen_destroy;
{
struct trace_resource *tr_res;
- if(!texture)
+ if (!texture)
goto error;
assert(texture->screen == tr_scr->screen);
tr_res = CALLOC_STRUCT(trace_resource);
- if(!tr_res)
+ if (!tr_res)
goto error;
memcpy(&tr_res->base, texture, sizeof(struct pipe_resource));
{
struct trace_surface *tr_surf;
- if(!surface)
+ if (!surface)
goto error;
assert(surface->texture == tr_res->resource);
tr_surf = CALLOC_STRUCT(trace_surface);
- if(!tr_surf)
+ if (!tr_surf)
goto error;
memcpy(&tr_surf->base, surface, sizeof(struct pipe_surface));
{
struct trace_transfer *tr_trans;
- if(!transfer)
+ if (!transfer)
goto error;
assert(transfer->resource == tr_res->resource);
tr_trans = CALLOC_STRUCT(trace_transfer);
- if(!tr_trans)
+ if (!tr_trans)
goto error;
memcpy(&tr_trans->base, transfer, sizeof(struct pipe_transfer));
static inline struct trace_resource *
trace_resource(struct pipe_resource *texture)
{
- if(!texture)
+ if (!texture)
return NULL;
(void)trace_screen(texture->screen);
return (struct trace_resource *)texture;
static inline struct trace_surface *
trace_surface(struct pipe_surface *surface)
{
- if(!surface)
+ if (!surface)
return NULL;
(void)trace_resource(surface->texture);
return (struct trace_surface *)surface;
static inline struct trace_transfer *
trace_transfer(struct pipe_transfer *transfer)
{
- if(!transfer)
+ if (!transfer)
return NULL;
(void)trace_resource(transfer->resource);
return (struct trace_transfer *)transfer;