mirror of
https://github.com/KhronosGroup/SPIRV-Tools
synced 2024-12-25 01:01:04 +00:00
Fix spelling mistakes
This commit is contained in:
parent
4f293b7139
commit
c9b2285bfc
@ -133,7 +133,7 @@ class Functions {
|
||||
// Returns the number of blocks in the current function being parsed
|
||||
size_t get_block_count() const;
|
||||
|
||||
// Retuns true if called after a function instruction but before the
|
||||
// Returns true if called after a function instruction but before the
|
||||
// function end instruction
|
||||
bool in_function_body() const;
|
||||
|
||||
@ -147,7 +147,7 @@ class Functions {
|
||||
// Parent module
|
||||
ValidationState_t& module_;
|
||||
|
||||
// Funciton IDs in a module
|
||||
// Function IDs in a module
|
||||
std::vector<uint32_t> id_;
|
||||
|
||||
// OpTypeFunction IDs of each of the id_ functions
|
||||
@ -216,7 +216,7 @@ class ValidationState_t {
|
||||
// Returns the function states
|
||||
Functions& get_functions();
|
||||
|
||||
// Retuns true if the called after a function instruction but before the
|
||||
// Returns true if the called after a function instruction but before the
|
||||
// function end instruction
|
||||
bool in_function_body() const;
|
||||
|
||||
|
@ -103,7 +103,7 @@ spv_result_t FunctionScopedInstructions(ValidationState_t& _,
|
||||
}
|
||||
if (_.get_functions().get_block_count() != 0) {
|
||||
return _.diag(SPV_ERROR_INVALID_LAYOUT)
|
||||
<< "Function parameters must only appear immediatly after the "
|
||||
<< "Function parameters must only appear immediately after the "
|
||||
"function definition";
|
||||
}
|
||||
spvCheckReturn(_.get_functions().RegisterFunctionParameter(
|
||||
|
@ -32,7 +32,7 @@ using std::function;
|
||||
using libspirv::ValidationState_t;
|
||||
|
||||
namespace {
|
||||
// This funciton takes the opcode of an instruction and returns
|
||||
// This function takes the opcode of an instruction and returns
|
||||
// a function object that will return true if the index
|
||||
// of the operand can be forwarad declared. This function will
|
||||
// used in the SSA validation stage of the pipeline
|
||||
@ -95,7 +95,7 @@ namespace libspirv {
|
||||
//
|
||||
// TODO(umar): Use dominators to correctly validate SSA. For example, the result
|
||||
// id from a 'then' block cannot dominate its usage in the 'else' block. This
|
||||
// is not yet performed by this funciton.
|
||||
// is not yet performed by this function.
|
||||
spv_result_t SsaPass(ValidationState_t& _,
|
||||
const spv_parsed_instruction_t* inst) {
|
||||
auto can_have_forward_declared_ids =
|
||||
|
@ -38,7 +38,7 @@ using testing::Eq;
|
||||
|
||||
TEST_F(TextToBinaryTest, Whitespace) {
|
||||
std::string input = R"(
|
||||
; I'm a proud comment at the begining of the file
|
||||
; I'm a proud comment at the beginning of the file
|
||||
; I hide: OpCapability Shader
|
||||
OpMemoryModel Logical Simple ; comment after instruction
|
||||
;;;;;;;; many ;'s
|
||||
|
@ -330,7 +330,7 @@ INSTANTIATE_TEST_CASE_P(
|
||||
INSTANTIATE_TEST_CASE_P(
|
||||
OpenCLMiscPrintf, ExtInstOpenCLStdRoundTripTest,
|
||||
::testing::ValuesIn(std::vector<InstructionCase>({
|
||||
// Printf is interesting becuase it takes a variable number of arguments.
|
||||
// Printf is interesting because it takes a variable number of arguments.
|
||||
// Start with zero optional arguments.
|
||||
{PREFIX, "%4", {4}},
|
||||
{PREFIX, "%4 %5", {4, 5}},
|
||||
|
@ -199,7 +199,7 @@ class EnumCase {
|
||||
// each of which has a 4-byte UTF-8 encoding.
|
||||
inline std::string MakeLongUTF8String(size_t num_4_byte_chars) {
|
||||
// An example of a longest valid UTF-8 character.
|
||||
// Be explicit about the character type becuase Microsoft compilers can
|
||||
// Be explicit about the character type because Microsoft compilers can
|
||||
// otherwise interpret the character string as being over wide (16-bit)
|
||||
// characters. Ideally, we would just use a C++11 UTF-8 string literal,
|
||||
// but we want to support older Microsoft compilers.
|
||||
|
@ -302,7 +302,7 @@ TEST_F(ValidateLayout, FuncParameterNotImmediatlyAfterFuncBad) {
|
||||
%funcl = OpLabel
|
||||
OpNop
|
||||
OpBranch %next
|
||||
%func2p = OpFunctionParameter %intt ;FunctionParameter appears in a function but not immediatly afterwards
|
||||
%func2p = OpFunctionParameter %intt ;FunctionParameter appears in a function but not immediately afterwards
|
||||
%next = OpLabel
|
||||
OpNop
|
||||
OpReturn
|
||||
|
Loading…
Reference in New Issue
Block a user