emeryberger/Hoard

Compilation issues on Solaris SunOS 5.10

varun85gupta opened this issue · 3 comments

Hoard 3.12 is not compiling on SunOS 5.10 with compiler version CC: Sun C++ 5.8

Errors:

CC -dalign -xbuiltin=%all -fast -xO5 -DNDEBUG -mt -g -xildoff -xthreadvar=dynamic -L/usr/lib/lwp -R/usr/lib/lwp -I. -Iinclude -Iinclude/util -Iinclude/hoard -Iinclude/superblocks -IHeap-Layers -D_REENTRANT=1 -G -PIC source/libhoard.cpp source/unixtls.cpp Heap-Layers/wrappers/wrapper.cpp Heap-Layers/wrappers/arch-specific/sparc-interchange.il -o libhoard_32.so -lthread -ldl -lCrun
source/libhoard.cpp:
"include/superblocks/tlab.h", line 90: Error: Cannot use HL::SLList::Entry* to initialize int_.
"source/libhoard.cpp", line 131: Where: While instantiating "Hoard::ThreadLocalAllocationBuffer<11, &HL::bins<Hoard::HoardSuperblockHeader<HL::SpinLockType, 65536, Hoard::SmallHeap>, 65536>::getSizeClass, &HL::bins<Hoard::HoardSuperblockHeader<HL::SpinLockType, 65536, Hoard::SmallHeap>, 65536>::getClassSize, 256, 2097152, Hoard::HoardSuperblock<HL::SpinLockType, 65536, Hoard::SmallHeap>, 65536, Hoard::HoardHeapType>::malloc(unsigned)".
"source/libhoard.cpp", line 131: Where: Instantiated from non-template code.
"include/superblocks/tlab.h", line 102: Error: Cannot use void_ to initialize int_.
"source/libhoard.cpp", line 131: Where: While instantiating "Hoard::ThreadLocalAllocationBuffer<11, &HL::bins<Hoard::HoardSuperblockHeader<HL::SpinLockType, 65536, Hoard::SmallHeap>, 65536>::getSizeClass, &HL::bins<Hoard::HoardSuperblockHeader<HL::SpinLockType, 65536, Hoard::SmallHeap>, 65536>::getClassSize, 256, 2097152, Hoard::HoardSuperblock<HL::SpinLockType, 65536, Hoard::SmallHeap>, 65536, Hoard::HoardHeapType>::malloc(unsigned)".
"source/libhoard.cpp", line 131: Where: Instantiated from non-template code.
2 Error(s) detected.
source/unixtls.cpp:
"source/unixtls.cpp", line 82: Error: "," expected instead of "attribute".
"source/unixtls.cpp", line 83: Error: "," expected instead of "attribute".
"source/unixtls.cpp", line 87: Error: "{" expected instead of "attribute".
"source/unixtls.cpp", line 87: Error: constructor is not defined.
"source/unixtls.cpp", line 89: Error: Use ";" to terminate declarations.
"source/unixtls.cpp", line 99: Error: Use ";" to terminate declarations.
"source/unixtls.cpp", line 100: Error: Cannot return bool from a function that should return Hoard::ThreadLocalAllocationBuffer<11, &HL::bins<Hoard::HoardSuperblockHeader<HL::SpinLockType, 65536, Hoard::SmallHeap>, 65536>::getSizeClass, &HL::bins<Hoard::HoardSuperblockHeader<HL::SpinLockType, 65536, Hoard::SmallHeap>, 65536>::getClassSize, 256, 2097152, Hoard::HoardSuperblock<HL::SpinLockType, 65536, Hoard::SmallHeap>, 65536, Hoard::HoardHeapType>.
"source/unixtls.cpp", line 103: Error: Use ";" to terminate declarations.
"source/unixtls.cpp", line 185: Error: Linkage specifications are allowed only at file level.
"source/unixtls.cpp", line 185: Error: Identifier expected instead of "{".
"source/unixtls.cpp", line 185: Error: Use ";" to terminate declarations.
"source/unixtls.cpp", line 200: Error: Use ";" to terminate declarations.
"source/unixtls.cpp", line 215: Error: Linkage specifications are allowed only at file level.
"source/unixtls.cpp", line 215: Error: Identifier expected instead of "{".
"source/unixtls.cpp", line 215: Error: Use ";" to terminate declarations.
"source/unixtls.cpp", line 216: Error: "inline" is not allowed here.
"source/unixtls.cpp", line 216: Error: Use ";" to terminate declarations.
"source/unixtls.cpp", line 219: Error: threadFunctionType is not defined.
"source/unixtls.cpp", line 220: Error: threadFunctionType is not defined.
"source/unixtls.cpp", line 220: Error: a is not defined.
"source/unixtls.cpp", line 220: Error: Cannot use int to initialize int
.
"source/unixtls.cpp", line 222: Error: threadFunctionType is not defined.
"source/unixtls.cpp", line 222: Error: int is not a structure type.
"source/unixtls.cpp", line 223: Error: int is not a structure type.
"source/unixtls.cpp", line 226: Error: The operation "_ int" is illegal.
Compilation aborted, too many Error messages.
Heap-Layers/wrappers/wrapper.cpp:
make: *** [SunOS-sunw-sparc] Error 3

I have no access to a Sun machine to debug this - if you can give me a guest account, I will be happy to look into it.

I am sorry to inform that I do not have any machine which can be shared.

Closing since I have no way to debug this issue and Solaris/SPARC is basically dead (http://www.networkworld.com/article/3160176/hardware/game-over-for-solaris-and-sparc.html).