c++
I am writing a program to compute Groebner bases using the library FGB. While it has a C interface, I am calling the library from C++ code compiled with g++ on Ubuntu.
Compiling with the option -g and using x/i $pc in gdb, the illegal instruction is as follows.
0x421c39 FGb_xmalloc_spec+985: vcvtsi2sd %rbx,%xmm0,%xmm0
The line above has angle brackets around FGB_xmalloc_spec+985. As far as I can tell, my processor does not support this instruction, and I am trying to figure out why the program uses it. It looks to me like the instruction comes from the library code. However, the code I am compiling used to work on the desktop it is now failing on - one day just started throwing the illegal instruction. I assumed I screwed up some libraries or something, so I reinstalled Ubuntu 16.04 but I continue to get the illegal instruction. The same exact code does work on another desktop and a chromebook, running Ubuntu 16.04 and 14.04 respectively.
Technical information:
Process: x86info output
Found 4 identical CPUs Extended Family: 0 Extended Model: 1 Family: 6 Model: 23 Stepping: 10 Type: 0 (Original OEM) CPU Model (x86info's best guess): Core 2 Duo Processor name string (BIOS programmed): Intel(R) Core(TM)2 Quad CPU Q9650 @ 3.00GHz
cpu flags
fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx lm constant_tsc arch_perfmon pebs bts rep_good nopl aperfmperf pni dtes64 monitor ds_cpl vmx smx est tm2 ssse3 cx16 xtpr pdcm sse4_1 xsave lahf_lm tpr_shadow vnmi flexpriority dtherm
Compile line
g++ -std=c++11 -g -I src -o bin/main.o -c src/main.cpp
g++ -std=c++11 -g -I src -o bin/Polynomial.o -c src/Polynomial.cpp
g++ -std=c++11 -g -I src -o bin/Util.o -c src/Util.cpp
g++ -std=c++11 -g -I src -o bin/Solve.o -c src/Solve.cpp
g++ -std=c++11 -g -o bin/StartUp bin/main.o bin/Util.o bin/Polynomial.o bin/Solve.o -Llib -lfgb -lfgbexp -lgb -lgbexp -lminpoly -lminpolyvgf -lgmp -lm -fopenmp
At this point, I am not sure what further things I can try to avoid this illegal instruction and welcome any and all suggestions.
链接地址: http://www.djcxy.com/p/72574.html下一篇: C ++