Browse Source

Only use Win64 vectorcall special case if calling convention is vectorcall.

Brendan Dougherty 3 years ago
parent
commit
1923c8a611
1 changed files with 2 additions and 2 deletions
  1. 2 2
      compiler/x86_64/cpupara.pas

+ 2 - 2
compiler/x86_64/cpupara.pas

@@ -1674,9 +1674,9 @@ unit cpupara;
                   continue;
                   continue;
                 end;
                 end;
 
 
-            { on win64, if a record has only one field and that field is a
+            { on vectorcall, if a record has only one field and that field is a
               single or double, it has to be handled like a single/double }
               single or double, it has to be handled like a single/double }
-            if use_ms_abi and
+            if (p.proccalloption=pocall_vectorcall) and
                ((paradef.typ=recorddef) {or
                ((paradef.typ=recorddef) {or
                is_object(paradef)}) and
                is_object(paradef)}) and
                tabstractrecordsymtable(tabstractrecorddef(paradef).symtable).has_single_field(fdef) and
                tabstractrecordsymtable(tabstractrecorddef(paradef).symtable).has_single_field(fdef) and