Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upDo not use lookup tables for put_image_data operations #9599
Comments
|
I'd like to claim this one if it's still free |
|
Go for it! |
bors-servo
added a commit
that referenced
this issue
Mar 9, 2016
Don't use lookup tables for put_image_data and GetImageData Fixes #9599 "This is the first Rust code I have ever written" (and also my first time writing real browser code, it's been quite the learning experience). Some questions: > For really fast CPU results, use integer SIMD instructions to handle more than one pixel at a time. This was out of the scope of #9599, right? I started looking into doing that, but it seems to be a lot more work than the `E-easy` label would suggest. [`std::simd`](https://doc.rust-lang.org/1.0.0/std/simd/index.html) is marked as "unstable", is that a blocker? > 128 can be added before dividing to round more accurately. @michaelwu, what did you mean by that? Also, the #9599 is `Do not use lookup tables for {Get,Put}ImageData operations`, but we only use lookup tables for the `Put`, not the `Get`, right? Sorry for all the noobish questions. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9911) <!-- Reviewable:end -->
bors-servo
added a commit
that referenced
this issue
Mar 12, 2016
Don't use lookup tables for put_image_data and GetImageData Fixes #9599 "This is the first Rust code I have ever written" (and also my first time writing real browser code, it's been quite the learning experience). Some questions: > For really fast CPU results, use integer SIMD instructions to handle more than one pixel at a time. This was out of the scope of #9599, right? I started looking into doing that, but it seems to be a lot more work than the `E-easy` label would suggest. [`std::simd`](https://doc.rust-lang.org/1.0.0/std/simd/index.html) is marked as "unstable", is that a blocker? > 128 can be added before dividing to round more accurately. @michaelwu, what did you mean by that? Also, the #9599 is `Do not use lookup tables for {Get,Put}ImageData operations`, but we only use lookup tables for the `Put`, not the `Get`, right? Sorry for all the noobish questions. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9911) <!-- Reviewable:end -->
bors-servo
added a commit
that referenced
this issue
Mar 14, 2016
Don't use lookup tables for put_image_data and GetImageData Fixes #9599 "This is the first Rust code I have ever written" (and also my first time writing real browser code, it's been quite the learning experience). Some questions: > For really fast CPU results, use integer SIMD instructions to handle more than one pixel at a time. This was out of the scope of #9599, right? I started looking into doing that, but it seems to be a lot more work than the `E-easy` label would suggest. [`std::simd`](https://doc.rust-lang.org/1.0.0/std/simd/index.html) is marked as "unstable", is that a blocker? > 128 can be added before dividing to round more accurately. @michaelwu, what did you mean by that? Also, the #9599 is `Do not use lookup tables for {Get,Put}ImageData operations`, but we only use lookup tables for the `Put`, not the `Get`, right? Sorry for all the noobish questions. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9911) <!-- Reviewable:end -->
|
Renamed this because unpremultiplying for GetImageData is a harder problem. |
bors-servo
added a commit
that referenced
this issue
Mar 15, 2016
Do not use lookup tables for put_image_data Fixes #9599 "This is the first Rust code I have ever written" (and also my first time writing real browser code, it's been quite the learning experience). Some questions: > For really fast CPU results, use integer SIMD instructions to handle more than one pixel at a time. This was out of the scope of #9599, right? I started looking into doing that, but it seems to be a lot more work than the `E-easy` label would suggest. [`std::simd`](https://doc.rust-lang.org/1.0.0/std/simd/index.html) is marked as "unstable", is that a blocker? > 128 can be added before dividing to round more accurately. @michaelwu, what did you mean by that? Also, the #9599 is `Do not use lookup tables for {Get,Put}ImageData operations`, but we only use lookup tables for the `Put`, not the `Get`, right? Sorry for all the noobish questions. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9911) <!-- Reviewable:end -->
bors-servo
added a commit
that referenced
this issue
Mar 25, 2016
Do not use lookup tables for put_image_data Fixes #9599 "This is the first Rust code I have ever written" (and also my first time writing real browser code, it's been quite the learning experience). Some questions: > For really fast CPU results, use integer SIMD instructions to handle more than one pixel at a time. This was out of the scope of #9599, right? I started looking into doing that, but it seems to be a lot more work than the `E-easy` label would suggest. [`std::simd`](https://doc.rust-lang.org/1.0.0/std/simd/index.html) is marked as "unstable", is that a blocker? > 128 can be added before dividing to round more accurately. @michaelwu, what did you mean by that? Also, the #9599 is `Do not use lookup tables for {Get,Put}ImageData operations`, but we only use lookup tables for the `Put`, not the `Get`, right? Sorry for all the noobish questions. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9911) <!-- Reviewable:end -->
bors-servo
added a commit
that referenced
this issue
Apr 1, 2016
Do not use lookup tables for put_image_data Fixes #9599 "This is the first Rust code I have ever written" (and also my first time writing real browser code, it's been quite the learning experience). Some questions: > For really fast CPU results, use integer SIMD instructions to handle more than one pixel at a time. This was out of the scope of #9599, right? I started looking into doing that, but it seems to be a lot more work than the `E-easy` label would suggest. [`std::simd`](https://doc.rust-lang.org/1.0.0/std/simd/index.html) is marked as "unstable", is that a blocker? > 128 can be added before dividing to round more accurately. @michaelwu, what did you mean by that? Also, the #9599 is `Do not use lookup tables for {Get,Put}ImageData operations`, but we only use lookup tables for the `Put`, not the `Get`, right? Sorry for all the noobish questions. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9911) <!-- Reviewable:end -->
bors-servo
added a commit
that referenced
this issue
Apr 1, 2016
Do not use lookup tables for put_image_data Fixes #9599 "This is the first Rust code I have ever written" (and also my first time writing real browser code, it's been quite the learning experience). Some questions: > For really fast CPU results, use integer SIMD instructions to handle more than one pixel at a time. This was out of the scope of #9599, right? I started looking into doing that, but it seems to be a lot more work than the `E-easy` label would suggest. [`std::simd`](https://doc.rust-lang.org/1.0.0/std/simd/index.html) is marked as "unstable", is that a blocker? > 128 can be added before dividing to round more accurately. @michaelwu, what did you mean by that? Also, the #9599 is `Do not use lookup tables for {Get,Put}ImageData operations`, but we only use lookup tables for the `Put`, not the `Get`, right? Sorry for all the noobish questions. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9911) <!-- Reviewable:end -->
bors-servo
added a commit
that referenced
this issue
Apr 1, 2016
Do not use lookup tables for put_image_data Fixes #9599 "This is the first Rust code I have ever written" (and also my first time writing real browser code, it's been quite the learning experience). Some questions: > For really fast CPU results, use integer SIMD instructions to handle more than one pixel at a time. This was out of the scope of #9599, right? I started looking into doing that, but it seems to be a lot more work than the `E-easy` label would suggest. [`std::simd`](https://doc.rust-lang.org/1.0.0/std/simd/index.html) is marked as "unstable", is that a blocker? > 128 can be added before dividing to round more accurately. @michaelwu, what did you mean by that? Also, the #9599 is `Do not use lookup tables for {Get,Put}ImageData operations`, but we only use lookup tables for the `Put`, not the `Get`, right? Sorry for all the noobish questions. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9911) <!-- Reviewable:end -->
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
#8086 is pretty sketchy. If floating point math is a bottleneck here, then we can switch to fixed point math. Using a 64kbyte lookup table to avoid floating point multiplication isn't worth it. For really fast CPU results, use integer SIMD instructions to handle more than one pixel at a time.
128 can be added before dividing to round more accurately.
cc @glennw @jdm