Skip to content

Reapply stabilisation of the #[coverage(..)] attribute #134942

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

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions compiler/rustc_feature/src/accepted.rs
Original file line number Diff line number Diff line change
@@ -157,6 +157,9 @@ declare_features! (
(accepted, const_refs_to_static, "1.83.0", Some(119618)),
/// Allows implementing `Copy` for closures where possible (RFC 2132).
(accepted, copy_closures, "1.26.0", Some(44490)),
/// Allows function attribute `#[coverage(on/off)]`, to control coverage
/// instrumentation of that function.
(accepted, coverage_attribute, "CURRENT_RUSTC_VERSION", Some(84605)),
/// Allows `crate` in paths.
(accepted, crate_in_paths, "1.30.0", Some(45477)),
/// Allows users to provide classes for fenced code block using `class:classname`.
3 changes: 1 addition & 2 deletions compiler/rustc_feature/src/builtin_attrs.rs
Original file line number Diff line number Diff line change
@@ -480,10 +480,9 @@ pub const BUILTIN_ATTRIBUTES: &[BuiltinAttribute] = &[
template!(List: "address, kcfi, memory, thread"), DuplicatesOk,
EncodeCrossCrate::No, experimental!(no_sanitize)
),
gated!(
ungated!(
coverage, Normal, template!(OneOf: &[sym::off, sym::on]),
ErrorPreceding, EncodeCrossCrate::No,
coverage_attribute, experimental!(coverage)
),

ungated!(
3 changes: 0 additions & 3 deletions compiler/rustc_feature/src/unstable.rs
Original file line number Diff line number Diff line change
@@ -447,9 +447,6 @@ declare_features! (
(unstable, coroutine_clone, "1.65.0", Some(95360)),
/// Allows defining coroutines.
(unstable, coroutines, "1.21.0", Some(43122)),
/// Allows function attribute `#[coverage(on/off)]`, to control coverage
/// instrumentation of that function.
(unstable, coverage_attribute, "1.74.0", Some(84605)),
/// Allows non-builtin attributes in inner attribute position.
(unstable, custom_inner_attributes, "1.30.0", Some(54726)),
/// Allows custom test frameworks with `#![test_runner]` and `#[test_case]`.
2 changes: 1 addition & 1 deletion library/core/src/cmp.rs
Original file line number Diff line number Diff line change
@@ -348,7 +348,7 @@ pub trait Eq: PartialEq<Self> {
#[rustc_builtin_macro]
#[stable(feature = "builtin_macro_prelude", since = "1.38.0")]
#[allow_internal_unstable(core_intrinsics, derive_eq, structural_match)]
#[allow_internal_unstable(coverage_attribute)]
#[cfg_attr(bootstrap, allow_internal_unstable(coverage_attribute))]
pub macro Eq($item:item) {
/* compiler built-in */
}
2 changes: 1 addition & 1 deletion library/core/src/lib.rs
Original file line number Diff line number Diff line change
@@ -107,14 +107,14 @@
//
// Library features:
// tidy-alphabetical-start
#![cfg_attr(bootstrap, feature(coverage_attribute))]
#![cfg_attr(bootstrap, feature(do_not_recommend))]
#![feature(array_ptr_get)]
#![feature(asm_experimental_arch)]
#![feature(const_carrying_mul_add)]
#![feature(const_eval_select)]
#![feature(const_typed_swap)]
#![feature(core_intrinsics)]
#![feature(coverage_attribute)]
#![feature(internal_impls_macro)]
#![feature(ip)]
#![feature(is_ascii_octdigit)]
6 changes: 4 additions & 2 deletions library/core/src/macros/mod.rs
Original file line number Diff line number Diff line change
@@ -1673,7 +1673,8 @@ pub(crate) mod builtin {
///
/// [the reference]: ../../../reference/attributes/testing.html#the-test-attribute
#[stable(feature = "rust1", since = "1.0.0")]
#[allow_internal_unstable(test, rustc_attrs, coverage_attribute)]
#[allow_internal_unstable(test, rustc_attrs)]
#[cfg_attr(bootstrap, allow_internal_unstable(coverage_attribute))]
#[rustc_builtin_macro]
pub macro test($item:item) {
/* compiler built-in */
@@ -1686,7 +1687,8 @@ pub(crate) mod builtin {
soft,
reason = "`bench` is a part of custom test frameworks which are unstable"
)]
#[allow_internal_unstable(test, rustc_attrs, coverage_attribute)]
#[allow_internal_unstable(test, rustc_attrs)]
#[cfg_attr(bootstrap, allow_internal_unstable(coverage_attribute))]
#[rustc_builtin_macro]
pub macro bench($item:item) {
/* compiler built-in */
30 changes: 0 additions & 30 deletions src/doc/unstable-book/src/language-features/coverage-attribute.md

This file was deleted.

Original file line number Diff line number Diff line change
@@ -237,7 +237,7 @@ pub const INERT_ATTRIBUTES: &[BuiltinAttribute] = &[
template!(List: "address, kcfi, memory, thread"), DuplicatesOk,
experimental!(no_sanitize)
),
gated!(coverage, Normal, template!(Word, List: "on|off"), WarnFollowing, coverage_attribute, experimental!(coverage)),
ungated!(coverage, Normal, template!(Word, List: "on|off"), WarnFollowing),

ungated!(
doc, Normal, template!(List: "hidden|inline|...", NameValueStr: "string"), DuplicatesOk
100 changes: 50 additions & 50 deletions tests/coverage/async.cov-map
Original file line number Diff line number Diff line change
@@ -1,114 +1,114 @@
Function name: async::c
Raw bytes (9): 0x[01, 01, 00, 01, 01, 0b, 01, 00, 19]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 0a, 01, 00, 19]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 11, 1) to (start + 0, 25)
- Code(Counter(0)) at (prev + 10, 1) to (start + 0, 25)
Highest counter ID seen: c0

Function name: async::c::{closure#0}
Raw bytes (26): 0x[01, 01, 01, 01, 05, 04, 01, 0b, 19, 01, 0e, 05, 02, 09, 00, 0a, 02, 02, 09, 00, 0a, 01, 02, 01, 00, 02]
Raw bytes (26): 0x[01, 01, 01, 01, 05, 04, 01, 0a, 19, 01, 0e, 05, 02, 09, 00, 0a, 02, 02, 09, 00, 0a, 01, 02, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
Number of file 0 mappings: 4
- Code(Counter(0)) at (prev + 11, 25) to (start + 1, 14)
- Code(Counter(0)) at (prev + 10, 25) to (start + 1, 14)
- Code(Counter(1)) at (prev + 2, 9) to (start + 0, 10)
- Code(Expression(0, Sub)) at (prev + 2, 9) to (start + 0, 10)
= (c0 - c1)
- Code(Counter(0)) at (prev + 2, 1) to (start + 0, 2)
Highest counter ID seen: c1

Function name: async::d
Raw bytes (9): 0x[01, 01, 00, 01, 01, 13, 01, 00, 14]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 12, 01, 00, 14]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 19, 1) to (start + 0, 20)
- Code(Counter(0)) at (prev + 18, 1) to (start + 0, 20)
Highest counter ID seen: c0

Function name: async::d::{closure#0}
Raw bytes (9): 0x[01, 01, 00, 01, 01, 13, 14, 00, 19]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 12, 14, 00, 19]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 19, 20) to (start + 0, 25)
- Code(Counter(0)) at (prev + 18, 20) to (start + 0, 25)
Highest counter ID seen: c0

Function name: async::e (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 15, 01, 00, 14]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 14, 01, 00, 14]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 21, 1) to (start + 0, 20)
- Code(Zero) at (prev + 20, 1) to (start + 0, 20)
Highest counter ID seen: (none)

Function name: async::e::{closure#0} (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 15, 14, 00, 19]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 14, 14, 00, 19]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 21, 20) to (start + 0, 25)
- Code(Zero) at (prev + 20, 20) to (start + 0, 25)
Highest counter ID seen: (none)

Function name: async::f
Raw bytes (9): 0x[01, 01, 00, 01, 01, 17, 01, 00, 14]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 16, 01, 00, 14]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 23, 1) to (start + 0, 20)
- Code(Counter(0)) at (prev + 22, 1) to (start + 0, 20)
Highest counter ID seen: c0

Function name: async::f::{closure#0}
Raw bytes (9): 0x[01, 01, 00, 01, 01, 17, 14, 00, 19]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 16, 14, 00, 19]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 23, 20) to (start + 0, 25)
- Code(Counter(0)) at (prev + 22, 20) to (start + 0, 25)
Highest counter ID seen: c0

Function name: async::foo (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 19, 01, 00, 1e]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 18, 01, 00, 1e]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 25, 1) to (start + 0, 30)
- Code(Zero) at (prev + 24, 1) to (start + 0, 30)
Highest counter ID seen: (none)

Function name: async::foo::{closure#0} (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 19, 1e, 00, 2d]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 18, 1e, 00, 2d]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 25, 30) to (start + 0, 45)
- Code(Zero) at (prev + 24, 30) to (start + 0, 45)
Highest counter ID seen: (none)

Function name: async::g
Raw bytes (9): 0x[01, 01, 00, 01, 01, 1b, 01, 00, 17]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 1a, 01, 00, 17]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 27, 1) to (start + 0, 23)
- Code(Counter(0)) at (prev + 26, 1) to (start + 0, 23)
Highest counter ID seen: c0

Function name: async::g::{closure#0} (unused)
Raw bytes (59): 0x[01, 01, 00, 0b, 00, 1b, 17, 01, 0c, 00, 02, 09, 00, 0a, 00, 00, 0e, 00, 17, 00, 00, 1b, 00, 1c, 00, 00, 20, 00, 22, 00, 01, 09, 00, 0a, 00, 00, 0e, 00, 17, 00, 00, 1b, 00, 1c, 00, 00, 20, 00, 22, 00, 01, 0e, 00, 10, 00, 02, 01, 00, 02]
Raw bytes (59): 0x[01, 01, 00, 0b, 00, 1a, 17, 01, 0c, 00, 02, 09, 00, 0a, 00, 00, 0e, 00, 17, 00, 00, 1b, 00, 1c, 00, 00, 20, 00, 22, 00, 01, 09, 00, 0a, 00, 00, 0e, 00, 17, 00, 00, 1b, 00, 1c, 00, 00, 20, 00, 22, 00, 01, 0e, 00, 10, 00, 02, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 11
- Code(Zero) at (prev + 27, 23) to (start + 1, 12)
- Code(Zero) at (prev + 26, 23) to (start + 1, 12)
- Code(Zero) at (prev + 2, 9) to (start + 0, 10)
- Code(Zero) at (prev + 0, 14) to (start + 0, 23)
- Code(Zero) at (prev + 0, 27) to (start + 0, 28)
@@ -122,21 +122,21 @@ Number of file 0 mappings: 11
Highest counter ID seen: (none)

Function name: async::h
Raw bytes (9): 0x[01, 01, 00, 01, 01, 23, 01, 00, 16]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 22, 01, 00, 16]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 35, 1) to (start + 0, 22)
- Code(Counter(0)) at (prev + 34, 1) to (start + 0, 22)
Highest counter ID seen: c0

Function name: async::h::{closure#0} (unused)
Raw bytes (39): 0x[01, 01, 00, 07, 00, 23, 16, 03, 0c, 00, 04, 09, 00, 0a, 00, 00, 0e, 00, 19, 00, 00, 1a, 00, 1b, 00, 00, 20, 00, 22, 00, 01, 0e, 00, 10, 00, 02, 01, 00, 02]
Raw bytes (39): 0x[01, 01, 00, 07, 00, 22, 16, 03, 0c, 00, 04, 09, 00, 0a, 00, 00, 0e, 00, 19, 00, 00, 1a, 00, 1b, 00, 00, 20, 00, 22, 00, 01, 0e, 00, 10, 00, 02, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 7
- Code(Zero) at (prev + 35, 22) to (start + 3, 12)
- Code(Zero) at (prev + 34, 22) to (start + 3, 12)
- Code(Zero) at (prev + 4, 9) to (start + 0, 10)
- Code(Zero) at (prev + 0, 14) to (start + 0, 25)
- Code(Zero) at (prev + 0, 26) to (start + 0, 27)
@@ -146,23 +146,23 @@ Number of file 0 mappings: 7
Highest counter ID seen: (none)

Function name: async::i
Raw bytes (9): 0x[01, 01, 00, 01, 01, 2c, 01, 00, 13]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 2b, 01, 00, 13]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 44, 1) to (start + 0, 19)
- Code(Counter(0)) at (prev + 43, 1) to (start + 0, 19)
Highest counter ID seen: c0

Function name: async::i::{closure#0}
Raw bytes (63): 0x[01, 01, 02, 07, 15, 0d, 11, 0b, 01, 2c, 13, 04, 0c, 09, 05, 09, 00, 0a, 01, 00, 0e, 00, 18, 05, 00, 1c, 00, 21, 09, 00, 27, 00, 30, 11, 01, 09, 00, 0a, 19, 00, 0e, 00, 17, 1d, 00, 1b, 00, 20, 11, 00, 24, 00, 26, 15, 01, 0e, 00, 10, 03, 02, 01, 00, 02]
Raw bytes (63): 0x[01, 01, 02, 07, 15, 0d, 11, 0b, 01, 2b, 13, 04, 0c, 09, 05, 09, 00, 0a, 01, 00, 0e, 00, 18, 05, 00, 1c, 00, 21, 09, 00, 27, 00, 30, 11, 01, 09, 00, 0a, 19, 00, 0e, 00, 17, 1d, 00, 1b, 00, 20, 11, 00, 24, 00, 26, 15, 01, 0e, 00, 10, 03, 02, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 2
- expression 0 operands: lhs = Expression(1, Add), rhs = Counter(5)
- expression 1 operands: lhs = Counter(3), rhs = Counter(4)
Number of file 0 mappings: 11
- Code(Counter(0)) at (prev + 44, 19) to (start + 4, 12)
- Code(Counter(0)) at (prev + 43, 19) to (start + 4, 12)
- Code(Counter(2)) at (prev + 5, 9) to (start + 0, 10)
- Code(Counter(0)) at (prev + 0, 14) to (start + 0, 24)
- Code(Counter(1)) at (prev + 0, 28) to (start + 0, 33)
@@ -177,14 +177,14 @@ Number of file 0 mappings: 11
Highest counter ID seen: c7

Function name: async::j
Raw bytes (58): 0x[01, 01, 02, 07, 0d, 05, 09, 0a, 01, 37, 01, 00, 0d, 01, 0b, 0b, 00, 0c, 05, 01, 09, 00, 0a, 01, 00, 0e, 00, 1b, 05, 00, 1f, 00, 27, 09, 01, 09, 00, 0a, 11, 00, 0e, 00, 1a, 09, 00, 1e, 00, 20, 0d, 01, 0e, 00, 10, 03, 02, 01, 00, 02]
Raw bytes (58): 0x[01, 01, 02, 07, 0d, 05, 09, 0a, 01, 36, 01, 00, 0d, 01, 0b, 0b, 00, 0c, 05, 01, 09, 00, 0a, 01, 00, 0e, 00, 1b, 05, 00, 1f, 00, 27, 09, 01, 09, 00, 0a, 11, 00, 0e, 00, 1a, 09, 00, 1e, 00, 20, 0d, 01, 0e, 00, 10, 03, 02, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 2
- expression 0 operands: lhs = Expression(1, Add), rhs = Counter(3)
- expression 1 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 10
- Code(Counter(0)) at (prev + 55, 1) to (start + 0, 13)
- Code(Counter(0)) at (prev + 54, 1) to (start + 0, 13)
- Code(Counter(0)) at (prev + 11, 11) to (start + 0, 12)
- Code(Counter(1)) at (prev + 1, 9) to (start + 0, 10)
- Code(Counter(0)) at (prev + 0, 14) to (start + 0, 27)
@@ -198,59 +198,59 @@ Number of file 0 mappings: 10
Highest counter ID seen: c4

Function name: async::j::c
Raw bytes (26): 0x[01, 01, 01, 01, 05, 04, 01, 39, 05, 01, 12, 05, 02, 0d, 00, 0e, 02, 02, 0d, 00, 0e, 01, 02, 05, 00, 06]
Raw bytes (26): 0x[01, 01, 01, 01, 05, 04, 01, 38, 05, 01, 12, 05, 02, 0d, 00, 0e, 02, 02, 0d, 00, 0e, 01, 02, 05, 00, 06]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
Number of file 0 mappings: 4
- Code(Counter(0)) at (prev + 57, 5) to (start + 1, 18)
- Code(Counter(0)) at (prev + 56, 5) to (start + 1, 18)
- Code(Counter(1)) at (prev + 2, 13) to (start + 0, 14)
- Code(Expression(0, Sub)) at (prev + 2, 13) to (start + 0, 14)
= (c0 - c1)
- Code(Counter(0)) at (prev + 2, 5) to (start + 0, 6)
Highest counter ID seen: c1

Function name: async::j::d
Raw bytes (9): 0x[01, 01, 00, 01, 01, 40, 05, 00, 17]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 3f, 05, 00, 17]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 64, 5) to (start + 0, 23)
- Code(Counter(0)) at (prev + 63, 5) to (start + 0, 23)
Highest counter ID seen: c0

Function name: async::j::f
Raw bytes (9): 0x[01, 01, 00, 01, 01, 41, 05, 00, 17]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 40, 05, 00, 17]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 65, 5) to (start + 0, 23)
- Code(Counter(0)) at (prev + 64, 5) to (start + 0, 23)
Highest counter ID seen: c0

Function name: async::k (unused)
Raw bytes (29): 0x[01, 01, 00, 05, 00, 49, 01, 01, 0c, 00, 02, 0e, 00, 10, 00, 01, 0e, 00, 10, 00, 01, 0e, 00, 10, 00, 02, 01, 00, 02]
Raw bytes (29): 0x[01, 01, 00, 05, 00, 48, 01, 01, 0c, 00, 02, 0e, 00, 10, 00, 01, 0e, 00, 10, 00, 01, 0e, 00, 10, 00, 02, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 5
- Code(Zero) at (prev + 73, 1) to (start + 1, 12)
- Code(Zero) at (prev + 72, 1) to (start + 1, 12)
- Code(Zero) at (prev + 2, 14) to (start + 0, 16)
- Code(Zero) at (prev + 1, 14) to (start + 0, 16)
- Code(Zero) at (prev + 1, 14) to (start + 0, 16)
- Code(Zero) at (prev + 2, 1) to (start + 0, 2)
Highest counter ID seen: (none)

Function name: async::l
Raw bytes (33): 0x[01, 01, 02, 01, 07, 05, 09, 05, 01, 51, 01, 01, 0c, 02, 02, 0e, 00, 10, 09, 01, 0e, 00, 10, 05, 01, 0e, 00, 10, 01, 02, 01, 00, 02]
Raw bytes (33): 0x[01, 01, 02, 01, 07, 05, 09, 05, 01, 50, 01, 01, 0c, 02, 02, 0e, 00, 10, 09, 01, 0e, 00, 10, 05, 01, 0e, 00, 10, 01, 02, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 2
- expression 0 operands: lhs = Counter(0), rhs = Expression(1, Add)
- expression 1 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 5
- Code(Counter(0)) at (prev + 81, 1) to (start + 1, 12)
- Code(Counter(0)) at (prev + 80, 1) to (start + 1, 12)
- Code(Expression(0, Sub)) at (prev + 2, 14) to (start + 0, 16)
= (c0 - (c1 + c2))
- Code(Counter(2)) at (prev + 1, 14) to (start + 0, 16)
@@ -259,29 +259,29 @@ Number of file 0 mappings: 5
Highest counter ID seen: c2

Function name: async::m
Raw bytes (9): 0x[01, 01, 00, 01, 01, 59, 01, 00, 19]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 58, 01, 00, 19]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 89, 1) to (start + 0, 25)
- Code(Counter(0)) at (prev + 88, 1) to (start + 0, 25)
Highest counter ID seen: c0

Function name: async::m::{closure#0} (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 59, 19, 00, 22]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 58, 19, 00, 22]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 89, 25) to (start + 0, 34)
- Code(Zero) at (prev + 88, 25) to (start + 0, 34)
Highest counter ID seen: (none)

Function name: async::main
Raw bytes (9): 0x[01, 01, 00, 01, 01, 5b, 01, 08, 02]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 5a, 01, 08, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 91, 1) to (start + 8, 2)
- Code(Counter(0)) at (prev + 90, 1) to (start + 8, 2)
Highest counter ID seen: c0

1 change: 0 additions & 1 deletion tests/coverage/async.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |#![feature(custom_inner_attributes)] // for #![rustfmt::skip]
LL| |#![allow(unused_assignments, dead_code)]
LL| |#![rustfmt::skip]
1 change: 0 additions & 1 deletion tests/coverage/async.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
#![feature(custom_inner_attributes)] // for #![rustfmt::skip]
#![allow(unused_assignments, dead_code)]
#![rustfmt::skip]
24 changes: 12 additions & 12 deletions tests/coverage/async2.cov-map
Original file line number Diff line number Diff line change
@@ -1,58 +1,58 @@
Function name: async2::async_func
Raw bytes (9): 0x[01, 01, 00, 01, 01, 0f, 01, 00, 17]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 0e, 01, 00, 17]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 15, 1) to (start + 0, 23)
- Code(Counter(0)) at (prev + 14, 1) to (start + 0, 23)
Highest counter ID seen: c0

Function name: async2::async_func::{closure#0}
Raw bytes (24): 0x[01, 01, 00, 04, 01, 0f, 17, 03, 09, 05, 03, 0a, 02, 06, 00, 02, 05, 00, 06, 01, 01, 01, 00, 02]
Raw bytes (24): 0x[01, 01, 00, 04, 01, 0e, 17, 03, 09, 05, 03, 0a, 02, 06, 00, 02, 05, 00, 06, 01, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 4
- Code(Counter(0)) at (prev + 15, 23) to (start + 3, 9)
- Code(Counter(0)) at (prev + 14, 23) to (start + 3, 9)
- Code(Counter(1)) at (prev + 3, 10) to (start + 2, 6)
- Code(Zero) at (prev + 2, 5) to (start + 0, 6)
- Code(Counter(0)) at (prev + 1, 1) to (start + 0, 2)
Highest counter ID seen: c1

Function name: async2::async_func_just_println
Raw bytes (9): 0x[01, 01, 00, 01, 01, 17, 01, 00, 24]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 16, 01, 00, 24]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 23, 1) to (start + 0, 36)
- Code(Counter(0)) at (prev + 22, 1) to (start + 0, 36)
Highest counter ID seen: c0

Function name: async2::async_func_just_println::{closure#0}
Raw bytes (9): 0x[01, 01, 00, 01, 01, 17, 24, 02, 02]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 16, 24, 02, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 23, 36) to (start + 2, 2)
- Code(Counter(0)) at (prev + 22, 36) to (start + 2, 2)
Highest counter ID seen: c0

Function name: async2::main
Raw bytes (9): 0x[01, 01, 00, 01, 01, 1b, 01, 07, 02]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 1a, 01, 07, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 27, 1) to (start + 7, 2)
- Code(Counter(0)) at (prev + 26, 1) to (start + 7, 2)
Highest counter ID seen: c0

Function name: async2::non_async_func
Raw bytes (24): 0x[01, 01, 00, 04, 01, 07, 01, 03, 09, 05, 03, 0a, 02, 06, 00, 02, 05, 00, 06, 01, 01, 01, 00, 02]
Raw bytes (24): 0x[01, 01, 00, 04, 01, 06, 01, 03, 09, 05, 03, 0a, 02, 06, 00, 02, 05, 00, 06, 01, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 4
- Code(Counter(0)) at (prev + 7, 1) to (start + 3, 9)
- Code(Counter(0)) at (prev + 6, 1) to (start + 3, 9)
- Code(Counter(1)) at (prev + 3, 10) to (start + 2, 6)
- Code(Zero) at (prev + 2, 5) to (start + 0, 6)
- Code(Counter(0)) at (prev + 1, 1) to (start + 0, 2)
1 change: 0 additions & 1 deletion tests/coverage/async2.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2018
LL| |
LL| |//@ aux-build: executor.rs
1 change: 0 additions & 1 deletion tests/coverage/async2.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2018

//@ aux-build: executor.rs
8 changes: 4 additions & 4 deletions tests/coverage/async_block.cov-map
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
Function name: async_block::main
Raw bytes (36): 0x[01, 01, 01, 01, 05, 06, 01, 07, 01, 00, 0b, 05, 01, 09, 00, 0a, 03, 00, 0e, 00, 13, 05, 00, 14, 01, 16, 05, 07, 0a, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (36): 0x[01, 01, 01, 01, 05, 06, 01, 06, 01, 00, 0b, 05, 01, 09, 00, 0a, 03, 00, 0e, 00, 13, 05, 00, 14, 01, 16, 05, 07, 0a, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
Number of file 0 mappings: 6
- Code(Counter(0)) at (prev + 7, 1) to (start + 0, 11)
- Code(Counter(0)) at (prev + 6, 1) to (start + 0, 11)
- Code(Counter(1)) at (prev + 1, 9) to (start + 0, 10)
- Code(Expression(0, Add)) at (prev + 0, 14) to (start + 0, 19)
= (c0 + c1)
@@ -15,13 +15,13 @@ Number of file 0 mappings: 6
Highest counter ID seen: c1

Function name: async_block::main::{closure#0}
Raw bytes (26): 0x[01, 01, 01, 01, 05, 04, 01, 09, 1c, 01, 17, 05, 01, 18, 02, 0e, 02, 02, 14, 02, 0e, 01, 03, 09, 00, 0a]
Raw bytes (26): 0x[01, 01, 01, 01, 05, 04, 01, 08, 1c, 01, 17, 05, 01, 18, 02, 0e, 02, 02, 14, 02, 0e, 01, 03, 09, 00, 0a]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
Number of file 0 mappings: 4
- Code(Counter(0)) at (prev + 9, 28) to (start + 1, 23)
- Code(Counter(0)) at (prev + 8, 28) to (start + 1, 23)
- Code(Counter(1)) at (prev + 1, 24) to (start + 2, 14)
- Code(Expression(0, Sub)) at (prev + 2, 20) to (start + 2, 14)
= (c0 - c1)
1 change: 0 additions & 1 deletion tests/coverage/async_block.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |
LL| |//@ aux-build: executor.rs
1 change: 0 additions & 1 deletion tests/coverage/async_block.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021

//@ aux-build: executor.rs
12 changes: 6 additions & 6 deletions tests/coverage/attr/impl.cov-map
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
Function name: <impl::MyStruct>::off_on (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 0f, 05, 00, 13]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 0e, 05, 00, 13]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 15, 5) to (start + 0, 19)
- Code(Zero) at (prev + 14, 5) to (start + 0, 19)
Highest counter ID seen: (none)

Function name: <impl::MyStruct>::on_inherit (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 17, 05, 00, 17]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 16, 05, 00, 17]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 23, 5) to (start + 0, 23)
- Code(Zero) at (prev + 22, 5) to (start + 0, 23)
Highest counter ID seen: (none)

Function name: <impl::MyStruct>::on_on (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 1a, 05, 00, 12]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 19, 05, 00, 12]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 26, 5) to (start + 0, 18)
- Code(Zero) at (prev + 25, 5) to (start + 0, 18)
Highest counter ID seen: (none)

1 change: 0 additions & 1 deletion tests/coverage/attr/impl.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ reference: attributes.coverage.nesting
LL| |
1 change: 0 additions & 1 deletion tests/coverage/attr/impl.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ reference: attributes.coverage.nesting

12 changes: 6 additions & 6 deletions tests/coverage/attr/module.cov-map
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
Function name: module::off::on (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 0d, 05, 00, 0f]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 0c, 05, 00, 0f]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 13, 5) to (start + 0, 15)
- Code(Zero) at (prev + 12, 5) to (start + 0, 15)
Highest counter ID seen: (none)

Function name: module::on::inherit (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 15, 05, 00, 14]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 14, 05, 00, 14]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 21, 5) to (start + 0, 20)
- Code(Zero) at (prev + 20, 5) to (start + 0, 20)
Highest counter ID seen: (none)

Function name: module::on::on (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 18, 05, 00, 0f]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 17, 05, 00, 0f]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 24, 5) to (start + 0, 15)
- Code(Zero) at (prev + 23, 5) to (start + 0, 15)
Highest counter ID seen: (none)

1 change: 0 additions & 1 deletion tests/coverage/attr/module.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ reference: attributes.coverage.nesting
LL| |
1 change: 0 additions & 1 deletion tests/coverage/attr/module.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ reference: attributes.coverage.nesting

2 changes: 1 addition & 1 deletion tests/coverage/attr/nested.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
LL| |#![feature(coverage_attribute, stmt_expr_attributes)]
LL| |#![feature(stmt_expr_attributes)]
LL| |//@ edition: 2021
LL| |//@ reference: attributes.coverage.nesting
LL| |
2 changes: 1 addition & 1 deletion tests/coverage/attr/nested.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#![feature(coverage_attribute, stmt_expr_attributes)]
#![feature(stmt_expr_attributes)]
//@ edition: 2021
//@ reference: attributes.coverage.nesting

12 changes: 6 additions & 6 deletions tests/coverage/attr/off-on-sandwich.cov-map
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
Function name: off_on_sandwich::dense_a::dense_b
Raw bytes (14): 0x[01, 01, 00, 02, 01, 10, 05, 02, 12, 01, 07, 05, 00, 06]
Raw bytes (14): 0x[01, 01, 00, 02, 01, 0f, 05, 02, 12, 01, 07, 05, 00, 06]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 16, 5) to (start + 2, 18)
- Code(Counter(0)) at (prev + 15, 5) to (start + 2, 18)
- Code(Counter(0)) at (prev + 7, 5) to (start + 0, 6)
Highest counter ID seen: c0

Function name: off_on_sandwich::sparse_a::sparse_b::sparse_c
Raw bytes (14): 0x[01, 01, 00, 02, 01, 22, 09, 02, 17, 01, 0b, 09, 00, 0a]
Raw bytes (14): 0x[01, 01, 00, 02, 01, 21, 09, 02, 17, 01, 0b, 09, 00, 0a]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 34, 9) to (start + 2, 23)
- Code(Counter(0)) at (prev + 33, 9) to (start + 2, 23)
- Code(Counter(0)) at (prev + 11, 9) to (start + 0, 10)
Highest counter ID seen: c0

Function name: off_on_sandwich::sparse_a::sparse_b::sparse_c::sparse_d
Raw bytes (14): 0x[01, 01, 00, 02, 01, 25, 0d, 02, 1b, 01, 07, 0d, 00, 0e]
Raw bytes (14): 0x[01, 01, 00, 02, 01, 24, 0d, 02, 1b, 01, 07, 0d, 00, 0e]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 37, 13) to (start + 2, 27)
- Code(Counter(0)) at (prev + 36, 13) to (start + 2, 27)
- Code(Counter(0)) at (prev + 7, 13) to (start + 0, 14)
Highest counter ID seen: c0

1 change: 0 additions & 1 deletion tests/coverage/attr/off-on-sandwich.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ reference: attributes.coverage.nesting
LL| |
1 change: 0 additions & 1 deletion tests/coverage/attr/off-on-sandwich.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ reference: attributes.coverage.nesting

4 changes: 2 additions & 2 deletions tests/coverage/attr/trait-impl-inherit.cov-map
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
Function name: <trait_impl_inherit::S as trait_impl_inherit::T>::f
Raw bytes (9): 0x[01, 01, 00, 01, 01, 11, 05, 02, 06]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 10, 05, 02, 06]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 17, 5) to (start + 2, 6)
- Code(Counter(0)) at (prev + 16, 5) to (start + 2, 6)
Highest counter ID seen: c0

1 change: 0 additions & 1 deletion tests/coverage/attr/trait-impl-inherit.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |// Checks that `#[coverage(..)]` in a trait method is not inherited in an
LL| |// implementation.
LL| |//@ edition: 2021
1 change: 0 additions & 1 deletion tests/coverage/attr/trait-impl-inherit.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
// Checks that `#[coverage(..)]` in a trait method is not inherited in an
// implementation.
//@ edition: 2021
1 change: 0 additions & 1 deletion tests/coverage/auxiliary/executor.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021

use core::future::Future;
8 changes: 4 additions & 4 deletions tests/coverage/await_ready.cov-map
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
Function name: await_ready::await_ready
Raw bytes (9): 0x[01, 01, 00, 01, 01, 0e, 01, 00, 1e]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 0d, 01, 00, 1e]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 14, 1) to (start + 0, 30)
- Code(Counter(0)) at (prev + 13, 1) to (start + 0, 30)
Highest counter ID seen: c0

Function name: await_ready::await_ready::{closure#0}
Raw bytes (14): 0x[01, 01, 00, 02, 01, 0e, 1e, 03, 0f, 05, 04, 01, 00, 02]
Raw bytes (14): 0x[01, 01, 00, 02, 01, 0d, 1e, 03, 0f, 05, 04, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 14, 30) to (start + 3, 15)
- Code(Counter(0)) at (prev + 13, 30) to (start + 3, 15)
- Code(Counter(1)) at (prev + 4, 1) to (start + 0, 2)
Highest counter ID seen: c1

1 change: 0 additions & 1 deletion tests/coverage/await_ready.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |#![coverage(off)]
LL| |//@ edition: 2021
LL| |
1 change: 0 additions & 1 deletion tests/coverage/await_ready.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
#![coverage(off)]
//@ edition: 2021

32 changes: 16 additions & 16 deletions tests/coverage/bad_counter_ids.cov-map
Original file line number Diff line number Diff line change
@@ -1,88 +1,88 @@
Function name: bad_counter_ids::eq_bad
Raw bytes (14): 0x[01, 01, 00, 02, 01, 24, 01, 02, 1f, 00, 03, 01, 00, 02]
Raw bytes (14): 0x[01, 01, 00, 02, 01, 23, 01, 02, 1f, 00, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 36, 1) to (start + 2, 31)
- Code(Counter(0)) at (prev + 35, 1) to (start + 2, 31)
- Code(Zero) at (prev + 3, 1) to (start + 0, 2)
Highest counter ID seen: c0

Function name: bad_counter_ids::eq_bad_message
Raw bytes (21): 0x[01, 01, 01, 01, 00, 03, 01, 29, 01, 02, 0f, 02, 02, 20, 00, 2b, 00, 01, 01, 00, 02]
Raw bytes (21): 0x[01, 01, 01, 01, 00, 03, 01, 28, 01, 02, 0f, 02, 02, 20, 00, 2b, 00, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Zero
Number of file 0 mappings: 3
- Code(Counter(0)) at (prev + 41, 1) to (start + 2, 15)
- Code(Counter(0)) at (prev + 40, 1) to (start + 2, 15)
- Code(Expression(0, Sub)) at (prev + 2, 32) to (start + 0, 43)
= (c0 - Zero)
- Code(Zero) at (prev + 1, 1) to (start + 0, 2)
Highest counter ID seen: c0

Function name: bad_counter_ids::eq_good
Raw bytes (14): 0x[01, 01, 00, 02, 01, 10, 01, 02, 1f, 05, 03, 01, 00, 02]
Raw bytes (14): 0x[01, 01, 00, 02, 01, 0f, 01, 02, 1f, 05, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 16, 1) to (start + 2, 31)
- Code(Counter(0)) at (prev + 15, 1) to (start + 2, 31)
- Code(Counter(1)) at (prev + 3, 1) to (start + 0, 2)
Highest counter ID seen: c1

Function name: bad_counter_ids::eq_good_message
Raw bytes (19): 0x[01, 01, 00, 03, 01, 15, 01, 02, 0f, 00, 02, 20, 00, 2b, 05, 01, 01, 00, 02]
Raw bytes (19): 0x[01, 01, 00, 03, 01, 14, 01, 02, 0f, 00, 02, 20, 00, 2b, 05, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 3
- Code(Counter(0)) at (prev + 21, 1) to (start + 2, 15)
- Code(Counter(0)) at (prev + 20, 1) to (start + 2, 15)
- Code(Zero) at (prev + 2, 32) to (start + 0, 43)
- Code(Counter(1)) at (prev + 1, 1) to (start + 0, 2)
Highest counter ID seen: c1

Function name: bad_counter_ids::ne_bad
Raw bytes (14): 0x[01, 01, 00, 02, 01, 2e, 01, 02, 1f, 00, 03, 01, 00, 02]
Raw bytes (14): 0x[01, 01, 00, 02, 01, 2d, 01, 02, 1f, 00, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 46, 1) to (start + 2, 31)
- Code(Counter(0)) at (prev + 45, 1) to (start + 2, 31)
- Code(Zero) at (prev + 3, 1) to (start + 0, 2)
Highest counter ID seen: c0

Function name: bad_counter_ids::ne_bad_message
Raw bytes (19): 0x[01, 01, 00, 03, 01, 33, 01, 02, 0f, 05, 02, 20, 00, 2b, 00, 01, 01, 00, 02]
Raw bytes (19): 0x[01, 01, 00, 03, 01, 32, 01, 02, 0f, 05, 02, 20, 00, 2b, 00, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 3
- Code(Counter(0)) at (prev + 51, 1) to (start + 2, 15)
- Code(Counter(0)) at (prev + 50, 1) to (start + 2, 15)
- Code(Counter(1)) at (prev + 2, 32) to (start + 0, 43)
- Code(Zero) at (prev + 1, 1) to (start + 0, 2)
Highest counter ID seen: c1

Function name: bad_counter_ids::ne_good
Raw bytes (16): 0x[01, 01, 01, 01, 00, 02, 01, 1a, 01, 02, 1f, 02, 03, 01, 00, 02]
Raw bytes (16): 0x[01, 01, 01, 01, 00, 02, 01, 19, 01, 02, 1f, 02, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Zero
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 26, 1) to (start + 2, 31)
- Code(Counter(0)) at (prev + 25, 1) to (start + 2, 31)
- Code(Expression(0, Sub)) at (prev + 3, 1) to (start + 0, 2)
= (c0 - Zero)
Highest counter ID seen: c0

Function name: bad_counter_ids::ne_good_message
Raw bytes (21): 0x[01, 01, 01, 01, 00, 03, 01, 1f, 01, 02, 0f, 00, 02, 20, 00, 2b, 02, 01, 01, 00, 02]
Raw bytes (21): 0x[01, 01, 01, 01, 00, 03, 01, 1e, 01, 02, 0f, 00, 02, 20, 00, 2b, 02, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Zero
Number of file 0 mappings: 3
- Code(Counter(0)) at (prev + 31, 1) to (start + 2, 15)
- Code(Counter(0)) at (prev + 30, 1) to (start + 2, 15)
- Code(Zero) at (prev + 2, 32) to (start + 0, 43)
- Code(Expression(0, Sub)) at (prev + 1, 1) to (start + 0, 2)
= (c0 - Zero)
1 change: 0 additions & 1 deletion tests/coverage/bad_counter_ids.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Copt-level=0 -Zmir-opt-level=3
LL| |
1 change: 0 additions & 1 deletion tests/coverage/bad_counter_ids.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ compile-flags: -Copt-level=0 -Zmir-opt-level=3

12 changes: 6 additions & 6 deletions tests/coverage/branch/generics.cov-map
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
Function name: generics::print_size::<()>
Raw bytes (33): 0x[01, 01, 01, 01, 05, 05, 01, 06, 01, 01, 24, 20, 05, 02, 01, 08, 00, 24, 05, 00, 25, 02, 06, 02, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (33): 0x[01, 01, 01, 01, 05, 05, 01, 05, 01, 01, 24, 20, 05, 02, 01, 08, 00, 24, 05, 00, 25, 02, 06, 02, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
Number of file 0 mappings: 5
- Code(Counter(0)) at (prev + 6, 1) to (start + 1, 36)
- Code(Counter(0)) at (prev + 5, 1) to (start + 1, 36)
- Branch { true: Counter(1), false: Expression(0, Sub) } at (prev + 1, 8) to (start + 0, 36)
true = c1
false = (c0 - c1)
@@ -16,13 +16,13 @@ Number of file 0 mappings: 5
Highest counter ID seen: c1

Function name: generics::print_size::<u32>
Raw bytes (33): 0x[01, 01, 01, 01, 05, 05, 01, 06, 01, 01, 24, 20, 05, 02, 01, 08, 00, 24, 05, 00, 25, 02, 06, 02, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (33): 0x[01, 01, 01, 01, 05, 05, 01, 05, 01, 01, 24, 20, 05, 02, 01, 08, 00, 24, 05, 00, 25, 02, 06, 02, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
Number of file 0 mappings: 5
- Code(Counter(0)) at (prev + 6, 1) to (start + 1, 36)
- Code(Counter(0)) at (prev + 5, 1) to (start + 1, 36)
- Branch { true: Counter(1), false: Expression(0, Sub) } at (prev + 1, 8) to (start + 0, 36)
true = c1
false = (c0 - c1)
@@ -33,13 +33,13 @@ Number of file 0 mappings: 5
Highest counter ID seen: c1

Function name: generics::print_size::<u64>
Raw bytes (33): 0x[01, 01, 01, 01, 05, 05, 01, 06, 01, 01, 24, 20, 05, 02, 01, 08, 00, 24, 05, 00, 25, 02, 06, 02, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (33): 0x[01, 01, 01, 01, 05, 05, 01, 05, 01, 01, 24, 20, 05, 02, 01, 08, 00, 24, 05, 00, 25, 02, 06, 02, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
Number of file 0 mappings: 5
- Code(Counter(0)) at (prev + 6, 1) to (start + 1, 36)
- Code(Counter(0)) at (prev + 5, 1) to (start + 1, 36)
- Branch { true: Counter(1), false: Expression(0, Sub) } at (prev + 1, 8) to (start + 0, 36)
true = c1
false = (c0 - c1)
1 change: 0 additions & 1 deletion tests/coverage/branch/generics.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Zcoverage-options=branch
LL| |//@ llvm-cov-flags: --show-branches=count
1 change: 0 additions & 1 deletion tests/coverage/branch/generics.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ compile-flags: -Zcoverage-options=branch
//@ llvm-cov-flags: --show-branches=count
4 changes: 2 additions & 2 deletions tests/coverage/branch/guard.cov-map
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Function name: guard::branch_match_guard
Raw bytes (89): 0x[01, 01, 08, 05, 0d, 05, 17, 0d, 11, 1f, 17, 05, 09, 0d, 11, 1f, 15, 05, 09, 0d, 01, 0c, 01, 01, 10, 02, 03, 0b, 00, 0c, 15, 01, 14, 02, 0a, 0d, 03, 0e, 00, 0f, 05, 00, 14, 00, 19, 20, 0d, 02, 00, 14, 00, 1e, 0d, 00, 1d, 02, 0a, 11, 03, 0e, 00, 0f, 02, 00, 14, 00, 19, 20, 11, 06, 00, 14, 00, 1e, 11, 00, 1d, 02, 0a, 0e, 03, 0e, 02, 0a, 1b, 04, 01, 00, 02]
Raw bytes (89): 0x[01, 01, 08, 05, 0d, 05, 17, 0d, 11, 1f, 17, 05, 09, 0d, 11, 1f, 15, 05, 09, 0d, 01, 0b, 01, 01, 10, 02, 03, 0b, 00, 0c, 15, 01, 14, 02, 0a, 0d, 03, 0e, 00, 0f, 05, 00, 14, 00, 19, 20, 0d, 02, 00, 14, 00, 1e, 0d, 00, 1d, 02, 0a, 11, 03, 0e, 00, 0f, 02, 00, 14, 00, 19, 20, 11, 06, 00, 14, 00, 1e, 11, 00, 1d, 02, 0a, 0e, 03, 0e, 02, 0a, 1b, 04, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 8
@@ -12,7 +12,7 @@ Number of expressions: 8
- expression 6 operands: lhs = Expression(7, Add), rhs = Counter(5)
- expression 7 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 13
- Code(Counter(0)) at (prev + 12, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 11, 1) to (start + 1, 16)
- Code(Expression(0, Sub)) at (prev + 3, 11) to (start + 0, 12)
= (c1 - c3)
- Code(Counter(5)) at (prev + 1, 20) to (start + 2, 10)
1 change: 0 additions & 1 deletion tests/coverage/branch/guard.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Zcoverage-options=branch
LL| |//@ llvm-cov-flags: --show-branches=count
1 change: 0 additions & 1 deletion tests/coverage/branch/guard.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ compile-flags: -Zcoverage-options=branch
//@ llvm-cov-flags: --show-branches=count
2 changes: 1 addition & 1 deletion tests/coverage/branch/if-let.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
LL| |#![feature(coverage_attribute, let_chains)]
LL| |#![feature(let_chains)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Zcoverage-options=branch
LL| |//@ llvm-cov-flags: --show-branches=count
2 changes: 1 addition & 1 deletion tests/coverage/branch/if-let.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#![feature(coverage_attribute, let_chains)]
#![feature(let_chains)]
//@ edition: 2021
//@ compile-flags: -Zcoverage-options=branch
//@ llvm-cov-flags: --show-branches=count
16 changes: 8 additions & 8 deletions tests/coverage/branch/if.cov-map
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
Function name: if::branch_and
Raw bytes (54): 0x[01, 01, 03, 05, 09, 09, 0d, 05, 0d, 08, 01, 2b, 01, 01, 10, 05, 03, 08, 00, 09, 20, 09, 02, 00, 08, 00, 09, 09, 00, 0d, 00, 0e, 20, 0d, 06, 00, 0d, 00, 0e, 0d, 00, 0f, 02, 06, 0a, 02, 0c, 02, 06, 05, 03, 01, 00, 02]
Raw bytes (54): 0x[01, 01, 03, 05, 09, 09, 0d, 05, 0d, 08, 01, 2a, 01, 01, 10, 05, 03, 08, 00, 09, 20, 09, 02, 00, 08, 00, 09, 09, 00, 0d, 00, 0e, 20, 0d, 06, 00, 0d, 00, 0e, 0d, 00, 0f, 02, 06, 0a, 02, 0c, 02, 06, 05, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 3
- expression 0 operands: lhs = Counter(1), rhs = Counter(2)
- expression 1 operands: lhs = Counter(2), rhs = Counter(3)
- expression 2 operands: lhs = Counter(1), rhs = Counter(3)
Number of file 0 mappings: 8
- Code(Counter(0)) at (prev + 43, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 42, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 3, 8) to (start + 0, 9)
- Branch { true: Counter(2), false: Expression(0, Sub) } at (prev + 0, 8) to (start + 0, 9)
true = c2
@@ -23,7 +23,7 @@ Number of file 0 mappings: 8
Highest counter ID seen: c3

Function name: if::branch_not
Raw bytes (116): 0x[01, 01, 07, 05, 09, 05, 0d, 05, 0d, 05, 11, 05, 11, 05, 15, 05, 15, 12, 01, 0c, 01, 01, 10, 05, 03, 08, 00, 09, 20, 09, 02, 00, 08, 00, 09, 09, 01, 09, 00, 11, 02, 01, 05, 00, 06, 05, 01, 08, 00, 0a, 20, 0a, 0d, 00, 08, 00, 0a, 0a, 00, 0b, 02, 06, 0d, 02, 05, 00, 06, 05, 01, 08, 00, 0b, 20, 11, 12, 00, 08, 00, 0b, 11, 00, 0c, 02, 06, 12, 02, 05, 00, 06, 05, 01, 08, 00, 0c, 20, 1a, 15, 00, 08, 00, 0c, 1a, 00, 0d, 02, 06, 15, 02, 05, 00, 06, 05, 01, 01, 00, 02]
Raw bytes (116): 0x[01, 01, 07, 05, 09, 05, 0d, 05, 0d, 05, 11, 05, 11, 05, 15, 05, 15, 12, 01, 0b, 01, 01, 10, 05, 03, 08, 00, 09, 20, 09, 02, 00, 08, 00, 09, 09, 01, 09, 00, 11, 02, 01, 05, 00, 06, 05, 01, 08, 00, 0a, 20, 0a, 0d, 00, 08, 00, 0a, 0a, 00, 0b, 02, 06, 0d, 02, 05, 00, 06, 05, 01, 08, 00, 0b, 20, 11, 12, 00, 08, 00, 0b, 11, 00, 0c, 02, 06, 12, 02, 05, 00, 06, 05, 01, 08, 00, 0c, 20, 1a, 15, 00, 08, 00, 0c, 1a, 00, 0d, 02, 06, 15, 02, 05, 00, 06, 05, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 7
@@ -35,7 +35,7 @@ Number of expressions: 7
- expression 5 operands: lhs = Counter(1), rhs = Counter(5)
- expression 6 operands: lhs = Counter(1), rhs = Counter(5)
Number of file 0 mappings: 18
- Code(Counter(0)) at (prev + 12, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 11, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 3, 8) to (start + 0, 9)
- Branch { true: Counter(2), false: Expression(0, Sub) } at (prev + 0, 8) to (start + 0, 9)
true = c2
@@ -68,7 +68,7 @@ Number of file 0 mappings: 18
Highest counter ID seen: c5

Function name: if::branch_not_as
Raw bytes (90): 0x[01, 01, 05, 05, 09, 05, 0d, 05, 0d, 05, 11, 05, 11, 0e, 01, 1d, 01, 01, 10, 05, 03, 08, 00, 14, 20, 02, 09, 00, 08, 00, 14, 02, 00, 15, 02, 06, 09, 02, 05, 00, 06, 05, 01, 08, 00, 15, 20, 0d, 0a, 00, 08, 00, 15, 0d, 00, 16, 02, 06, 0a, 02, 05, 00, 06, 05, 01, 08, 00, 16, 20, 12, 11, 00, 08, 00, 16, 12, 00, 17, 02, 06, 11, 02, 05, 00, 06, 05, 01, 01, 00, 02]
Raw bytes (90): 0x[01, 01, 05, 05, 09, 05, 0d, 05, 0d, 05, 11, 05, 11, 0e, 01, 1c, 01, 01, 10, 05, 03, 08, 00, 14, 20, 02, 09, 00, 08, 00, 14, 02, 00, 15, 02, 06, 09, 02, 05, 00, 06, 05, 01, 08, 00, 15, 20, 0d, 0a, 00, 08, 00, 15, 0d, 00, 16, 02, 06, 0a, 02, 05, 00, 06, 05, 01, 08, 00, 16, 20, 12, 11, 00, 08, 00, 16, 12, 00, 17, 02, 06, 11, 02, 05, 00, 06, 05, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 5
@@ -78,7 +78,7 @@ Number of expressions: 5
- expression 3 operands: lhs = Counter(1), rhs = Counter(4)
- expression 4 operands: lhs = Counter(1), rhs = Counter(4)
Number of file 0 mappings: 14
- Code(Counter(0)) at (prev + 29, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 28, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 3, 8) to (start + 0, 20)
- Branch { true: Expression(0, Sub), false: Counter(2) } at (prev + 0, 8) to (start + 0, 20)
true = (c1 - c2)
@@ -104,7 +104,7 @@ Number of file 0 mappings: 14
Highest counter ID seen: c4

Function name: if::branch_or
Raw bytes (60): 0x[01, 01, 06, 05, 09, 05, 17, 09, 0d, 09, 0d, 05, 17, 09, 0d, 08, 01, 35, 01, 01, 10, 05, 03, 08, 00, 09, 20, 09, 02, 00, 08, 00, 09, 02, 00, 0d, 00, 0e, 20, 0d, 12, 00, 0d, 00, 0e, 17, 00, 0f, 02, 06, 12, 02, 0c, 02, 06, 05, 03, 01, 00, 02]
Raw bytes (60): 0x[01, 01, 06, 05, 09, 05, 17, 09, 0d, 09, 0d, 05, 17, 09, 0d, 08, 01, 34, 01, 01, 10, 05, 03, 08, 00, 09, 20, 09, 02, 00, 08, 00, 09, 02, 00, 0d, 00, 0e, 20, 0d, 12, 00, 0d, 00, 0e, 17, 00, 0f, 02, 06, 12, 02, 0c, 02, 06, 05, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 6
@@ -115,7 +115,7 @@ Number of expressions: 6
- expression 4 operands: lhs = Counter(1), rhs = Expression(5, Add)
- expression 5 operands: lhs = Counter(2), rhs = Counter(3)
Number of file 0 mappings: 8
- Code(Counter(0)) at (prev + 53, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 52, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 3, 8) to (start + 0, 9)
- Branch { true: Counter(2), false: Expression(0, Sub) } at (prev + 0, 8) to (start + 0, 9)
true = c2
1 change: 0 additions & 1 deletion tests/coverage/branch/if.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Zcoverage-options=branch
LL| |//@ llvm-cov-flags: --show-branches=count
1 change: 0 additions & 1 deletion tests/coverage/branch/if.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ compile-flags: -Zcoverage-options=branch
//@ llvm-cov-flags: --show-branches=count
16 changes: 8 additions & 8 deletions tests/coverage/branch/lazy-boolean.cov-map
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
Function name: lazy_boolean::branch_and
Raw bytes (38): 0x[01, 01, 01, 05, 09, 06, 01, 13, 01, 01, 10, 05, 04, 09, 00, 0a, 05, 00, 0d, 00, 0e, 20, 09, 02, 00, 0d, 00, 0e, 09, 00, 12, 00, 13, 05, 01, 05, 01, 02]
Raw bytes (38): 0x[01, 01, 01, 05, 09, 06, 01, 12, 01, 01, 10, 05, 04, 09, 00, 0a, 05, 00, 0d, 00, 0e, 20, 09, 02, 00, 0d, 00, 0e, 09, 00, 12, 00, 13, 05, 01, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 6
- Code(Counter(0)) at (prev + 19, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 18, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 4, 9) to (start + 0, 10)
- Code(Counter(1)) at (prev + 0, 13) to (start + 0, 14)
- Branch { true: Counter(2), false: Expression(0, Sub) } at (prev + 0, 13) to (start + 0, 14)
@@ -16,13 +16,13 @@ Number of file 0 mappings: 6
Highest counter ID seen: c2

Function name: lazy_boolean::branch_or
Raw bytes (38): 0x[01, 01, 01, 05, 09, 06, 01, 1b, 01, 01, 10, 05, 04, 09, 00, 0a, 05, 00, 0d, 00, 0e, 20, 09, 02, 00, 0d, 00, 0e, 02, 00, 12, 00, 13, 05, 01, 05, 01, 02]
Raw bytes (38): 0x[01, 01, 01, 05, 09, 06, 01, 1a, 01, 01, 10, 05, 04, 09, 00, 0a, 05, 00, 0d, 00, 0e, 20, 09, 02, 00, 0d, 00, 0e, 02, 00, 12, 00, 13, 05, 01, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 6
- Code(Counter(0)) at (prev + 27, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 26, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 4, 9) to (start + 0, 10)
- Code(Counter(1)) at (prev + 0, 13) to (start + 0, 14)
- Branch { true: Counter(2), false: Expression(0, Sub) } at (prev + 0, 13) to (start + 0, 14)
@@ -34,7 +34,7 @@ Number of file 0 mappings: 6
Highest counter ID seen: c2

Function name: lazy_boolean::chain
Raw bytes (141): 0x[01, 01, 0f, 05, 09, 09, 0d, 0d, 11, 05, 15, 05, 15, 05, 3b, 15, 19, 05, 3b, 15, 19, 05, 37, 3b, 1d, 15, 19, 05, 37, 3b, 1d, 15, 19, 13, 01, 24, 01, 01, 10, 05, 04, 09, 00, 0a, 05, 00, 0d, 00, 12, 20, 09, 02, 00, 0d, 00, 12, 09, 00, 16, 00, 1b, 20, 0d, 06, 00, 16, 00, 1b, 0d, 00, 1f, 00, 24, 20, 11, 0a, 00, 1f, 00, 24, 11, 00, 28, 00, 2d, 05, 01, 05, 00, 11, 05, 03, 09, 00, 0a, 05, 00, 0d, 00, 12, 20, 15, 12, 00, 0d, 00, 12, 12, 00, 16, 00, 1b, 20, 19, 1e, 00, 16, 00, 1b, 1e, 00, 1f, 00, 24, 20, 1d, 32, 00, 1f, 00, 24, 32, 00, 28, 00, 2d, 05, 01, 05, 01, 02]
Raw bytes (141): 0x[01, 01, 0f, 05, 09, 09, 0d, 0d, 11, 05, 15, 05, 15, 05, 3b, 15, 19, 05, 3b, 15, 19, 05, 37, 3b, 1d, 15, 19, 05, 37, 3b, 1d, 15, 19, 13, 01, 23, 01, 01, 10, 05, 04, 09, 00, 0a, 05, 00, 0d, 00, 12, 20, 09, 02, 00, 0d, 00, 12, 09, 00, 16, 00, 1b, 20, 0d, 06, 00, 16, 00, 1b, 0d, 00, 1f, 00, 24, 20, 11, 0a, 00, 1f, 00, 24, 11, 00, 28, 00, 2d, 05, 01, 05, 00, 11, 05, 03, 09, 00, 0a, 05, 00, 0d, 00, 12, 20, 15, 12, 00, 0d, 00, 12, 12, 00, 16, 00, 1b, 20, 19, 1e, 00, 16, 00, 1b, 1e, 00, 1f, 00, 24, 20, 1d, 32, 00, 1f, 00, 24, 32, 00, 28, 00, 2d, 05, 01, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 15
@@ -54,7 +54,7 @@ Number of expressions: 15
- expression 13 operands: lhs = Expression(14, Add), rhs = Counter(7)
- expression 14 operands: lhs = Counter(5), rhs = Counter(6)
Number of file 0 mappings: 19
- Code(Counter(0)) at (prev + 36, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 35, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 4, 9) to (start + 0, 10)
- Code(Counter(1)) at (prev + 0, 13) to (start + 0, 18)
- Branch { true: Counter(2), false: Expression(0, Sub) } at (prev + 0, 13) to (start + 0, 18)
@@ -91,7 +91,7 @@ Number of file 0 mappings: 19
Highest counter ID seen: c7

Function name: lazy_boolean::nested_mixed
Raw bytes (137): 0x[01, 01, 0d, 05, 09, 05, 1f, 09, 0d, 09, 0d, 1f, 11, 09, 0d, 1f, 11, 09, 0d, 05, 15, 15, 19, 05, 19, 05, 33, 19, 1d, 13, 01, 31, 01, 01, 10, 05, 04, 09, 00, 0a, 05, 00, 0e, 00, 13, 20, 09, 02, 00, 0e, 00, 13, 02, 00, 17, 00, 1d, 20, 0d, 06, 00, 17, 00, 1d, 1f, 00, 23, 00, 28, 20, 11, 1a, 00, 23, 00, 28, 1a, 00, 2c, 00, 33, 05, 01, 05, 00, 11, 05, 03, 09, 00, 0a, 05, 00, 0e, 00, 13, 20, 15, 22, 00, 0e, 00, 13, 15, 00, 17, 00, 1c, 20, 19, 26, 00, 17, 00, 1c, 2a, 00, 22, 00, 28, 20, 1d, 2e, 00, 22, 00, 28, 1d, 00, 2c, 00, 33, 05, 01, 05, 01, 02]
Raw bytes (137): 0x[01, 01, 0d, 05, 09, 05, 1f, 09, 0d, 09, 0d, 1f, 11, 09, 0d, 1f, 11, 09, 0d, 05, 15, 15, 19, 05, 19, 05, 33, 19, 1d, 13, 01, 30, 01, 01, 10, 05, 04, 09, 00, 0a, 05, 00, 0e, 00, 13, 20, 09, 02, 00, 0e, 00, 13, 02, 00, 17, 00, 1d, 20, 0d, 06, 00, 17, 00, 1d, 1f, 00, 23, 00, 28, 20, 11, 1a, 00, 23, 00, 28, 1a, 00, 2c, 00, 33, 05, 01, 05, 00, 11, 05, 03, 09, 00, 0a, 05, 00, 0e, 00, 13, 20, 15, 22, 00, 0e, 00, 13, 15, 00, 17, 00, 1c, 20, 19, 26, 00, 17, 00, 1c, 2a, 00, 22, 00, 28, 20, 1d, 2e, 00, 22, 00, 28, 1d, 00, 2c, 00, 33, 05, 01, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 13
@@ -109,7 +109,7 @@ Number of expressions: 13
- expression 11 operands: lhs = Counter(1), rhs = Expression(12, Add)
- expression 12 operands: lhs = Counter(6), rhs = Counter(7)
Number of file 0 mappings: 19
- Code(Counter(0)) at (prev + 49, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 48, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 4, 9) to (start + 0, 10)
- Code(Counter(1)) at (prev + 0, 14) to (start + 0, 19)
- Branch { true: Counter(2), false: Expression(0, Sub) } at (prev + 0, 14) to (start + 0, 19)
1 change: 0 additions & 1 deletion tests/coverage/branch/lazy-boolean.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Zcoverage-options=branch
LL| |//@ llvm-cov-flags: --show-branches=count
1 change: 0 additions & 1 deletion tests/coverage/branch/lazy-boolean.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ compile-flags: -Zcoverage-options=branch
//@ llvm-cov-flags: --show-branches=count
4 changes: 2 additions & 2 deletions tests/coverage/branch/let-else.cov-map
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
Function name: let_else::let_else
Raw bytes (43): 0x[01, 01, 01, 05, 09, 07, 01, 0c, 01, 01, 10, 20, 02, 09, 03, 09, 00, 10, 02, 00, 0e, 00, 0f, 05, 00, 13, 00, 18, 09, 01, 09, 01, 0f, 02, 04, 05, 00, 0b, 05, 01, 01, 00, 02]
Raw bytes (43): 0x[01, 01, 01, 05, 09, 07, 01, 0b, 01, 01, 10, 20, 02, 09, 03, 09, 00, 10, 02, 00, 0e, 00, 0f, 05, 00, 13, 00, 18, 09, 01, 09, 01, 0f, 02, 04, 05, 00, 0b, 05, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 7
- Code(Counter(0)) at (prev + 12, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 11, 1) to (start + 1, 16)
- Branch { true: Expression(0, Sub), false: Counter(2) } at (prev + 3, 9) to (start + 0, 16)
true = (c1 - c2)
false = c2
1 change: 0 additions & 1 deletion tests/coverage/branch/let-else.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Zcoverage-options=branch
LL| |//@ llvm-cov-flags: --show-branches=count
1 change: 0 additions & 1 deletion tests/coverage/branch/let-else.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ compile-flags: -Zcoverage-options=branch
//@ llvm-cov-flags: --show-branches=count
12 changes: 6 additions & 6 deletions tests/coverage/branch/match-arms.cov-map
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Function name: match_arms::guards
Raw bytes (98): 0x[01, 01, 0d, 11, 19, 27, 19, 2b, 00, 2f, 11, 33, 0d, 05, 09, 1f, 25, 23, 21, 27, 1d, 2b, 00, 2f, 11, 33, 0d, 05, 09, 0c, 01, 30, 01, 01, 10, 11, 03, 0b, 00, 10, 1d, 01, 11, 00, 29, 20, 1d, 05, 00, 17, 00, 1b, 21, 01, 11, 00, 29, 20, 21, 09, 00, 17, 00, 1b, 25, 01, 11, 00, 29, 20, 25, 0d, 00, 17, 00, 1b, 19, 01, 11, 00, 29, 20, 19, 02, 00, 17, 00, 1b, 06, 01, 0e, 00, 18, 1b, 03, 05, 01, 02]
Raw bytes (98): 0x[01, 01, 0d, 11, 19, 27, 19, 2b, 00, 2f, 11, 33, 0d, 05, 09, 1f, 25, 23, 21, 27, 1d, 2b, 00, 2f, 11, 33, 0d, 05, 09, 0c, 01, 2f, 01, 01, 10, 11, 03, 0b, 00, 10, 1d, 01, 11, 00, 29, 20, 1d, 05, 00, 17, 00, 1b, 21, 01, 11, 00, 29, 20, 21, 09, 00, 17, 00, 1b, 25, 01, 11, 00, 29, 20, 25, 0d, 00, 17, 00, 1b, 19, 01, 11, 00, 29, 20, 19, 02, 00, 17, 00, 1b, 06, 01, 0e, 00, 18, 1b, 03, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 13
@@ -17,7 +17,7 @@ Number of expressions: 13
- expression 11 operands: lhs = Expression(12, Add), rhs = Counter(3)
- expression 12 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 12
- Code(Counter(0)) at (prev + 48, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 47, 1) to (start + 1, 16)
- Code(Counter(4)) at (prev + 3, 11) to (start + 0, 16)
- Code(Counter(7)) at (prev + 1, 17) to (start + 0, 41)
- Branch { true: Counter(7), false: Counter(1) } at (prev + 0, 23) to (start + 0, 27)
@@ -42,15 +42,15 @@ Number of file 0 mappings: 12
Highest counter ID seen: c9

Function name: match_arms::match_arms
Raw bytes (45): 0x[01, 01, 03, 05, 07, 0b, 11, 09, 0d, 07, 01, 18, 01, 01, 10, 05, 03, 0b, 00, 10, 09, 01, 11, 00, 21, 0d, 01, 11, 00, 21, 11, 01, 11, 00, 21, 02, 01, 11, 00, 21, 05, 03, 05, 01, 02]
Raw bytes (45): 0x[01, 01, 03, 05, 07, 0b, 11, 09, 0d, 07, 01, 17, 01, 01, 10, 05, 03, 0b, 00, 10, 09, 01, 11, 00, 21, 0d, 01, 11, 00, 21, 11, 01, 11, 00, 21, 02, 01, 11, 00, 21, 05, 03, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 3
- expression 0 operands: lhs = Counter(1), rhs = Expression(1, Add)
- expression 1 operands: lhs = Expression(2, Add), rhs = Counter(4)
- expression 2 operands: lhs = Counter(2), rhs = Counter(3)
Number of file 0 mappings: 7
- Code(Counter(0)) at (prev + 24, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 23, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 3, 11) to (start + 0, 16)
- Code(Counter(2)) at (prev + 1, 17) to (start + 0, 33)
- Code(Counter(3)) at (prev + 1, 17) to (start + 0, 33)
@@ -61,7 +61,7 @@ Number of file 0 mappings: 7
Highest counter ID seen: c4

Function name: match_arms::or_patterns
Raw bytes (57): 0x[01, 01, 04, 09, 0d, 05, 0b, 03, 11, 05, 03, 09, 01, 25, 01, 01, 10, 05, 03, 0b, 00, 10, 09, 01, 11, 00, 12, 0d, 00, 1e, 00, 1f, 03, 00, 24, 00, 2e, 11, 01, 11, 00, 12, 06, 00, 1e, 00, 1f, 0e, 00, 24, 00, 2e, 05, 03, 05, 01, 02]
Raw bytes (57): 0x[01, 01, 04, 09, 0d, 05, 0b, 03, 11, 05, 03, 09, 01, 24, 01, 01, 10, 05, 03, 0b, 00, 10, 09, 01, 11, 00, 12, 0d, 00, 1e, 00, 1f, 03, 00, 24, 00, 2e, 11, 01, 11, 00, 12, 06, 00, 1e, 00, 1f, 0e, 00, 24, 00, 2e, 05, 03, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 4
@@ -70,7 +70,7 @@ Number of expressions: 4
- expression 2 operands: lhs = Expression(0, Add), rhs = Counter(4)
- expression 3 operands: lhs = Counter(1), rhs = Expression(0, Add)
Number of file 0 mappings: 9
- Code(Counter(0)) at (prev + 37, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 36, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 3, 11) to (start + 0, 16)
- Code(Counter(2)) at (prev + 1, 17) to (start + 0, 18)
- Code(Counter(3)) at (prev + 0, 30) to (start + 0, 31)
1 change: 0 additions & 1 deletion tests/coverage/branch/match-arms.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Zcoverage-options=branch
LL| |//@ llvm-cov-flags: --show-branches=count
1 change: 0 additions & 1 deletion tests/coverage/branch/match-arms.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ compile-flags: -Zcoverage-options=branch
//@ llvm-cov-flags: --show-branches=count
8 changes: 4 additions & 4 deletions tests/coverage/branch/match-trivial.cov-map
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
Function name: match_trivial::_uninhabited (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 16, 01, 01, 10]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 15, 01, 01, 10]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 22, 1) to (start + 1, 16)
- Code(Zero) at (prev + 21, 1) to (start + 1, 16)
Highest counter ID seen: (none)

Function name: match_trivial::trivial
Raw bytes (14): 0x[01, 01, 00, 02, 01, 1e, 01, 01, 10, 05, 03, 0b, 05, 02]
Raw bytes (14): 0x[01, 01, 00, 02, 01, 1d, 01, 01, 10, 05, 03, 0b, 05, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 30, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 29, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 3, 11) to (start + 5, 2)
Highest counter ID seen: c1

1 change: 0 additions & 1 deletion tests/coverage/branch/match-trivial.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Zcoverage-options=branch
LL| |//@ llvm-cov-flags: --show-branches=count
1 change: 0 additions & 1 deletion tests/coverage/branch/match-trivial.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ compile-flags: -Zcoverage-options=branch
//@ llvm-cov-flags: --show-branches=count
16 changes: 8 additions & 8 deletions tests/coverage/branch/no-mir-spans.cov-map
Original file line number Diff line number Diff line change
@@ -1,35 +1,35 @@
Function name: no_mir_spans::while_cond
Raw bytes (16): 0x[01, 01, 00, 02, 01, 10, 01, 00, 11, 20, 05, 09, 04, 0b, 00, 10]
Raw bytes (16): 0x[01, 01, 00, 02, 01, 0f, 01, 00, 11, 20, 05, 09, 04, 0b, 00, 10]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 16, 1) to (start + 0, 17)
- Code(Counter(0)) at (prev + 15, 1) to (start + 0, 17)
- Branch { true: Counter(1), false: Counter(2) } at (prev + 4, 11) to (start + 0, 16)
true = c1
false = c2
Highest counter ID seen: c2

Function name: no_mir_spans::while_cond_not
Raw bytes (16): 0x[01, 01, 00, 02, 01, 19, 01, 00, 15, 20, 09, 05, 04, 0b, 00, 14]
Raw bytes (16): 0x[01, 01, 00, 02, 01, 18, 01, 00, 15, 20, 09, 05, 04, 0b, 00, 14]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 25, 1) to (start + 0, 21)
- Code(Counter(0)) at (prev + 24, 1) to (start + 0, 21)
- Branch { true: Counter(2), false: Counter(1) } at (prev + 4, 11) to (start + 0, 20)
true = c2
false = c1
Highest counter ID seen: c2

Function name: no_mir_spans::while_op_and
Raw bytes (25): 0x[01, 01, 01, 05, 09, 03, 01, 22, 01, 00, 13, 20, 05, 0d, 05, 0b, 00, 10, 20, 02, 09, 00, 14, 00, 19]
Raw bytes (25): 0x[01, 01, 01, 05, 09, 03, 01, 21, 01, 00, 13, 20, 05, 0d, 05, 0b, 00, 10, 20, 02, 09, 00, 14, 00, 19]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 3
- Code(Counter(0)) at (prev + 34, 1) to (start + 0, 19)
- Code(Counter(0)) at (prev + 33, 1) to (start + 0, 19)
- Branch { true: Counter(1), false: Counter(3) } at (prev + 5, 11) to (start + 0, 16)
true = c1
false = c3
@@ -39,13 +39,13 @@ Number of file 0 mappings: 3
Highest counter ID seen: c3

Function name: no_mir_spans::while_op_or
Raw bytes (25): 0x[01, 01, 01, 09, 0d, 03, 01, 2d, 01, 00, 12, 20, 05, 09, 05, 0b, 00, 10, 20, 0d, 02, 00, 14, 00, 19]
Raw bytes (25): 0x[01, 01, 01, 09, 0d, 03, 01, 2c, 01, 00, 12, 20, 05, 09, 05, 0b, 00, 10, 20, 0d, 02, 00, 14, 00, 19]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(2), rhs = Counter(3)
Number of file 0 mappings: 3
- Code(Counter(0)) at (prev + 45, 1) to (start + 0, 18)
- Code(Counter(0)) at (prev + 44, 1) to (start + 0, 18)
- Branch { true: Counter(1), false: Counter(2) } at (prev + 5, 11) to (start + 0, 16)
true = c1
false = c2
1 change: 0 additions & 1 deletion tests/coverage/branch/no-mir-spans.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Zcoverage-options=branch,no-mir-spans
LL| |//@ llvm-cov-flags: --show-branches=count
1 change: 0 additions & 1 deletion tests/coverage/branch/no-mir-spans.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ compile-flags: -Zcoverage-options=branch,no-mir-spans
//@ llvm-cov-flags: --show-branches=count
16 changes: 8 additions & 8 deletions tests/coverage/branch/while.cov-map
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
Function name: while::while_cond
Raw bytes (38): 0x[01, 01, 01, 05, 09, 06, 01, 0c, 01, 01, 10, 05, 03, 09, 00, 12, 03, 01, 0b, 00, 10, 20, 09, 05, 00, 0b, 00, 10, 09, 00, 11, 02, 06, 05, 03, 01, 00, 02]
Raw bytes (38): 0x[01, 01, 01, 05, 09, 06, 01, 0b, 01, 01, 10, 05, 03, 09, 00, 12, 03, 01, 0b, 00, 10, 20, 09, 05, 00, 0b, 00, 10, 09, 00, 11, 02, 06, 05, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 6
- Code(Counter(0)) at (prev + 12, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 11, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 3, 9) to (start + 0, 18)
- Code(Expression(0, Add)) at (prev + 1, 11) to (start + 0, 16)
= (c1 + c2)
@@ -17,13 +17,13 @@ Number of file 0 mappings: 6
Highest counter ID seen: c2

Function name: while::while_cond_not
Raw bytes (38): 0x[01, 01, 01, 05, 09, 06, 01, 15, 01, 01, 10, 05, 03, 09, 00, 12, 03, 01, 0b, 00, 14, 20, 09, 05, 00, 0b, 00, 14, 09, 00, 15, 02, 06, 05, 03, 01, 00, 02]
Raw bytes (38): 0x[01, 01, 01, 05, 09, 06, 01, 14, 01, 01, 10, 05, 03, 09, 00, 12, 03, 01, 0b, 00, 14, 20, 09, 05, 00, 0b, 00, 14, 09, 00, 15, 02, 06, 05, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 6
- Code(Counter(0)) at (prev + 21, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 20, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 3, 9) to (start + 0, 18)
- Code(Expression(0, Add)) at (prev + 1, 11) to (start + 0, 20)
= (c1 + c2)
@@ -35,7 +35,7 @@ Number of file 0 mappings: 6
Highest counter ID seen: c2

Function name: while::while_op_and
Raw bytes (56): 0x[01, 01, 04, 05, 09, 03, 0d, 03, 0d, 05, 0d, 08, 01, 1e, 01, 01, 10, 05, 03, 09, 01, 12, 03, 02, 0b, 00, 10, 20, 0a, 0d, 00, 0b, 00, 10, 0a, 00, 14, 00, 19, 20, 09, 0e, 00, 14, 00, 19, 09, 00, 1a, 03, 06, 05, 04, 01, 00, 02]
Raw bytes (56): 0x[01, 01, 04, 05, 09, 03, 0d, 03, 0d, 05, 0d, 08, 01, 1d, 01, 01, 10, 05, 03, 09, 01, 12, 03, 02, 0b, 00, 10, 20, 0a, 0d, 00, 0b, 00, 10, 0a, 00, 14, 00, 19, 20, 09, 0e, 00, 14, 00, 19, 09, 00, 1a, 03, 06, 05, 04, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 4
@@ -44,7 +44,7 @@ Number of expressions: 4
- expression 2 operands: lhs = Expression(0, Add), rhs = Counter(3)
- expression 3 operands: lhs = Counter(1), rhs = Counter(3)
Number of file 0 mappings: 8
- Code(Counter(0)) at (prev + 30, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 29, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 3, 9) to (start + 1, 18)
- Code(Expression(0, Add)) at (prev + 2, 11) to (start + 0, 16)
= (c1 + c2)
@@ -61,7 +61,7 @@ Number of file 0 mappings: 8
Highest counter ID seen: c3

Function name: while::while_op_or
Raw bytes (58): 0x[01, 01, 05, 07, 0d, 05, 09, 05, 0d, 05, 0d, 09, 0d, 08, 01, 29, 01, 01, 10, 05, 03, 09, 01, 12, 03, 02, 0b, 00, 10, 20, 09, 0f, 00, 0b, 00, 10, 0f, 00, 14, 00, 19, 20, 0d, 05, 00, 14, 00, 19, 13, 00, 1a, 03, 06, 05, 04, 01, 00, 02]
Raw bytes (58): 0x[01, 01, 05, 07, 0d, 05, 09, 05, 0d, 05, 0d, 09, 0d, 08, 01, 28, 01, 01, 10, 05, 03, 09, 01, 12, 03, 02, 0b, 00, 10, 20, 09, 0f, 00, 0b, 00, 10, 0f, 00, 14, 00, 19, 20, 0d, 05, 00, 14, 00, 19, 13, 00, 1a, 03, 06, 05, 04, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 5
@@ -71,7 +71,7 @@ Number of expressions: 5
- expression 3 operands: lhs = Counter(1), rhs = Counter(3)
- expression 4 operands: lhs = Counter(2), rhs = Counter(3)
Number of file 0 mappings: 8
- Code(Counter(0)) at (prev + 41, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 40, 1) to (start + 1, 16)
- Code(Counter(1)) at (prev + 3, 9) to (start + 1, 18)
- Code(Expression(0, Add)) at (prev + 2, 11) to (start + 0, 16)
= ((c1 + c2) + c3)
1 change: 0 additions & 1 deletion tests/coverage/branch/while.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Zcoverage-options=branch
LL| |//@ llvm-cov-flags: --show-branches=count
1 change: 0 additions & 1 deletion tests/coverage/branch/while.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ compile-flags: -Zcoverage-options=branch
//@ llvm-cov-flags: --show-branches=count
16 changes: 8 additions & 8 deletions tests/coverage/closure_macro_async.cov-map
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
Function name: closure_macro_async::load_configuration_files
Raw bytes (9): 0x[01, 01, 00, 01, 01, 21, 01, 02, 02]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 20, 01, 02, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 33, 1) to (start + 2, 2)
- Code(Counter(0)) at (prev + 32, 1) to (start + 2, 2)
Highest counter ID seen: c0

Function name: closure_macro_async::test
Raw bytes (9): 0x[01, 01, 00, 01, 01, 25, 01, 00, 2b]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 24, 01, 00, 2b]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 37, 1) to (start + 0, 43)
- Code(Counter(0)) at (prev + 36, 1) to (start + 0, 43)
Highest counter ID seen: c0

Function name: closure_macro_async::test::{closure#0}
Raw bytes (36): 0x[01, 01, 01, 01, 05, 06, 01, 25, 2b, 01, 21, 02, 02, 09, 00, 0f, 01, 00, 12, 00, 54, 05, 00, 54, 00, 55, 02, 02, 09, 02, 0b, 01, 03, 01, 00, 02]
Raw bytes (36): 0x[01, 01, 01, 01, 05, 06, 01, 24, 2b, 01, 21, 02, 02, 09, 00, 0f, 01, 00, 12, 00, 54, 05, 00, 54, 00, 55, 02, 02, 09, 02, 0b, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
Number of file 0 mappings: 6
- Code(Counter(0)) at (prev + 37, 43) to (start + 1, 33)
- Code(Counter(0)) at (prev + 36, 43) to (start + 1, 33)
- Code(Expression(0, Sub)) at (prev + 2, 9) to (start + 0, 15)
= (c0 - c1)
- Code(Counter(0)) at (prev + 0, 18) to (start + 0, 84)
@@ -34,15 +34,15 @@ Number of file 0 mappings: 6
Highest counter ID seen: c1

Function name: closure_macro_async::test::{closure#0}::{closure#0}
Raw bytes (35): 0x[01, 01, 03, 01, 05, 01, 0b, 05, 09, 05, 01, 14, 1c, 03, 21, 05, 04, 11, 01, 27, 02, 03, 11, 00, 16, 06, 00, 17, 00, 1e, 01, 02, 09, 00, 0a]
Raw bytes (35): 0x[01, 01, 03, 01, 05, 01, 0b, 05, 09, 05, 01, 13, 1c, 03, 21, 05, 04, 11, 01, 27, 02, 03, 11, 00, 16, 06, 00, 17, 00, 1e, 01, 02, 09, 00, 0a]
Number of files: 1
- file 0 => global file 1
Number of expressions: 3
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(0), rhs = Expression(2, Add)
- expression 2 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 5
- Code(Counter(0)) at (prev + 20, 28) to (start + 3, 33)
- Code(Counter(0)) at (prev + 19, 28) to (start + 3, 33)
- Code(Counter(1)) at (prev + 4, 17) to (start + 1, 39)
- Code(Expression(0, Sub)) at (prev + 3, 17) to (start + 0, 22)
= (c0 - c1)
1 change: 0 additions & 1 deletion tests/coverage/closure_macro_async.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2018
LL| |
LL| |//@ aux-build: executor.rs
1 change: 0 additions & 1 deletion tests/coverage/closure_macro_async.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2018

//@ aux-build: executor.rs
16 changes: 8 additions & 8 deletions tests/coverage/closure_unit_return.cov-map
Original file line number Diff line number Diff line change
@@ -1,38 +1,38 @@
Function name: closure_unit_return::explicit_unit
Raw bytes (14): 0x[01, 01, 00, 02, 01, 07, 01, 01, 10, 01, 05, 05, 02, 02]
Raw bytes (14): 0x[01, 01, 00, 02, 01, 06, 01, 01, 10, 01, 05, 05, 02, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 7, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 6, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 5, 5) to (start + 2, 2)
Highest counter ID seen: c0

Function name: closure_unit_return::explicit_unit::{closure#0} (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 08, 16, 02, 06]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 07, 16, 02, 06]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 8, 22) to (start + 2, 6)
- Code(Zero) at (prev + 7, 22) to (start + 2, 6)
Highest counter ID seen: (none)

Function name: closure_unit_return::implicit_unit
Raw bytes (14): 0x[01, 01, 00, 02, 01, 10, 01, 01, 10, 01, 05, 05, 02, 02]
Raw bytes (14): 0x[01, 01, 00, 02, 01, 0f, 01, 01, 10, 01, 05, 05, 02, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 2
- Code(Counter(0)) at (prev + 16, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 15, 1) to (start + 1, 16)
- Code(Counter(0)) at (prev + 5, 5) to (start + 2, 2)
Highest counter ID seen: c0

Function name: closure_unit_return::implicit_unit::{closure#0} (unused)
Raw bytes (9): 0x[01, 01, 00, 01, 00, 11, 16, 02, 06]
Raw bytes (9): 0x[01, 01, 00, 01, 00, 10, 16, 02, 06]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Zero) at (prev + 17, 22) to (start + 2, 6)
- Code(Zero) at (prev + 16, 22) to (start + 2, 6)
Highest counter ID seen: (none)

1 change: 0 additions & 1 deletion tests/coverage/closure_unit_return.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |
LL| |// Regression test for an inconsistency between functions that return the value
1 change: 0 additions & 1 deletion tests/coverage/closure_unit_return.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021

// Regression test for an inconsistency between functions that return the value
28 changes: 14 additions & 14 deletions tests/coverage/condition/conditions.cov-map
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Function name: conditions::assign_3_and_or
Raw bytes (65): 0x[01, 01, 05, 01, 05, 05, 09, 01, 09, 01, 13, 09, 0d, 09, 01, 1c, 01, 00, 2f, 01, 01, 09, 00, 0a, 01, 00, 0d, 00, 0e, 20, 05, 02, 00, 0d, 00, 0e, 05, 00, 12, 00, 13, 20, 09, 06, 00, 12, 00, 13, 0a, 00, 17, 00, 18, 20, 0d, 0e, 00, 17, 00, 18, 01, 01, 05, 01, 02]
Raw bytes (65): 0x[01, 01, 05, 01, 05, 05, 09, 01, 09, 01, 13, 09, 0d, 09, 01, 1b, 01, 00, 2f, 01, 01, 09, 00, 0a, 01, 00, 0d, 00, 0e, 20, 05, 02, 00, 0d, 00, 0e, 05, 00, 12, 00, 13, 20, 09, 06, 00, 12, 00, 13, 0a, 00, 17, 00, 18, 20, 0d, 0e, 00, 17, 00, 18, 01, 01, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 5
@@ -9,7 +9,7 @@ Number of expressions: 5
- expression 3 operands: lhs = Counter(0), rhs = Expression(4, Add)
- expression 4 operands: lhs = Counter(2), rhs = Counter(3)
Number of file 0 mappings: 9
- Code(Counter(0)) at (prev + 28, 1) to (start + 0, 47)
- Code(Counter(0)) at (prev + 27, 1) to (start + 0, 47)
- Code(Counter(0)) at (prev + 1, 9) to (start + 0, 10)
- Code(Counter(0)) at (prev + 0, 13) to (start + 0, 14)
- Branch { true: Counter(1), false: Expression(0, Sub) } at (prev + 0, 13) to (start + 0, 14)
@@ -28,7 +28,7 @@ Number of file 0 mappings: 9
Highest counter ID seen: c3

Function name: conditions::assign_3_or_and
Raw bytes (63): 0x[01, 01, 04, 01, 05, 01, 0b, 05, 09, 09, 0d, 09, 01, 17, 01, 00, 2f, 01, 01, 09, 00, 0a, 01, 00, 0d, 00, 0e, 20, 05, 02, 00, 0d, 00, 0e, 02, 00, 12, 00, 13, 20, 09, 06, 00, 12, 00, 13, 09, 00, 17, 00, 18, 20, 0d, 0e, 00, 17, 00, 18, 01, 01, 05, 01, 02]
Raw bytes (63): 0x[01, 01, 04, 01, 05, 01, 0b, 05, 09, 09, 0d, 09, 01, 16, 01, 00, 2f, 01, 01, 09, 00, 0a, 01, 00, 0d, 00, 0e, 20, 05, 02, 00, 0d, 00, 0e, 02, 00, 12, 00, 13, 20, 09, 06, 00, 12, 00, 13, 09, 00, 17, 00, 18, 20, 0d, 0e, 00, 17, 00, 18, 01, 01, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 4
@@ -37,7 +37,7 @@ Number of expressions: 4
- expression 2 operands: lhs = Counter(1), rhs = Counter(2)
- expression 3 operands: lhs = Counter(2), rhs = Counter(3)
Number of file 0 mappings: 9
- Code(Counter(0)) at (prev + 23, 1) to (start + 0, 47)
- Code(Counter(0)) at (prev + 22, 1) to (start + 0, 47)
- Code(Counter(0)) at (prev + 1, 9) to (start + 0, 10)
- Code(Counter(0)) at (prev + 0, 13) to (start + 0, 14)
- Branch { true: Counter(1), false: Expression(0, Sub) } at (prev + 0, 13) to (start + 0, 14)
@@ -56,14 +56,14 @@ Number of file 0 mappings: 9
Highest counter ID seen: c3

Function name: conditions::assign_and
Raw bytes (47): 0x[01, 01, 02, 01, 05, 05, 09, 07, 01, 0d, 01, 00, 21, 01, 01, 09, 00, 0a, 01, 00, 0d, 00, 0e, 20, 05, 02, 00, 0d, 00, 0e, 05, 00, 12, 00, 13, 20, 09, 06, 00, 12, 00, 13, 01, 01, 05, 01, 02]
Raw bytes (47): 0x[01, 01, 02, 01, 05, 05, 09, 07, 01, 0c, 01, 00, 21, 01, 01, 09, 00, 0a, 01, 00, 0d, 00, 0e, 20, 05, 02, 00, 0d, 00, 0e, 05, 00, 12, 00, 13, 20, 09, 06, 00, 12, 00, 13, 01, 01, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 2
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 7
- Code(Counter(0)) at (prev + 13, 1) to (start + 0, 33)
- Code(Counter(0)) at (prev + 12, 1) to (start + 0, 33)
- Code(Counter(0)) at (prev + 1, 9) to (start + 0, 10)
- Code(Counter(0)) at (prev + 0, 13) to (start + 0, 14)
- Branch { true: Counter(1), false: Expression(0, Sub) } at (prev + 0, 13) to (start + 0, 14)
@@ -77,15 +77,15 @@ Number of file 0 mappings: 7
Highest counter ID seen: c2

Function name: conditions::assign_or
Raw bytes (49): 0x[01, 01, 03, 01, 05, 01, 0b, 05, 09, 07, 01, 12, 01, 00, 20, 01, 01, 09, 00, 0a, 01, 00, 0d, 00, 0e, 20, 05, 02, 00, 0d, 00, 0e, 02, 00, 12, 00, 13, 20, 09, 06, 00, 12, 00, 13, 01, 01, 05, 01, 02]
Raw bytes (49): 0x[01, 01, 03, 01, 05, 01, 0b, 05, 09, 07, 01, 11, 01, 00, 20, 01, 01, 09, 00, 0a, 01, 00, 0d, 00, 0e, 20, 05, 02, 00, 0d, 00, 0e, 02, 00, 12, 00, 13, 20, 09, 06, 00, 12, 00, 13, 01, 01, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 3
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(0), rhs = Expression(2, Add)
- expression 2 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 7
- Code(Counter(0)) at (prev + 18, 1) to (start + 0, 32)
- Code(Counter(0)) at (prev + 17, 1) to (start + 0, 32)
- Code(Counter(0)) at (prev + 1, 9) to (start + 0, 10)
- Code(Counter(0)) at (prev + 0, 13) to (start + 0, 14)
- Branch { true: Counter(1), false: Expression(0, Sub) } at (prev + 0, 13) to (start + 0, 14)
@@ -100,23 +100,23 @@ Number of file 0 mappings: 7
Highest counter ID seen: c2

Function name: conditions::foo
Raw bytes (9): 0x[01, 01, 00, 01, 01, 21, 01, 02, 02]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 20, 01, 02, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 33, 1) to (start + 2, 2)
- Code(Counter(0)) at (prev + 32, 1) to (start + 2, 2)
Highest counter ID seen: c0

Function name: conditions::func_call
Raw bytes (37): 0x[01, 01, 02, 01, 05, 05, 09, 05, 01, 25, 01, 01, 0a, 20, 05, 02, 01, 09, 00, 0a, 05, 00, 0e, 00, 0f, 20, 09, 06, 00, 0e, 00, 0f, 01, 01, 01, 00, 02]
Raw bytes (37): 0x[01, 01, 02, 01, 05, 05, 09, 05, 01, 24, 01, 01, 0a, 20, 05, 02, 01, 09, 00, 0a, 05, 00, 0e, 00, 0f, 20, 09, 06, 00, 0e, 00, 0f, 01, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 2
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 5
- Code(Counter(0)) at (prev + 37, 1) to (start + 1, 10)
- Code(Counter(0)) at (prev + 36, 1) to (start + 1, 10)
- Branch { true: Counter(1), false: Expression(0, Sub) } at (prev + 1, 9) to (start + 0, 10)
true = c1
false = (c0 - c1)
@@ -128,11 +128,11 @@ Number of file 0 mappings: 5
Highest counter ID seen: c2

Function name: conditions::simple_assign
Raw bytes (9): 0x[01, 01, 00, 01, 01, 08, 01, 03, 02]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 07, 01, 03, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 8, 1) to (start + 3, 2)
- Code(Counter(0)) at (prev + 7, 1) to (start + 3, 2)
Highest counter ID seen: c0

1 change: 0 additions & 1 deletion tests/coverage/condition/conditions.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ compile-flags: -Zcoverage-options=condition
LL| |//@ llvm-cov-flags: --show-branches=count
1 change: 0 additions & 1 deletion tests/coverage/condition/conditions.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ compile-flags: -Zcoverage-options=condition
//@ llvm-cov-flags: --show-branches=count
2 changes: 1 addition & 1 deletion tests/coverage/coverage_attr_closure.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
LL| |#![feature(coverage_attribute, stmt_expr_attributes)]
LL| |#![feature(stmt_expr_attributes)]
LL| |#![allow(dead_code)]
LL| |//@ edition: 2021
LL| |
2 changes: 1 addition & 1 deletion tests/coverage/coverage_attr_closure.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#![feature(coverage_attribute, stmt_expr_attributes)]
#![feature(stmt_expr_attributes)]
#![allow(dead_code)]
//@ edition: 2021

16 changes: 8 additions & 8 deletions tests/coverage/fn_sig_into_try.cov-map
Original file line number Diff line number Diff line change
@@ -1,48 +1,48 @@
Function name: fn_sig_into_try::a
Raw bytes (9): 0x[01, 01, 00, 01, 01, 0a, 01, 05, 02]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 09, 01, 05, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 10, 1) to (start + 5, 2)
- Code(Counter(0)) at (prev + 9, 1) to (start + 5, 2)
Highest counter ID seen: c0

Function name: fn_sig_into_try::b
Raw bytes (26): 0x[01, 01, 01, 01, 00, 04, 01, 11, 01, 03, 0f, 00, 03, 0f, 00, 10, 02, 01, 05, 00, 0c, 01, 01, 01, 00, 02]
Raw bytes (26): 0x[01, 01, 01, 01, 00, 04, 01, 10, 01, 03, 0f, 00, 03, 0f, 00, 10, 02, 01, 05, 00, 0c, 01, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Zero
Number of file 0 mappings: 4
- Code(Counter(0)) at (prev + 17, 1) to (start + 3, 15)
- Code(Counter(0)) at (prev + 16, 1) to (start + 3, 15)
- Code(Zero) at (prev + 3, 15) to (start + 0, 16)
- Code(Expression(0, Sub)) at (prev + 1, 5) to (start + 0, 12)
= (c0 - Zero)
- Code(Counter(0)) at (prev + 1, 1) to (start + 0, 2)
Highest counter ID seen: c0

Function name: fn_sig_into_try::c
Raw bytes (26): 0x[01, 01, 01, 01, 00, 04, 01, 18, 01, 03, 17, 00, 03, 17, 00, 18, 02, 01, 05, 00, 0c, 01, 01, 01, 00, 02]
Raw bytes (26): 0x[01, 01, 01, 01, 00, 04, 01, 17, 01, 03, 17, 00, 03, 17, 00, 18, 02, 01, 05, 00, 0c, 01, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Zero
Number of file 0 mappings: 4
- Code(Counter(0)) at (prev + 24, 1) to (start + 3, 23)
- Code(Counter(0)) at (prev + 23, 1) to (start + 3, 23)
- Code(Zero) at (prev + 3, 23) to (start + 0, 24)
- Code(Expression(0, Sub)) at (prev + 1, 5) to (start + 0, 12)
= (c0 - Zero)
- Code(Counter(0)) at (prev + 1, 1) to (start + 0, 2)
Highest counter ID seen: c0

Function name: fn_sig_into_try::d
Raw bytes (26): 0x[01, 01, 01, 01, 00, 04, 01, 1f, 01, 04, 0f, 00, 04, 0f, 00, 10, 02, 01, 05, 00, 0c, 01, 01, 01, 00, 02]
Raw bytes (26): 0x[01, 01, 01, 01, 00, 04, 01, 1e, 01, 04, 0f, 00, 04, 0f, 00, 10, 02, 01, 05, 00, 0c, 01, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(0), rhs = Zero
Number of file 0 mappings: 4
- Code(Counter(0)) at (prev + 31, 1) to (start + 4, 15)
- Code(Counter(0)) at (prev + 30, 1) to (start + 4, 15)
- Code(Zero) at (prev + 4, 15) to (start + 0, 16)
- Code(Expression(0, Sub)) at (prev + 1, 5) to (start + 0, 12)
= (c0 - Zero)
1 change: 0 additions & 1 deletion tests/coverage/fn_sig_into_try.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |
LL| |// Regression test for inconsistent handling of function signature spans that
1 change: 0 additions & 1 deletion tests/coverage/fn_sig_into_try.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021

// Regression test for inconsistent handling of function signature spans that
4 changes: 2 additions & 2 deletions tests/coverage/if_not.cov-map
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
Function name: if_not::if_not
Raw bytes (60): 0x[01, 01, 03, 01, 05, 01, 09, 01, 0d, 0a, 01, 05, 01, 03, 0d, 02, 04, 05, 02, 06, 05, 02, 05, 00, 06, 01, 03, 09, 01, 0d, 06, 02, 05, 02, 06, 09, 02, 05, 00, 06, 01, 03, 09, 01, 0d, 0a, 02, 05, 02, 06, 0d, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (60): 0x[01, 01, 03, 01, 05, 01, 09, 01, 0d, 0a, 01, 04, 01, 03, 0d, 02, 04, 05, 02, 06, 05, 02, 05, 00, 06, 01, 03, 09, 01, 0d, 06, 02, 05, 02, 06, 09, 02, 05, 00, 06, 01, 03, 09, 01, 0d, 0a, 02, 05, 02, 06, 0d, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 3
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(0), rhs = Counter(2)
- expression 2 operands: lhs = Counter(0), rhs = Counter(3)
Number of file 0 mappings: 10
- Code(Counter(0)) at (prev + 5, 1) to (start + 3, 13)
- Code(Counter(0)) at (prev + 4, 1) to (start + 3, 13)
- Code(Expression(0, Sub)) at (prev + 4, 5) to (start + 2, 6)
= (c0 - c1)
- Code(Counter(1)) at (prev + 2, 5) to (start + 0, 6)
1 change: 0 additions & 1 deletion tests/coverage/if_not.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |
LL| |#[rustfmt::skip]
1 change: 0 additions & 1 deletion tests/coverage/if_not.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021

#[rustfmt::skip]
12 changes: 6 additions & 6 deletions tests/coverage/let_else_loop.cov-map
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
Function name: let_else_loop::_if (unused)
Raw bytes (19): 0x[01, 01, 00, 03, 00, 16, 01, 01, 0c, 00, 01, 0f, 00, 16, 00, 00, 20, 00, 27]
Raw bytes (19): 0x[01, 01, 00, 03, 00, 15, 01, 01, 0c, 00, 01, 0f, 00, 16, 00, 00, 20, 00, 27]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 3
- Code(Zero) at (prev + 22, 1) to (start + 1, 12)
- Code(Zero) at (prev + 21, 1) to (start + 1, 12)
- Code(Zero) at (prev + 1, 15) to (start + 0, 22)
- Code(Zero) at (prev + 0, 32) to (start + 0, 39)
Highest counter ID seen: (none)

Function name: let_else_loop::_loop_either_way (unused)
Raw bytes (19): 0x[01, 01, 00, 03, 00, 0f, 01, 01, 14, 00, 01, 1c, 00, 23, 00, 01, 05, 00, 0c]
Raw bytes (19): 0x[01, 01, 00, 03, 00, 0e, 01, 01, 14, 00, 01, 1c, 00, 23, 00, 01, 05, 00, 0c]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 3
- Code(Zero) at (prev + 15, 1) to (start + 1, 20)
- Code(Zero) at (prev + 14, 1) to (start + 1, 20)
- Code(Zero) at (prev + 1, 28) to (start + 0, 35)
- Code(Zero) at (prev + 1, 5) to (start + 0, 12)
Highest counter ID seen: (none)

Function name: let_else_loop::loopy
Raw bytes (19): 0x[01, 01, 00, 03, 01, 09, 01, 01, 14, 09, 01, 1c, 00, 23, 05, 01, 01, 00, 02]
Raw bytes (19): 0x[01, 01, 00, 03, 01, 08, 01, 01, 14, 09, 01, 1c, 00, 23, 05, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 3
- Code(Counter(0)) at (prev + 9, 1) to (start + 1, 20)
- Code(Counter(0)) at (prev + 8, 1) to (start + 1, 20)
- Code(Counter(2)) at (prev + 1, 28) to (start + 0, 35)
- Code(Counter(1)) at (prev + 1, 1) to (start + 0, 2)
Highest counter ID seen: c2
1 change: 0 additions & 1 deletion tests/coverage/let_else_loop.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |
LL| |// Regression test for <https://github.com/rust-lang/rust/issues/122738>.
1 change: 0 additions & 1 deletion tests/coverage/let_else_loop.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021

// Regression test for <https://github.com/rust-lang/rust/issues/122738>.
8 changes: 4 additions & 4 deletions tests/coverage/macro_in_closure.cov-map
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
Function name: macro_in_closure::NO_BLOCK::{closure#0}
Raw bytes (9): 0x[01, 01, 00, 01, 01, 07, 1c, 00, 2d]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 06, 1c, 00, 2d]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 7, 28) to (start + 0, 45)
- Code(Counter(0)) at (prev + 6, 28) to (start + 0, 45)
Highest counter ID seen: c0

Function name: macro_in_closure::WITH_BLOCK::{closure#0}
Raw bytes (9): 0x[01, 01, 00, 01, 01, 09, 1e, 02, 02]
Raw bytes (9): 0x[01, 01, 00, 01, 01, 08, 1e, 02, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 0
Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 9, 30) to (start + 2, 2)
- Code(Counter(0)) at (prev + 8, 30) to (start + 2, 2)
Highest counter ID seen: c0

1 change: 0 additions & 1 deletion tests/coverage/macro_in_closure.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |
LL| |// If a closure body consists entirely of a single bang-macro invocation, the
1 change: 0 additions & 1 deletion tests/coverage/macro_in_closure.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021

// If a closure body consists entirely of a single bang-macro invocation, the
4 changes: 2 additions & 2 deletions tests/coverage/mcdc/condition-limit.cov-map
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Function name: condition_limit::accept_7_conditions
Raw bytes (147): 0x[01, 01, 08, 01, 05, 05, 09, 09, 0d, 0d, 11, 11, 15, 15, 19, 19, 1d, 01, 1d, 12, 01, 07, 01, 02, 09, 28, 08, 07, 02, 08, 00, 27, 30, 05, 02, 01, 07, 00, 00, 08, 00, 09, 05, 00, 0d, 00, 0e, 30, 09, 06, 07, 06, 00, 00, 0d, 00, 0e, 09, 00, 12, 00, 13, 30, 0d, 0a, 06, 05, 00, 00, 12, 00, 13, 0d, 00, 17, 00, 18, 30, 11, 0e, 05, 04, 00, 00, 17, 00, 18, 11, 00, 1c, 00, 1d, 30, 15, 12, 04, 03, 00, 00, 1c, 00, 1d, 15, 00, 21, 00, 22, 30, 19, 16, 03, 02, 00, 00, 21, 00, 22, 19, 00, 26, 00, 27, 30, 1d, 1a, 02, 00, 00, 00, 26, 00, 27, 1d, 00, 28, 02, 06, 1e, 02, 05, 00, 06, 01, 01, 01, 00, 02]
Raw bytes (147): 0x[01, 01, 08, 01, 05, 05, 09, 09, 0d, 0d, 11, 11, 15, 15, 19, 19, 1d, 01, 1d, 12, 01, 06, 01, 02, 09, 28, 08, 07, 02, 08, 00, 27, 30, 05, 02, 01, 07, 00, 00, 08, 00, 09, 05, 00, 0d, 00, 0e, 30, 09, 06, 07, 06, 00, 00, 0d, 00, 0e, 09, 00, 12, 00, 13, 30, 0d, 0a, 06, 05, 00, 00, 12, 00, 13, 0d, 00, 17, 00, 18, 30, 11, 0e, 05, 04, 00, 00, 17, 00, 18, 11, 00, 1c, 00, 1d, 30, 15, 12, 04, 03, 00, 00, 1c, 00, 1d, 15, 00, 21, 00, 22, 30, 19, 16, 03, 02, 00, 00, 21, 00, 22, 19, 00, 26, 00, 27, 30, 1d, 1a, 02, 00, 00, 00, 26, 00, 27, 1d, 00, 28, 02, 06, 1e, 02, 05, 00, 06, 01, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 8
@@ -12,7 +12,7 @@ Number of expressions: 8
- expression 6 operands: lhs = Counter(6), rhs = Counter(7)
- expression 7 operands: lhs = Counter(0), rhs = Counter(7)
Number of file 0 mappings: 18
- Code(Counter(0)) at (prev + 7, 1) to (start + 2, 9)
- Code(Counter(0)) at (prev + 6, 1) to (start + 2, 9)
- MCDCDecision { bitmap_idx: 8, conditions_num: 7 } at (prev + 2, 8) to (start + 0, 39)
- MCDCBranch { true: Counter(1), false: Expression(0, Sub), condition_id: 1, true_next_id: 7, false_next_id: 0 } at (prev + 0, 8) to (start + 0, 9)
true = c1
1 change: 0 additions & 1 deletion tests/coverage/mcdc/condition-limit.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ min-llvm-version: 19
LL| |//@ compile-flags: -Zcoverage-options=mcdc
1 change: 0 additions & 1 deletion tests/coverage/mcdc/condition-limit.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ min-llvm-version: 19
//@ compile-flags: -Zcoverage-options=mcdc
28 changes: 14 additions & 14 deletions tests/coverage/mcdc/if.cov-map
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
Function name: if::mcdc_check_a
Raw bytes (62): 0x[01, 01, 03, 01, 05, 05, 09, 01, 09, 08, 01, 0f, 01, 01, 09, 28, 03, 02, 01, 08, 00, 0e, 30, 05, 02, 01, 02, 00, 00, 08, 00, 09, 05, 00, 0d, 00, 0e, 30, 09, 06, 02, 00, 00, 00, 0d, 00, 0e, 09, 00, 0f, 02, 06, 0a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (62): 0x[01, 01, 03, 01, 05, 05, 09, 01, 09, 08, 01, 0e, 01, 01, 09, 28, 03, 02, 01, 08, 00, 0e, 30, 05, 02, 01, 02, 00, 00, 08, 00, 09, 05, 00, 0d, 00, 0e, 30, 09, 06, 02, 00, 00, 00, 0d, 00, 0e, 09, 00, 0f, 02, 06, 0a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 3
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(1), rhs = Counter(2)
- expression 2 operands: lhs = Counter(0), rhs = Counter(2)
Number of file 0 mappings: 8
- Code(Counter(0)) at (prev + 15, 1) to (start + 1, 9)
- Code(Counter(0)) at (prev + 14, 1) to (start + 1, 9)
- MCDCDecision { bitmap_idx: 3, conditions_num: 2 } at (prev + 1, 8) to (start + 0, 14)
- MCDCBranch { true: Counter(1), false: Expression(0, Sub), condition_id: 1, true_next_id: 2, false_next_id: 0 } at (prev + 0, 8) to (start + 0, 9)
true = c1
@@ -23,15 +23,15 @@ Number of file 0 mappings: 8
Highest counter ID seen: c2

Function name: if::mcdc_check_b
Raw bytes (62): 0x[01, 01, 03, 01, 05, 05, 09, 01, 09, 08, 01, 17, 01, 01, 09, 28, 03, 02, 01, 08, 00, 0e, 30, 05, 02, 01, 02, 00, 00, 08, 00, 09, 05, 00, 0d, 00, 0e, 30, 09, 06, 02, 00, 00, 00, 0d, 00, 0e, 09, 00, 0f, 02, 06, 0a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (62): 0x[01, 01, 03, 01, 05, 05, 09, 01, 09, 08, 01, 16, 01, 01, 09, 28, 03, 02, 01, 08, 00, 0e, 30, 05, 02, 01, 02, 00, 00, 08, 00, 09, 05, 00, 0d, 00, 0e, 30, 09, 06, 02, 00, 00, 00, 0d, 00, 0e, 09, 00, 0f, 02, 06, 0a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 3
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(1), rhs = Counter(2)
- expression 2 operands: lhs = Counter(0), rhs = Counter(2)
Number of file 0 mappings: 8
- Code(Counter(0)) at (prev + 23, 1) to (start + 1, 9)
- Code(Counter(0)) at (prev + 22, 1) to (start + 1, 9)
- MCDCDecision { bitmap_idx: 3, conditions_num: 2 } at (prev + 1, 8) to (start + 0, 14)
- MCDCBranch { true: Counter(1), false: Expression(0, Sub), condition_id: 1, true_next_id: 2, false_next_id: 0 } at (prev + 0, 8) to (start + 0, 9)
true = c1
@@ -47,15 +47,15 @@ Number of file 0 mappings: 8
Highest counter ID seen: c2

Function name: if::mcdc_check_both
Raw bytes (62): 0x[01, 01, 03, 01, 05, 05, 09, 01, 09, 08, 01, 1f, 01, 01, 09, 28, 03, 02, 01, 08, 00, 0e, 30, 05, 02, 01, 02, 00, 00, 08, 00, 09, 05, 00, 0d, 00, 0e, 30, 09, 06, 02, 00, 00, 00, 0d, 00, 0e, 09, 00, 0f, 02, 06, 0a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (62): 0x[01, 01, 03, 01, 05, 05, 09, 01, 09, 08, 01, 1e, 01, 01, 09, 28, 03, 02, 01, 08, 00, 0e, 30, 05, 02, 01, 02, 00, 00, 08, 00, 09, 05, 00, 0d, 00, 0e, 30, 09, 06, 02, 00, 00, 00, 0d, 00, 0e, 09, 00, 0f, 02, 06, 0a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 3
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(1), rhs = Counter(2)
- expression 2 operands: lhs = Counter(0), rhs = Counter(2)
Number of file 0 mappings: 8
- Code(Counter(0)) at (prev + 31, 1) to (start + 1, 9)
- Code(Counter(0)) at (prev + 30, 1) to (start + 1, 9)
- MCDCDecision { bitmap_idx: 3, conditions_num: 2 } at (prev + 1, 8) to (start + 0, 14)
- MCDCBranch { true: Counter(1), false: Expression(0, Sub), condition_id: 1, true_next_id: 2, false_next_id: 0 } at (prev + 0, 8) to (start + 0, 9)
true = c1
@@ -71,15 +71,15 @@ Number of file 0 mappings: 8
Highest counter ID seen: c2

Function name: if::mcdc_check_neither
Raw bytes (62): 0x[01, 01, 03, 01, 05, 05, 09, 01, 09, 08, 01, 07, 01, 01, 09, 28, 03, 02, 01, 08, 00, 0e, 30, 05, 02, 01, 02, 00, 00, 08, 00, 09, 05, 00, 0d, 00, 0e, 30, 09, 06, 02, 00, 00, 00, 0d, 00, 0e, 09, 00, 0f, 02, 06, 0a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (62): 0x[01, 01, 03, 01, 05, 05, 09, 01, 09, 08, 01, 06, 01, 01, 09, 28, 03, 02, 01, 08, 00, 0e, 30, 05, 02, 01, 02, 00, 00, 08, 00, 09, 05, 00, 0d, 00, 0e, 30, 09, 06, 02, 00, 00, 00, 0d, 00, 0e, 09, 00, 0f, 02, 06, 0a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 3
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(1), rhs = Counter(2)
- expression 2 operands: lhs = Counter(0), rhs = Counter(2)
Number of file 0 mappings: 8
- Code(Counter(0)) at (prev + 7, 1) to (start + 1, 9)
- Code(Counter(0)) at (prev + 6, 1) to (start + 1, 9)
- MCDCDecision { bitmap_idx: 3, conditions_num: 2 } at (prev + 1, 8) to (start + 0, 14)
- MCDCBranch { true: Counter(1), false: Expression(0, Sub), condition_id: 1, true_next_id: 2, false_next_id: 0 } at (prev + 0, 8) to (start + 0, 9)
true = c1
@@ -95,7 +95,7 @@ Number of file 0 mappings: 8
Highest counter ID seen: c2

Function name: if::mcdc_check_not_tree_decision
Raw bytes (85): 0x[01, 01, 07, 01, 05, 01, 17, 05, 09, 05, 09, 17, 0d, 05, 09, 01, 0d, 0a, 01, 31, 01, 03, 0a, 28, 05, 03, 03, 08, 00, 15, 30, 05, 02, 01, 02, 03, 00, 09, 00, 0a, 02, 00, 0e, 00, 0f, 30, 09, 06, 03, 02, 00, 00, 0e, 00, 0f, 17, 00, 14, 00, 15, 30, 0d, 12, 02, 00, 00, 00, 14, 00, 15, 0d, 00, 16, 02, 06, 1a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (85): 0x[01, 01, 07, 01, 05, 01, 17, 05, 09, 05, 09, 17, 0d, 05, 09, 01, 0d, 0a, 01, 30, 01, 03, 0a, 28, 05, 03, 03, 08, 00, 15, 30, 05, 02, 01, 02, 03, 00, 09, 00, 0a, 02, 00, 0e, 00, 0f, 30, 09, 06, 03, 02, 00, 00, 0e, 00, 0f, 17, 00, 14, 00, 15, 30, 0d, 12, 02, 00, 00, 00, 14, 00, 15, 0d, 00, 16, 02, 06, 1a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 7
@@ -107,7 +107,7 @@ Number of expressions: 7
- expression 5 operands: lhs = Counter(1), rhs = Counter(2)
- expression 6 operands: lhs = Counter(0), rhs = Counter(3)
Number of file 0 mappings: 10
- Code(Counter(0)) at (prev + 49, 1) to (start + 3, 10)
- Code(Counter(0)) at (prev + 48, 1) to (start + 3, 10)
- MCDCDecision { bitmap_idx: 5, conditions_num: 3 } at (prev + 3, 8) to (start + 0, 21)
- MCDCBranch { true: Counter(1), false: Expression(0, Sub), condition_id: 1, true_next_id: 2, false_next_id: 3 } at (prev + 0, 9) to (start + 0, 10)
true = c1
@@ -129,7 +129,7 @@ Number of file 0 mappings: 10
Highest counter ID seen: c3

Function name: if::mcdc_check_tree_decision
Raw bytes (87): 0x[01, 01, 08, 01, 05, 05, 09, 05, 09, 05, 1f, 09, 0d, 09, 0d, 01, 1f, 09, 0d, 0a, 01, 27, 01, 03, 09, 28, 04, 03, 03, 08, 00, 15, 30, 05, 02, 01, 02, 00, 00, 08, 00, 09, 05, 00, 0e, 00, 0f, 30, 09, 0a, 02, 00, 03, 00, 0e, 00, 0f, 0a, 00, 13, 00, 14, 30, 0d, 0e, 03, 00, 00, 00, 13, 00, 14, 1f, 00, 16, 02, 06, 1a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (87): 0x[01, 01, 08, 01, 05, 05, 09, 05, 09, 05, 1f, 09, 0d, 09, 0d, 01, 1f, 09, 0d, 0a, 01, 26, 01, 03, 09, 28, 04, 03, 03, 08, 00, 15, 30, 05, 02, 01, 02, 00, 00, 08, 00, 09, 05, 00, 0e, 00, 0f, 30, 09, 0a, 02, 00, 03, 00, 0e, 00, 0f, 0a, 00, 13, 00, 14, 30, 0d, 0e, 03, 00, 00, 00, 13, 00, 14, 1f, 00, 16, 02, 06, 1a, 02, 0c, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 8
@@ -142,7 +142,7 @@ Number of expressions: 8
- expression 6 operands: lhs = Counter(0), rhs = Expression(7, Add)
- expression 7 operands: lhs = Counter(2), rhs = Counter(3)
Number of file 0 mappings: 10
- Code(Counter(0)) at (prev + 39, 1) to (start + 3, 9)
- Code(Counter(0)) at (prev + 38, 1) to (start + 3, 9)
- MCDCDecision { bitmap_idx: 4, conditions_num: 3 } at (prev + 3, 8) to (start + 0, 21)
- MCDCBranch { true: Counter(1), false: Expression(0, Sub), condition_id: 1, true_next_id: 2, false_next_id: 0 } at (prev + 0, 8) to (start + 0, 9)
true = c1
@@ -164,7 +164,7 @@ Number of file 0 mappings: 10
Highest counter ID seen: c3

Function name: if::mcdc_nested_if
Raw bytes (120): 0x[01, 01, 0b, 01, 05, 01, 2b, 05, 09, 05, 09, 2b, 0d, 05, 09, 0d, 11, 2b, 11, 05, 09, 01, 2b, 05, 09, 0e, 01, 3b, 01, 01, 09, 28, 03, 02, 01, 08, 00, 0e, 30, 05, 02, 01, 00, 02, 00, 08, 00, 09, 02, 00, 0d, 00, 0e, 30, 09, 26, 02, 00, 00, 00, 0d, 00, 0e, 2b, 01, 09, 01, 0d, 28, 06, 02, 01, 0c, 00, 12, 30, 0d, 12, 01, 02, 00, 00, 0c, 00, 0d, 0d, 00, 11, 00, 12, 30, 11, 1a, 02, 00, 00, 00, 11, 00, 12, 11, 00, 13, 02, 0a, 1e, 02, 09, 00, 0a, 26, 01, 0c, 02, 06, 01, 03, 01, 00, 02]
Raw bytes (120): 0x[01, 01, 0b, 01, 05, 01, 2b, 05, 09, 05, 09, 2b, 0d, 05, 09, 0d, 11, 2b, 11, 05, 09, 01, 2b, 05, 09, 0e, 01, 3a, 01, 01, 09, 28, 03, 02, 01, 08, 00, 0e, 30, 05, 02, 01, 00, 02, 00, 08, 00, 09, 02, 00, 0d, 00, 0e, 30, 09, 26, 02, 00, 00, 00, 0d, 00, 0e, 2b, 01, 09, 01, 0d, 28, 06, 02, 01, 0c, 00, 12, 30, 0d, 12, 01, 02, 00, 00, 0c, 00, 0d, 0d, 00, 11, 00, 12, 30, 11, 1a, 02, 00, 00, 00, 11, 00, 12, 11, 00, 13, 02, 0a, 1e, 02, 09, 00, 0a, 26, 01, 0c, 02, 06, 01, 03, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 11
@@ -180,7 +180,7 @@ Number of expressions: 11
- expression 9 operands: lhs = Counter(0), rhs = Expression(10, Add)
- expression 10 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 14
- Code(Counter(0)) at (prev + 59, 1) to (start + 1, 9)
- Code(Counter(0)) at (prev + 58, 1) to (start + 1, 9)
- MCDCDecision { bitmap_idx: 3, conditions_num: 2 } at (prev + 1, 8) to (start + 0, 14)
- MCDCBranch { true: Counter(1), false: Expression(0, Sub), condition_id: 1, true_next_id: 0, false_next_id: 2 } at (prev + 0, 8) to (start + 0, 9)
true = c1
1 change: 0 additions & 1 deletion tests/coverage/mcdc/if.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ min-llvm-version: 19
LL| |//@ compile-flags: -Zcoverage-options=mcdc
1 change: 0 additions & 1 deletion tests/coverage/mcdc/if.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ min-llvm-version: 19
//@ compile-flags: -Zcoverage-options=mcdc
4 changes: 2 additions & 2 deletions tests/coverage/mcdc/inlined_expressions.cov-map
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
Function name: inlined_expressions::inlined_instance
Raw bytes (50): 0x[01, 01, 02, 01, 05, 05, 09, 06, 01, 08, 01, 01, 06, 28, 03, 02, 01, 05, 00, 0b, 30, 05, 02, 01, 02, 00, 00, 05, 00, 06, 05, 00, 0a, 00, 0b, 30, 09, 06, 02, 00, 00, 00, 0a, 00, 0b, 01, 01, 01, 00, 02]
Raw bytes (50): 0x[01, 01, 02, 01, 05, 05, 09, 06, 01, 07, 01, 01, 06, 28, 03, 02, 01, 05, 00, 0b, 30, 05, 02, 01, 02, 00, 00, 05, 00, 06, 05, 00, 0a, 00, 0b, 30, 09, 06, 02, 00, 00, 00, 0a, 00, 0b, 01, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 2
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(1), rhs = Counter(2)
Number of file 0 mappings: 6
- Code(Counter(0)) at (prev + 8, 1) to (start + 1, 6)
- Code(Counter(0)) at (prev + 7, 1) to (start + 1, 6)
- MCDCDecision { bitmap_idx: 3, conditions_num: 2 } at (prev + 1, 5) to (start + 0, 11)
- MCDCBranch { true: Counter(1), false: Expression(0, Sub), condition_id: 1, true_next_id: 2, false_next_id: 0 } at (prev + 0, 5) to (start + 0, 6)
true = c1
1 change: 0 additions & 1 deletion tests/coverage/mcdc/inlined_expressions.coverage
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
LL| |#![feature(coverage_attribute)]
LL| |//@ edition: 2021
LL| |//@ min-llvm-version: 19
LL| |//@ compile-flags: -Zcoverage-options=mcdc -Copt-level=z -Cllvm-args=--inline-threshold=0
1 change: 0 additions & 1 deletion tests/coverage/mcdc/inlined_expressions.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(coverage_attribute)]
//@ edition: 2021
//@ min-llvm-version: 19
//@ compile-flags: -Zcoverage-options=mcdc -Copt-level=z -Cllvm-args=--inline-threshold=0
Loading