Commit Graph

8 Commits

Author SHA1 Message Date
Ondřej Bílka a1ffb40e32 Use glibc_likely instead __builtin_expect. 2014-02-10 15:07:12 +01:00
Allan McRae d4697bc93d Update copyright notices with scripts/update-copyrights 2014-01-01 22:00:23 +10:00
Carlos O'Donell 13e23af76e Update comments in ldconfig.c and dl-hwcaps.c.
In dl-hwcaps.c the comment read that rounding was done
to ElfW(Addr), but it's actually rounded to ElfW(Word).

In ldconfig.c we make each comment a sentence and
mention that the "tls" pseudo-hwcap is just for legacy
installations where TLS was optional.

---

2013-05-22  Carlos O'Donell  <carlos@redhat.com>

	* elf/ldconfig.c (is_hwcap_platform): Make comments full setences.
	(main): Mention "tls" pseudo-hwcap is legacy.
	* elf/dl-hwcaps.c (_dl_important_hwcaps): Correct rounding comment.
2013-05-22 23:22:36 -04:00
Carlos O'Donell 141af660d8 Add comments to vDSO hwcap loading process.
Loading of the vDSO pseudo-hwcap from the type 2 GNU note is
a rather arcane and poorly documented process. Given that I had
a chance to review this code today I thought I would add all
of the things I had to lookup to verify the validity of the
process.

With a single .note.GNU the vDSO can register up to 64 flags,
though in practice you are limited to 64 - _DL_FIRST_EXTRA
bits which on x86 is 12 bits.

The only use of this that I know of is in the Xen support
in Linux where they use the 1st bit to indicate "nosegneg".
I see "We use bit 1 to avoid bugs in some versions of glibc
when bit 0 is used; the choice is otherwise arbitrary.", but
no reference to a glibc bug anywhere. The code as-is should
support bit zero, so we still have that free for future use.

The kernel, glibc, and ld.so.cache must coordinate to ensure
that bit values don't go too high and are used consistently.

---

2013-05-13  Carlos O'Donell  <carlos@redhat.com>

	* elf/dl-hwcaps.c (_dl_important_hwcaps): Comment vDSO hwcap loading.
	* elf/ldconfig.c (is_hwcap_platform): Comment each hwcap check.
	(main): Comment "tls" pseudo-hwcap.
2013-05-14 00:06:35 -04:00
Roland McGrath 7775448e57 Fix NEED_DL_SYSINFO_DSO conditionals. 2013-03-01 14:44:44 -08:00
Roland McGrath 573c29b288 Replace an alloca use with a variable-length array. 2013-02-05 12:15:56 -08:00
Joseph Myers 568035b787 Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
H.J. Lu 53cea63e99 Move _dl_important_hwcaps to dl-hwcaps.c 2012-10-05 10:26:29 -07:00