From 0aa8e9d8296d6baa2f0b532bc3855cc31d211c39 Mon Sep 17 00:00:00 2001 From: nickysn Date: Thu, 9 Apr 2015 22:47:21 +0000 Subject: [PATCH] + i8086 fixes in the binary writer for asm codes 0310 and 0311 git-svn-id: trunk@30524 - --- compiler/x86/aasmcpu.pas | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/compiler/x86/aasmcpu.pas b/compiler/x86/aasmcpu.pas index 0502fe88cf..60da68c473 100644 --- a/compiler/x86/aasmcpu.pas +++ b/compiler/x86/aasmcpu.pas @@ -2266,16 +2266,18 @@ implementation end; end; 200 : -{$ifndef x86_64} - inc(len); -{$else x86_64} +{$if defined(x86_64)} { every insentry with code 0310 must be marked with NOX86_64 } InternalError(2011051301); -{$endif x86_64} +{$elseif defined(i386)} + inc(len); +{$elseif defined(i8086)} + {nothing}; +{$endif} 201 : -{$ifdef x86_64} +{$if defined(x86_64) or defined(i8086)} inc(len) -{$endif x86_64} +{$endif x86_64 or i8086} ; 212 : inc(len); @@ -2952,22 +2954,24 @@ implementation {$endif x86_64} end; 200 : { fixed 16-bit addr } -{$ifndef x86_64} +{$if defined(x86_64)} + { every insentry having code 0310 must be marked with NOX86_64 } + InternalError(2011051302); +{$elseif defined(i386)} begin bytes[0]:=$67; objdata.writebytes(bytes,1); end; -{$else x86_64} - { every insentry having code 0310 must be marked with NOX86_64 } - InternalError(2011051302); +{$elseif defined(i8086)} + {nothing}; {$endif} 201 : { fixed 32-bit addr } -{$ifdef x86_64} +{$if defined(x86_64) or defined(i8086)} begin bytes[0]:=$67; objdata.writebytes(bytes,1); end -{$endif x86_64} +{$endif x86_64 or i8086} ; 208,209,210 : begin