mirror of
				https://gitlab.com/freepascal.org/fpc/source.git
				synced 2025-11-04 06:39:25 +01:00 
			
		
		
		
	* changed the llvm type of comp/currency in parameter and return type
on platforms that use the x87 for these types to extended in order
    to gaurantee the expected parameter passing conventions
git-svn-id: trunk@30719 -
			
			
This commit is contained in:
		
							parent
							
								
									491d9cfff1
								
							
						
					
					
						commit
						b9138a1c90
					
				@ -764,6 +764,14 @@ implementation
 | 
			
		||||
            usedef:=cgpara.location^.def;
 | 
			
		||||
            if beforevalueext then
 | 
			
		||||
              llvmextractvalueextinfo(cgpara.def,usedef,valueext);
 | 
			
		||||
            { comp and currency are handled by the x87 in this case. They cannot
 | 
			
		||||
              be represented directly in llvm, and llvmdef translates them into
 | 
			
		||||
              i64 (since that's their storage size and internally they also are
 | 
			
		||||
              int64). Solve this by changing the type to s80real in the
 | 
			
		||||
              returndef/parameter declaration. }
 | 
			
		||||
            if (usedef.typ=floatdef) and
 | 
			
		||||
               (tfloatdef(usedef).floattype in [s64comp,s64currency]) then
 | 
			
		||||
              usedef:=s80floattype;
 | 
			
		||||
            result:=usedef;
 | 
			
		||||
            exit
 | 
			
		||||
          end;
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user