68
Chapter 8. Assembler Directives
8.97.
.version "string"
This directive creates a
.note
section and places into it an ELF formatted note of type NT_VERSION.
The note's name is set to
string
.
8.98.
.vtable_entry table, offset
This directive finds or creates a symbol
table
and creates a
VTABLE_ENTRY
relocation for it with an
addend of
offset
.
8.99.
.vtable_inherit child, parent
This directive finds the symbol
child
and finds or creates the symbol
parent
and then creates a
VTABLE_INHERIT
relocation for the parent whose addend is the value of the child symbol. As a
special case the parent name of
0
is treated as refering the
*ABS*
section.
8.100.
.weak names
This directive sets the weak attribute on the comma separated list of symbol
names
. If the symbols do
not already exist, they will be created.
Weak symbols are supported in COFF as a GNU extension. This directive sets the weak attribute on
the comma separated list of symbol
names
. If the symbols do not already exist, they will be created.
.weak
name
[
= | ==
alternate
] [, ...]
On the PE target, weak aliases are supported natively. Weak aliases (usually called "weak externals"
in PE) are created when an alternate name is specified. When a weak symbol is linked and the symbol
is not defined, the weak symbol becomes an alias for the alternate symbol. If one equal sign is used,
the linker searches for defined symbols within other objects and libraries. This is the usual mode,
historically called "lazy externals." Otherwise, when two equal signs are used, the linker searches for
defined symbols only within other objects.
Non alias weak symbols are supported on PE as a GNU extension.
8.101.
.word expressions
This directive expects zero or more
expressions
, of any section, separated by commas.
The size of the number emitted, and its byte order, depend on what target computer the assembly is
for.
Warning: Special Treatment to support Compilers
Machines with a 32 bit address space, but that do less than 32 bit addressing, require the follow
ing special treatment. If the machine of interest to you does 32 bit addressing (or doesn't require it;
Chapter 9 Machine Dependent Features), you can ignore this issue.
In order to assemble compiler output into something that works,
as
occasionally does strange things
to
.word
directives. Directives of the form
.word sym1 sym2
are often emitted by compilers as
part of jump tables. Therefore, when
as
assembles a directive of the form
.word sym1 sym2
, and
the difference between
sym1
and
sym2
does not fit in 16 bits,
as
creates a secondary jump table,
footer
Our partners:
PHP: Hypertext Preprocessor Best Web Hosting
Java Web Hosting
Inexpensive Web Hosting
Jsp Web Hosting
Cheapest Web Hosting
Jsp Hosting
Cheap Hosting
Visionwebhosting.net Business web hosting division of Web
Design Plus. All rights reserved