-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Discussion about test #20
Comments
关于回归测试:
|
参考下面两个脚本
|
build.sh #!/usr/bin/bash
DIR=$(cd "$(dirname "${0}")" &> /dev/null && (pwd -W 2> /dev/null || pwd))
source ${DIR}/data.sh
# 指定要搜索的目录路径
pocl_directory="/home/triton/Codes/OpenCL-CTS/TEST/pocl"
cts_directory="/home/triton/Codes/OpenCL-CTS/TEST/cts"
# 使用 find 命令列出目录层级下的所有文件
pocl_executables=($(find "$pocl_directory" -type f -executable -print0 | xargs -0))
cts_executables=($(find "$cts_directory" -type f -executable -print0 | xargs -0))
#
export LD_LIBRARY_PATH=/work/ventus-llvm/install/lib
export OCL_ICD_VENDORS=/work/ventus-llvm/install/lib/libpocl.so
export POCL_DEVICES="ventus"
# 遍历数组并执行每个可执行文件
for file in "${pocl_executables[@]}"; do
echo "----"
if [ -x "$file" ]; then
echo "Running $file"
"$file" >& /dev/null
if [ $? -eq 0 ]; then
echo "$file execution successful"
else
echo "Execution failed with exit status $exit_status"
exit $?
fi
else
echo "$file is not executable or does not exist"
fi
done
run_cts_basic() {
for element in "${cts_basic_test[@]}"
do
echo "Running $1 $element"
$1 $element 32 >& /dev/null
if [ $? -eq 0 ]; then
echo "$1 $element execution successful"
else
echo "Execution failed with $1 $element"
exit $?
fi
done
}
run_cts_compiler() {
for element in "${cts_compiler_test[@]}"
do
echo "Running $1 $element"
$1 $element 32 >& /dev/null
if [ $? -eq 0 ]; then
echo "$1 $element execution successful"
else
echo "Execution failed with $1 $element"
exit $?
fi
done
}
run_cts_api() {
for element in "${cts_api_test[@]}"
do
echo "Running $1 $element"
$1 $element 32 >& /dev/null
if [ $? -eq 0 ]; then
echo "$1 $element execution successful"
else
echo "Execution failed with $1 $element"
fi
done
}
# CTS的测试不太一样,需要特别处理
for file in "${cts_executables[@]}"; do
echo "----"
if [[ "$file" == */test_basic ]]; then
run_cts_basic $file
elif [[ "$file" == */test_compiler ]]; then
run_cts_compiler $file
elif [[ "$file" == */test_api ]]; then
run_cts_api $file
else
echo "$file is not executable or does not exist"
fi
done |
cts_basic_test=(
if
loop
constant
constant_source
barrier
wg_barrier
arrayreadwrite
# bufferreadwriterect
# arraycopy
createkernelsinprogram
explicit_s2v_double
host_numeric_constants
get_global_offset
global_linear_id
pointer_cast
# kernel_numeric_constants
kernel_call_kernel_function
kernel_memory_alignment_global
kernel_memory_alignment_constant
# kernel_memory_alignment_local
# fpmath
# sizeof
# vload_global
# vload_local
# vload_constant
# vload_private
# explicit_s2v_char
# explicit_s2v_uchar
# explicit_s2v_short
# explicit_s2v_ushort
# explicit_s2v_int
# explicit_s2v_uint
# explicit_s2v_long
# explicit_s2v_ulong
# explicit_s2v_float
# explicit_s2v_double
# vec_type_hint
# vector_creation
# vector_hint
)
cts_compiler_test=(
load_program_source
load_multistring_source
load_two_kernel_source
load_null_terminated_source
load_null_terminated_multi_line_source
load_null_terminated_partial_multi_line_source
load_discreet_length_source
get_program_source
get_program_build_info
get_program_info
large_compile
async_build
options_build_optimizations
preprocessor_define_udef
preprocessor_include
preprocessor_line_error
preprocessor_pragma
image_macro
)
cts_api_test=(
get_platform_info
get_context_info
get_device_info
binary_get
kernel_required_group_size
release_kernel_order
release_during_execute
load_single_kernel
load_two_kernels
load_two_kernels_in_one
load_two_kernels_manually
get_program_info_kernel_names
# get_kernel_arg_info : too long
create_kernels_in_program
get_kernel_info
kernel_private_memory_size
execute_kernel_local_sizes
set_kernel_arg_by_index
set_kernel_arg_constant
set_kernel_arg_struct_array
kernel_global_constant
# kernel_attributes : too long
min_max_thread_dimensions
min_max_work_items_sizes
min_max_work_group_size
min_max_mem_alloc_size
min_max_compute_units
min_max_address_bits
min_max_single_fp_config
min_max_double_fp_config
min_max_kernel_preferred_work_group_size_multiple
min_max_language_version
create_context_from_type
platform_extensions
get_platform_ids
bool_type
retain_queue_single
retain_queue_multiple
retain_mem_object_single
retain_mem_object_multiple
retain_mem_object_set_kernel_arg
mem_object_destructor_callback
null_buffer_arg
negative_get_platform_info
negative_get_platform_ids
) |
10.26更新后的data.sh
|
12.1更新CTS除basic目录的其他目录已经可以通过的用例:
compiler:
events:
extension: generic_address_space: integer_ops:
mem_host_flags: multiple_device_context:
pipes:
profiling: relationals:
select:
SVM:
vectors:
workgroups:
|
2024.1.5更新CTS的basic目录下的通过情况:
|
2024.1.19更新CTS的basic目录下的通过情况:
|
build脚本更新设置
|
2024.3.28更新除basic, compiler, api外其他的部分目录通过情况(注释的是没通过的,有些通过的只是跳过了测试,会标注出来):commonfns目录:
events目录:
extensions目录:有5个子目录: generic_address_space目录:没实现 integer_ops目录:
mem_host_flags目录(通过的都很快,不是跳过,但是没报错,注意一下):
multiple_device_context目录:
non_uniform_work_group目录:全部都是ERROR: clEnqueueNDRangeKernel failed!,pocl问题 pipes目录:
profiling目录:
relationals目录:
未完 |
目前的测试其实包括了很多模块,但是主要还是针对pocl和spike的功能测试,当前的测试比较分散,没有加入CTS,只有pocl和rodinia的部分测试,个人觉得不是很完善,应该把CTS通过的部分也加入进去,以下想法:
1 : 创建一个子仓库,里面存所有待测试的可执行文件,文件层级按目前的仓库来划分。类似
每次有通过的新用例可以往这个子仓库push,然后写一个脚本来跑测试,以后每次PR之前,都做一个这个测试,保证更改之后之前的测试都能过,这是一个大致的指导思路
当然总体思路是要保证能测试到目前所有通过的用例,然后后面每次修改都要保证通过前面所有的测试,而且前面每一次测试的dump和log文件最好能够保留,这样后面PR用例失败的时候,有新旧log比对
The text was updated successfully, but these errors were encountered: