summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2010-12-29Move implicit operand size override logic to calc_sizeVictor van den Elzen3-27/+47
It is more logical, it cleans up the code and it makes implicit operand size override prefixes come out in the same order as explicit ones instead of after all other prefixes. Suggested-by: H. Peter Anvin <hpa@zytor.com>
2010-12-23BR 3143040: Remove invalid form of VPEXTRWH. Peter Anvin1-1/+0
The 0F form, unlike the 0F3A form, of VPEXTRW cannot write a 16-bit memory location by specification. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2010-12-18preproc.c: fix tokenize() warnings for ignored expansion definitionsKeith Kanios1-3/+8
2010-12-18doc/nasmdoc.src: document additions from preprocessor-rewrite mergeKeith Kanios1-28/+49
2010-12-18preproc.c: simplify %un[i]macro warning messageKeith Kanios1-1/+1
2010-12-18preproc.c: warn/ignore when attempting to %un[i]macro an active macroKeith Kanios1-2/+8
2010-12-18preproc.c: replace tabs with spaces on recent commitsKeith Kanios1-2/+2
2010-12-18preproc.c: free expansion definitions as neededKeith Kanios1-16/+3
2010-12-18preproc.c: free tokens when ignoring expansion definition linesKeith Kanios1-1/+1
2010-12-18preproc.c: placate tokenize() warnings during expansion definitionKeith Kanios1-3/+3
2010-12-17NASM 2.10rc3H. Peter Anvin1-1/+1
2010-11-23insns.pl: Fix up merge conflict for sureCyrill Gorcunov1-1/+1
Now it should be fixed in real (one code snipped escaped me during merge conflict resolving). Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-23Merge branch 'insns'Cyrill Gorcunov2-589/+583
Conflicts: insns.pl Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-23insns: Fixup MOV[APS|UPS] for xmmrm casesCyrill Gorcunov1-2/+2
In fact it was written as MOVAPS xmmreg,xmmreg \360\2\x0F\x28\110 KATMAI,SSE MOVAPS xmmreg,xmmreg \360\2\x0F\x29\101 KATMAI,SSE in first place MOVUPS xmmreg,xmmreg \360\2\x0F\x10\110 KATMAI,SSE MOVUPS xmmreg,xmmreg \360\2\x0F\x11\101 KATMAI,SSE and for example x28 stands for xmmrm128,xmmreg and x1 for xmmrm128,xmmreg. TODO: Inspect and fix WILLAMETTE instructions. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-23insns: Implement size bits on KATMAICyrill Gorcunov1-69/+63
Perhaps not all of them are coevered yet, but mostly. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-23insns.pl: Clear tabs/space messCyrill Gorcunov1-520/+520
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-23make: Lift up openwcom.mak for build on FreeDOSAnthony Williams1-2/+2
Signed-off-by: Anthony Williams <rugxulo@gmail.com> Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-21Merge branch 'nasm-2.09.xx'Cyrill Gorcunov2-14/+46
Conflicts: version Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-21NASM 2.09.04Cyrill Gorcunov1-1/+1
Some important fixes: - Fix incorrect labels offset for VEX intructions - Eliminate bogus warning on implicit operand size override. - %if term could not handle 64 bit numbers. - The COFF backend was limiting relocations number to 16 bits even if in real there were a way more relocations. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-21Changes for 2.09.04Cyrill Gorcunov1-0/+12
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-21BR3104852: only warn once for repeated prefixesVictor van den Elzen1-1/+1
2010-11-21BR3058845: mostly fix bogus warning with implicit operand size overrideVictor van den Elzen2-6/+30
The implicit operand size override code didn't set the operand size prefix, which confused the size calculation code for the range check. The BITS 64 operand size calculation is still off, but "fixing" it by making it 32-bit unless REX.W is set breaks PUSH and maybe others.
2010-11-21misc: Enhance tag-releaseCyrill Gorcunov1-14/+34
It remains backward compatible Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-20eval: rexp3 should operate with 64bit numbersCyrill Gorcunov1-1/+1
reloc_value returns 64bit numbers but we strip it down to 'int' which causes problems if the former value is big enough to overflow 'int'. Fix it. [ BR3104312 ] Reported-by: Christian Masloch Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-20Fix autoconf 2.68 warning.Victor van den Elzen1-3/+2
The first argument of AC_COMPILE_IFELSE needs to be wrapped with AC_LANG_SOURCE.
2010-11-20coff: Handle massive relocationsCyrill Gorcunov2-3/+44
The backport of 4db724fdd76e3a6cd0f5124ef86de976c495d666 359b63f8976375f071edc33092daea57efa768fb 01102ee8e6a967830bcd6f0134efe8976f473121 2672af737954fb17ec0ebf17e787219a504c4400 so coff output target to be able to handle massive relocations. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-16Merge branch 'nasm-2.09.xx'H. Peter Anvin2-1/+10
2010-11-16BR 3109604: Fix C4 vs C5 VEX form selection in calcsize()H. Peter Anvin2-1/+10
calcsize() had the wrong criterion for when C5 prefixes are permitted (REX.R is permitted, REX.X is forbidden.) assemble() had the right test already. This caused symbol value errors.
2010-11-13preproc.c: fix handling of %? and %??Keith Kanios1-1/+1
2010-11-11Merge branch 'cleanup'Cyrill Gorcunov2-824/+813
2010-11-11Revert 29cb0bb1b39f4e3c9e013993457e85fce14f5142Cyrill Gorcunov1-1/+4
Redundant call on nonsmart compilers doesn't worth it in compare with two assignment operations. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-11preproc: Add dump_token helperCyrill Gorcunov1-0/+18
While being debugging some nifty problem I found that it might be useful to produce a full dump of tokens, in particular text of tokens. For this reason dump_token is here just to not loose it. It doesn't affect normal build procedure since it requires a special -DNASM_TRACE to be passed to the compiler. Which of course we don't in a regular compilations. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-11preproc: Use nasm_zalloc moreCyrill Gorcunov1-7/+5
To eliminate possible access into heap data Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-11preproc: Use memset for stack allocated structureCyrill Gorcunov1-11/+4
To be on safe side Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-11preproc: inc_fopen -- set sl->next earlyCyrill Gorcunov1-1/+1
It's safer to init it early and be sure we not miss anything after. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-11preproc: Use nasm_zalloc for new_ExpDef, new_ExpInvCyrill Gorcunov1-39/+10
Srink the code and make it a bit faster. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-11preproc: Use nasm_zalloc in new_LineCyrill Gorcunov1-5/+2
It's shorter Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-11autoconf: Add --with-ccache optionCyrill Gorcunov1-0/+9
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-11preproc.c: Get rid of tab/space messCyrill Gorcunov1-809/+809
No change on binary level Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-10preproc: do_directive: Allocate 'Include' from zeroified-memoryCyrill Gorcunov1-14/+12
If not all members of structure being allocated from heap get initialized we better to use nasm_zalloc instead of nasm_malloc. For example inc gets allocated in do_directive being parially initialized and we erroniously get mmac_depth set to some crappy value leading to SIGSEV in result. [ http://forum.nasm.us/index.php?topic=921.msg3257#msg3257 ] nb: I've cleaned verror from tab/space mess while were at it Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-08preproc.c: use nasm_strdup() rather than naked strdup()H. Peter Anvin1-1/+1
2010-11-08preproc.c: placate errors in OpenWatcom CompilerKeith Kanios1-5/+7
2010-11-07BR3104852: only warn once for repeated prefixesVictor van den Elzen1-1/+1
2010-11-07BR3058845: mostly fix bogus warning with implicit operand size overrideVictor van den Elzen2-6/+30
The implicit operand size override code didn't set the operand size prefix, which confused the size calculation code for the range check. The BITS 64 operand size calculation is still off, but "fixing" it by making it 32-bit unless REX.W is set breaks PUSH and maybe others.
2010-11-07preproc.c: Fix OpenWatcom compiler errorKeith Kanios1-2/+2
2010-11-08preproc.c: Fix OpenWatcom compiler errorCyrill Gorcunov1-2/+1
It doesn't like when we mess scope of variables declaration. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
2010-11-07Fix autoconf 2.68 warning.Victor van den Elzen1-3/+2
The first argument of AC_COMPILE_IFELSE needs to be wrapped with AC_LANG_SOURCE.
2010-11-07Fix Perl deprecation warnings.Victor van den Elzen5-5/+5
Use of defined on aggregates (hashes and arrays) is deprecated. You should instead use a simple test for size.
2010-11-06NASM 2.10rc2Keith Kanios1-1/+1
2010-11-06version: reverting back to 2.10rc1Keith Kanios1-1/+1