diff options
author | 2017-10-17 14:22:58 -0400 | |
---|---|---|
committer | 2017-10-18 16:17:55 +0000 | |
commit | 85f8536ca2dd446f2f68d82b0e69134a3e7a88b7 (patch) | |
tree | f09aa8f7eb3f7f7f6018f8b4c672046a95a62d75 /src/jumper/SkJumper_stages.cpp | |
parent | e4442cb0b537720ab32106b3b5353dbb78f11b26 (diff) |
Feed seed_shader() iota through a context pointer.
As this array grows longer it causes troublesome code generation
when we're compiling offline, but it's easy as an argument.
Change-Id: I53526443f534f29d3bff17c3aec24a9e916c9b86
Reviewed-on: https://skia-review.googlesource.com/60564
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Herb Derby <herb@google.com>
Diffstat (limited to 'src/jumper/SkJumper_stages.cpp')
-rw-r--r-- | src/jumper/SkJumper_stages.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/jumper/SkJumper_stages.cpp b/src/jumper/SkJumper_stages.cpp index 1f9848e1fa..690ba574ef 100644 --- a/src/jumper/SkJumper_stages.cpp +++ b/src/jumper/SkJumper_stages.cpp @@ -214,11 +214,10 @@ SI U32 ix_and_ptr(T** ptr, const SkJumper_GatherCtx* ctx, F x, F y) { // Now finally, normal Stages! -STAGE(seed_shader, Ctx::None) { +STAGE(seed_shader, const float* iota) { // It's important for speed to explicitly cast(dx) and cast(dy), // which has the effect of splatting them to vectors before converting to floats. // On Intel this breaks a data dependency on previous loop iterations' registers. - float iota[] = { 0.5f,1.5f,2.5f,3.5f,4.5f,5.5f,6.5f,7.5f }; r = cast(dx) + unaligned_load<F>(iota); g = cast(dy) + 0.5f; b = 1.0f; |