Browse Source

Version 2.18.0-146.0.dev

Merge commit 'd18798a6de514de1379a872f4ab312a66ac361f8' into 'dev'
dev 2.18.0-146.0.dev
Dart CI 1 month ago
parent
commit
2b6cf804af
  1. 2
      DEPS
  2. 29
      pkg/wasm_builder/lib/src/types.dart
  3. 21
      runtime/tests/vm/dart/isolates/fast_object_copy_timeline_test.dart
  4. 21
      runtime/tests/vm/dart_2/isolates/fast_object_copy_timeline_test.dart
  5. 2
      tools/VERSION

2
DEPS

@ -106,7 +106,7 @@ vars = {
# For more details, see https://github.com/dart-lang/sdk/issues/30164.
"dart_style_rev": "d7b73536a8079331c888b7da539b80e6825270ea",
"dartdoc_rev": "cf0685a2d1ce7b698a5e155448d337b86381318a",
"dartdoc_rev": "c58f21042ebd95014c5426a2f34411876685ecc7",
"devtools_rev": "3c16b8d73120e46958982d94215d499793b972eb",
"ffi_rev": "0c8364a728cfe4e4ba859c53b99d56b3dbe3add4",
"file_rev": "0132eeedea2933513bf230513a766a8baeab0c4f",

29
pkg/wasm_builder/lib/src/types.dart

@ -201,10 +201,6 @@ class RefType extends ValueType {
const RefType.i31({bool nullable = I31HeapType.defaultNullability})
: this._(HeapType.i31, nullable);
/// A (possibly nullable) reference to the `extern` heap type.
const RefType.extern({bool nullable = ExternHeapType.defaultNullability})
: this._(HeapType.extern, nullable);
/// A (possibly nullable) reference to a custom heap type.
RefType.def(DefType defType, {required bool nullable})
: this(defType, nullable: nullable);
@ -266,9 +262,6 @@ abstract class HeapType implements Serializable {
/// The `i31` heap type.
static const i31 = I31HeapType._();
/// The `extern` heap type.
static const extern = ExternHeapType._();
/// Whether this heap type is nullable by default, i.e. when written with the
/// -`ref` shorthand. A `null` value here means the heap type has no default
/// nullability, so the nullability of a reference has to be specified
@ -295,7 +288,7 @@ class AnyHeapType extends HeapType {
bool isSubtypeOf(HeapType other) => other == HeapType.any;
@override
void serialize(Serializer s) => s.writeByte(0x6E);
void serialize(Serializer s) => s.writeByte(0x6F);
@override
String toString() => "any";
@ -381,26 +374,6 @@ class I31HeapType extends HeapType {
String toString() => "i31";
}
/// The `extern` heap type.
class ExternHeapType extends HeapType {
const ExternHeapType._();
static const defaultNullability = true;
@override
bool? get nullableByDefault => defaultNullability;
@override
bool isSubtypeOf(HeapType other) =>
other == HeapType.any || other == HeapType.extern;
@override
void serialize(Serializer s) => s.writeByte(0x6F);
@override
String toString() => "extern";
}
/// A custom heap type.
abstract class DefType extends HeapType {
int? _index;

21
runtime/tests/vm/dart/isolates/fast_object_copy_timeline_test.dart

@ -15,8 +15,10 @@ import 'package:expect/expect.dart';
import '../timeline_utils.dart';
final int wordSize = sizeOf<IntPtr>();
final bool useCompressedPointers =
wordSize == 8 && (Platform.isAndroid || Platform.isIOS);
final bool useCompressedPointers = wordSize == 8 &&
(Platform.isAndroid ||
Platform.isIOS ||
Platform.executable.contains('64C'));
final int kAllocationSize = 2 * wordSize;
final int headerSize = wordSize;
@ -76,32 +78,29 @@ List<ObjectCopyOperation> getCopyOperations(
List<TimelineEvent> events, String isolateId) {
final copyOperations = <ObjectCopyOperation>[];
int? startTs = null;
int? startTts = null;
TimelineEvent? start = null;
for (final e in events) {
if (e.isolateId != isolateId) continue;
if (e.name != 'CopyMutableObjectGraph') continue;
if (startTts != null) {
if (start != null) {
if (!e.isEnd) throw 'Missing end of copy event';
final us = e.ts - startTs!;
final threadUs = e.tts! - startTts;
final us = e.ts - start.ts;
final threadUs = e.tts != null ? (e.tts! - start.tts!) : 0;
copyOperations.add(ObjectCopyOperation(
us,
threadUs,
int.parse(e.args['AllocatedBytes']!),
int.parse(e.args['CopiedObjects']!)));
startTs = null;
startTts = null;
start = null;
continue;
}
if (!e.isStart) throw 'Expected end of copy event';
startTs = e.ts;
startTts = e.tts;
start = e;
}
return copyOperations;
}

21
runtime/tests/vm/dart_2/isolates/fast_object_copy_timeline_test.dart

@ -17,8 +17,10 @@ import 'package:expect/expect.dart';
import '../timeline_utils.dart';
final int wordSize = sizeOf<IntPtr>();
final bool useCompressedPointers =
wordSize == 8 && (Platform.isAndroid || Platform.isIOS);
final bool useCompressedPointers = wordSize == 8 &&
(Platform.isAndroid ||
Platform.isIOS ||
Platform.executable.contains('64C'));
final int kAllocationSize = 2 * wordSize;
final int headerSize = wordSize;
@ -78,32 +80,29 @@ List<ObjectCopyOperation> getCopyOperations(
List<TimelineEvent> events, String isolateId) {
final copyOperations = <ObjectCopyOperation>[];
int startTs = null;
int startTts = null;
TimelineEvent start = null;
for (final e in events) {
if (e.isolateId != isolateId) continue;
if (e.name != 'CopyMutableObjectGraph') continue;
if (startTts != null) {
if (start != null) {
if (!e.isEnd) throw 'Missing end of copy event';
final us = e.ts - startTs;
final threadUs = e.tts - startTts;
final us = e.ts - start.ts;
final threadUs = e.tts != null ? (e.tts - start.tts) : 0;
copyOperations.add(ObjectCopyOperation(
us,
threadUs,
int.parse(e.args['AllocatedBytes']),
int.parse(e.args['CopiedObjects'])));
startTs = null;
startTts = null;
start = null;
continue;
}
if (!e.isStart) throw 'Expected end of copy event';
startTs = e.ts;
startTts = e.tts;
start = e;
}
return copyOperations;
}

2
tools/VERSION

@ -27,5 +27,5 @@ CHANNEL dev
MAJOR 2
MINOR 18
PATCH 0
PRERELEASE 145
PRERELEASE 146
PRERELEASE_PATCH 0
Loading…
Cancel
Save