On Thu, 13 Dec 2012, [email protected] wrote:
Hi Nilay,
Yes, I had to make two changes to make it compile.
1. Solaris does not recognize std::isnan() function. So I had to put my
own implementation. This was a solution posted online >
https://gist.github.com/870503
-namespace std
-{
- int isnan (int x) { return x != x; }
-}
2. for some reason definitions for BYTE_ORDER,LITTLE_ENDIAN were not found
by compiler. As I knew my host machine is BigEndian, I commented out the
below part in src/sim/byteswap.hh line 159 - 164
-//#elif defined(_LITTLE_ENDIAN) || BYTE_ORDER == LITTLE_ENDIAN
-//const ByteOrder HostByteOrder = LittleEndianByteOrder;
-//template <typename T> inline T htole(T value) {return value;}
-//template <typename T> inline T letoh(T value) {return value;}
-//template <typename T> inline T htobe(T value) {return
swap_byte(value);}
-//template <typename T> inline T betoh(T value) {return
swap_byte(value);}
Is there something wrong with my changes? I would be grateful for any
pointers.
It seems to me that you have not listed all the changes in the file
src/sim/byteswap.hh because if these were the only changes, I would expect
the compilation to fail.
Rather than commenting out the code, I would suggest that you figure out
the files where these macros (or something similar) have been defined and
include those files in src/sim/byteswap.hh. Also, if there is a debugger
like dbx, gdb available on Solaris, use it and try to see what piece of
code is responsible for the error.
--
Nilay
_______________________________________________
gem5-users mailing list
[email protected]
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users