> On 12 Mar 2020, at 10:49, Lijian Zhang <lijian.zh...@arm.com> wrote:
>
> Hi Maintainers,
> We are profiling VPP with MAP (a software profile suite on Arm CPUs, see
> details
> inhttps://www.arm.com/products/development-tools/server-and-hpc/forge/map) on
> Arm CPUs.
>
> The MAP sampler runs inside target process as a library because it does a lot
> more things that require access to the program's memory like matching up
> OpenMP threads etc. So it is a lot more invasive and uses the SIGPROF signal
> to control the sample rate.
>
> VPP will receive SIGPROF signal because MAP uses SIGPROF signal to drive its
> sampler to do profiling on VPP. However, the default action of SIGPROF signal
> handler in VPP such as unix_signal_handler() is process termination. To
> profile VPP with MAP, We need to change VPP signal handler to ignore SIGPROF
> signal.
>
> Can we upstream a patch to simply ignore the SIGPROF in VPP?
I think so, please submit patch and unless somebody raises his concern here I
will merge it...
>
> diff --git a/src/vlib/unix/main.c b/src/vlib/unix/main.c
> index e40a462..6138a6f 100755
> --- a/src/vlib/unix/main.c
> +++ b/src/vlib/unix/main.c
> @@ -218,6 +218,7 @@
> /* ignore SIGPIPE, SIGCHLD */
> case SIGPIPE:
> case SIGCHLD:
> + case SIGPROF:
> sa.sa_sigaction = (void *) SIG_IGN;
> break;
—
Damjan
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#15745): https://lists.fd.io/g/vpp-dev/message/15745
Mute This Topic: https://lists.fd.io/mt/71898718/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-