Skip to content

Commit

Permalink
Typographical/Grammar Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
davis-matthew authored and dbabokin committed Nov 16, 2023
1 parent 29a67b2 commit 4197632
Show file tree
Hide file tree
Showing 11 changed files with 21 additions and 21 deletions.
2 changes: 1 addition & 1 deletion LICENSE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License.

===========================================================================
Copyrights and Licenses for Third Party Software Distrubted with
Copyrights and Licenses for Third Party Software Distributed with
Yet Another Random Program Generator
===========================================================================

Expand Down
4 changes: 2 additions & 2 deletions scripts/blame_opt.py
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ def blame(fail_dir, valid_res, fail_target, out_dir, lock, num, inplace):
blame_str += i
blame_phase_num = execute_blame_phase(valid_res, fail_target, blame_str, num, phase_num)
if fail_target.specs.name == "dpcpp":
# Special case becasue triagging mechanism is different and there's only one level of triagging.
# Special case because triaging mechanism is different and there's only one level of triaging.
blame_str += str(blame_phase_num-1)
else:
blame_str += str(blame_phase_num)
Expand Down Expand Up @@ -224,7 +224,7 @@ def blame(fail_dir, valid_res, fail_target, out_dir, lock, num, inplace):
opt_name = opt_name.replace(" ", "_")
else:
if blame_phase_num == 1:
# It's special case for DPC++. 1 means that triagging failed, no specific phase can be blamed.
# It's special case for DPC++. 1 means that triaging failed, no specific phase can be blamed.
real_opt_name = opt_name = "FailedToBlame"
else:
opt_name_pattern = re.compile(compilers_opt_name_cutter[fail_target.specs.name][0] + ".*" +
Expand Down
2 changes: 1 addition & 1 deletion scripts/collect_other_stats.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ def prepare_and_start(work_dir, config_file, timeout, num_jobs, csmith_bin_path,
# Check for binary of generator
csmith_home = os.environ.get("CSMITH_HOME")
if csmith_home is None:
common.print_and_exit("Please set CSMITH_HOME envirnoment variable")
common.print_and_exit("Please set CSMITH_HOME environment variable")
csmith_bin = os.path.abspath(csmith_home + os.sep + csmith_bin_path + os.sep + "csmith")
common.check_and_copy(csmith_bin, work_dir)
os.chdir(work_dir)
Expand Down
4 changes: 2 additions & 2 deletions scripts/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -263,15 +263,15 @@ def run_cmd(cmd, time_out=None, num=-1, memory_limit=None):
except ValueError:
output = b''
err_output = b''
log_msg(logging.DEBUG, "Procces " + str(process.pid) + " has finally died")
log_msg(logging.DEBUG, "Process " + str(process.pid) + " has finally died")
is_time_expired = True
ret_code = None
except:
log_msg(logging.ERROR, str(cmd) + " failed: unknown exception (proc num "+ str(process.pid) + ")")
# Something really bad is going on, so better to send sigkill
os.killpg(os.getpgid(process.pid), signal.SIGKILL)
process.wait()
log_msg(logging.DEBUG, "Procces " + str(process.pid) + " has finally died")
log_msg(logging.DEBUG, "Process " + str(process.pid) + " has finally died")
raise
end_time = os.times()
elapsed_time = end_time.children_user - start_time.children_user + \
Expand Down
2 changes: 1 addition & 1 deletion scripts/gen_test_makefile.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def __init__(self, name, value):
self.name = name
self.value = value

# I can't use build-in dictionary, because variables should be ordered
# I can't use built-in dictionary, because variables should be ordered
Makefile_variable_list = []

cxx_flags = MakefileVariable("CXXFLAGS", "")
Expand Down
18 changes: 9 additions & 9 deletions scripts/run_gen.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ class Test(object):
# Generate new test
# stat is statistics object
# seed is optional, if we want to generate some particular seed.
# proc_num is optinal debug info to track in what process we are running this activity.
# proc_num is optional debug info to track in what process we are running this activity.
def __init__(self, stat, seed="", proc_num=-1, blame=False, creduce_makefile=None):
# Run generator
yarpgen_run_list = [".." + os.sep + "yarpgen",
Expand Down Expand Up @@ -292,7 +292,7 @@ def add_success_run(self, test_run):
def add_fail_run(self, test_run):
self.fail_test_runs.append(test_run)

# Save failed runs and verify successul runs
# Save failed runs and verify successful runs
def handle_results(self, lock):
# Handle compfails and runfails.
self.save_failed(lock)
Expand Down Expand Up @@ -387,7 +387,7 @@ def verify_results(self, lock):
for run in results.values():
bad_runs += run

# Run blame triagging for one of failing optsets
# Run blame triaging for one of failing optsets
if self.blame and good_runs:
do_blame(self, self.files, good_runs[0].checksum, bad_runs[0].target)

Expand Down Expand Up @@ -756,7 +756,7 @@ def do_creduce_runfail(self, runfail_run):
test_sh +="[ $RETCODE -eq " + str(runfail_run.run_ret_code) + " ] && \\\n"
# it's "temporary" (until LLVM bug 33133 is fixed).
# This is needed when reduceing gcc_ubsan problem. Without this check we have good chances to reduce to the code
# snipent, which contains left shift of negative value (caught by gcc ubsan, but not clang ubsan).
# snippet, which contains left shift of negative value (caught by gcc ubsan, but not clang ubsan).
test_sh +="! grep \"left shift of negative value\" err.log && \\\n"

test_sh +="make -f $TEST_PWD" + os.sep + creduce_makefile_name + " " + ubsan_run.optset + " && \\\n"
Expand Down Expand Up @@ -1041,7 +1041,7 @@ def do_blame(test_obj, test_files, good_result, target_to_blame):
lock = None,
num = test_obj.proc_num,
inplace = True)
# Copy resuls back
# Copy results back
os.chdir(current_dir)
if os.path.exists("blame/Blame_Makefile"):
common.check_and_copy("blame/Blame_Makefile", ".")
Expand All @@ -1052,7 +1052,7 @@ def do_blame(test_obj, test_files, good_result, target_to_blame):
# interpret results
if type(blame_phase) is str:
test_obj.blame_phase = blame_phase
test_obj.blame_result = "was successul"
test_obj.blame_result = "was successful"
else:
test_obj.blame_result = "has failed"
except Exception as e:
Expand Down Expand Up @@ -1721,7 +1721,7 @@ class CustomFormatter(argparse.ArgumentDefaultsHelpFormatter, argparse.RawDescri
"clang, ubsan_clang, polly and gcc (ubsan_clang is a clang with sanitizer options)."
"They can be separated by a space or comma.")
parser.add_argument("-j", dest="num_jobs", default=multiprocessing.cpu_count(), type=int,
help='Maximum number of instances to run in parallel. By defaulti, it is set to'
help='Maximum number of instances to run in parallel. By default, it is set to'
' number of processor in your system')
parser.add_argument("--config-file", dest="config_file",
default=os.path.join(common.yarpgen_scripts, gen_test_makefile.default_test_sets_file_name),
Expand All @@ -1735,10 +1735,10 @@ class CustomFormatter(argparse.ArgumentDefaultsHelpFormatter, argparse.RawDescri
parser.add_argument("--seeds", dest="seeds_option_value", default="", type=str,
help="List of generator seeds to run or a file name with the list of seeds. "\
"Seeds may be separated by whitespaces and commas."\
"The seed may start with S_ or end with /, i.e. S_12345/ is interpretted as 12345."
"The seed may start with S_ or end with /, i.e. S_12345/ is interpreted as 12345."
"File comments may start with #")
parser.add_argument("--blame", dest="blame", default=False, action="store_true",
help="Enable optimization triagging for failing tests for supported compilers")
help="Enable optimization triaging for failing tests for supported compilers")
parser.add_argument("--creduce", dest="creduce", nargs='?', const=4, type=int, default=False,
help="Enable test reduction using CReduce tool. When given a number, "
"it's used as a number of creduce processes run for a single reduction (default is 4)")
Expand Down
2 changes: 1 addition & 1 deletion scripts/test_sets.txt
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ polly | clang++ | clang | -fPIC -mcmodel=large -w
# Otherwise it may fail with "undefined reference to `__mulodi4'" error message.
# See https://bugs.llvm.org//show_bug.cgi?id=16404 for more information
# Note that -fpermissive option for gcc is required to allow reduction of ubsan_gcc fails.
# Otherwise result of reducion is empty program.
# Otherwise result of reduction is empty program.
ubsan_clang | clang++ | clang | -fPIC -mcmodel=large -fsanitize=undefined -fno-sanitize-recover=undefined -Werror=uninitialized -Werror=implicitly-unsigned-literal | -march=
ubsan_gcc | g++ | gcc | -fPIC -mcmodel=large -fsanitize=undefined -fno-sanitize-recover=undefined -Werror=uninitialized -fpermissive | -march=
icc | icpc | icc | -fPIC -mcmodel=large -w | -x
Expand Down
2 changes: 1 addition & 1 deletion src/enums.h
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ enum class ArrayDimsReuseKind { SAME, OFFSET, SCALE, COMBINE };
// REPEAT means that we repeat the iterator that we've used before. It also
// conflicts with the dimensions in-order setting
// SWAP means that we swap new iterator with one that we've used before.
// The goal here is to alternate the order so we can generate somthing like
// The goal here is to alternate the order so we can generate something like
// matrix multiplication
enum class SubscriptKind { CONST, ITER, OFFSET, REPEAT };
// We need to make sure that we create special cases of array access patterns
Expand Down
2 changes: 1 addition & 1 deletion src/expr.h
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@ class ReductionExpr : public AssignmentExpr {
BinaryOp bin_op;
LibCallKind lib_call_kind;
std::shared_ptr<Expr> result_expr;
// This member indicates if we want to use a simpel AssignmentExpr as a
// This member indicates if we want to use a simple AssignmentExpr as a
// fallback option for reduction
bool is_degenerate;
};
Expand Down
2 changes: 1 addition & 1 deletion src/gen_policy.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ class GenPolicy {
// Hard threshold for loop depth
size_t loop_depth_limit;

// Hard threshold for if-else dpeth
// Hard threshold for if-else depth
size_t if_else_depth_limit;

// Number of statements in a scope
Expand Down
2 changes: 1 addition & 1 deletion src/type.h
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ class TypeBool : public IntegralTypeHelper<bool> {
: IntegralTypeHelper(getIntTypeId(), _is_static, _cv_qual) {}

// TODO: decouple language representation of the type from back-end type.
// I.e. for different languages the name ofter type and the suffix might be
// I.e. for different languages the name of the type and the suffix might be
// different.
IntTypeID getIntTypeId() final { return IntTypeID::BOOL; }
std::string getName(std::shared_ptr<EmitCtx> ctx) final {
Expand Down

0 comments on commit 4197632

Please sign in to comment.