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

Side by Side Diff: src/opts/SkBlitRow_opts_mips_dsp.cpp

Issue 2097883002: revise row blits to keep intermediate precision so that color is preserved when blended against its… (Closed) Base URL: https://skia.googlesource.com/skia@master
Patch Set: Fix overflow in destination scale calculation Created 4 years, 5 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
OLDNEW
1 /* 1 /*
2 * Copyright 2014 The Android Open Source Project 2 * Copyright 2014 The Android Open Source Project
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkBlitRow.h" 8 #include "SkBlitRow.h"
9 #include "SkBlitMask.h" 9 #include "SkBlitMask.h"
10 #include "SkColorPriv.h" 10 #include "SkColorPriv.h"
(...skipping 771 matching lines...) Expand 10 before | Expand all | Expand 10 after
782 "preceu.ph.qbr %[t2], %[t0] \n\t" 782 "preceu.ph.qbr %[t2], %[t0] \n\t"
783 "preceu.ph.qbl %[t3], %[t0] \n\t" 783 "preceu.ph.qbl %[t3], %[t0] \n\t"
784 "preceu.ph.qbr %[t4], %[t1] \n\t" 784 "preceu.ph.qbr %[t4], %[t1] \n\t"
785 "preceu.ph.qbl %[t5], %[t1] \n\t" 785 "preceu.ph.qbl %[t5], %[t1] \n\t"
786 "muleu_s.ph.qbr %[t2], %[t7], %[t2] \n\t" 786 "muleu_s.ph.qbr %[t2], %[t7], %[t2] \n\t"
787 "muleu_s.ph.qbr %[t3], %[t7], %[t3] \n\t" 787 "muleu_s.ph.qbr %[t3], %[t7], %[t3] \n\t"
788 "muleu_s.ph.qbr %[t4], %[t6], %[t4] \n\t" 788 "muleu_s.ph.qbr %[t4], %[t6], %[t4] \n\t"
789 "muleu_s.ph.qbr %[t5], %[t6], %[t5] \n\t" 789 "muleu_s.ph.qbr %[t5], %[t6], %[t5] \n\t"
790 "addiu %[src], %[src], 4 \n\t" 790 "addiu %[src], %[src], 4 \n\t"
791 "addiu %[count], %[count], -1 \n\t" 791 "addiu %[count], %[count], -1 \n\t"
792 "precrq.qb.ph %[t0], %[t3], %[t2] \n\t" 792 "addu %[t0], %[t3], %[t5] \n\t"
793 "precrq.qb.ph %[t2], %[t5], %[t4] \n\t" 793 "addu %[t2], %[t2], %[t4] \n\t"
794 "addu %[t1], %[t0], %[t2] \n\t" 794 "precrq.qb.ph %[t1], %[t0], %[t2] \n\t"
795 "sw %[t1], 0(%[dst]) \n\t" 795 "sw %[t1], 0(%[dst]) \n\t"
796 "b 1b \n\t" 796 "b 1b \n\t"
797 " addi %[dst], %[dst], 4 \n\t" 797 " addi %[dst], %[dst], 4 \n\t"
798 "2: \n\t" 798 "2: \n\t"
799 ".set pop \n\t" 799 ".set pop \n\t"
800 : [src]"+r"(src), [dst]"+r"(dst), [count]"+r"(count), 800 : [src]"+r"(src), [dst]"+r"(dst), [count]"+r"(count),
801 [t0]"=&r"(t0), [t1]"=&r"(t1), [t2]"=&r"(t2), [t3]"=&r"(t3), 801 [t0]"=&r"(t0), [t1]"=&r"(t1), [t2]"=&r"(t2), [t3]"=&r"(t3),
802 [t4]"=&r"(t4), [t5]"=&r"(t5), [t6]"=&r"(t6), [t7]"=&r"(t7) 802 [t4]"=&r"(t4), [t5]"=&r"(t5), [t6]"=&r"(t6), [t7]"=&r"(t7)
803 : [alpha]"r"(alpha) 803 : [alpha]"r"(alpha)
804 : "memory", "hi", "lo" 804 : "memory", "hi", "lo"
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
943 return platform_565_procs_mips_dsp[flags]; 943 return platform_565_procs_mips_dsp[flags];
944 } 944 }
945 945
946 SkBlitRow::ColorProc16 SkBlitRow::PlatformColorFactory565(unsigned flags) { 946 SkBlitRow::ColorProc16 SkBlitRow::PlatformColorFactory565(unsigned flags) {
947 return nullptr; 947 return nullptr;
948 } 948 }
949 949
950 SkBlitRow::Proc32 SkBlitRow::PlatformProcs32(unsigned flags) { 950 SkBlitRow::Proc32 SkBlitRow::PlatformProcs32(unsigned flags) {
951 return platform_32_procs_mips_dsp[flags]; 951 return platform_32_procs_mips_dsp[flags];
952 } 952 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698