misc: docs, typo fixes, small cleanups

This commit is contained in:
Justin Viiret
2018-01-18 10:41:43 +11:00
committed by Chang, Harry
parent ea9d1f69fb
commit ce7cfbde82
16 changed files with 68 additions and 49 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2015-2017, Intel Corporation
* Copyright (c) 2015-2018, Intel Corporation
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
@@ -459,7 +459,7 @@ public:
const_iterator end() const { return ordering.end(); }
};
typedef Bouquet<left_id> RoseBouquet;
typedef Bouquet<left_id> LeftfixBouquet;
typedef Bouquet<suffix_id> SuffixBouquet;
} // namespace
@@ -565,7 +565,7 @@ bool hasSameEngineType(const RoseVertexProps &u_prop,
*
* Parameters are vectors of literals + lag pairs.
*
* Note: if more constaints of when the leftfixes were going to be checked
* Note: if more constraints of when the leftfixes were going to be checked
* (mandatory lookarounds passing, offset checks), more merges may be allowed.
*/
static
@@ -599,7 +599,7 @@ bool compatibleLiteralsForMerge(
/* An engine requires that all accesses to it are ordered by offsets. (ie,
we can not check an engine's state at offset Y, if we have already
checked its status at offset X and X > Y). If we can not establish that
the literals used for triggering will statisfy this property, then it is
the literals used for triggering will satisfy this property, then it is
not safe to merge the engine. */
for (const auto &ue : ulits) {
const rose_literal_id &ul = *ue.first;
@@ -1778,7 +1778,7 @@ u32 estimatedAccelStates(const RoseBuildImpl &tbi, const NGHolder &h) {
}
static
void mergeNfaLeftfixes(RoseBuildImpl &tbi, RoseBouquet &roses) {
void mergeNfaLeftfixes(RoseBuildImpl &tbi, LeftfixBouquet &roses) {
RoseGraph &g = tbi.g;
DEBUG_PRINTF("%zu nfa rose merge candidates\n", roses.size());
@@ -1894,7 +1894,7 @@ void mergeSmallLeftfixes(RoseBuildImpl &tbi) {
RoseGraph &g = tbi.g;
RoseBouquet nfa_roses;
LeftfixBouquet nfa_leftfixes;
for (auto v : vertices_range(g)) {
if (!g[v].left) {
@@ -1939,20 +1939,20 @@ void mergeSmallLeftfixes(RoseBuildImpl &tbi) {
continue;
}
nfa_roses.insert(left, v);
nfa_leftfixes.insert(left, v);
}
deque<RoseBouquet> rose_groups;
chunkBouquets(nfa_roses, rose_groups, MERGE_GROUP_SIZE_MAX);
nfa_roses.clear();
DEBUG_PRINTF("chunked nfa roses into %zu groups\n", rose_groups.size());
deque<LeftfixBouquet> leftfix_groups;
chunkBouquets(nfa_leftfixes, leftfix_groups, MERGE_GROUP_SIZE_MAX);
nfa_leftfixes.clear();
DEBUG_PRINTF("chunked nfa leftfixes into %zu groups\n",
leftfix_groups.size());
for (auto &group : rose_groups) {
for (auto &group : leftfix_groups) {
mergeNfaLeftfixes(tbi, group);
}
}
static
void mergeCastleChunk(RoseBuildImpl &build, vector<left_id> &cands,
insertion_ordered_map<left_id, vector<RoseVertex>> &eng_verts) {