fix: correct typos and improve comments across multiple files by codespell (#4116)

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
This commit is contained in:
Huang Qi
2025-03-07 08:21:54 +08:00
committed by GitHub
parent 73998e4c85
commit 412631ac13
108 changed files with 215 additions and 215 deletions

View File

@ -790,7 +790,7 @@ set_local_gc_ref(AOTCompFrame *frame, int n, LLVMValueRef value, uint8 ref_type)
} \
else { \
char *func_name = #name; \
/* AOT mode, delcare the function */ \
/* AOT mode, declare the function */ \
if (!(func = LLVMGetNamedFunction(func_ctx->module, func_name)) \
&& !(func = LLVMAddFunction(func_ctx->module, func_name, \
func_type))) { \

View File

@ -3846,7 +3846,7 @@ aot_resolve_object_relocation_group(AOTObjectData *obj_data,
}
}
/* pares each relocation */
/* parse each relocation */
if (!(rel_itr = LLVMGetRelocations(rel_sec))) {
aot_set_last_error("llvm get relocations failed.");
return false;

View File

@ -345,7 +345,7 @@ aot_check_memory_overflow(AOTCompContext *comp_ctx, AOTFuncContext *func_ctx,
memory allocator, the hmu node includes hmu header and hmu
memory, only the latter is returned to the caller as the
allocated memory, the hmu header isn't returned so the
first byte of the shared heap won't be accesed, (2) using
first byte of the shared heap won't be accessed, (2) using
IntUGT gets better performance than IntUGE in some cases */
BUILD_ICMP(LLVMIntUGT, offset1, func_ctx->shared_heap_start_off,
is_in_shared_heap, "is_in_shared_heap");
@ -1101,7 +1101,7 @@ aot_compile_op_memory_grow(AOTCompContext *comp_ctx, AOTFuncContext *func_ctx)
}
else {
char *func_name = "aot_enlarge_memory";
/* AOT mode, delcare the function */
/* AOT mode, declare the function */
if (!(func = LLVMGetNamedFunction(func_ctx->module, func_name))
&& !(func =
LLVMAddFunction(func_ctx->module, func_name, func_type))) {
@ -1184,7 +1184,7 @@ check_bulk_memory_overflow(AOTCompContext *comp_ctx, AOTFuncContext *func_ctx,
* Note: not throw the integer-overflow-exception here since it must
* have been thrown when converting float to integer before
*/
/* return addres directly if constant offset and inside memory space */
/* return address directly if constant offset and inside memory space */
if (LLVMIsEfficientConstInt(offset) && LLVMIsEfficientConstInt(bytes)) {
uint64 mem_offset = (uint64)LLVMConstIntGetZExtValue(offset);
uint64 mem_len = (uint64)LLVMConstIntGetZExtValue(bytes);

View File

@ -1720,7 +1720,7 @@ aot_create_stack_sizes(const AOTCompData *comp_data, AOTCompContext *comp_ctx)
* This value is a placeholder, which will be replaced
* after the corresponding functions are compiled.
*
* Don't use zeros becasue LLVM can optimize them to
* Don't use zeros because LLVM can optimize them to
* zeroinitializer.
*/
values[i] = I32_NEG_ONE;
@ -2354,7 +2354,7 @@ create_target_machine_detect_host(AOTCompContext *comp_ctx)
}
if (!LLVMTargetHasJIT(target)) {
aot_set_last_error("unspported JIT on this platform.");
aot_set_last_error("unsupported JIT on this platform.");
goto fail;
}
@ -3412,7 +3412,7 @@ aot_get_native_symbol_index(AOTCompContext *comp_ctx, const char *symbol)
sym = bh_list_first_elem(&comp_ctx->native_symbols);
/* Lookup an existing symobl record */
/* Lookup an existing symbol record */
while (sym) {
if (strcmp(sym->symbol, symbol) == 0) {

View File

@ -17,7 +17,7 @@ endif()
set (IWASM_COMPL_SOURCE ${source_all})
# Disalbe rtti to works with LLVM
# Disable rtti to works with LLVM
if (MSVC)
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /GR-")

View File

@ -32,7 +32,7 @@ simd_integer_arith(AOTCompContext *comp_ctx, AOTFuncContext *func_ctx,
result = LLVMBuildMul(comp_ctx->builder, lhs, rhs, "product");
break;
default:
HANDLE_FAILURE("Unsupport arith_op");
HANDLE_FAILURE("Unsupported arith_op");
break;
}