-
Notifications
You must be signed in to change notification settings - Fork 695
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reintroduce and update Dart SIMD guide #3679
Comments
I would also be happy to contribute a PR updating the previous documentation page if someone could give some guidance on what specifically was lacking in it that caused it to be classified as "obsolete". |
@mit-mit what would you like us to do about SIMD? It seems like we could update the article, put it under https://dart.dev/guides/libraries, and add mentions of SIMD to https://dart.dev/guides/language/numbers & maybe the language/library tour (at least). What do you think? Who knows the most about SIMD now? |
@maks I think the code examples would need to pass analysis using the current set of recommended lints. We'd ensure this by adding all code in the article to /examples, as documented in https://github.com/dart-lang/site-shared/blob/master/doc/code-excerpts.md & https://github.com/dart-lang/site-shared/blob/master/doc/examples.md. |
@kwalrath thanks for looking into this so quickly! I'll have a read of those docs to see how it's done - or should I wait for @mit-mit to say on if the SIMD docs can come back before I start working on it? |
Most of our SIMD support IIRC is just methods in https://api.dart.dev/stable/2.14.4/dart-typed_data/dart-typed_data-library.html Things like https://api.dart.dev/stable/2.14.4/dart-typed_data/Int32x4/operator_plus.html Where you can operate on "chunks" of numeric values together. |
@kevmoo thats true, but the dartdoc documentation is somewhat terse. Really I just found that the previous documentation page did a really nice job of clearly explaining SIMD and how to make use of SIMD in the context of Dart. Having something like this article that brings it all together with some diagrams and small code examples (at least for me) I find is super helpful if being able to dive in and start using it quickly. For example the explanation and diagrams in the branching section I found helpful as a newcomer to using SIMD (not just SIMD in Dart). |
There was a really good article on SIMD that I suspect we jettisoned because its code was untested and rotting. The figures alone are very helpful! |
@atsansone – I don't there have been any changes w/ Dart 3. |
My main reason for opening this issue originally was just that I found https://web.archive.org/web/20190402213240/https://www.dartlang.org/articles/server/simd really helpful and useful and thought others would too. Would the Dart team be open to republishing on dart.dev again if I submitted a PR which updated the code examples in it to modern Dart usage (eg removing |
@mraleph can you take a quick look at https://web.archive.org/web/20190402213240/https://www.dartlang.org/articles/server/simd and determine if that content is still relevant for the current-day VM? |
The content is okay if it is updated. It's not just about updating the code - e.g. it should reflect that That being said,
|
Thanks for looking into it @mraleph I understand not wanting to promote something that you would like to replace, but I guess the current API is going to be here for quite sometime or are there plans for this to change this soon? sorry I couldn't seem to find if there is a roadmap for DartVM features vs the one that exists for upcoming language features/changes. On the web front, would the upcoming support in Dart for WASM also help with not needing to worry as much about the JS implementation? Funny thing is that the V8 doc on WASM SIMD actually references as being influenced by both SIMD.js and the Dart SIMD 🙂 . |
If my memory serves, we decided to drop the SIMD documentation as it was poorly maintained and outdated. |
I think any non-perfect documentation is better than no documentation (or one that will change in the future), otherwise googling for "dart simd" will yield a parody-site as the first result (like as of now). |
What information is missing?
There is not really any information at all regarding Dart supporting SIMD, in fact you would need to be fairly determined in searching dart.dev to even discover that such support exists.
Yet there used to be what I would consider a pretty good documentation page for it: https://web.archive.org/web/20190402213240/https://www.dartlang.org/articles/server/simd
and reading through it, I am unclear as to why it was considered obsolete and hence removed from the website? Apart from its use of the
new
keyword, is any of the code or the prose text actually inaccurate for the current versions of Dart lang?How would you like us to fix this problem?
Please re-instate the previously removed page documenting SIMD usage in Dart.
The text was updated successfully, but these errors were encountered: