void-packages/srcpkgs/beignet/patches/cl_uint.patch
Đoàn Trần Công Danh c6ce65d3d0 srcpkgs/b*: convert patches to -Np1
```sh

git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" |
while read template; do
	for p in ${template%/template}/patches/*; do
		sed -i '
			\,^[+-][+-][+-] /dev/null,b
			/^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b
			s,^[*][*][*] ,&a/,
			/^--- /{
				s,\(^--- \)\(./\)*,\1a/,
				s,[.-][Oo][Rr][Ii][Gg]\([	/]\),\1,
				s/[.-][Oo][Rr][Ii][Gg]$//
				s/[.]patched[.]\([^.]\)/.\1/
				h
			}
			/^+++ -/{
				g
				s/^--- a/+++ b/
				b
			}
			s,\(^+++ \)\(./\)*,\1b/,
		' "$p"
	done
	sed -i '/^patch_args=/d' $template
done
```
2021-06-20 13:17:29 +07:00

23 lines
944 B
Diff

--- a/src/cl_api_kernel.c 2017-09-22 10:05:22.000000000 +0200
+++ b/src/cl_api_kernel.c 2020-03-24 18:27:40.186485887 +0100
@@ -151,7 +151,7 @@
fixed_local_sz[0] = 16;
fixed_local_sz[1] = 1;
} else {
- uint j, maxDimSize = 64 /* from 64? */, maxGroupSize = 256; //MAX_WORK_GROUP_SIZE may too large
+ cl_uint j, maxDimSize = 64 /* from 64? */, maxGroupSize = 256; //MAX_WORK_GROUP_SIZE may too large
size_t realGroupSize = 1;
for (i = 0; i < work_dim; i++) {
for (j = maxDimSize; j > 1; j--) {
--- a/src/cl_enqueue.c 2017-09-22 10:05:22.000000000 +0200
+++ b/src/cl_enqueue.c 2020-03-24 18:30:12.031479833 +0100
@@ -494,7 +494,7 @@
cl_int cl_enqueue_svm_free(enqueue_data *data, cl_int status) {
int i;
void **pointers = data->pointers;
- uint num_svm_ptrs = data->size;
+ cl_uint num_svm_ptrs = data->size;
cl_int err = CL_SUCCESS;
if (status != CL_COMPLETE)