summaryrefslogtreecommitdiff
path: root/testtools/source/performance
diff options
context:
space:
mode:
Diffstat (limited to 'testtools/source/performance')
-rw-r--r--testtools/source/performance/pseudo.cxx22
-rw-r--r--testtools/source/performance/ubobject.cxx28
-rw-r--r--testtools/source/performance/ubtest.cxx42
3 files changed, 46 insertions, 46 deletions
diff --git a/testtools/source/performance/pseudo.cxx b/testtools/source/performance/pseudo.cxx
index 8f81138fb4f2..2fb9730c408b 100644
--- a/testtools/source/performance/pseudo.cxx
+++ b/testtools/source/performance/pseudo.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -46,10 +46,10 @@ namespace pseudo_uno
//==================================================================================================
struct pseudo_Mapping : public uno_Mapping
{
- oslInterlockedCount nRef;
+ oslInterlockedCount nRef;
- uno_ExtEnvironment * pFrom;
- uno_ExtEnvironment * pTo;
+ uno_ExtEnvironment * pFrom;
+ uno_ExtEnvironment * pTo;
pseudo_Mapping( uno_ExtEnvironment * pFrom_, uno_ExtEnvironment * pTo_ );
~pseudo_Mapping();
@@ -58,13 +58,13 @@ struct pseudo_Mapping : public uno_Mapping
//==== a uno pseudo proxy =============================================================================
struct pseudo_unoInterfaceProxy : public uno_Interface
{
- oslInterlockedCount nRef;
- pseudo_Mapping * pPseudoMapping;
+ oslInterlockedCount nRef;
+ pseudo_Mapping * pPseudoMapping;
// mapping information
- uno_Interface * pUnoI; // wrapped interface
- typelib_InterfaceTypeDescription * pTypeDescr;
- OUString oid;
+ uno_Interface * pUnoI; // wrapped interface
+ typelib_InterfaceTypeDescription * pTypeDescr;
+ OUString oid;
// ctor
inline pseudo_unoInterfaceProxy( pseudo_Mapping * pPseudoMapping_,
@@ -255,7 +255,7 @@ extern "C" void SAL_CALL uno_ext_getMapping(
if (ppMapping && pFrom && pTo && pFrom->pExtEnv && pTo->pExtEnv)
{
uno_Mapping * pMapping = 0;
-
+
if (0 == rtl_ustr_ascii_compare( pFrom->pTypeName->buffer, UNO_LB_UNO ) &&
0 == rtl_ustr_ascii_compare( pTo->pTypeName->buffer, UNO_LB_UNO ))
{
@@ -267,7 +267,7 @@ extern "C" void SAL_CALL uno_ext_getMapping(
(uno_Environment *)pTo->pExtEnv,
aMappingPurpose.pData );
}
-
+
if (*ppMapping)
(*(*ppMapping)->release)( *ppMapping );
*ppMapping = pMapping;
diff --git a/testtools/source/performance/ubobject.cxx b/testtools/source/performance/ubobject.cxx
index 15397de078d1..72bc8cc36c1c 100644
--- a/testtools/source/performance/ubobject.cxx
+++ b/testtools/source/performance/ubobject.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -48,8 +48,8 @@ using namespace com::sun::star::lang;
using namespace com::sun::star::registry;
using namespace com::sun::star::test::performance;
-#define SERVICENAME "com.sun.star.test.performance.PerformanceTestObject"
-#define IMPLNAME "com.sun.star.comp.performance.PerformanceTestObject"
+#define SERVICENAME "com.sun.star.test.performance.PerformanceTestObject"
+#define IMPLNAME "com.sun.star.comp.performance.PerformanceTestObject"
namespace benchmark_object
{
@@ -73,7 +73,7 @@ class ServiceImpl
RuntimeException _aDummyRE;
sal_Int32 _nRef;
-
+
public:
ServiceImpl()
: _nRef( 0 )
@@ -81,7 +81,7 @@ public:
ServiceImpl( const Reference< XMultiServiceFactory > & xMgr )
: _nRef( 0 )
{}
-
+
// XInterface
virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type& aType ) throw(::com::sun::star::uno::RuntimeException)
{
@@ -108,7 +108,7 @@ public:
{ osl_incrementInterlockedCount( &_nRef ); }
virtual void SAL_CALL release() throw()
{ if (! osl_decrementInterlockedCount( &_nRef )) delete this; }
-
+
// XServiceInfo
virtual OUString SAL_CALL getImplementationName() throw (RuntimeException);
virtual sal_Bool SAL_CALL supportsService( const OUString & rServiceName ) throw (RuntimeException);
@@ -151,8 +151,8 @@ public:
{ return _aDummyStruct; }
virtual void SAL_CALL setStruct_attr( const ::com::sun::star::test::performance::ComplexTypes& _attributestruct ) throw(::com::sun::star::uno::RuntimeException)
{}
-
- // Methods
+
+ // Methods
virtual sal_Int32 SAL_CALL getLong() throw(::com::sun::star::uno::RuntimeException)
{ return 0; }
virtual void SAL_CALL setLong( sal_Int32 _long ) throw(::com::sun::star::uno::RuntimeException)
@@ -184,12 +184,12 @@ public:
virtual Sequence< Reference< XInterface > > SAL_CALL getSequence() throw(::com::sun::star::uno::RuntimeException)
{ return _aDummySequence; }
virtual void SAL_CALL setSequence( const Sequence< Reference< XInterface > >& _sequence ) throw(::com::sun::star::uno::RuntimeException)
- {}
+ {}
virtual ComplexTypes SAL_CALL getStruct() throw(::com::sun::star::uno::RuntimeException)
{ return _aDummyStruct; }
virtual void SAL_CALL setStruct( const ::com::sun::star::test::performance::ComplexTypes& c ) throw(::com::sun::star::uno::RuntimeException)
{}
-
+
virtual void SAL_CALL async() throw(::com::sun::star::uno::RuntimeException)
{}
virtual void SAL_CALL sync() throw(::com::sun::star::uno::RuntimeException)
@@ -273,7 +273,7 @@ sal_Bool SAL_CALL component_writeInfo(
reinterpret_cast< XRegistryKey * >( pRegistryKey )->createKey(
OUString( RTL_CONSTASCII_USTRINGPARAM("/" IMPLNAME "/UNO/SERVICES") ) ) );
xNewKey->createKey( OUString( RTL_CONSTASCII_USTRINGPARAM(SERVICENAME) ) );
-
+
return sal_True;
}
catch (InvalidRegistryException &)
@@ -288,7 +288,7 @@ void * SAL_CALL component_getFactory(
const sal_Char * pImplName, void * pServiceManager, void * pRegistryKey )
{
void * pRet = 0;
-
+
if (pServiceManager && rtl_str_compare( pImplName, IMPLNAME ) == 0)
{
Reference< XSingleServiceFactory > xFactory( createSingleFactory(
@@ -296,14 +296,14 @@ void * SAL_CALL component_getFactory(
OUString( RTL_CONSTASCII_USTRINGPARAM(IMPLNAME) ),
benchmark_object::ServiceImpl_create,
benchmark_object::getSupportedServiceNames() ) );
-
+
if (xFactory.is())
{
xFactory->acquire();
pRet = xFactory.get();
}
}
-
+
return pRet;
}
}
diff --git a/testtools/source/performance/ubtest.cxx b/testtools/source/performance/ubtest.cxx
index 0347612fa18c..4eaadf24bec2 100644
--- a/testtools/source/performance/ubtest.cxx
+++ b/testtools/source/performance/ubtest.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -83,8 +83,8 @@ using namespace com::sun::star::bridge;
using namespace com::sun::star::container;
using namespace com::sun::star::test::performance;
-#define SERVICENAME "com.sun.star.test.performance.PerformanceTest"
-#define IMPLNAME "com.sun.star.comp.performance.PerformanceTest"
+#define SERVICENAME "com.sun.star.test.performance.PerformanceTest"
+#define IMPLNAME "com.sun.star.comp.performance.PerformanceTest"
namespace benchmark_test
{
@@ -94,18 +94,18 @@ static inline sal_uInt32 getSystemTicks()
#ifdef SAL_W32
return (sal_uInt32)GetTickCount();
#else // only UNX supported for now
- static sal_uInt32 nImplTicksPerSecond = 0;
- static double dImplTicksPerSecond;
- static double dImplTicksULONGMAX;
+ static sal_uInt32 nImplTicksPerSecond = 0;
+ static double dImplTicksPerSecond;
+ static double dImplTicksULONGMAX;
- struct tms aTms;
+ struct tms aTms;
sal_uInt32 nTicks = (sal_uInt32)times( &aTms );
if ( !nImplTicksPerSecond )
{
nImplTicksPerSecond = sysconf(_SC_CLK_TCK);
dImplTicksPerSecond = nImplTicksPerSecond;
- dImplTicksULONGMAX = (double)(sal_uInt32)ULONG_MAX;
+ dImplTicksULONGMAX = (double)(sal_uInt32)ULONG_MAX;
}
double fTicks = nTicks;
@@ -368,10 +368,10 @@ static void createInstance( Reference< T > & rxOut,
OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.bridge.UnoUrlResolver") ),
xMgr, Reference< XRegistryKey >() ) ) );
// java loader
-// xSet->insert( makeAny( loadLibComponentFactory(
-// OUString( RTL_CONSTASCII_USTRINGPARAM("javaloader") ),
-// OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.stoc.JavaComponentLoader") ),
-// xMgr, Reference< XRegistryKey >() ) ) );
+// xSet->insert( makeAny( loadLibComponentFactory(
+// OUString( RTL_CONSTASCII_USTRINGPARAM("javaloader") ),
+// OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.stoc.JavaComponentLoader") ),
+// xMgr, Reference< XRegistryKey >() ) ) );
}
s_bSet = sal_True;
}
@@ -522,8 +522,8 @@ Reference< XInterface > TestImpl::resolveObject( const OUString & rUnoUrl )
//==================================================================================================
class TimeEntry
{
- sal_Int64 nLoop;
- sal_uInt32 nTicks;
+ sal_Int64 nLoop;
+ sal_uInt32 nTicks;
public:
TimeEntry()
@@ -558,7 +558,7 @@ typedef std::map< std::string, TimeEntry > t_TimeEntryMap;
//==================================================================================================
struct TimingSheet
{
- t_TimeEntryMap _entries;
+ t_TimeEntryMap _entries;
void insert( const sal_Char * pText, sal_Int64 nLoop, sal_uInt32 nTicks );
};
//__________________________________________________________________________________________________
@@ -922,12 +922,12 @@ static void benchmark(
rSheet.insert( "Ad: set struct attribute", nLoop, tEnd - tStart );
// load
-// i = nLoop;
-// tStart = getSystemTicks();
-// while (i--)
-// xBench->setSequence( aSeq );
-// tEnd = getSystemTicks();
-// rSheet.insert( "transfer of exisiting objects", nLoop, tEnd - tStart );
+// i = nLoop;
+// tStart = getSystemTicks();
+// while (i--)
+// xBench->setSequence( aSeq );
+// tEnd = getSystemTicks();
+// rSheet.insert( "transfer of exisiting objects", nLoop, tEnd - tStart );
// exceptions
i = nLoop;