Fix typos.

This commit is contained in:
Bruce Mitchener
2018-12-24 10:20:32 -05:00
committed by Dan Gohman
parent 4224a95f0d
commit 4f8753fa11
26 changed files with 41 additions and 41 deletions

View File

@@ -49,7 +49,7 @@ pub enum Reloc {
impl fmt::Display for Reloc {
/// Display trait implementation drops the arch, since its used in contexts where the arch is
/// already unambigious, e.g. clif syntax with isa specified. In other contexts, use Debug.
/// already unambiguous, e.g. clif syntax with isa specified. In other contexts, use Debug.
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
Reloc::Abs4 => write!(f, "Abs4"),

View File

@@ -505,7 +505,7 @@ impl DominatorTree {
/// - An ordering of EBBs according to a dominator tree pre-order.
/// - Constant time dominance checks at the EBB granularity.
///
/// The information in this auxillary data structure is not easy to update when the control flow
/// The information in this auxiliary data structure is not easy to update when the control flow
/// graph changes, which is why it is kept separate.
pub struct DominatorTreePreorder {
nodes: SecondaryMap<Ebb, ExtraNode>,

View File

@@ -162,7 +162,7 @@ where
{
let dfg = self.inserter.data_flow_graph_mut();
inst = dfg.make_inst(data);
// Make an `Interator<Item = Option<Value>>`.
// Make an `Iterator<Item = Option<Value>>`.
let ru = self.reuse.as_ref().iter().cloned();
dfg.make_inst_results_reusing(inst, ctrl_typevar, ru);
}

View File

@@ -92,8 +92,8 @@ impl MemFlags {
/// Test if the `readonly` flag is set.
///
/// Loads with this flag have no memory dependendies.
/// This results in indefined behavior if the dereferenced memory is mutated at any time
/// Loads with this flag have no memory dependencies.
/// This results in undefined behavior if the dereferenced memory is mutated at any time
/// between when the function is called and when it is exited.
pub fn readonly(self) -> bool {
self.read(FlagBit::Readonly)

View File

@@ -118,7 +118,7 @@ impl LoopAnalysis {
self.valid
}
/// Clear all the data structures contanted in the loop analysis. This will leave the
/// Clear all the data structures contained in the loop analysis. This will leave the
/// analysis in a similar state to a context returned by `new()` except that allocated
/// memory be retained.
pub fn clear(&mut self) {
@@ -191,7 +191,7 @@ impl LoopAnalysis {
let mut node_loop_parent_option = self.loops[node_loop].parent;
while let Some(node_loop_parent) = node_loop_parent_option.expand() {
if node_loop_parent == lp {
// We have encounterd lp so we stop (already visited)
// We have encountered lp so we stop (already visited)
break;
} else {
//

View File

@@ -157,7 +157,7 @@ mod details {
continue;
}
// Write a duration as secs.milis, trailing space.
// Write a duration as secs.millis, trailing space.
fn fmtdur(mut dur: Duration, f: &mut fmt::Formatter) -> fmt::Result {
// Round to nearest ms by adding 500us.
dur += Duration::new(0, 500_000);

View File

@@ -377,7 +377,7 @@ fn write_instruction(
write_operands(w, &func.dfg, isa, inst)?;
writeln!(w)?;
// Value aliases come out on lines after the instruction defining the referrent.
// Value aliases come out on lines after the instruction defining the referent.
for r in func.dfg.inst_results(inst) {
write_value_aliases(w, aliases, *r, indent)?;
}