1/* 2 * CDDL HEADER START 3 * 4 * The contents of this file are subject to the terms of the 5 * Common Development and Distribution License (the "License"). 6 * You may not use this file except in compliance with the License. 7 * 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE --- 22 unchanged lines hidden (view full) --- 31#include <errno.h> 32#include <unistd.h> 33#include <dt_impl.h> 34#include <assert.h> 35#if defined(sun) 36#include <alloca.h> 37#else 38#include <sys/sysctl.h> |
39#include <libproc_compat.h> |
40#endif 41#include <limits.h> 42 43#define DTRACE_AHASHSIZE 32779 /* big 'ol prime */ 44 45/* 46 * Because qsort(3C) does not allow an argument to be passed to a comparison 47 * function, the variables that affect comparison must regrettably be global; --- 212 unchanged lines hidden (view full) --- 260 if (dtp->dt_vector != NULL) 261 return; 262 263 if ((P = dt_proc_grab(dtp, pid, PGRAB_RDONLY | PGRAB_FORCE, 0)) == NULL) 264 return; 265 266 dt_proc_lock(dtp, P); 267 |
268 if (Plookup_by_addr(P, *pc, NULL, 0, &sym) == 0) |
269 *pc = sym.st_value; 270 271 dt_proc_unlock(dtp, P); 272 dt_proc_release(dtp, P); 273} 274 275static void 276dt_aggregate_umod(dtrace_hdl_t *dtp, uint64_t *data) --- 6 unchanged lines hidden (view full) --- 283 if (dtp->dt_vector != NULL) 284 return; 285 286 if ((P = dt_proc_grab(dtp, pid, PGRAB_RDONLY | PGRAB_FORCE, 0)) == NULL) 287 return; 288 289 dt_proc_lock(dtp, P); 290 |
291 if ((map = Paddr_to_map(P, *pc)) != NULL) |
292 *pc = map->pr_vaddr; 293 294 dt_proc_unlock(dtp, P); 295 dt_proc_release(dtp, P); 296} 297 298static void 299dt_aggregate_sym(dtrace_hdl_t *dtp, uint64_t *data) --- 1580 unchanged lines hidden --- |