My cpp project compiles and runs as well successfully with correct results in a linux based pc
. But the same cpp project luckily gets compiled in xillinux platform(ubuntu 12.04 LTS based Linux distribution) on Zedboard(development board with arm cortex a9 dual core processor) but while running it makes a logical error in computation and eventually aborts as its programmed to abort if something goes wrong.
Assertion fails and then aborts and gets cored dumped.
The assertion is to check a variable's value if its less than or equal to 1. But it gets a value 255 instead 1 or 0 or -1
In a PC with centos/ubuntu and intel i3 processor it didn't give 255 ever..!
Gcc compiler version in my PC running centos is:
gcc version 4.4.6 20110731 (Red Hat 4.4.6-3) (GCC)
Gcc compiler version in xillinux (zedboard) is:
gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5)
It seems to be some incompatibility but not sure about the cause. How to get rid of this problem?
Can anyone help me in this please..?