Lines Matching +full:on +full:- +full:the +full:- +full:go

1 // SPDX-License-Identifier: GPL-2.0-only
3 * vdso2c - A vdso image preparation tool
7 * to fully strip the input in here, but, for reasons described below,
9 * equivalent to dropping all non-allocatable sections, but it's
16 * The Go runtime had a couple of bugs: it would read the section
18 * shouldn't have looked at the section table at all) and, if there
20 * uninitialized value for the number of symbols. An empty DYNSYM
22 * keep full performance for old Go programs). This hack is only
23 * needed on x86_64.
25 * The bug was introduced on 2012-08-31 by:
26 * https://code.google.com/p/go/source/detail?r=56ea40aac72b
27 * and was fixed on 2014-06-13 by:
28 * https://code.google.com/p/go/source/detail?r=fc1cd5e12595
30 * Binutils has issues debugging the vDSO: it reads the section table to
31 * find SHT_NOTE; it won't look at PT_NOTE for the in-memory vDSO, which
32 * would break build-id if we removed the section table. Binutils
40 * just write a mostly complete one. We omit non-dynamic symbols,
44 * the 64-bit vdso, since build-id only works in kernel RPMs, and
46 * binutils in sync. build-id has never worked for home-built kernel
122 * Evil macros for little-endian reads and writes
169 static void go(void *raw_addr, size_t raw_len, in go() function
175 if (hdr->e_ident[EI_CLASS] == ELFCLASS64) { in go()
178 } else if (hdr->e_ident[EI_CLASS] == ELFCLASS32) { in go()
191 if (fd == -1) in map_input()
195 if (tmp_len == (off_t)-1) in map_input()
220 * Figure out the struct name. If we're writing to a .so file, in main()
225 if (namelen >= 3 && !strcmp(name + namelen - 3, ".so")) { in main()
235 if (*tmp == '-') in main()
247 go(raw_addr, raw_len, stripped_addr, stripped_len, outfile, name); in main()