Masm32 SDK description, downloads and other helpful links

Main Menu

Re: X64 ABI, REAL8 passed in xmmreg?

Started by jj2007, April 09, 2021, 11:23:41 PM

Previous topic - Next topic


Quote from: nidud on April 12, 2021, 08:04:36 PM
it kicks in at the :VARARG position.

Good point, thanks :thumbsup:

Is there any "mixed" WinAPI call that you know of? There are more than 1,000 VARARG API calls in \Masm32\include...

Just for fun, I checked it (source & exe attached):
include \masm32\MasmBasic\
  SetGlobals ctVar, ctMixed
  GetFiles "\Masm32\include\*.inc"
  PrintLine Str$("%i files found\n", eax)
  For_ fcount=0 To Files$(?)-1
Recall Files$(fcount), L$()
For_ ct=0 To eax-1
mov esi, L$(ct)
.if Instr_(esi, ":VARARG")
inc ctVar
lea ecx, [edx+6] ; +6 for len(":VARARG")
.if Len(esi)!=ecx
inc ctMixed
Print Str$("\n%___i", ct), esi
  Inkey Str$("\n%i vararg calls found", ctVar), Str$(", of which %i are mixed", ctMixed)




Quote from: nidud on April 12, 2021, 11:22:17 PM
It's common in graphic code to use long arrays of floats and VARARG

There are some other candidates, too:
frequency of VARARG:
184  \Masm32\include\
150  \Masm32\include\
102  \Masm32\include\
076  \Masm32\include\
065  \Masm32\include\
063  \Masm32\include\
056  \Masm32\include\
050  \Masm32\include\
049  \Masm32\include\
042  \Masm32\include\
026  \Masm32\include\
025  \Masm32\include\
021  \Masm32\include\
013  \Masm32\include\
013  \Masm32\include\
010  \Masm32\include\
008  \Masm32\include\
008  \Masm32\include\
008  \Masm32\include\
007  \Masm32\include\

With GetFiles "\Masm32\include\g*.inc":
frequency of VARARG:
000  \Masm32\include\
000  \Masm32\include\
000  \Masm32\include\
000  \Masm32\include\
000  \Masm32\include\
000  \Masm32\include\
000  \Masm32\include\