This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[参考译文] TDA4VH-Q1:TIOVX 一致性测试 (tivxGraph.GraphPipelineDepth) 失败

Guru**** 2826855 points
请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/processors-group/processors/f/processors-forum/1628739/tda4vh-q1-tiovx-conformance-test-tivxgraph-graphpipelinedepth-failure

器件型号: TDA4VH-Q1

您好、

由于未传递未对齐的地址、tivxGraphPipelineDepthTIOVX 测试失败。

TEST(tivxGraph, testGraphPipelineDepth)
{
    vx_context context = context_->vx_context_;
    vx_graph graph = NULL;
    vx_uint32 pipeline_depth = 2U, invalid_size_pipeline_depth = TIVX_GRAPH_MAX_PIPELINE_DEPTH, pipeline_depth_query;
    vx_int8 invalid_pipeline_depth = 2U;

    ASSERT_VX_OBJECT(graph = vxCreateGraph(context), VX_TYPE_GRAPH);

    ASSERT_EQ_VX_STATUS(VX_ERROR_INVALID_PARAMETERS, vxSetGraphAttribute(graph, VX_GRAPH_PIPELINE_DEPTH, &invalid_pipeline_depth, sizeof(vx_uint32)));
    ASSERT_EQ_VX_STATUS(VX_ERROR_INVALID_VALUE, vxSetGraphAttribute(graph, VX_GRAPH_PIPELINE_DEPTH, &invalid_size_pipeline_depth, sizeof(vx_uint32)));
    ASSERT_EQ_VX_STATUS(VX_SUCCESS, vxSetGraphAttribute(graph, VX_GRAPH_PIPELINE_DEPTH, &pipeline_depth, sizeof(vx_uint32)));

    ASSERT_EQ_VX_STATUS(VX_SUCCESS, vxQueryGraph(graph, VX_GRAPH_PIPELINE_DEPTH, &pipeline_depth_query, sizeof(pipeline_depth_query)));

    ASSERT(pipeline_depth_query==pipeline_depth);

    VX_CALL(vxReleaseGraph(&graph));
}

在上面的测试脚本中、传递 int_8 类型变量地址以满足 API vxSetGraphAttribute 中的未对齐检查、但未对齐检查作为变量在我们的环境中传递 Vx_INT8 INVALID_PUBLE_DEPTH 分配在 4 字节对齐的地址、并且该测试失败。

在传递给 API 之前、是否应该更新测试用例以保证未对齐的地址  vxSetGraphAttribute 由于 int_8 可能也可以获得对齐的地址?