aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/compute/skc
diff options
context:
space:
mode:
authorGravatar Hal Canary <halcanary@google.com>2018-07-11 16:10:14 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-07-16 13:59:36 +0000
commit1419534a0079618b9c12edd74fd756e36b0523bf (patch)
tree46e83a5a3c46cdf5aa70f48c2ed73b81874f481a /src/compute/skc
parent7e83f89dd67e7c66d853e78b4630450bfb406de0 (diff)
Whitespace cleanup again
Change-Id: I38ab9ff141eb088084a4c0e664f327ceb89fcf70 Reviewed-on: https://skia-review.googlesource.com/140784 Commit-Queue: Hal Canary <halcanary@google.com> Auto-Submit: Hal Canary <halcanary@google.com> Reviewed-by: Mike Klein <mtklein@google.com>
Diffstat (limited to 'src/compute/skc')
-rw-r--r--src/compute/skc/allocator_host.c10
-rw-r--r--src/compute/skc/context.c2
-rw-r--r--src/compute/skc/context.h2
-rw-r--r--src/compute/skc/extent_ring.c12
-rw-r--r--src/compute/skc/grid.c4
-rw-r--r--src/compute/skc/handle.h2
-rw-r--r--src/compute/skc/interop.h2
-rw-r--r--src/compute/skc/main.c4
-rw-r--r--src/compute/skc/path_builder.h4
-rw-r--r--src/compute/skc/platforms/cl_12/allocator_device_cl.c8
-rw-r--r--src/compute/skc/platforms/cl_12/allocator_device_cl.h2
-rw-r--r--src/compute/skc/platforms/cl_12/composition_cl_12.c26
-rw-r--r--src/compute/skc/platforms/cl_12/composition_cl_12.h6
-rw-r--r--src/compute/skc/platforms/cl_12/config_cl.h6
-rw-r--r--src/compute/skc/platforms/cl_12/cq_pool_cl.c12
-rw-r--r--src/compute/skc/platforms/cl_12/cq_pool_cl.h2
-rw-r--r--src/compute/skc/platforms/cl_12/device_cl_12.h12
-rw-r--r--src/compute/skc/platforms/cl_12/export_cl_12.h4
-rw-r--r--src/compute/skc/platforms/cl_12/extent_cl_12.c4
-rw-r--r--src/compute/skc/platforms/cl_12/extent_cl_12.h6
-rw-r--r--src/compute/skc/platforms/cl_12/handle_pool_cl_12.h2
-rw-r--r--src/compute/skc/platforms/cl_12/interop/interop_glfw.c22
-rw-r--r--src/compute/skc/platforms/cl_12/kernels/devices/gen9/device_cl_12.c8
-rw-r--r--src/compute/skc/platforms/cl_12/path_builder_cl_12.c12
-rw-r--r--src/compute/skc/platforms/cl_12/raster_builder_cl_12.c34
-rw-r--r--src/compute/skc/platforms/cl_12/runtime_cl_12.c20
-rw-r--r--src/compute/skc/platforms/cl_12/styling_cl_12.c20
-rw-r--r--src/compute/skc/platforms/cl_12/styling_cl_12.h2
-rw-r--r--src/compute/skc/platforms/cl_12/surface_cl_12.c12
-rw-r--r--src/compute/skc/raster_builder.c6
-rw-r--r--src/compute/skc/scheduler.cpp4
-rw-r--r--src/compute/skc/scheduler.h6
-rw-r--r--src/compute/skc/styling.h2
-rw-r--r--src/compute/skc/styling_types.h10
-rw-r--r--src/compute/skc/suballocator.c6
-rw-r--r--src/compute/skc/suballocator.h4
-rw-r--r--src/compute/skc/tile.h2
-rw-r--r--src/compute/skc/util.c2
-rw-r--r--src/compute/skc/weakref.c10
-rw-r--r--src/compute/skc/weakref.h12
40 files changed, 163 insertions, 163 deletions
diff --git a/src/compute/skc/allocator_host.c b/src/compute/skc/allocator_host.c
index dbdcba0f51..0d7cbca9e4 100644
--- a/src/compute/skc/allocator_host.c
+++ b/src/compute/skc/allocator_host.c
@@ -33,7 +33,7 @@
//
void *
-skc_runtime_host_perm_alloc(struct skc_runtime * const runtime,
+skc_runtime_host_perm_alloc(struct skc_runtime * const runtime,
skc_mem_flags_e const flags,
size_t const size)
{
@@ -42,7 +42,7 @@ skc_runtime_host_perm_alloc(struct skc_runtime * const runtime,
}
void
-skc_runtime_host_perm_free(struct skc_runtime * const runtime,
+skc_runtime_host_perm_free(struct skc_runtime * const runtime,
void * const mem)
{
SKC_ALIGNED_FREE(mem);
@@ -65,11 +65,11 @@ skc_runtime_host_temp_alloc(struct skc_runtime * const runtime,
if (subbuf_size != NULL)
*subbuf_size = 0;
-
+
return NULL;
}
- return runtime->allocator.host.temp.extent +
+ return runtime->allocator.host.temp.extent +
skc_suballocator_subbuf_alloc(&runtime->allocator.host.temp.suballocator,
runtime->scheduler,
size,subbuf_id,subbuf_size);
@@ -101,7 +101,7 @@ skc_allocator_host_create(struct skc_runtime * const runtime)
SKC_RUNTIME_HOST_CACHELINE_SIZE,
runtime->config->suballocator.host.size);
- runtime->allocator.host.temp.extent =
+ runtime->allocator.host.temp.extent =
skc_runtime_host_perm_alloc(runtime,
SKC_MEM_FLAGS_READ_WRITE,
runtime->config->suballocator.host.size);
diff --git a/src/compute/skc/context.c b/src/compute/skc/context.c
index 8066dc2b9b..59c7956fd5 100644
--- a/src/compute/skc/context.c
+++ b/src/compute/skc/context.c
@@ -28,7 +28,7 @@
//
skc_err
-skc_context_create_cl(skc_context_t * context,
+skc_context_create_cl(skc_context_t * context,
cl_context context_cl,
cl_device_id device_id_cl)
{
diff --git a/src/compute/skc/context.h b/src/compute/skc/context.h
index 65da835c9c..1dc026151e 100644
--- a/src/compute/skc/context.h
+++ b/src/compute/skc/context.h
@@ -49,7 +49,7 @@ struct skc_context
skc_err (* path_flush )(struct skc_runtime * const runtime,
skc_path_t const * paths,
uint32_t count);
-
+
//
//
//
diff --git a/src/compute/skc/extent_ring.c b/src/compute/skc/extent_ring.c
index ca489441ab..ecb41e6fcd 100644
--- a/src/compute/skc/extent_ring.c
+++ b/src/compute/skc/extent_ring.c
@@ -99,17 +99,17 @@ skc_extent_ring_snap_alloc(struct skc_runtime * const runtime,
{
skc_subbuf_id_t id;
- struct skc_extent_ring_snap * snap =
+ struct skc_extent_ring_snap * snap =
skc_runtime_host_temp_alloc(runtime,
SKC_MEM_FLAGS_READ_WRITE,
sizeof(*snap),&id,NULL);
// save the id
snap->id = id;
-
+
// back point to parent
snap->ring = ring;
snap->next = NULL;
-
+
// save the inner boundaries of the ring to the snapshot
snap->reads = ring->inner.reads;
snap->writes = ring->inner.reads = ring->inner.writes;
@@ -123,7 +123,7 @@ skc_extent_ring_snap_alloc(struct skc_runtime * const runtime,
ring->head = snap;
ring->last = snap;
}
- else
+ else
{
ring->last->next = snap;
ring->last = snap;
@@ -156,7 +156,7 @@ skc_extent_ring_snap_free(struct skc_runtime * const runtime,
do {
// increment read counter
ring->outer.reads = curr->writes;
-
+
struct skc_extent_ring_snap * const next = curr->next;
skc_runtime_host_temp_free(runtime,curr,curr->id);
@@ -164,7 +164,7 @@ skc_extent_ring_snap_free(struct skc_runtime * const runtime,
curr = next;
// this was the last snap...
- if (curr == NULL)
+ if (curr == NULL)
{
ring->last = NULL;
break;
diff --git a/src/compute/skc/grid.c b/src/compute/skc/grid.c
index fb5a073a16..3c5ebcdf4d 100644
--- a/src/compute/skc/grid.c
+++ b/src/compute/skc/grid.c
@@ -113,7 +113,7 @@ struct skc_grid
struct skc_grid_pfn_name waiting; // optional - if defined, typically used to yank the grid away from host
struct skc_grid_pfn_name execute; // optional - starts execution of waiting grid
struct skc_grid_pfn_name dispose; // optional - invoked when grid is complete
-
+
struct {
skc_uint words[SKC_GRID_SIZE_WORDS]; // 0:inactive, 1:active
skc_uint count;
@@ -535,7 +535,7 @@ skc_grid_clear_dependency(skc_grid_t const after, skc_uint const before)
after->before.count -= 1;
- if ((after->before.count == 0) && ((after->state == SKC_GRID_STATE_WAITING) ||
+ if ((after->before.count == 0) && ((after->state == SKC_GRID_STATE_WAITING) ||
(after->state == SKC_GRID_STATE_FORCED)))
{
// schedule grid for execution
diff --git a/src/compute/skc/handle.h b/src/compute/skc/handle.h
index 3751b653c9..34a3d7ab21 100644
--- a/src/compute/skc/handle.h
+++ b/src/compute/skc/handle.h
@@ -39,7 +39,7 @@ typedef enum skc_typed_handle_type_e
SKC_TYPED_HANDLE_TYPE_IS_PATH = 0x40000000,
SKC_TYPED_HANDLE_TYPE_IS_RASTER = 0x80000000
} skc_typed_handle_type_e;
-
+
typedef skc_uint skc_typed_handle_t;
typedef skc_uint skc_handle_t;
diff --git a/src/compute/skc/interop.h b/src/compute/skc/interop.h
index 555f3c41c4..775da8623f 100644
--- a/src/compute/skc/interop.h
+++ b/src/compute/skc/interop.h
@@ -52,7 +52,7 @@ void
skc_interop_blit(struct skc_interop * interop);
void
-skc_interop_get_size(struct skc_interop * interop,
+skc_interop_get_size(struct skc_interop * interop,
uint32_t * width,
uint32_t * height);
//
diff --git a/src/compute/skc/main.c b/src/compute/skc/main.c
index fe37324229..067d24c773 100644
--- a/src/compute/skc/main.c
+++ b/src/compute/skc/main.c
@@ -194,7 +194,7 @@ main(int argc, char** argv)
// rasterize, render and reclaim svg until escape
//
skc_pipeline_start_at_e pipeline_start_at_base = SKC_PIPELINE_START_AT_DEFINE_PATHS;
- skc_pipeline_start_at_e pipeline_start_at_loop = SKC_PIPELINE_START_AT_DEFINE_PATHS;
+ skc_pipeline_start_at_e pipeline_start_at_loop = SKC_PIPELINE_START_AT_DEFINE_PATHS;
skc_path_t * paths;
skc_raster_t * rasters;
@@ -269,7 +269,7 @@ main(int argc, char** argv)
// do we only want to run part of the pipeline?
if ((key >= SKC_PIPELINE_START_AT_DEFINE_PATHS) && (key <= SKC_PIPELINE_START_AT_RENDER))
pipeline_start_at_base = key;
-
+
// valid for a loop
pipeline_start_at_loop = pipeline_start_at_base;
diff --git a/src/compute/skc/path_builder.h b/src/compute/skc/path_builder.h
index c8e36dfbdf..a956475f49 100644
--- a/src/compute/skc/path_builder.h
+++ b/src/compute/skc/path_builder.h
@@ -55,10 +55,10 @@ struct skc_coords_rem_count_cubic
struct skc_path_builder
{
struct skc_context * context;
-
+
struct skc_path_builder_impl * impl;
- void (* begin )(struct skc_path_builder_impl * const impl);
+ void (* begin )(struct skc_path_builder_impl * const impl);
void (* end )(struct skc_path_builder_impl * const impl, skc_path_t * const path);
void (* new_line )(struct skc_path_builder_impl * const impl);
void (* new_quad )(struct skc_path_builder_impl * const impl);
diff --git a/src/compute/skc/platforms/cl_12/allocator_device_cl.c b/src/compute/skc/platforms/cl_12/allocator_device_cl.c
index 90ae26eb71..8003504706 100644
--- a/src/compute/skc/platforms/cl_12/allocator_device_cl.c
+++ b/src/compute/skc/platforms/cl_12/allocator_device_cl.c
@@ -57,7 +57,7 @@ skc_runtime_device_temp_alloc(struct skc_runtime * const runtime,
if (subbuf_size != NULL)
*subbuf_size = 0;
-
+
return NULL;
}
@@ -83,7 +83,7 @@ skc_runtime_device_temp_alloc(struct skc_runtime * const runtime,
void
-skc_runtime_device_temp_free(struct skc_runtime * const runtime,
+skc_runtime_device_temp_free(struct skc_runtime * const runtime,
cl_mem const mem,
skc_subbuf_id_t const subbuf_id)
{
@@ -92,7 +92,7 @@ skc_runtime_device_temp_free(struct skc_runtime * const runtime,
skc_suballocator_subbuf_free(&runtime->allocator.device.temp.suballocator,subbuf_id);
- cl(ReleaseMemObject(mem));
+ cl(ReleaseMemObject(mem));
}
//
@@ -116,7 +116,7 @@ skc_allocator_device_create(struct skc_runtime * const runtime)
cl_mem_flags const flags = CL_MEM_READ_WRITE;
#endif
- runtime->allocator.device.temp.extent =
+ runtime->allocator.device.temp.extent =
skc_runtime_device_perm_alloc(runtime,
flags,
runtime->config->suballocator.device.size);
diff --git a/src/compute/skc/platforms/cl_12/allocator_device_cl.h b/src/compute/skc/platforms/cl_12/allocator_device_cl.h
index 67d4e41398..08c4518a6a 100644
--- a/src/compute/skc/platforms/cl_12/allocator_device_cl.h
+++ b/src/compute/skc/platforms/cl_12/allocator_device_cl.h
@@ -28,7 +28,7 @@ struct skc_allocator_device
{
#if 0
struct {
-
+
} perm;
#endif
diff --git a/src/compute/skc/platforms/cl_12/composition_cl_12.c b/src/compute/skc/platforms/cl_12/composition_cl_12.c
index 7853564636..5db86762f3 100644
--- a/src/compute/skc/platforms/cl_12/composition_cl_12.c
+++ b/src/compute/skc/platforms/cl_12/composition_cl_12.c
@@ -118,7 +118,7 @@ struct skc_composition_place
static
void
-skc_composition_unseal_block(struct skc_composition_impl * const impl,
+skc_composition_unseal_block(struct skc_composition_impl * const impl,
skc_bool const block);
//
@@ -140,7 +140,7 @@ skc_composition_pfn_release(struct skc_composition_impl * const impl)
skc_composition_unseal_block(impl,true); // block
struct skc_runtime * const runtime = impl->runtime;
-
+
// free host composition
skc_runtime_host_perm_free(runtime,impl->composition);
@@ -149,7 +149,7 @@ skc_composition_pfn_release(struct skc_composition_impl * const impl)
// release kernels
cl(ReleaseKernel(impl->kernels.place));
- cl(ReleaseKernel(impl->kernels.segment));
+ cl(ReleaseKernel(impl->kernels.segment));
// release extents
skc_extent_phw1g_tdrNs_free(runtime,&impl->cmds.extent);
@@ -158,7 +158,7 @@ skc_composition_pfn_release(struct skc_composition_impl * const impl)
skc_extent_pdrw_free (runtime,&impl->keys);
skc_extent_pdrw_free (runtime,&impl->offsets);
-
+
// free composition impl
skc_runtime_host_perm_free(runtime,impl);
}
@@ -204,7 +204,7 @@ void
skc_composition_place_read_cb(cl_event event, cl_int status, skc_grid_t const grid)
{
SKC_CL_CB(status);
-
+
struct skc_composition_place * const place = skc_grid_get_data(grid);
struct skc_composition_impl * const impl = place->impl;
struct skc_runtime * const runtime = impl->runtime;
@@ -288,7 +288,7 @@ skc_composition_snap(struct skc_composition_impl * const impl)
// set grid data
skc_grid_set_data(impl->grids.place,place);
-
+
// acquire command queue
place->cq = skc_runtime_acquire_cq_in_order(impl->runtime);
@@ -297,7 +297,7 @@ skc_composition_snap(struct skc_composition_impl * const impl)
// make a snapshot
skc_extent_phw1g_tdrNs_snap_init(impl->runtime,&impl->cmds.ring,&place->cmds);
-
+
// unmap the snapshot (could be a copy)
skc_extent_phw1g_tdrNs_snap_alloc(impl->runtime,
&impl->cmds.extent,
@@ -382,7 +382,7 @@ skc_composition_sort_grid_pfn_execute(skc_grid_t const grid)
{
struct skc_composition_impl * const impl = skc_grid_get_data(grid);
- // we should be sealing
+ // we should be sealing
assert(impl->state == SKC_COMPOSITION_STATE_SEALING);
struct skc_place_atomics * const atomics = impl->atomics.hr;
@@ -422,7 +422,7 @@ skc_composition_sort_grid_pfn_execute(skc_grid_t const grid)
// next stage needs to know number of key segments
skc_extent_phr_pdrw_read(&impl->atomics,impl->cq,&complete);
-
+
// register a callback
cl(SetEventCallback(complete,CL_COMPLETE,skc_composition_sort_execute_cb,impl));
cl(ReleaseEvent(complete));
@@ -456,7 +456,7 @@ skc_composition_raster_release(struct skc_composition_impl * const impl)
static
void
-skc_composition_unseal_block(struct skc_composition_impl * const impl,
+skc_composition_unseal_block(struct skc_composition_impl * const impl,
skc_bool const block)
{
// return if already unsealed
@@ -526,7 +526,7 @@ skc_composition_reset(struct skc_composition_impl * const impl)
static
void
-skc_composition_unseal_block_reset(struct skc_composition_impl * const impl,
+skc_composition_unseal_block_reset(struct skc_composition_impl * const impl,
skc_bool const block,
skc_bool const reset)
{
@@ -590,7 +590,7 @@ skc_composition_pfn_place(struct skc_composition_impl * const impl,
SKC_TYPED_HANDLE_TYPE_IS_RASTER,
rasters,
count);
- if (err)
+ if (err)
return err;
skc_runtime_handle_device_retain(impl->runtime,rasters,count);
@@ -614,7 +614,7 @@ skc_composition_pfn_place(struct skc_composition_impl * const impl,
do {
skc_uint rem;
- // find out how much room is left in then ring's snap
+ // find out how much room is left in then ring's snap
// if the place ring is full -- let it drain
SKC_SCHEDULER_WAIT_WHILE(impl->runtime->scheduler,(rem = skc_extent_ring_wip_rem(&impl->cmds.ring)) == 0);
diff --git a/src/compute/skc/platforms/cl_12/composition_cl_12.h b/src/compute/skc/platforms/cl_12/composition_cl_12.h
index 81a544fdee..a6368d2bad 100644
--- a/src/compute/skc/platforms/cl_12/composition_cl_12.h
+++ b/src/compute/skc/platforms/cl_12/composition_cl_12.h
@@ -38,15 +38,15 @@ typedef enum skc_composition_state_e {
//
struct skc_composition_impl
-{
+{
struct skc_composition * composition;
struct skc_runtime * runtime;
-
+
SKC_ASSERT_STATE_DECLARE(skc_composition_state_e);
skc_int lock_count; // wip renders
- struct {
+ struct {
skc_grid_t place;
skc_grid_t sort;
} grids;
diff --git a/src/compute/skc/platforms/cl_12/config_cl.h b/src/compute/skc/platforms/cl_12/config_cl.h
index ac5cd76710..deef2db791 100644
--- a/src/compute/skc/platforms/cl_12/config_cl.h
+++ b/src/compute/skc/platforms/cl_12/config_cl.h
@@ -27,10 +27,10 @@ struct skc_config
} host; // alignment determined by compiler
struct {
skc_uint size;
- skc_uint subbufs;
+ skc_uint subbufs;
} device; // alignment determined by device
} suballocator;
-
+
struct {
skc_uint size;
} scheduler;
@@ -58,7 +58,7 @@ struct skc_config
struct {
skc_uint size; // a large fraction of block pool size
skc_uint width; // determines number of launched reclamation subgroups
- skc_uint recs; // how many in-flight width-subgroup reclamation grids
+ skc_uint recs; // how many in-flight width-subgroup reclamation grids
} handle_pool;
struct {
diff --git a/src/compute/skc/platforms/cl_12/cq_pool_cl.c b/src/compute/skc/platforms/cl_12/cq_pool_cl.c
index 2e37937b69..8d1537dc40 100644
--- a/src/compute/skc/platforms/cl_12/cq_pool_cl.c
+++ b/src/compute/skc/platforms/cl_12/cq_pool_cl.c
@@ -46,7 +46,7 @@ static
cl_command_queue
skc_runtime_cl_12_create_cq(struct skc_runtime * const runtime,
struct skc_cq_pool * const pool)
-
+
{
cl_command_queue cq;
@@ -59,7 +59,7 @@ skc_runtime_cl_12_create_cq(struct skc_runtime * const runtime,
cq = clCreateCommandQueue(runtime->cl.context,
runtime->cl.device_id,
pool->cq_props,
- &cl_err); cl_ok(cl_err);
+ &cl_err); cl_ok(cl_err);
#else
if (runtime_cl->version.major < 2)
{
@@ -71,7 +71,7 @@ skc_runtime_cl_12_create_cq(struct skc_runtime * const runtime,
cq = clCreateCommandQueue(runtime_cl->context,
runtime_cl->device_id,
(cl_command_queue_properties)type,
- &cl_err); cl_ok(cl_err);
+ &cl_err); cl_ok(cl_err);
}
else
{
@@ -135,7 +135,7 @@ skc_cq_pool_dispose(struct skc_runtime * const runtime,
//
//
-static
+static
void
skc_cq_pool_write(struct skc_cq_pool * const pool,
cl_command_queue cq)
@@ -174,7 +174,7 @@ skc_cq_pool_expand(struct skc_runtime * const runtime,
//
//
-static
+static
cl_command_queue
skc_cq_pool_read(struct skc_runtime * const runtime,
struct skc_cq_pool * const pool)
@@ -199,7 +199,7 @@ skc_runtime_acquire_cq_in_order(struct skc_runtime * const runtime)
}
void
-skc_runtime_release_cq_in_order(struct skc_runtime * const runtime,
+skc_runtime_release_cq_in_order(struct skc_runtime * const runtime,
cl_command_queue cq)
{
skc_cq_pool_write(&runtime->cq_pool,cq);
diff --git a/src/compute/skc/platforms/cl_12/cq_pool_cl.h b/src/compute/skc/platforms/cl_12/cq_pool_cl.h
index c614600e19..b0953c053a 100644
--- a/src/compute/skc/platforms/cl_12/cq_pool_cl.h
+++ b/src/compute/skc/platforms/cl_12/cq_pool_cl.h
@@ -14,7 +14,7 @@
// Why we need to wrap command queue creation:
//
// - command queue creation is expensive
-//
+//
// - the CL 1.2 function is deprecated in 2.0
//
diff --git a/src/compute/skc/platforms/cl_12/device_cl_12.h b/src/compute/skc/platforms/cl_12/device_cl_12.h
index ef574958b3..11dc208224 100644
--- a/src/compute/skc/platforms/cl_12/device_cl_12.h
+++ b/src/compute/skc/platforms/cl_12/device_cl_12.h
@@ -33,7 +33,7 @@ typedef enum skc_device_kernel_id {
SKC_DEVICE_KERNEL_ID_FILLS_EXPAND,
- SKC_DEVICE_KERNEL_ID_RASTERIZE_ALL,
+ SKC_DEVICE_KERNEL_ID_RASTERIZE_ALL,
SKC_DEVICE_KERNEL_ID_RASTERIZE_LINES,
SKC_DEVICE_KERNEL_ID_RASTERIZE_QUADS,
SKC_DEVICE_KERNEL_ID_RASTERIZE_CUBICS,
@@ -69,12 +69,12 @@ void
skc_device_dispose(struct skc_runtime * const runtime);
-//
+//
// multi-threading/context/device requires multiple kernel instances
//
cl_kernel
-skc_device_acquire_kernel(struct skc_device * const device,
+skc_device_acquire_kernel(struct skc_device * const device,
skc_device_kernel_id const type);
void
@@ -85,13 +85,13 @@ skc_device_release_kernel(struct skc_device * const device,
// grid shape can vary greatly by target platform
//
void
-skc_device_enqueue_kernel(struct skc_device * const device,
+skc_device_enqueue_kernel(struct skc_device * const device,
skc_device_kernel_id const type,
cl_command_queue cq,
cl_kernel kernel,
- size_t const work_size,
+ size_t const work_size,
cl_uint num_events_in_wait_list,
- cl_event const * const event_wait_list,
+ cl_event const * const event_wait_list,
cl_event * const event);
//
diff --git a/src/compute/skc/platforms/cl_12/export_cl_12.h b/src/compute/skc/platforms/cl_12/export_cl_12.h
index e577282791..23ff2343e6 100644
--- a/src/compute/skc/platforms/cl_12/export_cl_12.h
+++ b/src/compute/skc/platforms/cl_12/export_cl_12.h
@@ -15,7 +15,7 @@
#include "skc.h"
//
-//
+//
//
skc_err
@@ -23,7 +23,7 @@ skc_path_builder_cl_12_create(struct skc_context * const context,
struct skc_path_builder * * const path_builder);
//
-//
+//
//
skc_err
diff --git a/src/compute/skc/platforms/cl_12/extent_cl_12.c b/src/compute/skc/platforms/cl_12/extent_cl_12.c
index 73676d8063..e145d979c2 100644
--- a/src/compute/skc/platforms/cl_12/extent_cl_12.c
+++ b/src/compute/skc/platforms/cl_12/extent_cl_12.c
@@ -127,7 +127,7 @@ skc_extent_phr_pdrw_read(struct skc_extent_phr_pdrw * const extent,
if (extent->size == 0)
return;
- cl(EnqueueReadBuffer(cq,
+ cl(EnqueueReadBuffer(cq,
extent->drw,
CL_FALSE,
0,
@@ -191,7 +191,7 @@ skc_extent_thr_tdrw_read(struct skc_extent_thr_tdrw * const extent,
if (extent->size == 0)
return;
- cl(EnqueueReadBuffer(cq,
+ cl(EnqueueReadBuffer(cq,
extent->drw,
CL_FALSE,
0,
diff --git a/src/compute/skc/platforms/cl_12/extent_cl_12.h b/src/compute/skc/platforms/cl_12/extent_cl_12.h
index 47ba951bb3..1801c9c57f 100644
--- a/src/compute/skc/platforms/cl_12/extent_cl_12.h
+++ b/src/compute/skc/platforms/cl_12/extent_cl_12.h
@@ -40,7 +40,7 @@
// DURABLE R/W HOST EXTENT -- STANDARD CACHED MEMORY
//
-struct skc_extent_phrw
+struct skc_extent_phrw
{
void * hrw;
};
@@ -58,7 +58,7 @@ skc_extent_phrw_free(struct skc_runtime * const runtime,
// DURABLE R/W DEVICE EXTENT -- ALLOCATED FROM DEVICE HEAP
//
-struct skc_extent_pdrw
+struct skc_extent_pdrw
{
cl_mem drw;
};
@@ -76,7 +76,7 @@ skc_extent_pdrw_free(struct skc_runtime * const runtime,
// EPHEMERAL DEVICE R/W EXTENT -- ALLOCATED QUICKLY FROM A MANAGED RING
//
-struct skc_extent_tdrw
+struct skc_extent_tdrw
{
size_t size;
cl_mem drw;
diff --git a/src/compute/skc/platforms/cl_12/handle_pool_cl_12.h b/src/compute/skc/platforms/cl_12/handle_pool_cl_12.h
index 4fefae3552..455d9384a1 100644
--- a/src/compute/skc/platforms/cl_12/handle_pool_cl_12.h
+++ b/src/compute/skc/platforms/cl_12/handle_pool_cl_12.h
@@ -88,7 +88,7 @@ union skc_handle_reclaim_rec
{
// ELEMENT 0
struct skc_runtime * runtime;
-
+
// ELEMENT 1
struct {
skc_uint rem; // # of available records
diff --git a/src/compute/skc/platforms/cl_12/interop/interop_glfw.c b/src/compute/skc/platforms/cl_12/interop/interop_glfw.c
index a5c0bfcb57..8f94100552 100644
--- a/src/compute/skc/platforms/cl_12/interop/interop_glfw.c
+++ b/src/compute/skc/platforms/cl_12/interop/interop_glfw.c
@@ -132,7 +132,7 @@ void
skc_interop_key_callback(GLFWwindow * window, int key, int scancode, int action, int mods)
{
struct skc_interop * interop = glfwGetWindowUserPointer(window);
-
+
if (action == GLFW_RELEASE)
return;
@@ -182,7 +182,7 @@ void
skc_interop_window_size_callback(GLFWwindow * window, int width, int height)
{
struct skc_interop * interop = glfwGetWindowUserPointer(window);
-
+
interop->width = width;
interop->height = height;
interop->is_resized = true;
@@ -217,7 +217,7 @@ skc_interop_scroll_callback(GLFWwindow * window, double xoffset, double yoffset)
if (!ctrl)
return;
- struct skc_interop * interop = glfwGetWindowUserPointer(window);
+ struct skc_interop * interop = glfwGetWindowUserPointer(window);
skc_interop_scale(interop,yoffset);
@@ -242,7 +242,7 @@ static
void
skc_interop_cursor_position_callback(GLFWwindow * window, double x, double y)
{
-
+
int const state = glfwGetMouseButton(window,GLFW_MOUSE_BUTTON_LEFT);
static bool is_mouse_dragging = false;
@@ -253,8 +253,8 @@ skc_interop_cursor_position_callback(GLFWwindow * window, double x, double y)
if (state == GLFW_PRESS)
{
- struct skc_interop * interop = glfwGetWindowUserPointer(window);
-
+ struct skc_interop * interop = glfwGetWindowUserPointer(window);
+
if (is_mouse_dragging)
{
const bool ctrl =
@@ -294,7 +294,7 @@ skc_interop_cursor_position_callback(GLFWwindow * window, double x, double y)
mx - x_prev,
my - y_prev);
}
-
+
interop->is_transform = true;
}
else
@@ -417,7 +417,7 @@ skc_interop_create()
// save back pointer
glfwSetWindowUserPointer(interop->window,interop);
-
+
glfwMakeContextCurrent(interop->window);
// set up GLAD
@@ -519,7 +519,7 @@ skc_interop_transform(struct skc_interop * interop,
// spinner...
if (interop->is_spinning)
interop->rotate_theta = fmodf(interop->rotate_theta + SKC_ROTATE_STEP,(float)(M_PI*2.0));
-
+
// always rotate and scale around surface center point
skc_transform_stack_push_rotate_scale_xy(ts,
interop->rotate_theta,
@@ -673,7 +673,7 @@ skc_interop_poll(struct skc_interop * interop, int * key)
bool const is_transform = interop->is_transform || interop->is_spinning;
interop->is_transform = false;
-
+
return is_transform;
}
@@ -736,7 +736,7 @@ skc_interop_should_exit(struct skc_interop * interop)
//
void
-skc_interop_get_size(struct skc_interop * interop,
+skc_interop_get_size(struct skc_interop * interop,
uint32_t * width,
uint32_t * height)
{
diff --git a/src/compute/skc/platforms/cl_12/kernels/devices/gen9/device_cl_12.c b/src/compute/skc/platforms/cl_12/kernels/devices/gen9/device_cl_12.c
index d7f10e38bf..0be97235f3 100644
--- a/src/compute/skc/platforms/cl_12/kernels/devices/gen9/device_cl_12.c
+++ b/src/compute/skc/platforms/cl_12/kernels/devices/gen9/device_cl_12.c
@@ -90,7 +90,7 @@
// FIXME -- move these to log2 values where appropriate
//
-static
+static
struct skc_config const config =
{
.suballocator = {
@@ -102,7 +102,7 @@ struct skc_config const config =
.size = 128 * 1024 * 1024,
.subbufs = 1024 // must be <= (1 << (8 * sizeof(skc_subbuf_id_t)))
}
- },
+ },
.scheduler = {
.size = 4096 // 128 // FIXME -- this is just for testing -- way too big -- schedulees should bring their own state
@@ -382,7 +382,7 @@ skc_device_shaper_paths_copy(size_t const work_size,
work_local [0] = SKC_PATHS_COPY_SUBGROUP_SIZE;
return work_local;
-#else
+#else
return NULL; // let runtime figure out local work size
#endif
}
@@ -659,7 +659,7 @@ struct skc_device
{
//
// FIXME -- an OpenCL 2.1+ device would clone these kernels in a
- // multithreaded system.
+ // multithreaded system.
//
// Not having the ability to clone kernels (yet set their sticky
// args) was an oversight in previous versions of OpenCL.
diff --git a/src/compute/skc/platforms/cl_12/path_builder_cl_12.c b/src/compute/skc/platforms/cl_12/path_builder_cl_12.c
index e915dffada..e0a9d029ee 100644
--- a/src/compute/skc/platforms/cl_12/path_builder_cl_12.c
+++ b/src/compute/skc/platforms/cl_12/path_builder_cl_12.c
@@ -256,7 +256,7 @@ struct skc_path_builder_impl
static
union skc_ringdex_expand
-skc_ringdex_expand(struct skc_path_builder_impl * const impl,
+skc_ringdex_expand(struct skc_path_builder_impl * const impl,
skc_ringdex_t const ringdex)
{
return (union skc_ringdex_expand){
@@ -322,7 +322,7 @@ skc_ringdex_prev_is_equal(struct skc_path_builder_impl * const impl)
static
skc_uint
-skc_ringdex_dont_map_last(struct skc_path_builder_impl * const impl,
+skc_ringdex_dont_map_last(struct skc_path_builder_impl * const impl,
skc_uint const to_block)
{
// no blocks acquired OR this is last block in subbuf
@@ -509,7 +509,7 @@ skc_path_builder_impl_unmap(struct skc_path_builder_impl * const impl,
#if 0
fprintf(stderr,"unmap: [%2u,%2u)\n",from,to);
#endif
-
+
while (from != to) // 'to' might be out of range
{
// bring 'from' back in range
@@ -647,9 +647,9 @@ void
skc_path_builder_paths_copy_cb(cl_event event, cl_int status, skc_grid_t grid)
{
SKC_CL_CB(status);
-
+
struct skc_release_record * const release = skc_grid_get_data(grid);
-
+
SKC_SCHEDULER_SCHEDULE(release->impl->runtime->scheduler,skc_path_builder_complete,grid);
}
@@ -802,7 +802,7 @@ skc_path_builder_grid_pfn_waiting(skc_grid_t const grid)
// if there was no wip then round up to the next subbuf
//
skc_ringdex_wip_to_subbuf_inc(impl);
-
+
//
// update prev/curr with with incremented wip
//
diff --git a/src/compute/skc/platforms/cl_12/raster_builder_cl_12.c b/src/compute/skc/platforms/cl_12/raster_builder_cl_12.c
index 33992cbdfb..d84b92bfd7 100644
--- a/src/compute/skc/platforms/cl_12/raster_builder_cl_12.c
+++ b/src/compute/skc/platforms/cl_12/raster_builder_cl_12.c
@@ -329,7 +329,7 @@ skc_raster_builder_pfn_release(struct skc_raster_builder_impl * const impl)
//
//
-static
+static
void
skc_raster_builder_rasters_release(struct skc_runtime * const runtime,
skc_raster_t const * const rasters,
@@ -344,12 +344,12 @@ skc_raster_builder_rasters_release(struct skc_runtime * const runtime,
skc_grid_deps_unmap(runtime->deps,rasters_from,count_from);
skc_runtime_raster_device_release(runtime,rasters_from,count_from);
- }
+ }
else // from > to implies wrap
{
skc_raster_t const * rasters_lo = rasters + from;
skc_uint count_lo = size - from;
-
+
skc_grid_deps_unmap(runtime->deps,rasters_lo,count_lo);
skc_runtime_raster_device_release(runtime,rasters_lo,count_lo);
@@ -358,7 +358,7 @@ skc_raster_builder_rasters_release(struct skc_runtime * const runtime,
}
}
-static
+static
void
skc_raster_builder_paths_release(struct skc_runtime * const runtime,
struct skc_extent_phrwg_thr1s_snap * const snap)
@@ -401,7 +401,7 @@ skc_raster_builder_cohort_grid_pfn_dispose(skc_grid_t const grid)
// snap alloc the paths -- this host snap simply sets up pointers
skc_extent_phrwg_thr1s_snap_alloc(runtime,&impl->path_ids,&cohort->path_ids);
-
+
// unmap and release raster ids
skc_raster_builder_paths_release(runtime,&cohort->path_ids);
@@ -418,7 +418,7 @@ skc_raster_builder_cohort_grid_pfn_dispose(skc_grid_t const grid)
// unmap and release raster ids
skc_raster_builder_rasters_release(runtime,impl->raster_ids.hrw,size,from,to);
- // release cohort's remaining allocated resources
+ // release cohort's remaining allocated resources
skc_extent_phrwg_tdrNs_snap_free(runtime,&cohort->raster_ids);
skc_runtime_release_cq_in_order(runtime,cohort->cq);
skc_extent_thr_tdrw_free(runtime,&cohort->atomics);
@@ -458,7 +458,7 @@ skc_raster_cohort_prefix_release(skc_grid_t const grid)
// FIXME -- note that pfn_dispose can be accomplished here
// release the grid
- skc_grid_complete(grid);
+ skc_grid_complete(grid);
}
static
@@ -466,7 +466,7 @@ void
skc_raster_cohort_prefix_cb(cl_event event, cl_int status, skc_grid_t const grid)
{
SKC_CL_CB(status);
-
+
struct skc_raster_cohort * const cohort = skc_grid_get_data(grid);
struct skc_scheduler * const scheduler = cohort->impl->runtime->scheduler;
@@ -599,7 +599,7 @@ skc_raster_cohort_sort_prefix(skc_grid_t const grid)
// DELETE ALL THIS WHEN READY
//
-#if 0
+#if 0
//
//
//
@@ -625,7 +625,7 @@ skc_raster_cohort_sort_prefix(skc_grid_t const grid)
//
// some counters
//
- union skc_raster_cohort_meta_in meta_in = {
+ union skc_raster_cohort_meta_in meta_in = {
.blocks = 0,
.offset = 0,
.pk = 0,
@@ -665,10 +665,10 @@ skc_raster_cohort_sort_prefix(skc_grid_t const grid)
// store back to buffer
metas->inout[curr.cohort].in = meta_in;
-
+
// update meta_in
meta_in.blocks = 0;
- meta_in.offset = ii;
+ meta_in.offset = ii;
meta_in.pk = 0;
meta_in.rk = 0;
}
@@ -699,7 +699,7 @@ skc_raster_cohort_sort_prefix(skc_grid_t const grid)
// store back to buffer
metas->inout[curr.cohort].in = meta_in;
-
+
// unmap
skc_extent_thrw_tdrw_unmap(&cohort->keys,
keys,
@@ -795,7 +795,7 @@ void
skc_raster_cohort_rasterize_cb(cl_event event, cl_int status, skc_grid_t const grid)
{
SKC_CL_CB(status);
-
+
struct skc_raster_cohort * const cohort = skc_grid_get_data(grid);
// as quickly as possible, enqueue next stage in pipeline to context command scheduler
@@ -1079,7 +1079,7 @@ skc_raster_builder_cohort_grid_pfn_waiting(skc_grid_t const grid)
// allocate the ephemeral/temp cohort
skc_subbuf_id_t id;
- struct skc_raster_cohort * const cohort =
+ struct skc_raster_cohort * const cohort =
skc_runtime_host_temp_alloc(runtime,
SKC_MEM_FLAGS_READ_WRITE,
sizeof(*cohort),
@@ -1145,7 +1145,7 @@ skc_raster_builder_cohort_create(struct skc_raster_builder_impl * const impl)
static
skc_err
-skc_raster_builder_pfn_add(struct skc_raster_builder_impl * const impl,
+skc_raster_builder_pfn_add(struct skc_raster_builder_impl * const impl,
skc_path_t const * paths,
skc_uint count)
{
@@ -1329,7 +1329,7 @@ skc_raster_builder_cl_12_create(struct skc_context * const context,
// acquire kernels
//
impl->kernels.fills_expand = skc_device_acquire_kernel(runtime->device, SKC_DEVICE_KERNEL_ID_FILLS_EXPAND);
- impl->kernels.rasterize_all = skc_device_acquire_kernel(runtime->device, SKC_DEVICE_KERNEL_ID_RASTERIZE_ALL);
+ impl->kernels.rasterize_all = skc_device_acquire_kernel(runtime->device, SKC_DEVICE_KERNEL_ID_RASTERIZE_ALL);
#if 0
impl->kernels.rasterize_lines = skc_device_acquire_kernel(runtime->device, SKC_DEVICE_KERNEL_ID_RASTERIZE_LINES);
diff --git a/src/compute/skc/platforms/cl_12/runtime_cl_12.c b/src/compute/skc/platforms/cl_12/runtime_cl_12.c
index 81e1e8569e..81f3aba02f 100644
--- a/src/compute/skc/platforms/cl_12/runtime_cl_12.c
+++ b/src/compute/skc/platforms/cl_12/runtime_cl_12.c
@@ -31,7 +31,7 @@
//
//
-static
+static
void
skc_block_pool_create(struct skc_runtime * const runtime, cl_command_queue cq)
{
@@ -41,7 +41,7 @@ skc_block_pool_create(struct skc_runtime * const runtime, cl_command_queue cq)
// create block extent
skc_extent_pdrw_alloc(runtime,
&runtime->block_pool.blocks,
- runtime->block_pool.size->pool_size *
+ runtime->block_pool.size->pool_size *
runtime->config->block.bytes);
// allocate block pool ids
@@ -84,7 +84,7 @@ skc_block_pool_create(struct skc_runtime * const runtime, cl_command_queue cq)
cl(ReleaseKernel(k1));
}
-static
+static
void
skc_block_pool_dispose(struct skc_runtime * const runtime)
{
@@ -105,7 +105,7 @@ skc_runtime_yield(struct skc_runtime * const runtime)
}
static
-void
+void
skc_runtime_wait(struct skc_runtime * const runtime)
{
skc_scheduler_wait(runtime->scheduler);
@@ -122,7 +122,7 @@ skc_runtime_cl_12_create(struct skc_context * const context,
{
// allocate the runtime
struct skc_runtime * const runtime = malloc(sizeof(*runtime));
-
+
// save off CL objects
runtime->cl.context = context_cl;
runtime->cl.device_id = device_id_cl;
@@ -135,7 +135,7 @@ skc_runtime_cl_12_create(struct skc_context * const context,
sizeof(align_bits),
&align_bits,
NULL));
-
+
runtime->cl.align_bytes = align_bits / 8;
// create device
@@ -183,7 +183,7 @@ skc_runtime_cl_12_create(struct skc_context * const context,
context->yield = skc_runtime_yield;
context->wait = skc_runtime_wait;
-
+
context->path_builder = skc_path_builder_cl_12_create;
context->path_retain = skc_runtime_path_host_retain;
context->path_release = skc_runtime_path_host_release;
@@ -196,7 +196,7 @@ skc_runtime_cl_12_create(struct skc_context * const context,
context->composition = skc_composition_cl_12_create;
context->styling = skc_styling_cl_12_create;
-
+
context->surface = skc_surface_cl_12_create;
// block on pool creation
@@ -234,7 +234,7 @@ skc_runtime_cl_12_dispose(struct skc_context * const context)
skc_block_pool_dispose(context->runtime);
// skc_handle_pool_dispose(context->runtime);
-
+
return SKC_ERR_SUCCESS;
}
@@ -246,7 +246,7 @@ void
skc_runtime_cl_12_debug(struct skc_context * const context)
{
struct skc_runtime * const runtime = context->runtime;
-
+
// acquire out-of-order cq
cl_command_queue cq = skc_runtime_acquire_cq_in_order(runtime);
diff --git a/src/compute/skc/platforms/cl_12/styling_cl_12.c b/src/compute/skc/platforms/cl_12/styling_cl_12.c
index 8d8d90525d..9621a1f4b5 100644
--- a/src/compute/skc/platforms/cl_12/styling_cl_12.c
+++ b/src/compute/skc/platforms/cl_12/styling_cl_12.c
@@ -32,7 +32,7 @@ void
skc_styling_unmap_complete(skc_grid_t const grid)
{
struct skc_styling_impl * const impl = skc_grid_get_data(grid);
-
+
impl->state = SKC_STYLING_STATE_SEALED;
skc_grid_complete(grid);
@@ -65,7 +65,7 @@ skc_styling_grid_pfn_execute(skc_grid_t const grid)
skc_extent_phwN_pdrN_unmap(&impl->layers,styling->layers.extent,impl->cq,NULL);
skc_extent_phwN_pdrN_unmap(&impl->groups,styling->groups.extent,impl->cq,NULL);
- skc_extent_phwN_pdrN_unmap(&impl->extras,styling->extras.extent,impl->cq,&complete);
+ skc_extent_phwN_pdrN_unmap(&impl->extras,styling->extras.extent,impl->cq,&complete);
// set the event
cl(SetEventCallback(complete,CL_COMPLETE,skc_styling_unmap_cb,grid));
@@ -97,7 +97,7 @@ skc_styling_pfn_seal(struct skc_styling_impl * const impl)
{
SKC_SCHEDULER_WAIT_WHILE(scheduler,impl->state != SKC_STYLING_STATE_UNSEALED);
}
-
+
//
// we're unsealed so we need to seal and start the grid
//
@@ -121,7 +121,7 @@ void
skc_styling_unseal_complete(struct skc_styling_impl * const impl)
{
struct skc_runtime * const runtime = impl->runtime;
-
+
// we're now unsealed
impl->state = SKC_STYLING_STATE_UNSEALED;
}
@@ -131,7 +131,7 @@ void
skc_styling_unseal_cb(cl_event event, cl_int status, struct skc_styling_impl * const impl)
{
SKC_CL_CB(status);
-
+
// as quickly as possible, enqueue next stage in pipeline to context command scheduler
SKC_SCHEDULER_SCHEDULE(impl->runtime->scheduler,skc_styling_unseal_complete,impl);
}
@@ -166,10 +166,10 @@ skc_styling_pfn_unseal(struct skc_styling_impl * const impl, skc_bool const bloc
//
if (impl->state == SKC_STYLING_STATE_SEALING)
{
- // wait if sealing
+ // wait if sealing
SKC_SCHEDULER_WAIT_WHILE(scheduler,impl->state != SKC_STYLING_STATE_SEALED);
}
-
+
// wait for rendering locks to be released
SKC_SCHEDULER_WAIT_WHILE(scheduler,impl->lock_count > 0);
@@ -183,7 +183,7 @@ skc_styling_pfn_unseal(struct skc_styling_impl * const impl, skc_bool const bloc
cl_event complete;
struct skc_styling * const styling = impl->styling;
-
+
styling->layers.extent = skc_extent_phwN_pdrN_map(&impl->layers,impl->cq,NULL);
styling->groups.extent = skc_extent_phwN_pdrN_map(&impl->groups,impl->cq,NULL);
styling->extras.extent = skc_extent_phwN_pdrN_map(&impl->extras,impl->cq,&complete);
@@ -239,7 +239,7 @@ skc_styling_pfn_release(struct skc_styling_impl * const impl)
// release the cq
skc_runtime_release_cq_in_order(runtime,impl->cq);
-
+
// free extents
skc_extent_phwN_pdrN_free(runtime,&impl->layers);
skc_extent_phwN_pdrN_free(runtime,&impl->groups);
@@ -301,7 +301,7 @@ skc_styling_cl_12_create(struct skc_context * const context,
impl->lock_count = 0;
impl->cq = skc_runtime_acquire_cq_in_order(runtime);
-
+
//
// The styling object is unique in that the API lets the user
// specify resource limits
diff --git a/src/compute/skc/platforms/cl_12/styling_cl_12.h b/src/compute/skc/platforms/cl_12/styling_cl_12.h
index a319568ee5..e50361f555 100644
--- a/src/compute/skc/platforms/cl_12/styling_cl_12.h
+++ b/src/compute/skc/platforms/cl_12/styling_cl_12.h
@@ -40,7 +40,7 @@ struct skc_styling_impl
{
struct skc_styling * styling;
struct skc_runtime * runtime;
-
+
SKC_ASSERT_STATE_DECLARE(skc_styling_state_e);
skc_int lock_count; // # of wip renders
diff --git a/src/compute/skc/platforms/cl_12/surface_cl_12.c b/src/compute/skc/platforms/cl_12/surface_cl_12.c
index 24a0c45f3c..c4e205a04b 100644
--- a/src/compute/skc/platforms/cl_12/surface_cl_12.c
+++ b/src/compute/skc/platforms/cl_12/surface_cl_12.c
@@ -80,7 +80,7 @@ static
void
skc_surface_debug_clear(struct skc_surface_impl * const impl,
skc_framebuffer_t fb,
- float const rgba[4],
+ float const rgba[4],
uint32_t const rect[4])
{
size_t const origin[3] = { rect[0], rect[1], 0 };
@@ -150,11 +150,11 @@ skc_surface_pfn_release(struct skc_surface_impl * const impl)
//
// otherwise, release all resources
//
-
+
// drain the command queue
cl(Finish(impl->cq));
- struct skc_runtime * const runtime = impl->runtime;
+ struct skc_runtime * const runtime = impl->runtime;
// release the kernel
cl(ReleaseKernel(impl->kernels.render));
@@ -167,7 +167,7 @@ skc_surface_pfn_release(struct skc_surface_impl * const impl)
// release fb
// skc_extent_phrN_pdwN_free(runtime,&impl->fb);
-
+
// free surface impl
skc_runtime_host_perm_free(runtime,impl);
}
@@ -200,7 +200,7 @@ skc_surface_render_complete(struct skc_surface_render * const render)
// grid is now complete
skc_grid_complete(render->grid);
- struct skc_surface_impl * const impl = render->impl;
+ struct skc_surface_impl * const impl = render->impl;
struct skc_runtime * const runtime = impl->runtime;
// release the surface
@@ -341,7 +341,7 @@ skc_surface_pfn_render(struct skc_surface_impl * const impl,
// them here.
//
- // retain and lock the styling and composition
+ // retain and lock the styling and composition
skc_styling_retain_and_lock(styling);
skc_composition_retain_and_lock(composition);
diff --git a/src/compute/skc/raster_builder.c b/src/compute/skc/raster_builder.c
index a0f1fcfdb0..b86ff93d08 100644
--- a/src/compute/skc/raster_builder.c
+++ b/src/compute/skc/raster_builder.c
@@ -155,7 +155,7 @@ skc_raster_builder_transforms_append(struct skc_raster_builder * const raster_bu
static
skc_bool
skc_raster_builder_clips_append(struct skc_raster_builder * const raster_builder,
- union skc_cmd_fill * const cmd,
+ union skc_cmd_fill * const cmd,
skc_raster_clip_weakref_t * const raster_clip_weakref,
skc_float const * const raster_clip)
{
@@ -183,7 +183,7 @@ skc_raster_builder_cmds_append(struct skc_raster_builder * const raster_builder,
cmd->cohort = skc_extent_ring_wip_count(&raster_builder->raster_ids.ring);
skc_uint const base = skc_extent_ring_wip_index_inc(&raster_builder->fill_cmds.ring);
-
+
raster_builder->fill_cmds.extent[base] = *cmd;
#if 0
@@ -292,7 +292,7 @@ skc_raster_add_filled(skc_raster_builder_t raster_builder,
// mask off the guard bits
path = SKC_TYPED_HANDLE_TO_HANDLE(path);
- //
+ //
// build the command...
//
union skc_cmd_fill cmd;
diff --git a/src/compute/skc/scheduler.cpp b/src/compute/skc/scheduler.cpp
index 1099deb1ca..8171f64002 100644
--- a/src/compute/skc/scheduler.cpp
+++ b/src/compute/skc/scheduler.cpp
@@ -63,8 +63,8 @@ struct skc_scheduler_command
void * data;
skc_scheduler_command_pfn pfn;
skc_scheduler_command_state state;
- char const * name;
-};
+ char const * name;
+};
#if 0
struct skc_scheduler_command
diff --git a/src/compute/skc/scheduler.h b/src/compute/skc/scheduler.h
index 334cb0f69c..78da50be2a 100644
--- a/src/compute/skc/scheduler.h
+++ b/src/compute/skc/scheduler.h
@@ -18,12 +18,12 @@
#include "types.h"
//
-//
+//
//
#define SKC_SCHEDULER_SCHEDULE(s,c,d) skc_scheduler_schedule(s,c,d,#c)
-#ifndef NDEBUG
+#ifndef NDEBUG
#include <stdio.h>
@@ -70,7 +70,7 @@ skc_scheduler_create(struct skc_runtime * const runtime, skc_uint const size);
void
skc_scheduler_dispose(struct skc_runtime * const runtime,
struct skc_scheduler * const scheduler);
-
+
//
//
diff --git a/src/compute/skc/styling.h b/src/compute/skc/styling.h
index 7f20c1e489..310a739a07 100644
--- a/src/compute/skc/styling.h
+++ b/src/compute/skc/styling.h
@@ -27,7 +27,7 @@ struct skc_styling
void (* seal )(struct skc_styling_impl * const impl);
void (* unseal )(struct skc_styling_impl * const impl, skc_bool const block);
void (* release)(struct skc_styling_impl * const impl);
-
+
skc_int ref_count;
struct {
diff --git a/src/compute/skc/styling_types.h b/src/compute/skc/styling_types.h
index 07d9a10ca3..ee0e7aa7e3 100644
--- a/src/compute/skc/styling_types.h
+++ b/src/compute/skc/styling_types.h
@@ -127,7 +127,7 @@ SKC_STATIC_ASSERT(sizeof(struct skc_group_node) == sizeof(skc_uint2) * 3); // 6
union skc_gradient_slope
{
skc_float slope;
- skc_half color_pair[2];
+ skc_half color_pair[2];
};
SKC_STATIC_ASSERT(sizeof(union skc_gradient_slope) == sizeof(skc_float));
@@ -174,7 +174,7 @@ SKC_STATIC_ASSERT(sizeof(union skc_gradient_vector) == sizeof(skc_float4));
// +------------+---------------------------------+--------+-------------------------+
//
// COLOR LAYOUT:
-//
+//
// R[0]R[1], R[1]R[2], ... R[N-1]R[N-1]
// G[0]G[1], G[1]G[2], ... G[N-1]G[N-1]
// B[0]B[1], B[1]B[2], ... B[N-1]B[N-1]
@@ -203,7 +203,7 @@ SKC_STATIC_ASSERT(sizeof(union skc_gradient_vector) == sizeof(skc_float4));
// +------------+--------------------------------+--------+
//
// COLOR LAYOUT:
-//
+//
// R[0]R[1], R[1]R[2], ... R[N-1]R[N-1] <-------------------------- FIXME -- USE HERB'S SINGLE FMA REPRESENTATION
// G[0]G[1], G[1]G[2], ... G[N-1]G[N-1] <-------------------------- FIXME -- USE HERB'S SINGLE FMA REPRESENTATION
// B[0]B[1], B[1]B[2], ... B[N-1]B[N-1] <-------------------------- FIXME -- USE HERB'S SINGLE FMA REPRESENTATION
@@ -222,7 +222,7 @@ SKC_STATIC_ASSERT(sizeof(union skc_gradient_vector) == sizeof(skc_float4));
// This will require that the colors are laid out in sampler-friendly
// order:
//
-// RGBA[0]RGBA[1], RGBA[1]RGBA[2], ..., RGBA[N-1]RGBA[N-1]
+// RGBA[0]RGBA[1], RGBA[1]RGBA[2], ..., RGBA[N-1]RGBA[N-1]
//
//
@@ -247,4 +247,4 @@ SKC_STATIC_ASSERT(sizeof(union skc_gradient_vector) == sizeof(skc_float4));
//
//
-
+
diff --git a/src/compute/skc/suballocator.c b/src/compute/skc/suballocator.c
index 382e818c27..c6b9ec1681 100644
--- a/src/compute/skc/suballocator.c
+++ b/src/compute/skc/suballocator.c
@@ -178,7 +178,7 @@ skc_suballocator_subbuf_alloc(struct skc_suballocator * const suballocator,
}
assert(suballocator->rem.avail > 0);
-
+
// return origin
return avail->origin;
}
@@ -189,7 +189,7 @@ skc_suballocator_subbuf_alloc(struct skc_suballocator * const suballocator,
skc_uint spare_idx = suballocator->count - spare_rem;
skc_subbuf_id_t const spare_id = ids[spare_idx];
struct skc_subbuf * const spare = suballocator->subbufs + spare_id;
-
+
assert(spare->inuse == 0);
// simple -- we're popping the top-of-stack of spares
@@ -199,7 +199,7 @@ skc_suballocator_subbuf_alloc(struct skc_suballocator * const suballocator,
*subbuf_id = spare_id;
SKC_SUBALLOCATOR_DEBUG_ALLOC(suballocator,spare_id,size_ru);
-
+
// get prev
struct skc_subbuf * const prev = avail->prev;
diff --git a/src/compute/skc/suballocator.h b/src/compute/skc/suballocator.h
index 7c3a6e863c..df938e06f0 100644
--- a/src/compute/skc/suballocator.h
+++ b/src/compute/skc/suballocator.h
@@ -39,7 +39,7 @@
typedef skc_ushort skc_subbuf_id_t;
typedef skc_uint skc_subbuf_size_t; // <4GB
-// typedef size_t skc_subbuf_size_t; // >4GB
+// typedef size_t skc_subbuf_size_t; // >4GB
//
//
@@ -49,7 +49,7 @@ struct skc_subbuf
{
struct skc_subbuf * prev;
struct skc_subbuf * next;
-
+
skc_subbuf_size_t size;
skc_subbuf_size_t origin;
diff --git a/src/compute/skc/tile.h b/src/compute/skc/tile.h
index d6d3c7f2f1..d07c4932f3 100644
--- a/src/compute/skc/tile.h
+++ b/src/compute/skc/tile.h
@@ -414,7 +414,7 @@
#define SKC_TTCK_LO_BITS_PREFIX 1
#define SKC_TTCK_LO_OFFSET_PREFIX SKC_TTCK_LO_BITS_ID
#define SKC_TTCK_LO_MASK_PREFIX SKC_BITS_TO_MASK_AT(SKC_TTCK_LO_BITS_PREFIX,SKC_TTCK_LO_OFFSET_PREFIX)
-
+
#define SKC_TTCK_LO_BITS_ID_PREFIX (SKC_TTCK_LO_BITS_ID + SKC_TTCK_LO_BITS_PREFIX)
#define SKC_TTCK_LO_MASK_ID_PREFIX SKC_BITS_TO_MASK(SKC_TTCK_LO_BITS_ID_PREFIX)
diff --git a/src/compute/skc/util.c b/src/compute/skc/util.c
index fe368880ce..bf8a069016 100644
--- a/src/compute/skc/util.c
+++ b/src/compute/skc/util.c
@@ -12,7 +12,7 @@
//
//
-#include <intrin.h>
+#include <intrin.h>
//
//
diff --git a/src/compute/skc/weakref.c b/src/compute/skc/weakref.c
index e8a1d55f08..1867adea84 100644
--- a/src/compute/skc/weakref.c
+++ b/src/compute/skc/weakref.c
@@ -56,27 +56,27 @@ SKC_STATIC_ASSERT(sizeof(union skc_weakref) == sizeof(skc_ulong));
//
//
-void
+void
skc_weakref_epoch_init(skc_epoch_t * const epoch)
{
*epoch = SKC_WEAKREF_EPOCH_INIT;
}
-void
+void
skc_weakref_epoch_inc(skc_epoch_t * const epoch)
{
*epoch += SKC_WEAKREF_EPOCH_ONE;
}
-void
-skc_weakref_init(skc_weakref_t * const weakref,
+void
+skc_weakref_init(skc_weakref_t * const weakref,
skc_epoch_t * const epoch,
skc_uint const index)
{
*weakref = *epoch | (index & SKC_WEAKREF_INDEX_MASK);
}
-bool
+bool
skc_weakref_is_invalid(skc_weakref_t const * const weakref,
skc_epoch_t const * const epoch)
{
diff --git a/src/compute/skc/weakref.h b/src/compute/skc/weakref.h
index 9d09f8e5a6..c6ce6490f8 100644
--- a/src/compute/skc/weakref.h
+++ b/src/compute/skc/weakref.h
@@ -25,20 +25,20 @@ typedef skc_ulong skc_epoch_t;
//
//
-void
+void
skc_weakref_epoch_init(skc_epoch_t * const epoch);
-void
+void
skc_weakref_epoch_inc(skc_epoch_t * const epoch);
-void
-skc_weakref_init(skc_weakref_t * const weakref,
+void
+skc_weakref_init(skc_weakref_t * const weakref,
skc_epoch_t * const epoch,
skc_uint const index);
-bool
+bool
skc_weakref_is_invalid(skc_weakref_t const * const weakref,
- skc_epoch_t const * const epoch);
+ skc_epoch_t const * const epoch);
skc_uint
skc_weakref_index(skc_weakref_t const * const weakref);