The SIGILL handler is not very reliable and can cause crashes. Linux provides the CPU's AltiVec support status in getauxval.