From 92a8cf73475e6cebcd13a0a7e74f416289cf2c4f Mon Sep 17 00:00:00 2001 From: Tess Strickland Date: Mon, 1 Jun 2026 10:35:58 -0700 Subject: [PATCH] [vm,dyn_modules] Record coverage for instantiated instance calls. TEST=ci Cq-Include-Trybots: luci.dart.try:vm-dyn-linux-debug-x64-try Change-Id: Id8d84f131120b66984e9c9410b1f3aeeb4b41d83 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/507441 Reviewed-by: Alexander Markov --- pkg/dart2bytecode/lib/bytecode_generator.dart | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/dart2bytecode/lib/bytecode_generator.dart b/pkg/dart2bytecode/lib/bytecode_generator.dart index f68e0762c84..ad94b8bc42c 100644 --- a/pkg/dart2bytecode/lib/bytecode_generator.dart +++ b/pkg/dart2bytecode/lib/bytecode_generator.dart @@ -3535,6 +3535,8 @@ class BytecodeGenerator extends RecursiveVisitor { invocationKind != InvocationKind.getter && _isUncheckedCall(node, interfaceTarget, receiver); + _recordCoverage(node); + bool generated = false; if (invocationKind != InvocationKind.getter && !isDynamic && !isUnchecked) { final staticReceiverType = getStaticType(receiver, staticTypeContext); @@ -3557,7 +3559,6 @@ class BytecodeGenerator extends RecursiveVisitor { targetName, argDesc, ); - _recordCoverage(node); if (isDynamic) { assert(!isUnchecked); asm.emitDynamicCall(callCpIndex, totalArgCount);