This is the mail archive of the
libc-ports@sources.redhat.com
mailing list for the libc-ports project.
issue with SIGPROF signal handler on ARM
- From: "Arvind Ayyangar" <arvind dot ayyangar at gmail dot com>
- To: libc-ports at sourceware dot org
- Date: Wed, 10 Oct 2007 18:05:53 +0530
- Subject: issue with SIGPROF signal handler on ARM
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; bh=1iNLg9i8K+6xqyXlmuCgOgxGG8K/bxrwJg6EBKxudOA=; b=SV4Y4MTazfWxjPom4x2lYqeXyMSgXT7WCC8iZmhswUZYgbgLutL1fcMlnZWUZ6tDafJp08hkYG47AWjxnTC6vEGGna0m4s5cX6Q8OYWA1GDT8cZ/1LoAAnHTatQBs+3kFMx6OKwFCv62FFhf3Z4YgL2ZnSRnExF7maL36Xv0Qgs=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=uuSA89Re1IeEf2GGE7GqxgkCvpN8bHPtOe6QygNUyts2cnqI/anhViuPOjNRgfOrKx+HyHmVRkFG+kc10YWDqKqoC72QGtcHbIdoym1yFUTGpzmFViO80WBwpt0kdk1NHlBeQ7Uw3uocSXZbJeaIApQWZSZFyIAoPIzFVuCvnUc=
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