From 68dd05e259d699d55e938ff3ff7ab8c9e712ce85 Mon Sep 17 00:00:00 2001 From: Jonas Maebe Date: Sat, 15 Dec 2012 22:47:12 +0000 Subject: [PATCH] * fixed std_regname() for xmm registers with custom sizes * fixed findreg_by_number() for xmm registers with R_SUBNONE (from the assembler reader) git-svn-id: trunk@23151 - --- compiler/x86/cpubase.pas | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/compiler/x86/cpubase.pas b/compiler/x86/cpubase.pas index b1a670b11b..08e5ea5d32 100644 --- a/compiler/x86/cpubase.pas +++ b/compiler/x86/cpubase.pas @@ -458,10 +458,9 @@ implementation begin { for the name the sub reg doesn't matter } hr:=r; - case getsubreg(hr) of - R_SUBMMS,R_SUBMMD,R_SUBMMWHOLE: - setsubreg(hr,R_SUBMMX); - end; + if (getregtype(hr)=R_MMREGISTER) and + (getsubreg(hr)<>R_SUBMMY) then + setsubreg(hr,R_SUBMMX); result:=findreg_by_number_table(hr,regnumber_index); end; @@ -478,7 +477,7 @@ implementation begin if getregtype(r) in [R_MMREGISTER,R_MMXREGISTER] then r:=newreg(getregtype(r),getsupreg(r),R_SUBNONE); - p:=findreg_by_number_table(r,regnumber_index); + p:=findreg_by_number(r); if p<>0 then result:=std_regname_table[p] else