flat assembler
Message board for the users of flat assembler.

Index > Macroinstructions > PCOUNT files

Author
Thread Post new topic Reply to topic
bitshifter



Joined: 04 Dec 2007
Posts: 764
Location: Massachusetts, USA
bitshifter
Hello
I would like to make some new PCOUNT files.
Is a dword the standard size for count?
Do byte size params get a count of 1?
And do qword size params get a count of 2?

sample prototypes...
Code:
void MyFunc ( double x, double y ); // pcount = 4
void MyFunc ( long x, long y );     // pcount = 2
void MyFunc ( short x, short y );   // pcount = 2
void MyFunc ( char x, char y );     // pcount = 2    

Am i understanding this correctly?

_________________
Coding a 3D game engine with fasm is like trying to eat an elephant,
you just have to keep focused and take it one 'byte' at a time.
Post 21 Sep 2009, 10:50
View user's profile Send private message Reply with quote
Madis731



Joined: 25 Sep 2003
Posts: 2140
Location: Estonia
Madis731
no matter if it is a char, short, long or a double. The count should be one. I know that they are of different lengths (1,2,4 & Cool, but 64-bit Windows still uses the same amount of parameters.

I think the things get complicated (as I understand from your post) when you deal with a 32-bit native app, that wants access to larger than 32-bit variables. Then the stack space allocated for a "long long" variable would be double the native word.

But shouldn't then char be 0.25? Very Happy
Post 21 Sep 2009, 11:58
View user's profile Send private message Visit poster's website Yahoo Messenger MSN Messenger Reply with quote
madmatt



Joined: 07 Oct 2003
Posts: 1045
Location: Michigan, USA
madmatt
Madis731 wrote:
no matter if it is a char, short, long or a double.


actually in 32bit windows, a double parameter requires you to add 2 to the pcount variable, not just one. I don't know about 64bit windows.

_________________
Gimme a sledge hammer! I'LL FIX IT!
Post 29 Sep 2009, 07:23
View user's profile Send private message Reply with quote
bitshifter



Joined: 04 Dec 2007
Posts: 764
Location: Massachusetts, USA
bitshifter
Is Tomasz planning on expanding the standard include set?
If so, i can donate some time for API/EQUATES/PCOUNT files.
Recently i have been working on opengl32 and openal32 files.
I would really like to see opengl as a standard for fasm Smile
Also winmm32 would be a good one to have...
Post 11 Oct 2009, 09:34
View user's profile Send private message Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 7751
Location: Kraków, Poland
Tomasz Grysztar
Post 11 Oct 2009, 09:44
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on YouTube, Twitter.

Website powered by rwasa.