zoukankan      html  css  js  c++  java
  • 报错:/usr/lib/gcc/x86_64-linux-gnu/5/include/avx512vlintrin.h(11269): error: argument of type "void *" is incompatible with parameter of type "long long *"

    报错:/usr/lib/gcc/x86_64-linux-gnu/5/include/avx512vlintrin.h(11269): error: argument of type "void *" is incompatible with parameter of type "long long *"

    环境:cuda9.0,python3.6,pytorch1.0,gcc5.5

    服务器的环境,所以不能随意升级

    报错原因在这里有讨论:

    Apparently, there's a GCC bug involved:

    [Bug 76731 - AVX512] _mm512_i32gather_epi32 and other scatter/gather routines have incorrect signature

    It seems like GCC 5.5 shipped with some avx512?intrin.h headers that switched to using void* and const void*, but without switching the builtins to do the same. This was resolved in a post-release version of GCC 5. About GCC 6.x - I'm not sure.

    A way to get around this is discussed on this forum thread: Downloading the patched headers from the GNU servers.

    Shell script for use with GCC 5 (on a Linux system):

    for f in avx512fintrin.h avx512pfintrin.h avx512vlintrin.h; do
      curl -H "User-Agent:Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.94 Safari/537.36" -o $f "https://gcc.gnu.org/viewcvs/gcc/branches/gcc-5-branch/gcc/config/i386/${f}?view=co&revision=245536&content-type=text%2Fplain&pathrev=245536"
    done && mv avx512*intrin.h  /usr/lib/gcc/x86_64-linux-gnu/5/include/
    

    Actually, the files might be identical for all 3 versions, but I haven't checked.

    Note: If you're wondering why the user-agent string - it's to avoid the server from turning away clients it doesn't like with a "Forbidden" response. Of course it doesn't have to be this specific UA string.

    亲测,执行一下上面的脚本,也就是把那几个头文件拷贝过去,问题就解决了

    当然,如果是自用环境,可以直接升级gcc试一试

  • 相关阅读:
    Swift入门篇-Hello World
    Swift入门篇-swift简介
    Minecraft 插件 world edit 的cs 命令
    搭建本地MAVEN NEXUS 服务
    MC java 远程调试 plugin 开发
    企业内部从零开始安装docker hadoop 提纲
    javascript 命令方式 测试例子
    ca des key crt scr
    JSF 抽象和实现例子 (函数和属性)
    form 上传 html 代码
  • 原文地址:https://www.cnblogs.com/jiading/p/12156974.html
Copyright © 2011-2022 走看看