Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 26 Oct 2007 11:24:26 +0200
From:      Pietro Cerutti <gahr@gahr.ch>
To:        Yuri <yuri@rawbw.com>, User Questions <freebsd-questions@freebsd.org>
Subject:   Re: What is the equivalent of Linux 'gettid' systemcall on FreeBSD?
Message-ID:  <4721B24A.9000902@gahr.ch>
In-Reply-To: <1193366568.47215428811bd@webmail.rawbw.com>
References:  <1193366568.47215428811bd@webmail.rawbw.com>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 2440 and 3156)
--------------enigEEBCC60790816834B08215E0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

Yuri wrote:
> Hi,
>=20
> I am porting some code to FreeBSD and need to know what todoinstead of =
Linux gettid?

There isn't an equivalent in FreeBSD. gettid(2) is Linux-specific.
=46rom the man page, if the thread is not part of a thread group created
by passing the flag CLONE_THREAD to clone(2) [yet another Linux-specific
system call] gettid(2) is equivalent to getpid(2).

However, if the application being ported uses clone(2), you'll first
want to decide for a threading library available on FreeBSD.

>=20
> Thanks,
> Yuri


--=20
Pietro Cerutti

PGP Public Key:
http://gahr.ch/pgp


--------------enigEEBCC60790816834B08215E0
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (FreeBSD)

iD8DBQFHIbJOwMJqmJVx944RCkF7AKCJmnH+97YDQd5URYt7IaQU/Ji1wACgmq5K
KJl4vasneu265NwT8V0A7g4=
=HbhS
-----END PGP SIGNATURE-----

--------------enigEEBCC60790816834B08215E0--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4721B24A.9000902>