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

Side by Side Diff: src/core/SkOpts.cpp

Issue 1432903002: float xfermodes (burn, dodge, softlight) in Sk8f, possibly using AVX. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 1.0f/255 Created 5 years, 1 month 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 2015 Google Inc. 2 * Copyright 2015 Google Inc.
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 "SkOnce.h" 8 #include "SkOnce.h"
9 #include "SkOpts.h" 9 #include "SkOpts.h"
10 10
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 decltype(blit_row_color32) blit_row_color32 = sk_default::blit_row_color32; 77 decltype(blit_row_color32) blit_row_color32 = sk_default::blit_row_color32;
78 78
79 decltype(matrix_translate) matrix_translate = sk_default::matrix _translate; 79 decltype(matrix_translate) matrix_translate = sk_default::matrix _translate;
80 decltype(matrix_scale_translate) matrix_scale_translate = sk_default::matrix _scale_translate; 80 decltype(matrix_scale_translate) matrix_scale_translate = sk_default::matrix _scale_translate;
81 decltype(matrix_affine) matrix_affine = sk_default::matrix _affine; 81 decltype(matrix_affine) matrix_affine = sk_default::matrix _affine;
82 82
83 // Each Init_foo() is defined in src/opts/SkOpts_foo.cpp. 83 // Each Init_foo() is defined in src/opts/SkOpts_foo.cpp.
84 void Init_ssse3(); 84 void Init_ssse3();
85 void Init_sse41(); 85 void Init_sse41();
86 void Init_sse42() { SkDEBUGCODE( SkDebugf("sse 4.2 detected\n"); ) } 86 void Init_sse42() { SkDEBUGCODE( SkDebugf("sse 4.2 detected\n"); ) }
87 void Init_avx() { SkDEBUGCODE( SkDebugf("avx detected\n"); ) } 87 void Init_avx();
88 void Init_avx2() { SkDEBUGCODE( SkDebugf("avx2 detected\n"); ) } 88 void Init_avx2() { SkDEBUGCODE( SkDebugf("avx2 detected\n"); ) }
89 void Init_neon(); 89 void Init_neon();
90 //TODO: _dsp2, _armv7, _armv8, _x86, _x86_64, _sse42, ... ? 90 //TODO: _dsp2, _armv7, _armv8, _x86, _x86_64, _sse42, ... ?
91 91
92 static void init() { 92 static void init() {
93 // TODO: Chrome's not linking _sse* opts on iOS simulator builds. Bug o r feature? 93 // TODO: Chrome's not linking _sse* opts on iOS simulator builds. Bug o r feature?
94 #if defined(SK_CPU_X86) && !defined(SK_BUILD_FOR_IOS) 94 #if defined(SK_CPU_X86) && !defined(SK_BUILD_FOR_IOS)
95 uint32_t abcd[] = {0,0,0,0}; 95 uint32_t abcd[] = {0,0,0,0};
96 cpuid(abcd); 96 cpuid(abcd);
97 if (abcd[2] & (1<< 9)) { Init_ssse3(); } 97 if (abcd[2] & (1<< 9)) { Init_ssse3(); }
(...skipping 21 matching lines...) Expand all
119 119
120 SK_DECLARE_STATIC_ONCE(gInitOnce); 120 SK_DECLARE_STATIC_ONCE(gInitOnce);
121 void Init() { SkOnce(&gInitOnce, init); } 121 void Init() { SkOnce(&gInitOnce, init); }
122 122
123 #if SK_ALLOW_STATIC_GLOBAL_INITIALIZERS 123 #if SK_ALLOW_STATIC_GLOBAL_INITIALIZERS
124 static struct AutoInit { 124 static struct AutoInit {
125 AutoInit() { Init(); } 125 AutoInit() { Init(); }
126 } gAutoInit; 126 } gAutoInit;
127 #endif 127 #endif
128 } 128 }
OLDNEW
« no previous file with comments | « src/core/SkNx.h ('k') | src/opts/SkNx_avx.h » ('j') | src/opts/SkNx_avx.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698