Esempio n. 1
0
void __builtin_vec_delete ( void* p )
{
   MALLOC_TRACE("__builtin_vec_delete[simd=%d](%p)\n", 
                (UInt)VG_(is_running_on_simd_CPU)(), p );
   if (p == NULL) 
      return;
   if (VG_(is_running_on_simd_CPU)()) {
      (void)VALGRIND_NON_SIMD_CALL1( SK_(__builtin_vec_delete), p );
   } else {
      VG_(arena_free)(VG_AR_CLIENT, p);
   }
}
Esempio n. 2
0
void* __builtin_vec_new ( Int n )
{
   void* v;

   MALLOC_TRACE("__builtin_vec_new[simd=%d](%d)", 
                (UInt)VG_(is_running_on_simd_CPU)(), n );
   MAYBE_SLOPPIFY(n);

   if (VG_(is_running_on_simd_CPU)()) {
      v = (void*)VALGRIND_NON_SIMD_CALL1( SK_(__builtin_vec_new), n );
   } else if (VG_(clo_alignment) != 4) {
      v = VG_(arena_malloc_aligned)(VG_AR_CLIENT, VG_(clo_alignment), n);
   } else {
      v = VG_(arena_malloc)(VG_AR_CLIENT, n);
   }
   MALLOC_TRACE(" = %p\n", v );
   return v;
}
Esempio n. 3
0
void
Backdoor_HbIn(Backdoor_proto_hb *myBp) // IN/OUT
{
   ASSERT(myBp);

   myBp->in.ax.word = BDOOR_MAGIC;
   myBp->in.dx.halfs.low = BDOORHB_PORT;

   BACKDOOR_LOG(("Backdoor_HbIn: before "));
   BACKDOOR_LOG_HB_PROTO_STRUCT(myBp);

#ifdef USE_VALGRIND
   VALGRIND_NON_SIMD_CALL1(BackdoorHbInValgrind, myBp);
#else
   BackdoorHbIn(myBp);
#endif

   BACKDOOR_LOG(("Backdoor_HbIn: after "));
   BACKDOOR_LOG_HB_PROTO_STRUCT(myBp);
}