svn commit: r2010 - in trunk/yasm: frontends/yasm libyasm modules/dbgfmts/codeview modules/dbgfmts/dwarf2 modules/dbgfmts/stabs modules/objfmts/bin modules/objfmts/bin/tests modules/objfmts/bin/tests/multisect modules/objfmts/coff modules/objfmts/dbg modules/objfmts/elf modules/objfmts/rdf modules/objfmts/xdf

peter at tortall.net peter at tortall.net
Wed Nov 14 00:33:33 PST 2007


Author: peter
Date: Wed Nov 14 00:33:32 2007
New Revision: 2010

Added:
   trunk/yasm/modules/objfmts/bin/tests/multisect/
   trunk/yasm/modules/objfmts/bin/tests/multisect/Makefile.inc   (contents, props changed)
   trunk/yasm/modules/objfmts/bin/tests/multisect/bin-align.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/bin-align.errwarn
   trunk/yasm/modules/objfmts/bin/tests/multisect/bin-align.hex
   trunk/yasm/modules/objfmts/bin/tests/multisect/bin-align.map
   trunk/yasm/modules/objfmts/bin/tests/multisect/bin-ssym.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/bin-ssym.hex
   trunk/yasm/modules/objfmts/bin/tests/multisect/bin-ssym.map
   trunk/yasm/modules/objfmts/bin/tests/multisect/bin_multi_test.sh   (contents, props changed)
   trunk/yasm/modules/objfmts/bin/tests/multisect/follows-loop1-err.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/follows-loop1-err.errwarn
   trunk/yasm/modules/objfmts/bin/tests/multisect/follows-loop2-err.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/follows-loop2-err.errwarn
   trunk/yasm/modules/objfmts/bin/tests/multisect/follows-notfound-err.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/follows-notfound-err.errwarn
   trunk/yasm/modules/objfmts/bin/tests/multisect/initbss.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/initbss.errwarn
   trunk/yasm/modules/objfmts/bin/tests/multisect/initbss.hex
   trunk/yasm/modules/objfmts/bin/tests/multisect/initbss.map
   trunk/yasm/modules/objfmts/bin/tests/multisect/ldlinux-sects.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/ldlinux-sects.hex
   trunk/yasm/modules/objfmts/bin/tests/multisect/ldlinux-sects.map
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect1.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect1.hex
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect1.map
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect2.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect2.hex
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect2.map
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect3.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect3.hex
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect3.map
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect4.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect4.hex
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect4.map
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect5.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect5.hex
   trunk/yasm/modules/objfmts/bin/tests/multisect/multisect5.map
   trunk/yasm/modules/objfmts/bin/tests/multisect/nomultisect1.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/nomultisect1.hex
   trunk/yasm/modules/objfmts/bin/tests/multisect/nomultisect1.map
   trunk/yasm/modules/objfmts/bin/tests/multisect/nomultisect2.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/nomultisect2.hex
   trunk/yasm/modules/objfmts/bin/tests/multisect/nomultisect2.map
   trunk/yasm/modules/objfmts/bin/tests/multisect/vfollows-loop1-err.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/vfollows-loop1-err.errwarn
   trunk/yasm/modules/objfmts/bin/tests/multisect/vfollows-loop2-err.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/vfollows-loop2-err.errwarn
   trunk/yasm/modules/objfmts/bin/tests/multisect/vfollows-notfound-err.asm
   trunk/yasm/modules/objfmts/bin/tests/multisect/vfollows-notfound-err.errwarn
Modified:
   trunk/yasm/frontends/yasm/yasm.c
   trunk/yasm/libyasm/intnum.c
   trunk/yasm/libyasm/intnum.h
   trunk/yasm/libyasm/section.c
   trunk/yasm/libyasm/section.h
   trunk/yasm/libyasm/valparam.c
   trunk/yasm/libyasm/valparam.h
   trunk/yasm/modules/dbgfmts/codeview/cv-symline.c
   trunk/yasm/modules/dbgfmts/codeview/cv-type.c
   trunk/yasm/modules/dbgfmts/dwarf2/dwarf2-aranges.c
   trunk/yasm/modules/dbgfmts/dwarf2/dwarf2-info.c
   trunk/yasm/modules/dbgfmts/dwarf2/dwarf2-line.c
   trunk/yasm/modules/dbgfmts/stabs/stabs-dbgfmt.c
   trunk/yasm/modules/objfmts/bin/bin-objfmt.c
   trunk/yasm/modules/objfmts/bin/tests/Makefile.inc
   trunk/yasm/modules/objfmts/coff/coff-objfmt.c
   trunk/yasm/modules/objfmts/dbg/dbg-objfmt.c
   trunk/yasm/modules/objfmts/elf/elf-objfmt.c
   trunk/yasm/modules/objfmts/macho/macho-objfmt.c
   trunk/yasm/modules/objfmts/rdf/rdf-objfmt.c
   trunk/yasm/modules/objfmts/xdf/xdf-objfmt.c
Changeset:
   http://www.tortall.net/projects/yasm/changeset/2010

Log:
Add NASM-compatible multi-section binary support to bin object format.
This allows for arbitrary load (LMA) and execution (VMA) addresses.

The following new section attributes are supported:
 - start (LMA start address)
 - follows (follow another section's last LMA)
 - align (LMA alignment)
 - vstart (VMA start address)
 - vfollows (follow another section's last VMA)
 - valign (VMA alignment)
In addition, sections can be designed progbits or nobits.

The following special symbols are generated for program use:
 - section.<sectname>.start (LMA start address)
 - section.<sectname>.vstart (VMA start address)
 - section.<sectname>.length (section length)

The ORG directive adjusts the file offset relative to LMA, so that if
ORG=0x100, a section with LMA=0x100 will be at file offset 0.

VMA addresses are the same as LMA addresses unless otherwise specified.

Full map file support is supported via the [MAP] directive.  The map output
filename can be set either as a parameter to the [MAP] directive or on the
command line with --mapfile=<filename>.  MAP options are BRIEF, SECTIONS,
SEGMENTS, SYMBOLS, and ALL (all of the above).  If no filename is specified
either on the command line or in the source file, the map is output to
standard output.

Full documentation will be added to the Yasm manual in the near future.

This implementation supports several configurations NASM does not, for
instance http://osdir.com/ml/lang.nasm.devel/2004-12/msg00032.html .
It is also fully 64-bit aware.

Fixes: #71, #99.



More information about the yasm-cvs mailing list