News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

Moving to 64bit

Started by johnsa, July 06, 2010, 07:46:23 AM

Previous topic - Next topic

johnsa

Hey all,

I use masm / 32bit all the time, both for fun and for a bit of commercial work. I've kept an eye on the 64bit stuff in the past, and have used fasm for doing some 64bit code on a hobby-os project.
I really want to start moving some of my commercial 32bit windows work to 64bit and I'm not 100% sure of where everything stands at present.

I really love masm when it comes to working in 32bits, between the extensive work in porting headers/inc files, the macros and things to speed up / simplify coding make it a joy to work with. But from what I see 64bit ML/masm isn't really there yet.

Whats the status on porting all the necessary 64bit stuff to inc files?

Which would be the best assembler to use for 64bit win coding? - hopefully with necessary extensions to do proto/invoke/local etc. I'm not too keen on having to write out all the length code everytime i want to call something.

ecube

GoAsm is the best assembler in working with 64bit, and it's extremely similiar to MASM but has lot of benefits and few downside(depending on your view)

Advantages
- No more damn protos! yes thats write you don't need to write protos for your functions, just use em
- 64bit code is extremely similar to 32bit in GoASM, invoke auto handles the differences and registers are auto translated (eax to rax etc...)
- NO damn libs needed! Goasm auto extracts the necessary api info from dll's, while you can use static libs fine in GoASM you don't need em for winapi
- Inline string support!! so can do stuff like

invoke MessageBox,0,'hey i'm a string!','im a title',MB_OK ;this works fine on 32bit/64bit

- Awesome INVOKE support(allows you to call dynamic ptrs like normal functions! invoke eax,[param1], etc....
-Amazing unicode string support, has lot of options makes unicode very easy
- Great supports for windows headers(can translate all auto from the sdk, though I find donkeys manually translated ones are good for the most part, includes 64bit structs and stuff
- features like INCBIN allows you to include files inside your exe and use them like any data ptr, this is much better than the painful DB translation u gotta do with masm only have it to take 10 mins and 100% cpu to assemble in...or the .obj trick I find inconventient

the list goes on...point is GoASM rocks, and masm64 is beyond a joke

to get started I recommend you use my old(yet still useful) I really need to update GoASM sdk, includes donkeys headers, good number of 32bit/64bit examples, GoASM binaries, help files etc....
http://www.masm32.com/board/index.php?topic=11180.0


Additionally you can use JWASM which is a masm clone with 64bit support, I personally don't like it much at all, it errors on the simplest things, and trying to file bugs is pain staking with Japhelins elitest attitude(IMO anyway) so I don't bother. GoASM's author is pretty busy right now but hes a really friendly, intelligent guy.

Also FASM is a great 32bit/64bit assembler, but it lacks lot of definitions, and isn't complete enough for myself personally,as I use GoASM in commerical projects(32bit and 64bit) and I love it.


Ficko

Quoteand trying to file bugs is pain staking with Japhelins elitest attitude(IMO anyway) so I don't bother

I think you have to distinguish between "attitude of reply" and "attitude of doingness". :naughty:

If I filed a bug report and it had merit in it he often fixed it in 24 hours.

Try that with M$. :toothy

jcfuller

Quote from: Ficko on July 06, 2010, 11:59:35 AM
Quoteand trying to file bugs is pain staking with Japhelins elitest attitude(IMO anyway) so I don't bother

I think you have to distinguish between "attitude of reply" and "attitude of doingness". :naughty:

If I filed a bug report and it had merit in it he often fixed it in 24 hours.

Try that with M$. :toothy

My experience is identical to yours Ficko.

James

jj2007

Quote from: E^cube on July 06, 2010, 08:21:37 AM
Additionally you can use JWASM which is a masm clone with 64bit support, I personally don't like it much at all, it errors on the simplest things, and trying to file bugs is pain staking with Japhelins elitest attitude(IMO anyway)

Japheth's manners are occasionally a bit too German, but JWasm is an incredible product, and I regularly assemble my MasmBasic library without any problems - in spite of many very idiosyncratic macros. And as Ficko rightly says, if there is a real problem, it often gets fixed within a day.

Igor

Quote from: E^cube on July 06, 2010, 08:21:37 AM
- No more damn protos! yes thats write you don't need to write protos for your functions, just use em
This is also the same in masm64.

qWord

Quote from: Igor on July 08, 2010, 06:33:36 PM
Quote from: E^cube on July 06, 2010, 08:21:37 AM
- No more damn protos! yes thats write you don't need to write protos for your functions, just use em
This is also the same in masm64.
yep, because ml64 doesn't support the invoke-macro :(
FPU in a trice: SmplMath
It's that simple!

arlando

Using .if,.while,.repeat,invoke... macros still is possible with ml64.

GregL

arlando,

Those are some interesting macros you wrote there.


arlando

Yes, I am and use them last 7 month.
Today I have  masm64 project, which contain 1923 .if`s.

Igor

It seems that you defined each IF/ELSEIF separately up to 20, maybe you could remove that limitation and simplify them if you take a look at this macros http://www.masm32.com/board/index.php?topic=5654.0

arlando

I think, this 20 nesting level of .ifs is enough.
Why you need more?

arlando

Original built-in masm32 macros have almost same limitation with 19 levels.

This code can be assembled with my macros and you may try increase levels by 1.

.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax
.if eax

.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif
.endif