Skip to content

Stack smashing in IPPICV norm implementation on systems without AVX2 #27380

@asmorkalov

Description

@asmorkalov

System Information

OS: Ubuntu 24.04 x64
CPU: Core i5 2500k (Sandy Bridge)

Both debug and release tests crashed with stack smashing error in the test Core_Norm/ElemWiseTest.accuracy/0.

Stack trace from GDB:

Note: Google Test filter = Core_Norm/ElemWiseTest.accuracy/0
[==========] Running 1 test from 1 test case.
[----------] Global test environment set-up.
[----------] 1 test from Core_Norm/ElemWiseTest
[ RUN      ] Core_Norm/ElemWiseTest.accuracy/0, where GetParam() = 16-byte object <B0-E9 F9-56 55-55 00-00 30-D7 F9-56 55-55 00-00>

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff55f3bd6 in icv_y8_ownNorm_Inf_16u_C1MR_P8Y8 () from /home/arina/Projects/opencv-build/lib/libopencv_core.so.412
(gdb) bt
#0  0x00007ffff55f3bd6 in icv_y8_ownNorm_Inf_16u_C1MR_P8Y8 () at /home/arina/Projects/opencv-build/lib/libopencv_core.so.412
#1  0x000000000000000e in ??? ()
#2  0x000000000000000e in ??? ()
#3  0x000000000000001e in ??? ()
#4  0x0000000000000002 in ??? ()
#5  0x00007fffffffd850 in ??? ()
#6  0x00007ffff55e3bc7 in icv_y8_ippiNorm_Inf_16u_C1MR () at /home/arina/Projects/opencv-build/lib/libopencv_core.so.412
#7  0x00000000fffffff0 in ??? ()
#8  0x00007ffff55407f5 in ipp_hal_norm (src=0x5555572c9cdc "", src_step=28, mask=0x55555719608e "", mask_step=14, width=14, height=30, type=2, norm_type=1, result=0x7fffffffc6d0) at /home/arina/Projects/opencv/hal/ipp/src/norm_ipp.cpp:35
#9  0x00007ffff4cf22f7 in cv::norm (_src=..., normType=0, _mask=...) at /home/arina/Projects/opencv/modules/core/src/norm.dispatch.cpp:310

The issue is not visible on newer platform with the same OS and compiler.

Detailed description

Steps to reproduce

./bin/opencv_test_core --gtest_filter=Core_Norm/ElemWiseTest.accuracy/0

Issue submission checklist

  • I report the issue, it's not a question
  • I checked the problem with documentation, FAQ, open issues, forum.opencv.org, Stack Overflow, etc and have not found any solution
  • I updated to the latest OpenCV version and the issue is still there
  • There is reproducer code and related data files (videos, images, onnx, etc)

Metadata

Metadata

Assignees

Type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    pFad - Phonifier reborn

    Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

    Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


    Alternative Proxies:

    Alternative Proxy

    pFad Proxy

    pFad v3 Proxy

    pFad v4 Proxy