Floating Point Exception

Hi,

I am compiling "HelloWorld" C progam on 32-bit CentOS and i want to execute it on 64-bit CentOS architecture.

For that i copied the a.out file from 32-bit to 64-bit machine, but while executing a.out file on 64bit machine I am getting "Floating point exception error".
But we can run 32-bit application on 64-bit machine.

Please tell me what is the problem, and where i am wrong?.:confused:

Thanks in advance,
Mandar.

rebuild it with debugging support(-ggdb) and run it with the gdb program.

Can you share this piece of code, if possible ? If you're after 32-64 bit incompatibility - can you execute the same code successfully on a 32bit machine ?

Are you building it as static or shared?