Skip to content

Conversation

@qjia7
Copy link
Contributor

@qjia7 qjia7 commented Nov 25, 2019

PERF

Per testing, we find that Int32Array.from is very slow on windows.
If we use 'new Int32Array' to replace 'Int32Array.from', the fromPixels
can speed up 3x-5x on different windows platforms. With this change,
the posenet demo can speedup 2x-3x on plaforms that fromPixels are
bottleneck.

To see the logs from the Cloud Build CI, please join either our discussion or announcement mailing list.


This change is Reviewable

PERF

Per testing, we find that Int32Array.from is very slow on windows.
If we use 'new Int32Array' to replace 'Int32Array.from', the fromPixels
can speed up 3x~5x on different windows platforms. With this change,
the posenet demo can speedup 2x~3x on plaforms that fromPixels are
bottleneck.
@qjia7 qjia7 changed the title webgpu: Don't use Int32Array.from [WIP]webgpu: Don't use Int32Array.from Nov 25, 2019
@annxingyuan
Copy link
Contributor

@qjia7 just checking - is this ready for review?

@qjia7
Copy link
Contributor Author

qjia7 commented Nov 26, 2019

@qjia7 just checking - is this ready for review?

@annxingyuan I filed a chrome bug https://bugs.chromium.org/p/chromium/issues/detail?id=1028538 to track this issue. It seems that it should be fixed in v8 engine. And Shaobo in our team is doing the copyImageBitmapToTexture so that we don't need to read data back to cpu. In that time, these codes will be removed. The code is ready. But I am not sure if this patch is still needed.

@qjia7
Copy link
Contributor Author

qjia7 commented Dec 4, 2019

This change was merged with #2451. Close this one.

@qjia7 qjia7 closed this Dec 4, 2019
@qjia7 qjia7 deleted the win_Int32Array branch August 13, 2020 07:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants