core/x86/interp.c
/* Client routine to decode instructions at an arbitrary app address,
 * following all the rules that DynamoRIO follows internally for
 * terminating basic blocks.  Note that DynamoRIO does not validate
 * that start_pc is actually the first instruction of a basic block.
 * \note Caller is reponsible for freeing the list and its instrs!
 */
Client routine to decode instructions at an arbitrary app address,
following all the rules that DynamoRIO follows internally for
terminating basic blocks.  Note that DynamoRIO does not validate
that start_pc is actually the first instruction of a basic block.
\note Caller is reponsible for freeing the list and its instrs!
Client routine to decode instructions at an arbitrary app address following all the rules that DynamoRIO follows internally for terminating basic blocks . Note that DynamoRIO does not validate that start_pc is actually the first instruction of a basic block . \ note Caller is reponsible for freeing the list and its instrs!
instrlist_t *
decode_as_bb(void *drcontext, byte *start_pc)
{
    build_bb_t bb;
# ifdef WINDOWS
    byte *real_pc;
    if (is_intercepted_app_pc((app_pc)start_pc, &real_pc))
        start_pc = real_pc;
# endif
    init_build_bb(&bb, start_pc, false , 
                  false , false ,
                  true ,
                  INVALID_FILE, 0 , NULL );
    build_bb_ilist((dcontext_t *)drcontext, &bb);
    return bb.ilist;
}
instrlist_t * decode_as_bb ( void * drcontext , byte * start_pc ) { build_bb_t bb ; # ifdef WINDOWS byte * real_pc ; if ( is_intercepted_app_pc ( ( app_pc ) start_pc , & real_pc ) ) start_pc = real_pc ; # endif init_build_bb ( & bb , start_pc , false , false , false , true , INVALID_FILE , 0 , NULL ) ; build_bb_ilist ( ( dcontext_t * ) drcontext , & bb ) ; return bb . ilist ; }
Client routine to decode instructions at an arbitrary app address,
 following all the rules that DynamoRIO follows internally for
 terminating basic blocks.
Client routine to decode instructions at an arbitrary app address following all the rules that DynamoRIO follows internally for terminating basic blocks .
/* Case 10009: When we hook ntdll functions, we hide the jump to
     * the interception buffer from the client BB callback.  If the
     * client asks to decode that address here, we need to decode the
     * instructions in the interception buffer instead so that we
     * again hide our hooking.
     * We will have the jmp from the buffer back to after the hooked
     * app code visible to the client (just like it is for the
     * real bb built there, so at least we're consistent).
     */ /*not interp*/ /*not for cache*/ /*do not mangle*/ /* translation; xref case 10070 where this
                        * currently turns on full decode; today we
                        * provide no way to turn that off, as IR
                        * expansion routines are not exported (PR 200409). */ /*no pre flags*/ /*no overlap*/