rust-rse / reed-solomon-erasure

[Looking for new owners/maintainers, see #88] Rust implementation of Reed-Solomon erasure coding
MIT License
179 stars 61 forks source link

Some compilers do not support -march=haswell #113

Closed bestgopher closed 9 months ago

bestgopher commented 9 months ago

I catched some build errors:

warning: reed-solomon-erasure@6.0.0: simd_c/reedsolomon.c:1:0: error: bad value (haswell) for -march= switch
warning: reed-solomon-erasure@6.0.0:  /* reedsolomon.c - SIMD-optimized Galois-field multiplication routines
warning: reed-solomon-erasure@6.0.0:  ^

The reason may be that some specific version of compilers does not support -march=haswell.

-> root@AAA ~git:(main) 101? # gcc -march=native -E - < /dev/null
# 1 "<stdin>"
# 1 "<built-in>"
# 1 "<command-line>"
# 1 "/usr/include/stdc-predef.h" 1 3 4
# 1 "<command-line>" 2
# 1 "<stdin>"
-> root@AAA ~git:(main) ? # gcc -march=haswell -E - < /dev/null
# 1 "<stdin>"
<stdin>:1:0: error: bad value (haswell) for -march= switch

Could we sure that compiler supports -march=haswell when set build flag?

nazar-pc commented 9 months ago

Which version of GCC is it specifically? Might be just too old to know about Haswell, in which case I don't think we care about it all that much.

bestgopher commented 9 months ago

Which version of GCC is it specifically? Might be just too old to know about Haswell, in which case I don't think we care about it all that much.

-> root@AAA ~ ? # gcc --version
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-44)
Copyright © 2015 Free Software Foundation, Inc. 
nazar-pc commented 9 months ago

GCC 4.8.5 is from 2015, I'm fairly certain no one will bother doing anything to support it. You should really upgrade to more modern and supported OS or install newer GCC in some way yourself.

bestgopher commented 9 months ago

GCC 4.8.5 is from 2015, I'm fairly certain no one will bother doing anything to support it. You should really upgrade to more modern and supported OS or install newer GCC in some way yourself.

Okey. Thanks for your reply.