Package: lib6
Version: 2.19-18+deb8u4
Severity: important

vDSO is not in effect in static linked executable on jessie. This is
not the case with wheezy.

We build binary to run on both wheezy and jessie, so -static. When
building platform is wheezy, vdso works fine, but jessie the opposite.

This leads to performance hit. Unfortunately, we use g++ 4.9 for some
application, so wheezy can't be used as build platform.

How to reproduce

$ cat t.c
#include <time.h>
#include <unistd.h>
#include <stdio.h>
#include <sys/time.h>

int main()
{
        struct timeval now;
        gettimeofday(&now, NULL);
        printf("%d\n", now.tv_sec);
        printf("%d\n", time(NULL));
        return 0;
}

$ gcc -static t.c

$ strace ./a.out

>From output, you can see syscall gettimeofday() is called.

Reply via email to