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


C++ CALL_FN_W_WW函数代码示例

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


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

示例1: PTH_FUNC

// pthread_rwlock_init
PTH_FUNC(int, pthreadZurwlockZuinit, // pthread_rwlock_init
              pthread_rwlock_t *rwl,
              pthread_rwlockattr_t* attr)
{
   int    ret;
   OrigFn fn;
   VALGRIND_GET_ORIG_FN(fn);
   if (TRACE_PTH_FNS) {
      fprintf(stderr, "<< pthread_rwl_init %p", rwl); fflush(stderr);
   }

   CALL_FN_W_WW(ret, fn, rwl,attr);

   if (ret == 0 /*success*/) {
      DO_CREQ_v_W(_VG_USERREQ__HG_PTHREAD_RWLOCK_INIT_POST,
                  pthread_rwlock_t*,rwl);
   } else { 
      DO_PthAPIerror( "pthread_rwlock_init", ret );
   }

   if (TRACE_PTH_FNS) {
      fprintf(stderr, " :: rwl_init -> %d >>\n", ret);
   }
   return ret;
}
开发者ID:jrmuizel,项目名称:chronicle-recorder,代码行数:26,代码来源:hg_intercepts.c

示例2: I_WRAP_SONAME_FNNAME_ZZ

// TODO: Can we do additional checks?
CUresult I_WRAP_SONAME_FNNAME_ZZ(libcudaZdsoZa, cuArrayGetDescriptor)(CUDA_ARRAY_DESCRIPTOR *pArrayDescriptor, CUarray hArray) {
   OrigFn         fn;
   CUresult       result;
   CUcontext      ctx = NULL;
   cgCtxListType  *ctxNode;
   cgArrListType  *node;
   
   VALGRIND_GET_ORIG_FN(fn);
   cgLock();
   CALL_FN_W_WW(result, fn, pArrayDescriptor, hArray);
   
   // Determine context of current thread ..
   cgGetCtx(&ctx);
   // .. locate the respective ctx node ..
   ctxNode = cgFindCtx(ctx);
   // .. and finally locate the array in the context's list of arrays.
   node = cgFindArr(ctxNode, hArray);
   
   if (result == CUDA_SUCCESS && !node) {
      VALGRIND_PRINTF("cuArrayGetDescriptor returned successfully, but array not found\n");
      VALGRIND_PRINTF_BACKTRACE("   in cudagrind's internal list. Reason: Unknown\n");
   } else if (result != CUDA_SUCCESS && node) {
      VALGRIND_PRINTF("cuArrayGetDescriptor returned with error code: %d,\n", result);
      VALGRIND_PRINTF_BACKTRACE("   but array is found in cudagrind's internal list.\n");
   } else if (result != CUDA_SUCCESS) {
      VALGRIND_PRINTF("cuArrayGetDescriptor returned with error code: %d,\n", result);
      VALGRIND_PRINTF_BACKTRACE("   possible reason: Wrong context or array not previously created.\n");
   }
   
   cgUnlock();
   return result;
}
开发者ID:Grindland,项目名称:Cudagrind,代码行数:33,代码来源:cuArrayGetDescriptor.c

示例3: pthread_rwlock_init_intercept

static __always_inline
int pthread_rwlock_init_intercept(pthread_rwlock_t* rwlock,
                                  const pthread_rwlockattr_t* attr)
{
   int   ret;
   OrigFn fn;
   VALGRIND_GET_ORIG_FN(fn);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__PRE_RWLOCK_INIT,
                                   rwlock, 0, 0, 0, 0);
   CALL_FN_W_WW(ret, fn, rwlock, attr);
   return ret;
}
开发者ID:Zekom,项目名称:valgrind,代码行数:12,代码来源:drd_pthread_intercepts.c

示例4: I_WRAP_SONAME_FNNAME_ZU

UInt I_WRAP_SONAME_FNNAME_ZU(NONE,fn_2) ( UInt a1, UInt a2 )
{
   UInt r;
   void* fn;
   VALGRIND_GET_ORIG_FN(fn);
   printf("fn_2  wrapper pre ( %d, %d )\n", (int)a1, (int)a2);
   CALL_FN_W_WW(r, fn, a1, a2);
   printf("fn_2  wrapper post1 = %d\n", (int)r);
   CALL_FN_v_WW(fn, a1, a2);
   printf("fn_2  wrapper post2 = %d\n", (int)r);
   return r;
}
开发者ID:svn2github,项目名称:valgrind-3,代码行数:12,代码来源:wrap6.c

示例5: PTH_FUNC

// pthread_spin_init
PTH_FUNC(int, pthreadZuspinZuinit, // pthread_spin_init
         pthread_spinlock_t *spinlock,
         int pshared)
{
    int ret;
    int res;
    OrigFn fn;
    VALGRIND_GET_ORIG_FN(fn);
    VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__SPIN_INIT_OR_UNLOCK,
                               spinlock, mutex_type_spinlock, 0, 0, 0);
    CALL_FN_W_WW(ret, fn, spinlock, pshared);
    return ret;
}
开发者ID:svn2github,项目名称:valgrind-3,代码行数:14,代码来源:drd_pthread_intercepts.c

示例6: sem_timedwait_intercept

static __always_inline
int sem_timedwait_intercept(sem_t *sem, const struct timespec *abs_timeout)
{
   int   ret;
   OrigFn fn;
   VALGRIND_GET_ORIG_FN(fn);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__PRE_SEM_WAIT,
                                   sem, 0, 0, 0, 0);
   CALL_FN_W_WW(ret, fn, sem, abs_timeout);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__POST_SEM_WAIT,
                                   sem, ret == 0, 0, 0, 0);
   return ret;
}
开发者ID:Zekom,项目名称:valgrind,代码行数:13,代码来源:drd_pthread_intercepts.c

示例7: QT4CORE_FUNC

// QMutex::QMutex(RecursionMode) -- _ZN6QMutexC1ENS_13RecursionModeE,
QT4CORE_FUNC(void, _ZN6QMutexC1ENS_13RecursionModeE,
             void* mutex,
             qt_mutex_mode mode)
{
   int    ret;
   OrigFn fn;
   VALGRIND_GET_ORIG_FN(fn);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__PRE_MUTEX_INIT,
                                   mutex, qt_to_drd_mutex_type(mode), 0, 0, 0);
   CALL_FN_W_WW(ret, fn, mutex, mode);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__POST_MUTEX_INIT,
                                   mutex, 0, 0, 0, 0);
}
开发者ID:AboorvaDevarajan,项目名称:Valgrind-tool,代码行数:14,代码来源:drd_qtcore_intercepts.c

示例8: pthread_spin_init_intercept

static __always_inline
int pthread_spin_init_intercept(pthread_spinlock_t *spinlock, int pshared)
{
   int ret;
   OrigFn fn;
   VALGRIND_GET_ORIG_FN(fn);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__PRE_SPIN_INIT_OR_UNLOCK,
                                   spinlock, 0, 0, 0, 0);
   CALL_FN_W_WW(ret, fn, spinlock, pshared);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__POST_SPIN_INIT_OR_UNLOCK,
                                   spinlock, 0, 0, 0, 0);
   return ret;
}
开发者ID:Zekom,项目名称:valgrind,代码行数:13,代码来源:drd_pthread_intercepts.c

示例9: GOMP_FUNC

GOMP_FUNC(void, gompZubarrierZureinit, // gomp_barrier_reinit
          gomp_barrier_t* barrier, unsigned count)
{
    int    ret;
    int    res;
    OrigFn fn;
    VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_BARRIER_INIT,
                               barrier, gomp_barrier, count, 1, 0);
    VALGRIND_GET_ORIG_FN(fn);
    CALL_FN_W_WW(ret, fn, barrier, count);
    VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_BARRIER_INIT,
                               barrier, gomp_barrier, 0, 0, 0);
}
开发者ID:svn2github,项目名称:valgrind-3,代码行数:13,代码来源:drd_gomp_intercepts.c

示例10: pthread_cond_wait_intercept

static __always_inline
int pthread_cond_wait_intercept(pthread_cond_t *cond, pthread_mutex_t *mutex)
{
   int   ret;
   OrigFn fn;
   VALGRIND_GET_ORIG_FN(fn);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__PRE_COND_WAIT,
                                   cond, mutex, DRD_(mutex_type)(mutex), 0, 0);
   CALL_FN_W_WW(ret, fn, cond, mutex);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__POST_COND_WAIT,
                                   cond, mutex, 1, 0, 0);
   return ret;
}
开发者ID:Zekom,项目名称:valgrind,代码行数:13,代码来源:drd_pthread_intercepts.c

示例11: pthread_cond_init_intercept

static __always_inline
int pthread_cond_init_intercept(pthread_cond_t* cond,
                                const pthread_condattr_t* attr)
{
   int ret;
   OrigFn fn;
   VALGRIND_GET_ORIG_FN(fn);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__PRE_COND_INIT,
                                   cond, 0, 0, 0, 0);
   CALL_FN_W_WW(ret, fn, cond, attr);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__POST_COND_INIT,
                                   cond, 0, 0, 0, 0);
   return ret;
}
开发者ID:Zekom,项目名称:valgrind,代码行数:14,代码来源:drd_pthread_intercepts.c

示例12: VG_WRAP_FUNCTION_ZZ

void* VG_WRAP_FUNCTION_ZZ(dyld, ZuZZN4dyld18fastBindLazySymbolEPP11ImageLoaderm)
     (void** imageLoaderCache, uintptr_t lazyBindingInfoOffset)
{
   void* res;
   OrigFn fn;

   VALGRIND_GET_ORIG_FN(fn);

   ANNOTATE_IGNORE_READS_AND_WRITES_BEGIN();
   CALL_FN_W_WW(res, fn, imageLoaderCache, lazyBindingInfoOffset);
   ANNOTATE_IGNORE_READS_AND_WRITES_END();

   return res;
}
开发者ID:qtekfun,项目名称:htcDesire820Kernel,代码行数:14,代码来源:drd_darwin_intercepts.c

示例13: pthread_rwlock_timedwrlock_intercept

static __always_inline
int pthread_rwlock_timedwrlock_intercept(pthread_rwlock_t* rwlock,
                                         const struct timespec *timeout)
{
   int   ret;
   OrigFn fn;
   VALGRIND_GET_ORIG_FN(fn);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__PRE_RWLOCK_WRLOCK,
                                   rwlock, 0, 0, 0, 0);
   CALL_FN_W_WW(ret, fn, rwlock, timeout);
   VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__POST_RWLOCK_WRLOCK,
                                   rwlock, ret == 0, 0, 0, 0);
   return ret;
}
开发者ID:AboorvaDevarajan,项目名称:valgrind,代码行数:14,代码来源:drd_pthread_intercepts.c

示例14: I_WRAP_SONAME_FNNAME_ZU

long I_WRAP_SONAME_FNNAME_ZU(NONE,foo) (long x, long y)
{

	OrigFn fn;
	VALGRIND_GET_ORIG_FN(fn);

	printf("WRAPPER: foo(%ld, %ld);\n", x, y);

	long result;
	CALL_FN_W_WW(result, fn, x,y);
	printf("WRAPPER: return %ld;\n", result);

	return result;
}
开发者ID:LeonardKoenig,项目名称:valgrind_hooking,代码行数:14,代码来源:hook.c

示例15: PTH_FUNC

// pthread_rwlock_init
PTH_FUNC(int,
         pthreadZurwlockZuinitZa, // pthread_rwlock_init*
         pthread_rwlock_t* rwlock,
         const pthread_rwlockattr_t* attr)
{
   int   ret;
   int   res;
   OrigFn fn;
   VALGRIND_GET_ORIG_FN(fn);
   VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_RWLOCK_INIT,
                              rwlock, 0, 0, 0, 0);
   CALL_FN_W_WW(ret, fn, rwlock, attr);
   return ret;
}
开发者ID:svn2github,项目名称:valgrind-3,代码行数:15,代码来源:drd_pthread_intercepts.c


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