diff options
Diffstat (limited to 'meta-oe/recipes-graphics/xorg-lib/pixman-0.22.2/0004-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch')
-rw-r--r-- | meta-oe/recipes-graphics/xorg-lib/pixman-0.22.2/0004-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch | 94 |
1 files changed, 0 insertions, 94 deletions
diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.22.2/0004-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.22.2/0004-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch deleted file mode 100644 index 6bcc2fa30..000000000 --- a/meta-oe/recipes-graphics/xorg-lib/pixman-0.22.2/0004-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch +++ /dev/null | |||
@@ -1,94 +0,0 @@ | |||
1 | From 604f22b515d4d678df4c301ecec3c7da4987ee16 Mon Sep 17 00:00:00 2001 | ||
2 | From: Siarhei Siamashka <siarhei.siamashka@nokia.com> | ||
3 | Date: Wed, 18 Nov 2009 06:08:48 +0200 | ||
4 | Subject: [PATCH 4/4] Support of overlapping src/dst for pixman_blt_neon | ||
5 | |||
6 | --- | ||
7 | pixman/pixman-arm-neon.c | 62 +++++++++++++++++++++++++++++++++++++-------- | ||
8 | 1 files changed, 51 insertions(+), 11 deletions(-) | ||
9 | |||
10 | diff --git a/pixman/pixman-arm-neon.c b/pixman/pixman-arm-neon.c | ||
11 | index e5127a6..b67fed9 100644 | ||
12 | --- a/pixman/pixman-arm-neon.c | ||
13 | +++ b/pixman/pixman-arm-neon.c | ||
14 | @@ -234,26 +234,66 @@ pixman_blt_neon (uint32_t *src_bits, | ||
15 | int width, | ||
16 | int height) | ||
17 | { | ||
18 | - if (src_bpp != dst_bpp) | ||
19 | + uint8_t * src_bytes; | ||
20 | + uint8_t * dst_bytes; | ||
21 | + int bpp; | ||
22 | + | ||
23 | + if (src_bpp != dst_bpp || src_bpp & 7) | ||
24 | return FALSE; | ||
25 | |||
26 | + bpp = src_bpp >> 3; | ||
27 | + width *= bpp; | ||
28 | + src_stride *= 4; | ||
29 | + dst_stride *= 4; | ||
30 | + src_bytes = (uint8_t *)src_bits + src_y * src_stride + src_x * bpp; | ||
31 | + dst_bytes = (uint8_t *)dst_bits + dst_y * dst_stride + dst_x * bpp; | ||
32 | + | ||
33 | + if (src_bpp != 16 && src_bpp != 32) | ||
34 | + { | ||
35 | + pixman_blt_helper (src_bytes, dst_bytes, src_stride, dst_stride, | ||
36 | + width, height); | ||
37 | + return TRUE; | ||
38 | + } | ||
39 | + | ||
40 | + if (src_bytes < dst_bytes && src_bytes + src_stride * height > dst_bytes) | ||
41 | + { | ||
42 | + src_bytes += src_stride * height - src_stride; | ||
43 | + dst_bytes += dst_stride * height - dst_stride; | ||
44 | + dst_stride = -dst_stride; | ||
45 | + src_stride = -src_stride; | ||
46 | + | ||
47 | + if (src_bytes + width > dst_bytes) | ||
48 | + { | ||
49 | + /* TODO: reverse scanline copy using NEON */ | ||
50 | + while (--height >= 0) | ||
51 | + { | ||
52 | + memmove (dst_bytes, src_bytes, width); | ||
53 | + dst_bytes += dst_stride; | ||
54 | + src_bytes += src_stride; | ||
55 | + } | ||
56 | + return TRUE; | ||
57 | + } | ||
58 | + } | ||
59 | + | ||
60 | switch (src_bpp) | ||
61 | { | ||
62 | case 16: | ||
63 | pixman_composite_src_0565_0565_asm_neon ( | ||
64 | - width, height, | ||
65 | - (uint16_t *)(((char *) dst_bits) + | ||
66 | - dst_y * dst_stride * 4 + dst_x * 2), dst_stride * 2, | ||
67 | - (uint16_t *)(((char *) src_bits) + | ||
68 | - src_y * src_stride * 4 + src_x * 2), src_stride * 2); | ||
69 | + width >> 1, | ||
70 | + height, | ||
71 | + (uint16_t *) dst_bytes, | ||
72 | + dst_stride >> 1, | ||
73 | + (uint16_t *) src_bytes, | ||
74 | + src_stride >> 1); | ||
75 | return TRUE; | ||
76 | case 32: | ||
77 | pixman_composite_src_8888_8888_asm_neon ( | ||
78 | - width, height, | ||
79 | - (uint32_t *)(((char *) dst_bits) + | ||
80 | - dst_y * dst_stride * 4 + dst_x * 4), dst_stride, | ||
81 | - (uint32_t *)(((char *) src_bits) + | ||
82 | - src_y * src_stride * 4 + src_x * 4), src_stride); | ||
83 | + width >> 2, | ||
84 | + height, | ||
85 | + (uint32_t *) dst_bytes, | ||
86 | + dst_stride >> 2, | ||
87 | + (uint32_t *) src_bytes, | ||
88 | + src_stride >> 2); | ||
89 | return TRUE; | ||
90 | default: | ||
91 | return FALSE; | ||
92 | -- | ||
93 | 1.6.6.1 | ||
94 | |||