Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(188)

Side by Side Diff: source/row_neon64.cc

Issue 2035573002: ARGBExtractAlpha 16 pixels at a time for ARM (Closed) Base URL: https://chromium.googlesource.com/libyuv/libyuv@master
Patch Set: fix lint warning Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « source/row_neon.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2014 The LibYuv Project Authors. All rights reserved. 2 * Copyright 2014 The LibYuv Project Authors. All rights reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 432 matching lines...) Expand 10 before | Expand all | Expand 10 after
443 : "cc", "memory", "v0", "v1", "v2", "v3", "v4", "v5", "v6", "v7", "v20", 443 : "cc", "memory", "v0", "v1", "v2", "v3", "v4", "v5", "v6", "v7", "v20",
444 "v21", "v22", "v23", "v24", "v25", "v26", "v27", "v28", "v29", "v30" 444 "v21", "v22", "v23", "v24", "v25", "v26", "v27", "v28", "v29", "v30"
445 ); 445 );
446 } 446 }
447 #endif // HAS_I422TOARGB4444ROW_NEON 447 #endif // HAS_I422TOARGB4444ROW_NEON
448 448
449 #ifdef HAS_I400TOARGBROW_NEON 449 #ifdef HAS_I400TOARGBROW_NEON
450 void I400ToARGBRow_NEON(const uint8* src_y, 450 void I400ToARGBRow_NEON(const uint8* src_y,
451 uint8* dst_argb, 451 uint8* dst_argb,
452 int width) { 452 int width) {
453 int64 width64 = (int64)(width);
454 asm volatile ( 453 asm volatile (
455 YUVTORGB_SETUP 454 YUVTORGB_SETUP
456 "movi v23.8b, #255 \n" 455 "movi v23.8b, #255 \n"
457 "1: \n" 456 "1: \n"
458 READYUV400 457 READYUV400
459 YUVTORGB(v22, v21, v20) 458 YUVTORGB(v22, v21, v20)
460 "subs %w2, %w2, #8 \n" 459 "subs %w2, %w2, #8 \n"
461 MEMACCESS(1) 460 MEMACCESS(1)
462 "st4 {v20.8b,v21.8b,v22.8b,v23.8b}, [%1], #32 \n" 461 "st4 {v20.8b,v21.8b,v22.8b,v23.8b}, [%1], #32 \n"
463 "b.gt 1b \n" 462 "b.gt 1b \n"
464 : "+r"(src_y), // %0 463 : "+r"(src_y), // %0
465 "+r"(dst_argb), // %1 464 "+r"(dst_argb), // %1
466 "+r"(width64) // %2 465 "+r"(width) // %2
467 : [kUVToRB]"r"(&kYuvI601Constants.kUVToRB), 466 : [kUVToRB]"r"(&kYuvI601Constants.kUVToRB),
468 [kUVToG]"r"(&kYuvI601Constants.kUVToG), 467 [kUVToG]"r"(&kYuvI601Constants.kUVToG),
469 [kUVBiasBGR]"r"(&kYuvI601Constants.kUVBiasBGR), 468 [kUVBiasBGR]"r"(&kYuvI601Constants.kUVBiasBGR),
470 [kYToRgb]"r"(&kYuvI601Constants.kYToRgb) 469 [kYToRgb]"r"(&kYuvI601Constants.kYToRgb)
471 : "cc", "memory", "v0", "v1", "v2", "v3", "v4", "v5", "v6", "v7", "v20", 470 : "cc", "memory", "v0", "v1", "v2", "v3", "v4", "v5", "v6", "v7", "v20",
472 "v21", "v22", "v23", "v24", "v25", "v26", "v27", "v28", "v29", "v30" 471 "v21", "v22", "v23", "v24", "v25", "v26", "v27", "v28", "v29", "v30"
473 ); 472 );
474 } 473 }
475 #endif // HAS_I400TOARGBROW_NEON 474 #endif // HAS_I400TOARGBROW_NEON
476 475
(...skipping 920 matching lines...) Expand 10 before | Expand all | Expand 10 after
1397 : "cc", "memory", "v0", "v1", "v2", "v3", "v4", "v5", "v6", "v7" 1396 : "cc", "memory", "v0", "v1", "v2", "v3", "v4", "v5", "v6", "v7"
1398 ); 1397 );
1399 } 1398 }
1400 #endif // HAS_ARGBTOYROW_NEON 1399 #endif // HAS_ARGBTOYROW_NEON
1401 1400
1402 #ifdef HAS_ARGBEXTRACTALPHAROW_NEON 1401 #ifdef HAS_ARGBEXTRACTALPHAROW_NEON
1403 void ARGBExtractAlphaRow_NEON(const uint8* src_argb, uint8* dst_a, int width) { 1402 void ARGBExtractAlphaRow_NEON(const uint8* src_argb, uint8* dst_a, int width) {
1404 asm volatile ( 1403 asm volatile (
1405 "1: \n" 1404 "1: \n"
1406 MEMACCESS(0) 1405 MEMACCESS(0)
1407 "ld4 {v0.8b,v1.8b,v2.8b,v3.8b}, [%0], #32 \n" // load row 8 pixels 1406 "ld4 {v0.16b,v1.16b,v2.16b,v3.16b}, [%0], #64 \n" // load row 16 pix els
1408 "subs %w2, %w2, #8 \n" // 8 processed per loop 1407 "subs %w2, %w2, #16 \n" // 16 processed per loop
1409 MEMACCESS(1) 1408 MEMACCESS(1)
1410 "st1 {v3.8b}, [%1], #8 \n" // store 8 A's. 1409 "st1 {v3.16b}, [%1], #16 \n" // store 16 A's.
1411 "b.gt 1b \n" 1410 "b.gt 1b \n"
1412 : "+r"(src_argb), // %0 1411 : "+r"(src_argb), // %0
1413 "+r"(dst_a), // %1 1412 "+r"(dst_a), // %1
1414 "+r"(width) // %2 1413 "+r"(width) // %2
1415 : 1414 :
1416 : "cc", "memory", "v0", "v1", "v2", "v3" // Clobber List 1415 : "cc", "memory", "v0", "v1", "v2", "v3" // Clobber List
1417 ); 1416 );
1418 } 1417 }
1419 #endif // HAS_ARGBEXTRACTALPHAROW_NEON 1418 #endif // HAS_ARGBEXTRACTALPHAROW_NEON
1420 1419
(...skipping 1550 matching lines...) Expand 10 before | Expand all | Expand 10 after
2971 : "cc", "memory", "v0", "v1", "v2", "v3" // Clobber List 2970 : "cc", "memory", "v0", "v1", "v2", "v3" // Clobber List
2972 ); 2971 );
2973 } 2972 }
2974 #endif // HAS_SOBELYROW_NEON 2973 #endif // HAS_SOBELYROW_NEON
2975 #endif // !defined(LIBYUV_DISABLE_NEON) && defined(__aarch64__) 2974 #endif // !defined(LIBYUV_DISABLE_NEON) && defined(__aarch64__)
2976 2975
2977 #ifdef __cplusplus 2976 #ifdef __cplusplus
2978 } // extern "C" 2977 } // extern "C"
2979 } // namespace libyuv 2978 } // namespace libyuv
2980 #endif 2979 #endif
OLDNEW
« no previous file with comments | « source/row_neon.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698