当前位置: 首页>>代码示例>>C++>>正文


C++ PD_TRACE_EXIT函数代码示例

本文整理汇总了C++中PD_TRACE_EXIT函数的典型用法代码示例。如果您正苦于以下问题:C++ PD_TRACE_EXIT函数的具体用法?C++ PD_TRACE_EXIT怎么用?C++ PD_TRACE_EXIT使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了PD_TRACE_EXIT函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: PD_TRACE_ENTRY

// PD_TRACE_DECLARE_FUNCTION ( SDB_OSSSK_ISCONN, "ossSocket::isConnected" )
BOOLEAN _ossSocket::isConnected ()
{
   INT32 rc = SDB_OK ;
   PD_TRACE_ENTRY ( SDB_OSSSK_ISCONN );

   if ( !_init )
   {
      PD_TRACE_EXIT ( SDB_OSSSK_ISCONN );
      return FALSE ;
   }

#if defined (_WINDOWS)
   rc = ::send ( _fd, "", 0, 0 ) ;
   if ( SOCKET_ERROR == rc )
#else
   rc = ::recv ( _fd, NULL, 0, MSG_DONTWAIT ) ;
   if ( 0 == rc )
#endif
   {
      PD_TRACE_EXIT ( SDB_OSSSK_ISCONN );
      return FALSE ;
   }
   PD_TRACE_EXIT ( SDB_OSSSK_ISCONN );
   return TRUE ;
}
开发者ID:BryanLance,项目名称:SequoiaDB,代码行数:26,代码来源:ossSocket.cpp

示例2: PD_TRACE_ENTRY

   // PD_TRACE_DECLARE_FUNCTION ( SDB__RTNJOBMGR_FINDJOB, "_rtnJobMgr::findJob" )
   _rtnBaseJob* _rtnJobMgr::findJob( EDUID eduID, INT32 *pResult )
   {
      PD_TRACE_ENTRY ( SDB__RTNJOBMGR_FINDJOB ) ;

      {
         ossScopedLock lock ( &_latch, SHARED ) ;
         std::map<EDUID, _rtnBaseJob*>::iterator it = _mapJobs.find( eduID ) ;
         if ( it != _mapJobs.end() )
         {
            PD_TRACE_EXIT ( SDB__RTNJOBMGR_FINDJOB ) ;
            return it->second ;
         }
      }

      INT32 res = SDB_OK ;
      {
         ossScopedLock lock ( &_latch, EXCLUSIVE ) ;
         std::map<EDUID, INT32>::iterator itRes = _mapResult.find( eduID ) ;
         if ( itRes != _mapResult.end() )
         {
            res = itRes->second ;
            _mapResult.erase( itRes ) ;
         }
      }
      if ( pResult )
      {
         *pResult = res ;
      }
      PD_TRACE_EXIT ( SDB__RTNJOBMGR_FINDJOB ) ;
      return NULL ;
   }
开发者ID:Andrew8305,项目名称:SequoiaDB,代码行数:32,代码来源:rtnBackgroundJobBase.cpp

示例3: PD_TRACE_ENTRY

 // PD_TRACE_DECLARE_FUNCTION ( SDB__PMDEDUCB_GETINFO, "_pmdEDUCB::getInfo" )
 const CHAR *_pmdEDUCB::getInfo ( EDU_INFO_TYPE type )
 {
    PD_TRACE_ENTRY ( SDB__PMDEDUCB_GETINFO );
    UINT32 buffSize = 0 ;
    CHAR *buff = _getBuffInfo ( type, buffSize ) ;
    if ( buff && buff[0] != 0 )
    {
       PD_TRACE_EXIT ( SDB__PMDEDUCB_GETINFO );
       return buff ;
    }
    PD_TRACE_EXIT ( SDB__PMDEDUCB_GETINFO );
    return NULL ;
 }
开发者ID:jasonsungblog,项目名称:SequoiaDB,代码行数:14,代码来源:pmdEDU.cpp

示例4: ossWalkStack

// PD_TRACE_DECLARE_FUNCTION ( SDB_OSSWLKSTK, "ossWalkStack" )
void ossWalkStack ( UINT32 framesToSkip,
                    OSS_INSTRUCTION_PTR * ppInstruction,
                    UINT32 framesRequested )
{
   PD_TRACE_ENTRY ( SDB_OSSWLKSTK );
   void * syms[ OSS_MAX_BACKTRACE_FRAMES_SUPPORTED + 1 ] = { 0 } ;
   UINT32 numFrames, framesOnStk, i ;

   if ( NULL != ppInstruction )
   {
      numFrames = OSS_MIN( framesToSkip + framesRequested,
                           OSS_MAX_BACKTRACE_FRAMES_SUPPORTED ) ;

      framesOnStk = (UINT32_64)backtrace( syms, numFrames ) ;

      for ( i = 0 ; i < framesRequested ; i++ )
      {
         ppInstruction[i] = NULL ;
      }
      for ( i = 0 ; i < ( framesOnStk - framesToSkip ) ; i++ )
      {
         ppInstruction[i] = ( OSS_INSTRUCTION_PTR )syms[ framesToSkip + i ] ;
      }
   }
   PD_TRACE_EXIT ( SDB_OSSWLKSTK );
}
开发者ID:SequoiaDB,项目名称:SequoiaDB,代码行数:27,代码来源:ossStackDump.cpp

示例5: ossDumpRegistersInfo

// PD_TRACE_DECLARE_FUNCTION ( SDB_OSSDUMPREGSINFO2, "ossDumpRegistersInfo" )
void ossDumpRegistersInfo( ossSignalContext pContext,
                           ossPrimitiveFileOp * trapFile )
{
   PD_TRACE_ENTRY ( SDB_OSSDUMPREGSINFO2 );
   greg_t * r ;

   if ( ( NULL != trapFile ) && trapFile->isValid() )
   {
      if ( NULL != pContext )
      {
         r = pContext->uc_mcontext.gregs ;
         trapFile->fWrite( "Registers:"OSS_NEWLINE
                           "eax %08X  ebx %08X  ecx %08X  edx %08X"OSS_NEWLINE
                           "ebp %08X  esp %08X  edi %08X  esi %08X"OSS_NEWLINE
                           "efl %08X  eip %08X"OSS_NEWLINE
                           "cs %04hx  ss %04hx  ds %04hx  "
                           "ss %04hx  fs %04hx  ds %04hx"OSS_NEWLINE,
                           r[REG_EAX], r[REG_EBX], r[REG_ECX], r[REG_EDX],
                           r[REG_EBP], r[REG_ESP], r[REG_EDI], r[REG_ESI],
                           r[REG_EFL], r[REG_EIP],
                           r[REG_CS], r[REG_SS], r[REG_DS],
                           r[REG_ES], r[REG_FS], r[REG_GS] ) ;
      }
      else
      {
         trapFile->Write (OSS_NEWLINE"Unable to dump registers"OSS_NEWLINE) ;
      }
   }
   PD_TRACE_EXIT ( SDB_OSSDUMPREGSINFO2 );
}
开发者ID:SequoiaDB,项目名称:SequoiaDB,代码行数:31,代码来源:ossStackDump.cpp

示例6: isSameFrom

   BOOLEAN isSameFrom( const qgmOPFieldVec & left, const qgmOPFieldVec & right )
   {
      PD_TRACE_ENTRY( SDB__QGMISSAMEFROM ) ;
      if ( left.size() != right.size() )
      {
         return FALSE ;
      }

      UINT32 i = 0 ;
      while ( i < left.size() )
      {
         qgmOpField field ;

         if ( ( !right[i].alias.empty() &&
                 left[i].value.attr() != right[i].alias ) ||
              ( right[i].alias.empty() &&
                left[i].value.attr() != right[i].value.attr() ) )
         {
            return FALSE ;
         }
         ++i ;
      }
      PD_TRACE_EXIT( SDB__QGMISSAMEFROM ) ;
      return TRUE ;
   }
开发者ID:Niwalker,项目名称:SequoiaDB,代码行数:25,代码来源:qgmUtil.cpp

示例7: PD_TRACE_ENTRY

   // PD_TRACE_DECLARE_FUNCTION ( SDB__DMSSU_TOTALDATASIZE, "_dmsStorageUnit::totalDataSize" )
   INT64 _dmsStorageUnit::totalDataSize( UINT32 type ) const
   {
      INT64 totalSize = 0 ;
      PD_TRACE_ENTRY ( SDB__DMSSU_TOTALDATASIZE ) ;

      if ( !_pDataSu || !_pIndexSu || !_pLobSu )
      {
         goto done ;
      }

      if ( type & DMS_SU_DATA )
      {
         totalSize += ( totalDataPages( DMS_SU_DATA ) <<
                        _pDataSu->pageSizeSquareRoot() ) ;
      }
      if ( type & DMS_SU_INDEX )
      {
         totalSize += ( totalDataPages( DMS_SU_INDEX ) <<
                        _pDataSu->pageSizeSquareRoot() ) ;
      }
      if ( ( type & DMS_SU_LOB ) && _pLobSu->isOpened() )
      {
         totalSize += _pLobSu->getLobData()->getDataSz() ;
      }

   done:
      PD_TRACE1 ( SDB__DMSSU_TOTALDATASIZE,
                  PD_PACK_LONG ( totalSize ) ) ;
      PD_TRACE_EXIT ( SDB__DMSSU_TOTALDATASIZE ) ;
      return totalSize ;
   }
开发者ID:Niwalker,项目名称:SequoiaDB,代码行数:32,代码来源:dmsStorageUnit.cpp

示例8: PD_TRACE_ENTRY

   // PD_TRACE_DECLARE_FUNCTION ( SDB__DPSRPCMGR__PSH2SNDQUEUE, "_dpsReplicaLogMgr::_push2SendQueue" )
   void _dpsReplicaLogMgr::_push2SendQueue( const dpsPageMeta &allocated )
   {
      PD_TRACE_ENTRY ( SDB__DPSRPCMGR__PSH2SNDQUEUE );

      SDB_ASSERT( allocated.valid(), "impossible" ) ;
      for ( UINT32 i = 0; i < allocated.pageNum; ++i )
      {
         _dpsLogPage *page = PAGE(allocated.beginSub + i) ;
         if ( 0 == page->getLastSize() )
         {
            if ( !_restoreFlag )
            {
               _queue.push ( page ) ;
               _queSize.inc() ;
            }
            else
            {
               _idleSize.add( page->getLength() );
               page->clear() ;
            }
         }
      }

      PD_TRACE_EXIT ( SDB__DPSRPCMGR__PSH2SNDQUEUE );
      return ;
   }
开发者ID:2015520,项目名称:SequoiaDB,代码行数:27,代码来源:dpsReplicaLogMgr.cpp

示例9: PD_TRACE_ENTRY

   // PD_TRACE_DECLARE_FUNCTION ( SDB_SCOPE_INIT, "Scope::init" )
   BOOLEAN Scope::init()
   {
      BOOLEAN ret = FALSE ;
      PD_TRACE_ENTRY ( SDB_SCOPE_INIT );

      SDB_ASSERT( globalEngine, "Script engine has not been initialized" );
      SDB_ASSERT( ! _context && ! _global, "Can't init a scope twice" );

      _context = JS_NewContext( globalEngine->_runtime, 1024 * 1024 ) ;
      VERIFY( _context );

      JS_SetOptions( _context, JSOPTION_VAROBJFIX );
      JS_SetVersion( _context, JSVERSION_LATEST );
      JS_SetErrorReporter( _context, sdbReportError );

      _global = JS_NewCompartmentAndGlobalObject( _context, &global_class, NULL );
      VERIFY( _global );

      VERIFY( JS_InitStandardClasses( _context, _global ) );

      VERIFY( InitDbClasses( _context, _global ) ) ;

      VERIFY ( SDB_OK == evalInitScripts ( this ) ) ;

      ret = TRUE ;

   done :
      PD_TRACE_EXIT ( SDB_SCOPE_INIT );
      return ret ;
   error :
      goto done ;
   }
开发者ID:Andrew8305,项目名称:SequoiaDB,代码行数:33,代码来源:engine.cpp

示例10: PD_TRACE_ENTRY

 void migMaster::popFromQueue( pmdEDUCB *eduCB,
                               UINT32 &offset, UINT32 &size,
                               UINT32 &line,   UINT32 &column )
 {
    PD_TRACE_ENTRY ( SDB__MIGLOADJSONPS__POPFROMQUEUE );
    BOOLEAN isPop = FALSE ;
    _dataQueue data ;
    do
    {
       isPop = _queue.timed_wait_and_pop ( data, 100 ) ;
    }while ( !isPop &&
             !eduCB->isInterrupted() &&
             !eduCB->isDisconnected() &&
             !eduCB->isForced() &&
             _sock->isConnected() ) ;
    if ( isPop )
    {
       offset = data.offset ;
       size   = data.size ;
       line   = data.line ;
       column = data.column ;
    }
    else
    {
       offset = 0 ;
       size   = 0 ;
       line   = 0 ;
       column = 0 ;
    }
    PD_TRACE_EXIT ( SDB__MIGLOADJSONPS__POPFROMQUEUE );
 }
开发者ID:Andrew8305,项目名称:SequoiaDB,代码行数:31,代码来源:migLoad.cpp

示例11: _pDataSu

   // PD_TRACE_DECLARE_FUNCTION ( SDB__DMSSU, "_dmsStorageUnit::_dmsStorageUnit" )
   _dmsStorageUnit::_dmsStorageUnit ( const CHAR *pSUName, UINT32 sequence,
                                      INT32 pageSize, INT32 lobPageSize )
   :_apm(this),
    _pDataSu( NULL ),
    _pIndexSu( NULL ),
    _pLobSu( NULL )
   {
      PD_TRACE_ENTRY ( SDB__DMSSU ) ;
      SDB_ASSERT ( pSUName, "name can't be null" ) ;

      if ( 0 == pageSize )
      {
         pageSize = DMS_PAGE_SIZE_DFT ;
      }

      if ( 0 == lobPageSize )
      {
         lobPageSize = DMS_DEFAULT_LOB_PAGE_SZ ;
      }

      CHAR dataFileName[DMS_SU_FILENAME_SZ + 1] = {0} ;
      CHAR idxFileName[DMS_SU_FILENAME_SZ + 1] = {0} ;

      _storageInfo._pageSize = pageSize ;
      _storageInfo._lobdPageSize = lobPageSize ;
      ossStrncpy( _storageInfo._suName, pSUName, DMS_SU_NAME_SZ ) ;
      _storageInfo._suName[DMS_SU_NAME_SZ] = 0 ;
      _storageInfo._sequence = sequence ;
      _storageInfo._secretValue = ossPack32To64( (UINT32)time(NULL),
                                                 (UINT32)(ossRand()*239641) ) ;

      ossSnprintf( dataFileName, DMS_SU_FILENAME_SZ, "%s.%d.%s",
                   _storageInfo._suName, sequence, DMS_DATA_SU_EXT_NAME ) ;
      ossSnprintf( idxFileName, DMS_SU_FILENAME_SZ, "%s.%d.%s",
                   _storageInfo._suName, sequence, DMS_INDEX_SU_EXT_NAME ) ;

      _pDataSu = SDB_OSS_NEW dmsStorageData( dataFileName, &_storageInfo ) ;
      if ( _pDataSu )
      {
         _pIndexSu = SDB_OSS_NEW dmsStorageIndex( idxFileName, &_storageInfo,
                                                  _pDataSu ) ;
      }

      if ( NULL != _pDataSu && NULL != _pIndexSu )
      {
         ossMemset( dataFileName, 0, sizeof( dataFileName ) ) ;
         ossMemset( idxFileName, 0 , sizeof( idxFileName ) ) ;
         ossSnprintf( dataFileName, DMS_SU_FILENAME_SZ, "%s.%d.%s",
                      _storageInfo._suName, _storageInfo._sequence,
                      DMS_LOB_META_SU_EXT_NAME ) ;
         ossSnprintf( idxFileName, DMS_SU_FILENAME_SZ, "%s.%d.%s",
                      _storageInfo._suName, _storageInfo._sequence,
                      DMS_LOB_DATA_SU_EXT_NAME ) ;

         _pLobSu = SDB_OSS_NEW dmsStorageLob( dataFileName, idxFileName,
                                              &_storageInfo, _pDataSu ) ;
      }

      PD_TRACE_EXIT ( SDB__DMSSU ) ;
   }
开发者ID:Niwalker,项目名称:SequoiaDB,代码行数:61,代码来源:dmsStorageUnit.cpp

示例12: PD_TRACE_ENTRY

 // PD_TRACE_DECLARE_FUNCTION ( SDB__DPSLGWRAPP_COMMITLSN, "_dpsLogWrapper::commitLsn" )
 DPS_LSN _dpsLogWrapper::commitLsn()
 {
    PD_TRACE_ENTRY ( SDB__DPSLGWRAPP_COMMITLSN ) ;
    DPS_LSN lsn = _buf.commitLsn() ;
    PD_TRACE_EXIT( SDB__DPSLGWRAPP_COMMITLSN ) ;
    return lsn ;
 }
开发者ID:SequoiaDB,项目名称:SequoiaDB,代码行数:8,代码来源:dpsLogWrapper.cpp

示例13: PD_TRACE_ENTRY

   const MsgRouteID &_clsSrcSelector::selectPrimary ( UINT32 groupID,
                                         MSG_ROUTE_SERVICE_TYPE type )
   {
      PD_TRACE_ENTRY ( SDB__CLSSRCSL_SLPMY ) ;
      if ( _noRes > CLS_FS_NORES_TIMEOUT )
      {
         _src.value = MSG_INVALID_ROUTEID ;
      }

      if ( MSG_INVALID_ROUTEID != _src.value )
      {
         goto done ;
      }
      {
         _noRes  = 0 ;

         INT32 rc = SDB_OK ;

         rc = sdbGetShardCB()->syncUpdateGroupInfo( groupID ) ;
         if ( SDB_OK != rc )
         {
            goto done ;
         }

         _nodeMgrAgent->lock_r () ;
         _nodeMgrAgent->groupPrimaryNode( groupID, _src, type ) ;
         _nodeMgrAgent->release_r () ;
      }

   done:
      PD_TRACE_EXIT ( SDB__CLSSRCSL_SLPMY ) ;
      return _src ;
   }
开发者ID:2015520,项目名称:SequoiaDB,代码行数:33,代码来源:clsSrcSelector.cpp

示例14: SDB_ASSERT

// PD_TRACE_DECLARE_FUNCTION ( SDB__OSSSK__OSSSK3, "_ossSocket::_ossSocket" )
_ossSocket::_ossSocket ( SOCKET *sock, INT32 timeoutMilli )
{
   SDB_ASSERT ( sock, "Input sock is NULL" ) ;
   INT32 rc = SDB_OK ;
   PD_TRACE_ENTRY ( SDB__OSSSK__OSSSK3 );
   _fd = *sock ;
   _init = TRUE ;
   _timeout = timeoutMilli ;
   _closeWhenDestruct = TRUE ;
   _addressLen = sizeof ( _sockAddress ) ;

   ossMemset ( &_peerAddress, 0, sizeof(sockaddr_in) ) ;
   _peerAddressLen = sizeof ( _peerAddress ) ;

   ossInitSocket() ;

   rc = getsockname ( _fd, (sockaddr*)&_sockAddress, &_addressLen ) ;
   if ( rc )
   {
      PD_LOG ( PDERROR, "Failed to getsockname from socket %d", _fd ) ;
      _init = FALSE ;
   }
   else
   {
      rc = getpeername ( _fd, (sockaddr*)&_peerAddress, &_peerAddressLen ) ;
      if ( rc )
      {
         PD_LOG ( PDERROR, "Failed to getpeername from socket %d", _fd ) ;
      }
   }
   setTimeout ( _timeout ) ;
   PD_TRACE_EXIT ( SDB__OSSSK__OSSSK3 );
}
开发者ID:BryanLance,项目名称:SequoiaDB,代码行数:34,代码来源:ossSocket.cpp

示例15: ossSymInitialize

// PD_TRACE_DECLARE_FUNCTION ( SDB_OSSSYMINIT, "ossSymInitialize" )
UINT32 ossSymInitialize( HANDLE phProcess,
                         CHAR *  pUserSearchPath,
                         BOOLEAN bInvadeProcess )
{
   PD_TRACE_ENTRY ( SDB_OSSSYMINIT );
   static BOOLEAN  s_bSymInitialized = false ;
   UINT32 rc = ERROR_SUCCESS ;

   WaitForSingleObject( ossGetSysMutexHandle( _SymInitialize ), INFINITE ) ;
   if ( ! s_bSymInitialized )
   {
      if ( SymInitialize( phProcess, pUserSearchPath, bInvadeProcess ) )
      {
         s_bSymInitialized = TRUE ;
      }
      else
      {
         rc = GetLastError() ;
      }
   }
   ReleaseMutex ( ossGetSysMutexHandle( _SymInitialize ) ) ;

   if ( ERROR_SUCCESS != rc )
   {
      SetLastError( rc ) ;
   }
   PD_TRACE1 ( SDB_OSSSYMINIT, PD_PACK_UINT(rc) );
   PD_TRACE_EXIT ( SDB_OSSSYMINIT );
   return rc ;
}
开发者ID:SequoiaDB,项目名称:SequoiaDB,代码行数:31,代码来源:ossStackDump.cpp


注:本文中的PD_TRACE_EXIT函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。