diff options
Diffstat (limited to 'TAO/performance-tests/Cubit/TAO/IDL_Cubit/Cubit_i.cpp')
-rw-r--r-- | TAO/performance-tests/Cubit/TAO/IDL_Cubit/Cubit_i.cpp | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/TAO/performance-tests/Cubit/TAO/IDL_Cubit/Cubit_i.cpp b/TAO/performance-tests/Cubit/TAO/IDL_Cubit/Cubit_i.cpp index 91ad25fbc62..73897ae501b 100644 --- a/TAO/performance-tests/Cubit/TAO/IDL_Cubit/Cubit_i.cpp +++ b/TAO/performance-tests/Cubit/TAO/IDL_Cubit/Cubit_i.cpp @@ -284,7 +284,7 @@ Cubit_i::cube_long_sequence (const Cubit::long_seq &input, output->length (input.length ()); -#if 0 +#if (ACE_HAS_PURIFY == 1) for (CORBA::ULong i = 0; i < input.length (); ++i) { CORBA::Long x = input[i]; @@ -294,7 +294,7 @@ Cubit_i::cube_long_sequence (const Cubit::long_seq &input, CORBA::ULong i = 0; CORBA::Long x = input[0]; output[i] = x * x * x; -#endif +#endif /* ACE_HAS_PURIFY == 1 */ } // Cube an octet sequence @@ -319,7 +319,10 @@ Cubit_i::cube_octet_sequence (const Cubit::octet_seq &input, output->length (input.length ()); -#if 0 +#if (ACE_HAS_PURIFY == 1) + // For Purify, initialize every output since we're looking for + // accesses to uninitialized memory addresses. Performance + // is secondary when compiling for purify. for (CORBA::ULong i = 0; i < input.length (); ++i) { CORBA::Octet x = input[i]; @@ -333,7 +336,7 @@ Cubit_i::cube_octet_sequence (const Cubit::octet_seq &input, CORBA::ULong i = 0; CORBA::Octet x = input[0]; output[i] = x * x * x; -#endif +#endif /* ACE_HAS_PURIFY == 1 */ } void @@ -349,7 +352,7 @@ Cubit_i::cube_many_sequence (const Cubit::many_seq & input, output->length (input.length ()); -#if 0 +#if (ACE_HAS_PURIFY == 1) for (CORBA::ULong i = 0; i < input.length (); ++i) { const Cubit::Many &in = input[i]; @@ -367,7 +370,7 @@ Cubit_i::cube_many_sequence (const Cubit::many_seq & input, out.o = in.o * in.o * in.o; out.s = in.s * in.s * in.s; out.l = in.l * in.l * in.l; -#endif +#endif /* ACE_HAS_PURIFY == 1 */ } void |