This is the mail archive of the libc-ports@sources.redhat.com mailing list for the libc-ports project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

issue with SIGPROF signal handler on ARM


Hi,
 I am using glibc-2.3.6 on ARM. I tried using sprof to profile some
of my libraries but none of the libraries gave me any time
information. Looking into more detail, i realized that the PC value
passed to the signal handler (profil_count) was incorrect.

I changed the prototype of profil_counter from
 profil_counter (int signo, int _a2, int _a3, int _a4, union
k_sigcontext sc) to
 profil_counter (int signo, siginfo_t *sig_info, struct sigcontext
*scp) and passed the pc value stored in ((struct ucontext *)
scp)->uc_mcontext.arm_pc.  Here, the PC value passed to the signal
handler seems to be as expected.

Does the kernel fill the register values in the k_sigcontext structure  ?

-- 
Thanks and Regards
Arvind


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]