@@ -75,7 +75,7 @@ code branches, and injects additional [`Coverage`][coverage-statement]
75
75
statements into the ` BasicBlock ` s.
76
76
77
77
A MIR ` Coverage ` statement is a virtual instruction that indicates a counter
78
- should be incremented when its adjacent statemeents are executed, to count
78
+ should be incremented when its adjacent statements are executed, to count
79
79
a span of code ([ ` CodeRegion ` ] [ code-region ] ). It counts the number of times a
80
80
branch is executed, and also specifies the exact location of that code span in
81
81
the Rust source code.
@@ -181,7 +181,7 @@ MIR `Statement` into some backend-specific action or instruction.
181
181
CoverageKind :: Unreachable => {
182
182
...
183
183
```
184
- _ [ code snippet trimmed for brevity ] _
184
+ _ code snippet trimmed for brevity _
185
185
186
186
> The function name ` instrprof_increment() ` is taken from the LLVM intrinsic
187
187
call of the same name ([ ` llvm.instrprof.increment ` ] [ llvm-instrprof-increment ] ),
@@ -206,7 +206,7 @@ the last remaining step is to inject the LLVM IR variables that hold the
206
206
static data for the coverage map.
207
207
208
208
` rustc_codegen_llvm ` 's [ ` compile_codegen_unit() ` ] [ compile-codegen-unit ] calls
209
- [ ` coverageinfo_finalze ()` ] [ coverageinfo-finalize ] ,
209
+ [ ` coverageinfo_finalize ()` ] [ coverageinfo-finalize ] ,
210
210
which delegates its implementation to the
211
211
[ ` rustc_codegen_llvm::coverageinfo::mapgen ` ] [ mapgen-finalize ] module.
212
212
@@ -247,9 +247,9 @@ pub fn finalize<'ll, 'tcx>(cx: &CodegenCx<'ll, 'tcx>) {
247
247
mapgen . write_coverage_mapping (expressions , counter_regions , coverage_mapping_buffer );
248
248
});
249
249
```
250
- _ [ code snippet trimmed for brevity ] _
250
+ _ code snippet trimmed for brevity _
251
251
252
- One noteable step, performed by ` mapgen::finalize() ` before processing the
252
+ One notable step, performed by ` mapgen::finalize() ` before processing the
253
253
` Instance ` s and their ` FunctionCoverage ` s, is the call to
254
254
[ ` add_unreachable_functions() ` ] [ add-unreachable-coverage ] .
255
255
@@ -262,7 +262,7 @@ The set of unreachable functions is computed via the set difference of all MIR
262
262
` DefId ` s (` tcx ` query ` mir_keys ` ) minus the codegenned ` DefId ` s
263
263
(` tcx ` query ` collect_and_partition_mono_items ` ). ` add_unreachable_functions() `
264
264
computes the set of unreachable functions, queries the ` tcx ` for the
265
- previously-computed ` CodeRegions ` , for each unreachabe MIR, and adds those code
265
+ previously-computed ` CodeRegions ` , for each unreachable MIR, and adds those code
266
266
regions to one of the non-generic codegenned functions (non-generic avoids
267
267
potentially injecting the unreachable coverage multiple times for multiple
268
268
instantiations).
@@ -382,7 +382,7 @@ fundamental control flow, with many of the same
382
382
For anyone that knows how to work with the [ MIR, as a CFG] [ mir-dev-guide ] , the
383
383
` CoverageGraph ` will be familiar, and can be used in much the same way.
384
384
The nodes of the ` CoverageGraph ` are ` BasicCoverageBlock ` s (BCBs), which
385
- index into an ` IndexVec ` of ` BasicCoverageBlockData ` . This is analagous
385
+ index into an ` IndexVec ` of ` BasicCoverageBlockData ` . This is analogous
386
386
to the MIR CFG of ` BasicBlock ` s that index ` BasicBlockData ` .
387
387
388
388
Each ` BasicCoverageBlockData ` captures one or more MIR ` BasicBlock ` s,
@@ -450,7 +450,7 @@ The nodes contain information in sections:
450
450
its ` BasicCoverageBlockData ` ).
451
451
2 . The first content section shows the assigned ` Counter ` or ` Expression ` for
452
452
each contiguous section of code. (There may be more than one ` Expression `
453
- incremented by the same ` Counter ` for discontigous sections of code representing
453
+ incremented by the same ` Counter ` for discontiguous sections of code representing
454
454
the same sequential actions.) Note the code is represented by the line and
455
455
column ranges (for example: ` 52:28-52:33 ` , representing the original source
456
456
line 52, for columns 28-33). These are followed by the MIR ` Statement ` or
@@ -489,7 +489,7 @@ an initial set of `CoverageSpan`s from the `Span`s associated with each MIR
489
489
490
490
The final stage of ` generate_coverage_spans() ` is handled by
491
491
[ ` to_refined_spans() ` ] [ to-refined-spans ] , which iterates through the ` CoverageSpan ` s,
492
- merges and de-duplicates them, and returns an optimial , minimal set of ` CoverageSpan ` s
492
+ merges and de-duplicates them, and returns an optimal , minimal set of ` CoverageSpan ` s
493
493
that can be used to assign coverage ` Counter ` s or ` Expression ` s, one-for-one.
494
494
495
495
An visual, interactive representation of the final ` CoverageSpan ` s can be
0 commit comments