mirror of
				https://gitlab.com/freepascal.org/fpc/source.git
				synced 2025-10-31 02:31:49 +01:00 
			
		
		
		
	* support X86_64 and NOX86_64 flags
This commit is contained in:
		
							parent
							
								
									4372f8ef91
								
							
						
					
					
						commit
						e741991cfc
					
				| @ -208,6 +208,7 @@ var | |||||||
|    nopfile,attfile,intfile, |    nopfile,attfile,intfile, | ||||||
|    infile,insfile : text; |    infile,insfile : text; | ||||||
|    { instruction fields } |    { instruction fields } | ||||||
|  |    skip : boolean; | ||||||
|    last, |    last, | ||||||
|    ops    : longint; |    ops    : longint; | ||||||
|    intopcode, |    intopcode, | ||||||
| @ -257,8 +258,6 @@ begin | |||||||
|         readln(infile,s); |         readln(infile,s); | ||||||
|         while (s[1]=' ') do |         while (s[1]=' ') do | ||||||
|          delete(s,1,1); |          delete(s,1,1); | ||||||
|         if (s=';!!!x86_64') and not(x86_64) then |  | ||||||
|           break; |  | ||||||
|         if (s='') or (s[1]=';') then |         if (s='') or (s[1]=';') then | ||||||
|           continue; |           continue; | ||||||
|         if (s[1]='[') then |         if (s[1]='[') then | ||||||
| @ -343,6 +342,7 @@ begin | |||||||
|         optypes[3]:=''; |         optypes[3]:=''; | ||||||
|         codes:=''; |         codes:=''; | ||||||
|         flags:=''; |         flags:=''; | ||||||
|  |         skip:=false; | ||||||
|         { ops and optypes } |         { ops and optypes } | ||||||
|         i:=1; |         i:=1; | ||||||
|         repeat |         repeat | ||||||
| @ -404,12 +404,16 @@ begin | |||||||
|         while not(s[i] in [' ',#9,#13,#10]) and (i<=length(s)) do |         while not(s[i] in [' ',#9,#13,#10]) and (i<=length(s)) do | ||||||
|           begin |           begin | ||||||
|              hs:=readstr; |              hs:=readstr; | ||||||
|              if (hs='ignore') or | 	     if x86_64 then | ||||||
|                ((upcase(hs)='X86_64') and not(x86_64)) then | 	       begin | ||||||
|               begin |                  if (upcase(hs)='NOX86_64') then | ||||||
|                 flags:='0'; | 		   skip:=true; | ||||||
|                 break; | 	       end | ||||||
|               end; | 	     else   | ||||||
|  | 	       begin | ||||||
|  |                  if (upcase(hs)='X86_64') then | ||||||
|  |   		   skip:=true; | ||||||
|  | 	       end; | ||||||
|              if hs<>'ND' then |              if hs<>'ND' then | ||||||
|               begin |               begin | ||||||
|                 if flags<>'' then |                 if flags<>'' then | ||||||
| @ -421,19 +425,22 @@ begin | |||||||
|              else |              else | ||||||
|               break; |               break; | ||||||
|           end; |           end; | ||||||
|       { write instruction } |         { write instruction } | ||||||
|         if not(first) then | 	if not skip then | ||||||
|           writeln(insfile,',') | 	  begin | ||||||
|         else |             if not(first) then | ||||||
|           first:=false; |               writeln(insfile,',') | ||||||
|         writeln(insfile,'  ('); |             else | ||||||
|         writeln(insfile,'    opcode  : ',opcode,';'); |               first:=false; | ||||||
|         writeln(insfile,'    ops     : ',ops,';'); |             writeln(insfile,'  ('); | ||||||
|         writeln(insfile,'    optypes : (',optypes[1],',',optypes[2],',',optypes[3],');'); |             writeln(insfile,'    opcode  : ',opcode,';'); | ||||||
|         writeln(insfile,'    code    : ',codes,';'); |             writeln(insfile,'    ops     : ',ops,';'); | ||||||
|         writeln(insfile,'    flags   : ',flags); |             writeln(insfile,'    optypes : (',optypes[1],',',optypes[2],',',optypes[3],');'); | ||||||
|         write(insfile,'  )'); |             writeln(insfile,'    code    : ',codes,';'); | ||||||
|         inc(insns); |             writeln(insfile,'    flags   : ',flags); | ||||||
|  |             write(insfile,'  )'); | ||||||
|  |             inc(insns); | ||||||
|  | 	  end;   | ||||||
|      end; |      end; | ||||||
|    close(infile); |    close(infile); | ||||||
|    closeinc(insfile); |    closeinc(insfile); | ||||||
| @ -448,7 +455,10 @@ begin | |||||||
| end. | end. | ||||||
| { | { | ||||||
|   $Log$ |   $Log$ | ||||||
|   Revision 1.5  2004-02-03 16:50:51  peter |   Revision 1.6  2004-02-09 20:30:48  peter | ||||||
|  |     * support X86_64 and NOX86_64 flags | ||||||
|  | 
 | ||||||
|  |   Revision 1.5  2004/02/03 16:50:51  peter | ||||||
|     * linux path separators |     * linux path separators | ||||||
| 
 | 
 | ||||||
|   Revision 1.4  2004/01/15 14:01:32  florian |   Revision 1.4  2004/01/15 14:01:32  florian | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 peter
						peter