Attention is currently required from: Aske Simon Christensen.
Aske Simon Christensen uploaded patch set #64 to this change.
[dart2wasm] Initial commit for the Dart-to-Wasm compiler.
This is work in progress. Several language features are still
unimplemented or only partially implemented, and the interfaces to
running the compiler and its output are preliminary and expected to
change.
The history of the prototype that this is based on can be seen here:
https://github.com/askeksa-google/sdk/tree/wasm_prototype
Change-Id: I910b6ff239ef9c5f66863e4ca97b39b8202cce85
---
M .dart_tool/package_config.json
M .packages
M README.md
A pkg/dart2wasm/bin/dart2wasm.dart
A pkg/dart2wasm/bin/run_wasm.js
A pkg/dart2wasm/dart2wasm.md
A pkg/dart2wasm/lib/class_info.dart
A pkg/dart2wasm/lib/closures.dart
A pkg/dart2wasm/lib/code_generator.dart
A pkg/dart2wasm/lib/compile.dart
A pkg/dart2wasm/lib/constants.dart
A pkg/dart2wasm/lib/constants_backend.dart
A pkg/dart2wasm/lib/dispatch_table.dart
A pkg/dart2wasm/lib/functions.dart
A pkg/dart2wasm/lib/globals.dart
A pkg/dart2wasm/lib/intrinsics.dart
A pkg/dart2wasm/lib/param_info.dart
A pkg/dart2wasm/lib/reference_extensions.dart
A pkg/dart2wasm/lib/target.dart
A pkg/dart2wasm/lib/transformers.dart
A pkg/dart2wasm/lib/translator.dart
A pkg/dart2wasm/pubspec.yaml
M pkg/smith/lib/configuration.dart
M pkg/test_runner/lib/src/command.dart
M pkg/test_runner/lib/src/command_output.dart
M pkg/test_runner/lib/src/compiler_configuration.dart
M pkg/test_runner/lib/src/configuration.dart
M pkg/test_runner/lib/src/runtime_configuration.dart
M pkg/test_runner/lib/src/test_suite.dart
A pkg/wasm_builder/LICENSE
A pkg/wasm_builder/lib/src/instructions.dart
A pkg/wasm_builder/lib/src/module.dart
A pkg/wasm_builder/lib/src/serialize.dart
A pkg/wasm_builder/lib/src/types.dart
A pkg/wasm_builder/lib/wasm_builder.dart
A pkg/wasm_builder/pubspec.yaml
A sdk/bin/dart2wasm
A sdk/bin/dart2wasm_developer
M sdk/lib/_internal/vm/lib/collection_patch.dart
M sdk/lib/_internal/vm/lib/compact_hash.dart
M sdk/lib/_internal/vm/lib/hash_factories.dart
M sdk/lib/_internal/vm/lib/typed_data_patch.dart
A sdk/lib/_internal/wasm/lib/bool.dart
A sdk/lib/_internal/wasm/lib/class_id.dart
A sdk/lib/_internal/wasm/lib/core_patch.dart
A sdk/lib/_internal/wasm/lib/date_patch.dart
A sdk/lib/_internal/wasm/lib/developer.dart
A sdk/lib/_internal/wasm/lib/double.dart
A sdk/lib/_internal/wasm/lib/expando_patch.dart
A sdk/lib/_internal/wasm/lib/function.dart
A sdk/lib/_internal/wasm/lib/growable_list.dart
A sdk/lib/_internal/wasm/lib/hash_factories.dart
A sdk/lib/_internal/wasm/lib/identical_patch.dart
A sdk/lib/_internal/wasm/lib/immutable_map.dart
A sdk/lib/_internal/wasm/lib/int.dart
A sdk/lib/_internal/wasm/lib/internal_patch.dart
A sdk/lib/_internal/wasm/lib/list.dart
A sdk/lib/_internal/wasm/lib/math_patch.dart
A sdk/lib/_internal/wasm/lib/object_patch.dart
A sdk/lib/_internal/wasm/lib/patch.dart
A sdk/lib/_internal/wasm/lib/print_patch.dart
A sdk/lib/_internal/wasm/lib/string_buffer_patch.dart
A sdk/lib/_internal/wasm/lib/string_patch.dart
A sdk/lib/_internal/wasm/lib/timer_patch.dart
A sdk/lib/_internal/wasm/lib/type.dart
M sdk/lib/libraries.json
M sdk/lib/libraries.yaml
A sdk/lib/wasm/wasm_types.dart
A tests/language/language_dart2wasm.status
M tools/bots/test_matrix.json
70 files changed, 15,361 insertions(+), 73 deletions(-)
To view, visit change 175728. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Aske Simon Christensen.
Patch set 64:Code-Review +1
1 comment:
Patchset:
I think this patch looks good(as of PS 64). I'm going to lgtm now, but please let me know if you'd like a final pass over any additional changes.
Thanks!!!
To view, visit change 175728. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Aske Simon Christensen.
Aske Simon Christensen uploaded patch set #66 to this change.
[dart2wasm] Initial commit for the Dart-to-Wasm compiler.
This is work in progress. Several language features are still
unimplemented or only partially implemented, and the interfaces to
running the compiler and its output are preliminary and expected to
change.
The history of the prototype that this is based on can be seen here:
https://github.com/askeksa-google/sdk/tree/wasm_prototype
Issue: https://github.com/dart-lang/sdk/issues/32894
M sdk/lib/_internal/vm/lib/compact_hash.dart
68 files changed, 15,800 insertions(+), 1 deletion(-)
To view, visit change 175728. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Aske Simon Christensen.
go/dart-cbuild result: FAILURE (NO REGRESSIONS DETECTED)
Details: https://goto.google.com/dart-cbuild/find/b9c63b69692d6a04cddf22ca92eb1ae712decfb0
Patch set 67:Commit-Queue +1
4 comments:
Commit Message:
Consider adding brief class comments to every top level public class?
Done
Patchset:
I think the documentation is now at a suitable level. PTAL.
File pkg/wasm_builder/lib/src/instructions.dart:
Patch Set #56, Line 85: bool _debugTrace(List<Object>? trace,
Consider a comment on the overall debug functionality?
Put some comments in the public interface about this.
File sdk/lib/_internal/wasm/lib/internal_patch.dart:
Patch Set #62, Line 35: static void copy(List src, int srcStart, List dst, int dstStart, int count) {
We spoke offline, but to summarize the use of dynamic here doesn't matter because all this code does […]
The lists can't be typed with the same type variable, since they may be of different types.
I have added a TODO about intrinsification.
To view, visit change 175728. To unsubscribe, or for help writing mail filters, visit settings.
go/dart-cbuild result: SUCCESS
Details: https://goto.google.com/dart-cbuild/find/a0351561123e3bbc46a189e7477e75f52b043399
Attention is currently required from: Aske Simon Christensen.
Patch set 67:Code-Review +1
23 comments:
Patchset:
A bunch of nits, definitely still looks good to me.
A number of comments were added that read as questions. I tried to suggest some declarative alternatives. I can also suggest other alternatives if you want to replace the questions with declarative sentences but don't like my suggestions. Please feel free to leave the questions in place if you prefer that style of documentation.
Thanks!
File pkg/dart2wasm/lib/class_info.dart:
Patch Set #67, Line 245: represetations
representation? Though do you mean 'type representations' or is a 'representation type' something else?
File pkg/dart2wasm/lib/closures.dart:
Patch Set #67, Line 35: descendents
descendants?
Patch Set #67, Line 50: Does this context capture `this`?
'True if the context captures `this`'?
Patch Set #67, Line 248: CollectContexts
ContextCollector? I'm okay with this name, but it sounds a bit like a function.
File pkg/dart2wasm/lib/code_generator.dart:
if?
File pkg/dart2wasm/lib/constants.dart:
Patch Set #67, Line 250: ensured
initialized? Unless this has some other meaning I'm not aware of.
File pkg/dart2wasm/lib/dispatch_table.dart:
Patch Set #67, Line 52: representation types
'type representations'? Please ignore if a 'representation type' has some meaning I'm not aware of.
File pkg/dart2wasm/lib/translator.dart:
///
///
Are these two new lines intentional?
File pkg/wasm_builder/lib/src/instructions.dart:
/// When emitting instructions, should a textual trace of the instruction
/// stream be recorded (provided asserts are enabled)?
'Whether or not a textual trace of the instruction stream should be recorded when emitting instructions (provided asserts are enabled)'?
Patch Set #67, Line 99: /// Should the textual trace contain a byte offset for each instruction?
'Whether or not the textual trace should contain byte offsets for each instruction'?
Patch Set #67, Line 122: /// Is the current point in the instruction stream reachable?
'True if the current point in the instruction stream is reachable'?
Patch Set #67, Line 125: /// Has the instruction sequence been completed by the final `end`?
'True if the instruction sequence has been completed by the final `end`'?
File pkg/wasm_builder/lib/src/serialize.dart:
'...within this [SerializerMixin].'?
File pkg/wasm_builder/lib/src/types.dart:
/// Is this type a subtype of the [other] type, i.e. can this type be used
/// as input where [other] is expected.
'True if this [StorageType] is a subtype of [other], i.e...'?
Patch Set #67, Line 15: /// What is the *unpacked* form of this storage type
'The *unpacked* form of this storage type...'?
Patch Set #67, Line 19: /// Is this a primitive (i.e. not reference) type?
'True if this [StorageType] is a primitive...'?
Patch Set #67, Line 22: what is the size in bytes of a value of this type?
'...returns the size in bytes of a value of this type'?
Patch Set #67, Line 39: Is this type nullable?
'True if this type is nullable.'?
Patch Set #67, Line 46: Is this type defaultable?
'True if this type is defaultable'?
Patch Set #67, Line 272: Is this heap type nullable by default
'True if this heap type is nullable by default'?
Patch Set #67, Line 278: /// Is this heap type a declared subtype of the other heap type?
'True if this heap type is a declared subtype of the other heap type'?
Patch Set #67, Line 281: /// Is this heap type a structural subtype of the other heap type?
'True if this heap type is a structural subtype of the other heap type'?
To view, visit change 175728. To unsubscribe, or for help writing mail filters, visit settings.