缺少 strlen_sse4.S 会导致分段错误

发布于 2024-12-02 07:43:21 字数 2067 浏览 0 评论 0原文

我正在编写一个用 C 语言编写的小工具,并遇到了分段错误,我目前不知道如何解决。在 GDB 中运行给了我以下提示:

    Program received signal SIGSEGV, Segmentation fault. 
    __strlen_sse42 () at ../sysdeps/x86_64/multiarch/strlen-sse4.S:32 
    ../sysdeps/x86_64/multiarch/strlen-sse4.S: File or Directory not found 
    in ../sysdeps/x86_64/multiarch/strlen-sse4.S
    (gdb) bt
    0  __strlen_sse42 () at ../sysdeps/x86_64/multiarch/strlen-sse4.S:32
    1  0x00007ffff764fed8 in strdup_and_subst_obj () from /usr/lib/libgvc.so.5
    2  0x00007ffff7650631 in make_label () from /usr/lib/libgvc.so.5
    3  0x00007ffff765a6d1 in common_init_node_opt () from /usr/lib/libgvc.so.5
    4  0x00007ffff309d700 in dot_init_node_edge () from 
    usr/lib/graphviz/libgvplugin_dot_layout.so.6
    5  0x00007ffff309dcd8 in dot_layout () from /usr/lib/graphviz/libgvplugin_dot_layout.so.6
    6  0x00007ffff7633a94 in gvLayoutJobs () from /usr/lib/libgvc.so.5
    7  0x00007ffff7639425 in gvLayout () from /usr/lib/libgvc.so.5
    8  0x0000000000400eef in main ()

我会说:我缺少对我的系统或我的可执行文件(Ubuntu 11.04 64 位)的特定依赖项 如果有任何建议,我将非常感激 :]

我目前正在使用:

gcc(Ubuntu/Linaro 4.5.2-8ubuntu4)4.5.2

编辑:

(gdb) info registers

    rax            0x6380e0 6521056
    rbx            0x62dc14 6478868
    rcx            0x0  0
    rdx            0x0  0
    rsi            0x639770 6526832
    rdi            0x0  0
    rbp            0x639770 0x639770
    rsp            0x7fffffffd358   0x7fffffffd358
    r8             0x0  0
    r9             0x0  0
    r10            0x7fffffffd140   140737488343360
    r11            0x7ffff764fda0   140737343978912
    r12            0x62dc14 6478868
    r13            0x639770 6526832
    r14            0x0  0
    r15            0x7ffff7671d85   140737344118149
    rip            0x7ffff6d7d49f   0x7ffff6d7d49f 
    eflags         0x10246  [ PF ZF IF RF ]
    cs             0x33 51
    ss             0x2b 43
    ds             0x0  0
    es             0x0  0
    fs             0x0  0
    gs             0x0  0

i'm writing a small tool written in c and met on a segmentation fault which i don't know currently how to resolve. Running in GDB gives me the following hint:


    Program received signal SIGSEGV, Segmentation fault. 
    __strlen_sse42 () at ../sysdeps/x86_64/multiarch/strlen-sse4.S:32 
    ../sysdeps/x86_64/multiarch/strlen-sse4.S: File or Directory not found 
    in ../sysdeps/x86_64/multiarch/strlen-sse4.S
    (gdb) bt
    0  __strlen_sse42 () at ../sysdeps/x86_64/multiarch/strlen-sse4.S:32
    1  0x00007ffff764fed8 in strdup_and_subst_obj () from /usr/lib/libgvc.so.5
    2  0x00007ffff7650631 in make_label () from /usr/lib/libgvc.so.5
    3  0x00007ffff765a6d1 in common_init_node_opt () from /usr/lib/libgvc.so.5
    4  0x00007ffff309d700 in dot_init_node_edge () from 
    usr/lib/graphviz/libgvplugin_dot_layout.so.6
    5  0x00007ffff309dcd8 in dot_layout () from /usr/lib/graphviz/libgvplugin_dot_layout.so.6
    6  0x00007ffff7633a94 in gvLayoutJobs () from /usr/lib/libgvc.so.5
    7  0x00007ffff7639425 in gvLayout () from /usr/lib/libgvc.so.5
    8  0x0000000000400eef in main ()

I would say: i'm missing a specific dependency on my system or in my executable (Ubuntu 11.04 64-Bit) Would be very grateful for any advice :]

I'm currently using:

gcc (Ubuntu/Linaro 4.5.2-8ubuntu4) 4.5.2

Edit:

(gdb) info registers

    rax            0x6380e0 6521056
    rbx            0x62dc14 6478868
    rcx            0x0  0
    rdx            0x0  0
    rsi            0x639770 6526832
    rdi            0x0  0
    rbp            0x639770 0x639770
    rsp            0x7fffffffd358   0x7fffffffd358
    r8             0x0  0
    r9             0x0  0
    r10            0x7fffffffd140   140737488343360
    r11            0x7ffff764fda0   140737343978912
    r12            0x62dc14 6478868
    r13            0x639770 6526832
    r14            0x0  0
    r15            0x7ffff7671d85   140737344118149
    rip            0x7ffff6d7d49f   0x7ffff6d7d49f 
    eflags         0x10246  [ PF ZF IF RF ]
    cs             0x33 51
    ss             0x2b 43
    ds             0x0  0
    es             0x0  0
    fs             0x0  0
    gs             0x0  0

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

巨坚强 2024-12-09 07:43:21

分段错误通常是空指针取消引用。鉴于 libc 非常可靠,您很可能希望使用调试符号重新编译程序,并获取 libgvc 的 Ubuntu 软件包的调试变体。

“缺少 strlen_sse4.S”只是调试器抱怨它找不到文件来为您提供崩溃站点的列表。您只需获取 glibc 源代码的副本即可检查该文件。

Segmentation fault is usually a null pointer dereference. Given that libc is pretty solid, you most likely want to recompile your program with debug symbols, and get the debug variant of the Ubuntu package for libgvc.

The "Missing strlen_sse4.S" is just the debugger complaining that it can't find the file to give you a listing of the crash site. You need only get a copy of glibc source to examine the file.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文