From: Wheeler, F. (Research) <wh...@cr...> - 2002-08-28 13:53:47
|
I've written a new fake test that does not really test anything, but just prints out vcl and vxl configuration parameters. The current output is below. A perl script generates the cxx file which has a bunch of stanzas like this. vcl_cout << "VCL_HAS_MEMBER_TEMPLATES "; #ifdef VCL_HAS_MEMBER_TEMPLATES vcl_cout << "is set to '" << quote(VCL_HAS_MEMBER_TEMPLATES) << "'"; #else vcl_cout << "is not set"; #endif vcl_cout << vcl_endl; The quote() is this: #define quote0(x) #x #define quote(x) quote0(x) I though this would be useful because it would allow people to see how the configuration parameters are set on any of the systems that report to the dashboard by looking at the test output on the dashboard. If anybody else agrees I'll check it in. Right now its in my local tree. I think a good place for this is vcl/tests/test_vcl_print_config.cxx. Amitha wrote: (Amitha's full message is below) > May I ask why you have the VXL_INT_8 define? I understand the need for > VXL_HAS_INT_8, but not the VXL_INT_8. Surely you could just use > vxl_int_8, which has the added benefit of being a full type (instead > of a preprocessor define)? I added defines like VXL_INT_8 just so this test could print out the fundamental type (as you can see below). Not really a big deal, but I would be curious to see what types were what sizes on the various machines. I see your point that this invites people to use this instead of the superior typedefs, so I plan to remove them unless Amitha or someone else suggests otherwise after reading this. Fred Wheeler % ./sr_test_driver.exe test_config ----------------------------------------------------------------------------- Start Testing config: ----------------------------------------------------------------------------- VCL_HAS_BOOL is set to '1' VCL_HAS_DYNAMIC_CAST is set to '1' VCL_HAS_TYPENAME is set to '1' VCL_HAS_EXPORT is set to '1' VCL_HAS_MUTABLE is set to '1' VCL_HAS_EXPLICIT is set to '1' VCL_FOR_SCOPE_HACK is set to '0' VCL_IMPLEMENT_STATIC_CONSTS is not set VCL_CAN_STATIC_CONST_INIT_INT is set to '(1 && !0)' VCL_CAN_STATIC_CONST_INIT_FLOAT is set to '(1 && !0)' VCL_HAS_MEMBER_TEMPLATES is set to '1' VCL_CAN_DO_PARTIAL_SPECIALIZATION is set to '1' VCL_ALLOWS_INLINE_INSTANTIATION is set to '1' VCL_NEEDS_INLINE_INSTANTIATION is set to '0' VCL_CAN_DO_STATIC_TEMPLATE_MEMBER is set to '1' VCL_CAN_DO_NON_TYPE_FUNCTION_TEMPLATE_PARAMETER is set to '1' VCL_NEED_FRIEND_FOR_TEMPLATE_OVERLOAD is set to '0' VCL_NO_STATIC_DATA_MEMBERS is set to '0' VCL_HAS_TEMPLATE_SYMBOLS is set to '1' VCL_CAN_DO_COMPLETE_DEFAULT_TYPE_PARAMETER is set to '1' VCL_HAS_EXCEPTIONS is set to '1' VCL_HAS_NAMESPACES is set to '1' VCL_ALLOWS_NAMESPACE_STD is set to '1' VCL_NEEDS_NAMESPACE_STD is set to '0' VCL_CXX_HAS_HEADER_CASSERT is set to '1' VCL_CXX_HAS_HEADER_CISO646 is set to '1' VCL_CXX_HAS_HEADER_CSETJMP is set to '1' VCL_CXX_HAS_HEADER_CSTDIO is set to '1' VCL_CXX_HAS_HEADER_CTIME is set to '1' VCL_CXX_HAS_HEADER_CCTYPE is set to '1' VCL_CXX_HAS_HEADER_CLIMITS is set to '1' VCL_CXX_HAS_HEADER_CSIGNAL is set to '1' VCL_CXX_HAS_HEADER_CSTDLIB is set to '1' VCL_CXX_HAS_HEADER_CWCHAR is set to '1' VCL_CXX_HAS_HEADER_CERRNO is set to '1' VCL_CXX_HAS_HEADER_CLOCALE is set to '1' VCL_CXX_HAS_HEADER_CSTDARG is set to '1' VCL_CXX_HAS_HEADER_CSTRING is set to '1' VCL_CXX_HAS_HEADER_CWCTYPE is set to '0' VCL_CXX_HAS_HEADER_CFLOAT is set to '1' VCL_CXX_HAS_HEADER_CMATH is set to '1' VCL_CXX_HAS_HEADER_CSTDDEF is set to '1' VCL_CXX_HAS_HEADER_ALGORITHM is set to '1' VCL_CXX_HAS_HEADER_IOMANIP is set to '1' VCL_CXX_HAS_HEADER_LIST is set to '1' VCL_CXX_HAS_HEADER_OSTREAM is set to '0' VCL_CXX_HAS_HEADER_STREAMBUF is set to '0' VCL_CXX_HAS_HEADER_BITSET is set to '1' VCL_CXX_HAS_HEADER_IOS is set to '0' VCL_CXX_HAS_HEADER_LOCALE is set to '0' VCL_CXX_HAS_HEADER_QUEUE is set to '1' VCL_CXX_HAS_HEADER_STRING is set to '1' VCL_CXX_HAS_HEADER_COMPLEX is set to '1' VCL_CXX_HAS_HEADER_IOSFWD is set to '1' VCL_CXX_HAS_HEADER_MAP is set to '1' VCL_CXX_HAS_HEADER_SET is set to '1' VCL_CXX_HAS_HEADER_TYPEINFO is set to '1' VCL_CXX_HAS_HEADER_DEQUE is set to '1' VCL_CXX_HAS_HEADER_IOSTREAM is set to '1' VCL_CXX_HAS_HEADER_MEMORY is set to '1' VCL_CXX_HAS_HEADER_SSTREAM is set to '1' VCL_CXX_HAS_HEADER_UTILITY is set to '1' VCL_CXX_HAS_HEADER_EXCEPTION is set to '1' VCL_CXX_HAS_HEADER_ISTREAM is set to '0' VCL_CXX_HAS_HEADER_NEW is set to '1' VCL_CXX_HAS_HEADER_STACK is set to '1' VCL_CXX_HAS_HEADER_VALARRAY is set to '1' VCL_CXX_HAS_HEADER_FSTREAM is set to '1' VCL_CXX_HAS_HEADER_ITERATOR is set to '1' VCL_CXX_HAS_HEADER_NUMERIC is set to '1' VCL_CXX_HAS_HEADER_STDEXCEPT is set to '1' VCL_CXX_HAS_HEADER_VECTOR is set to '1' VCL_CXX_HAS_HEADER_FUNCTIONAL is set to '1' VCL_CXX_HAS_HEADER_LIMITS is set to '0' VCL_CXX_HAS_HEADER_STRSTREAM is set to '1' VCL_USE_NATIVE_STL is set to '1' VCL_USE_NATIVE_COMPLEX is set to '1' VCL_USE_IMPLICIT_TEMPLATES is set to '1' VXL_LITTLE_ENDIAN is set to '1' VXL_BIG_ENDIAN is set to '0' VXL_HAS_INT_8 is set to '1' VXL_INT_8 is set to 'char' VXL_HAS_INT_16 is set to '1' VXL_INT_16 is set to 'short' VXL_HAS_INT_32 is set to '1' VXL_INT_32 is set to 'int' VXL_HAS_INT_64 is set to '1' VXL_INT_64 is set to 'long long' VXL_HAS_IEEE_32 is set to '1' VXL_IEEE_32 is set to 'float' VXL_HAS_IEEE_64 is set to '1' VXL_IEEE_64 is set to 'double' VXL_HAS_IEEE_96 is set to '1' VXL_IEEE_96 is set to 'long double' VXL_HAS_IEEE_128 is set to '0' VXL_IEEE_128 is set to 'void' VXL_HAS_PTHREAD_H is set to '1' VXL_HAS_SEMAPHORE_H is set to '1' VXL_UNISTD_HAS_USECONDS_T is set to '1' VXL_UNISTD_HAS_INTPTR_T is set to '0' VXL_UNISTD_HAS_UALARM is set to '1' VXL_UNISTD_HAS_USLEEP is set to '1' VXL_UNISTD_HAS_LCHOWN is set to '1' VXL_UNISTD_HAS_PREAD is set to '0' VXL_UNISTD_HAS_PWRITE is set to '0' VXL_UNISTD_HAS_TELL is set to '0' VXL_STDLIB_HAS_QSORT is set to '1' VXL_STDLIB_HAS_LRAND48 is set to '1' VXL_STDLIB_HAS_DRAND48 is set to '1' VXL_IEEEFP_HAS_FINITE is set to '0' VXL_MATH_HAS_FINITE is set to '1' VXL_MATH_HAS_SQRTF is set to '1' VXL_UNISTD_USLEEP_IS_VOID is set to '0' VXL_TWO_ARG_GETTIME is set to '0' VXL_HAS_IEEEFP_H is set to '1' ----------------------------------------------------------------------------- config Test Summary: All 0 tests succeeded ----------------------------------------------------------------------------- > -----Original Message----- > From: Amitha Perera [mailto:pe...@cs...] > Sent: Tuesday, August 27, 2002 5:49 PM > To: Wheeler, Fred (Research) > Subject: Re: [Vxl-commit] vxl/vxl vxl_config.h.in,1.12,1.13 > > > Fred, > > May I ask why you have the VXL_INT_8 define? I understand the need for > VXL_HAS_INT_8, but not the VXL_INT_8. Surely you could just use > vxl_int_8, which has the added benefit of being a full type (instead > of a preprocessor define)? > > I changed the thing to make them types instead of defines, because the > defines fail with casts. For example, > > #define VXL_UINT_8 unsigned char > int b = VXL_UINT_8( c ); > > fails, but > > typedef unsigned char vxl_uint_8; > int b = vxl_uint_8( c ); > > succeeds. > > Amitha. > > > On Tue, Aug 27, 2002 at 02:35:41PM -0700, > fre...@us... wrote: > [...] > > + #define VXL_HAS_INT_8 @VXL_HAS_INT_8@ > > + #define VXL_INT_8 @VXL_INT_8@ > > #if @VXL_HAS_INT_8@ > > typedef @VXL_INT_8@ vxl_int_8; > [...] > |