Commit graph

1855 commits

Author SHA1 Message Date
Peter Johnson
3c262471a0 Bump version numbers for release.
svn path=/tags/yasm-0.7.2/; revision=2154
2008-10-09 06:00:29 +00:00
Peter Johnson
780736a8a7 Merge [2121], [2122], [2123], [2124], [2125], [2126], and [2127] from trunk.
[2121]: Mark gen_x86_insn.py outputs as generated.
[2122]: Don't read past end of string in parsers (not bug).
[2123]: Fix expression simplification bug.
[2124]: Warn if unused groups are detected in gen_x86_insn.py.
[2125]: VPBLENDVB doesn't have a 256-bit form; remove it.
[2126]: Generate GOTPCREL relocation for [rel foo wrt ..gotpc].
[2127]: Optimize non-strict push with 66 override to byte size if possible.

svn path=/branches/yasm-0.7.x/; revision=2148
2008-10-08 07:42:56 +00:00
Peter Johnson
4947c3edea Merge [2120] from trunk (Fix #153, name the absolute symbol in coff/win32).
svn path=/branches/yasm-0.7.x/; revision=2147
2008-10-08 07:39:18 +00:00
Peter Johnson
d1b8e92eab Merge [2116], [2117], [2118], and [2119] from trunk.
[2116]: Fix absolute path handling.
[2117]: Fix expression leveling bug.
[2118], [2119]: Add support for newly specified AVX/AES instructions.

svn path=/branches/yasm-0.7.x/; revision=2146
2008-10-08 07:37:52 +00:00
Peter Johnson
5afe24a8a0 Merge [2114] and [2115] from trunk (Fix #148, clearing of GAS elf sectflags).
svn path=/branches/yasm-0.7.x/; revision=2145
2008-10-08 07:34:51 +00:00
Peter Johnson
6e13bb01b7 Merge [2110], [2111], [2112], and [2113] from trunk.
[2110]: Fix address printing in bin map file
[2111]: automake build fixes
[2112]: libyasm documentation fix
[2113]: Fix register name lookup for printing

svn path=/branches/yasm-0.7.x/; revision=2144
2008-10-08 07:33:10 +00:00
Peter Johnson
300f38bde3 Merge [2109] from trunk (Fix #132, --prefix and --suffix options).
svn path=/branches/yasm-0.7.x/; revision=2143
2008-10-08 07:29:43 +00:00
Peter Johnson
154d91d85d Merge [2108] from trunk (Fix #141, macho64 PIC support).
svn path=/branches/yasm-0.7.x/; revision=2142
2008-10-08 07:26:32 +00:00
Peter Johnson
7e507cd28d Merge [2096] and [2097] from trunk (C89 compliance and util.h robustness).
svn path=/branches/yasm-0.7.x/; revision=2141
2008-10-08 07:23:44 +00:00
Peter Johnson
ef29b94867 Optimize non-strict push with 66 override to byte size if possible in NASM
syntax.

Previously, the forms of push that did this optimization were disabled in
NASM syntax due to conflicting with the size=BITS case.  Fix this via
reordering to allow these forms to be active in NASM syntax.

svn path=/trunk/yasm/; revision=2127
2008-10-05 08:31:04 +00:00
Peter Johnson
4d78c310b5 elf64: automatically promote [rel foo wrt ..gotpc] to GOTPCREL relocation.
Formerly, [rel foo wrt ..gotpcrel] was required.

svn path=/trunk/yasm/; revision=2126
2008-10-03 08:13:00 +00:00
Peter Johnson
0b002cd6a3 VPBLENDVB doesn't have a 256-bit form.
Reported by: Mark Charney

svn path=/trunk/yasm/; revision=2125
2008-10-02 07:26:22 +00:00
Peter Johnson
5abca04eff gen_x86_insn.py: Warn if any groups are unused (due to a typo, for example).
svn path=/trunk/yasm/; revision=2124
2008-10-02 02:15:56 +00:00
Peter Johnson
457170f54e Fix expr simplification bug.
If an expression of the form INT+(a+b)+INT was simplified, constant folding
would combine the ints, but then the level stage (to make INT+a+b) would
start reading from the second (deleted due to folding) INT rather than the
new end of the expression.

Reported by: Samuel Thibault (on yasm-devel@)

svn path=/trunk/yasm/; revision=2123
2008-09-30 03:56:37 +00:00
Peter Johnson
1b1c9ba0ad Nasm lexer: Don't read past end of passed string.
This was because the re2c-generated code always reads the next character
prior to user code being executed.  Instead, check for the \0 marker prior
to entering the re2c code.  Retain the re2c check just for sanity.

Reported by: Samuel Thibault (on yasm-devel@)

svn path=/trunk/yasm/; revision=2122
2008-09-30 02:52:56 +00:00
Peter Johnson
11798b4d6b Mark gen_x86_insn.py outputs as generated, to discourage hand-editing.
Suggested by: Mark Charney

svn path=/trunk/yasm/; revision=2121
2008-09-10 02:42:45 +00:00
Peter Johnson
c80ed373ba Fix #153: Name the absolute symbol.
While we're here, ensure it's always output regardless of all_syms setting.

svn path=/trunk/yasm/; revision=2120
2008-09-04 04:45:30 +00:00
Peter Johnson
a1b9924b9a Increase size of buffer now that mnenomics can be 16 characters.
svn path=/trunk/yasm/; revision=2119
2008-08-13 04:05:19 +00:00
Peter Johnson
b174e03f50 Add support for newly specified AVX/AES instructions:
- vaes*
- 256b vmovnt{ps,pd,dq}

Reported by: Mark.Charney@intel.com

svn path=/trunk/yasm/; revision=2118
2008-08-13 03:43:47 +00:00
Peter Johnson
33aa2d621b Fix bug in expr_level_op(). Discovered when adding on-the-fly expr leveling.
svn path=/trunk/yasm/; revision=2117
2008-07-18 05:52:01 +00:00
Peter Johnson
c6a2b083c1 Actually implement yasm__abspath() according to its documentation.
Formerly, it would not correctly handle absolute paths.  Now it uses
yasm__combpath() to do absolute-path aware path combination.
As a benefit, it no longer needs to be OS-specific.

Reported by: Shmuel Baron <shmulik@gmail.com>

svn path=/trunk/yasm/; revision=2116
2008-07-15 05:49:29 +00:00
Peter Johnson
e0d651acdd Fix extraneous warnings and update testcases for [2114] changes.
svn path=/trunk/yasm/; revision=2115
2008-07-08 06:36:44 +00:00
Peter Johnson
dbf6c6ce38 Fix #148: Don't clear elf section flags in GAS if it's a standard section and
no GAS flags were provided.

svn path=/trunk/yasm/; revision=2114
2008-07-08 06:28:37 +00:00
Peter Johnson
9cd2ac3378 x86_reg_print(): Add missing commas for correct register name lookup.
svn path=/trunk/yasm/; revision=2113
2008-07-07 06:17:33 +00:00
Peter Johnson
901b28cab4 yasm_symrec_get_global_name(): Document object parameter.
svn path=/trunk/yasm/; revision=2112
2008-07-06 22:30:07 +00:00
Peter Johnson
a78a908bab Generated files listed in SOURCES (rather than included by other files)
should not be listed in BUILT_SOURCES but rather have nodist_ prepended.
They still need to be separately listed as CLEANFILES as they're built
at make time.

Reported by: David Harvey <dmharvey@math.harvard.edu>

svn path=/trunk/yasm/; revision=2111
2008-07-06 22:26:49 +00:00
Peter Johnson
bd4a2ffdb8 Bin map file: Fix incorrect address printing for symbols.
We were printing the previous bytecode's start rather than the label's
bytecode.  Use yasm_bc_next_offset() to get the correct offset.

svn path=/trunk/yasm/; revision=2110
2008-07-03 04:19:12 +00:00
Peter Johnson
53b2d01a77 Fix #132: Add --prefix and --suffix (aka --postfix) options.
These allow arbitrary prefixes and/or suffixes to be added to
externally-visible (GLOBAL, EXTERN, or COMMON) symbol names.

svn path=/trunk/yasm/; revision=2109
2008-06-08 09:06:05 +00:00
Peter Johnson
3aab66a119 Fix #141: Add macho64 PIC support.
The way PIC relocations are generated for macho64 requires a bit of a hack
to detect MOV opcodes and generate GOT_LOAD relocs.
GAS contains a similar hack.

svn path=/trunk/yasm/; revision=2108
2008-06-05 08:48:21 +00:00
Peter Johnson
3196e62ef6 Quiet a warning about casting from a data to function pointer.
This is required to get a function pointer from dlsym().

svn path=/trunk/yasm/; revision=2107
2008-05-25 17:02:24 +00:00
Peter Johnson
13665a69db Update plugin README files for Windows.
svn path=/trunk/yasm/; revision=2106
2008-05-24 19:00:48 +00:00
Peter Johnson
e09d5a7968 Error out if Python not found.
svn path=/trunk/yasm/; revision=2105
2008-05-24 18:50:32 +00:00
Peter Johnson
c59ebcbe36 Fix x86 plugin build on Windows.
svn path=/trunk/yasm/; revision=2104
2008-05-24 18:49:59 +00:00
Peter Johnson
e733283016 Clean up plugins CMakeLists a bit.
Be more clever about finding the yasm executable on Windows.

svn path=/trunk/yasm/; revision=2103
2008-05-24 18:32:39 +00:00
Peter Johnson
0a3f7ea1b9 (cmake build) Install DLL files to correct locations on Windows.
svn path=/trunk/yasm/; revision=2102
2008-05-24 18:30:29 +00:00
Peter Johnson
eb7b1adb30 Enable DLL/plugin builds with cmake on Windows.
Add proper declspec dllimport/dllexport to all libyasm functions.
Use macros to make these do nothing on non-cmake and Unix builds.

svn path=/trunk/yasm/; revision=2101
2008-05-23 06:46:51 +00:00
Peter Johnson
e4f292ef16 Enable Id keyword expansion.
svn path=/trunk/yasm/; revision=2100
2008-05-23 06:31:52 +00:00
Peter Johnson
92d938f93f Prepend "lib" on plugin name only on Unix.
svn path=/trunk/yasm/; revision=2099
2008-05-23 06:30:38 +00:00
Peter Johnson
b7f2fbc64f Add cmake build infrastructure.
Not default nor even distributed in the .tar.gz, the cmake build allows for
loadable yasm plugins by building libyasm as a shared library.
Example plugins are in the plugins/ directory, and may be loaded into a
cmake-built yasm using the -N command line option (non-cmake builds will
not have this option).

Tested only on Linux so far, but should be relatively painless to port to
Windows thanks to the use of cmake rather than libtool to create shared
libraries.

The only modification to the main source tree is some conditional-compiled
additions to yasm.c.

svn path=/trunk/yasm/; revision=2098
2008-05-22 09:08:03 +00:00
Peter Johnson
811d7ad566 Make util.h more robust against use without config.h by moving the
toascii redefinition to the only file that uses it, errwarn.c.

svn path=/trunk/yasm/; revision=2097
2008-05-22 08:37:32 +00:00
Peter Johnson
3d8a8f577c Make ISO C89 compliant (too long constant string, use of // comment).
svn path=/trunk/yasm/; revision=2096
2008-05-15 06:55:57 +00:00
Peter Johnson
803b65246d Bump 0.7.x branch version to 0.7.2.
svn path=/branches/yasm-0.7.x/; revision=2095
2008-05-15 01:40:09 +00:00
Peter Johnson
81f12a1830 Merge [2088] from trunk (Add westmere CPU).
svn path=/branches/yasm-0.7.x/; revision=2092
2008-05-14 03:46:41 +00:00
Peter Johnson
464cbc852b Merge [2077] from trunk (LAR and LSL should be 286+Prot, not 386).
svn path=/branches/yasm-0.7.x/; revision=2091
2008-05-14 03:44:53 +00:00
Peter Johnson
0fdda0e00e Merge [2074] from trunk.
svn path=/branches/yasm-0.7.x/; revision=2090
2008-05-14 03:43:20 +00:00
Peter Johnson
a72cc83b3c Add westmere CPU (supports AES and CLMUL), redefine sandybridge to add AVX
(FMA won't appear until the 22nm shrink of sandybridge).

Reported by: nasm64developer@users.sf.net

svn path=/trunk/yasm/; revision=2088
2008-05-14 03:32:20 +00:00
Peter Johnson
0fb038e9a1 Bring Mkfiles up-to-date with genmacro/preproc changes.
svn path=/trunk/yasm/; revision=2087
2008-05-13 05:28:09 +00:00
Peter Johnson
77aea19bc4 Fix handling of alloc_stack macro in GAS mode.
Reported by: Brian Gladman <brg@gladman.plus.com>

svn path=/trunk/yasm/; revision=2086
2008-05-13 03:41:27 +00:00
Peter Johnson
deffd98d53 Commit moved, updated genmacro script missed in [2082] commit.
svn path=/trunk/yasm/; revision=2084
2008-05-09 07:08:17 +00:00
Peter Johnson
a1cd884de8 Fix #138: Incorrect UNW_FLAG_CHAININFO value (currently unused).
svn path=/trunk/yasm/; revision=2083
2008-05-09 06:51:41 +00:00