The MASM Forum

64 bit assembler => 64 bit assembler. Conceptual Issues => Topic started by: Negens on January 19, 2017, 10:37:00 AM

Title: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: Negens on January 19, 2017, 10:37:00 AM
I successfully installed ml64.exe on Windows 8 but, on Windows 7 64bits, ml64.exe doesn't do anything.
No error, no messages, nothing !!!

ml64.exe /? doesn't even print anything !  :icon_eek:

For information, ml.exe workds fine.
Have you ever encountered that ?


EDIT : I finally opt for jwasm/jwlink solution that works pretty well.
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: hutch-- on January 19, 2017, 12:18:59 PM
It sounds like you are in business with JWASM/JLINK but your problem with ML64 sounds unusual. Hard to tell with no version info but various versions of ML64 run on Win7/8/10 with no problems.
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: rrr314159 on January 19, 2017, 10:17:22 PM
Negens, ml64 should work on Win7. There must be something wrong with your installation. But your conclusion is right, IMHO. Use JWasm and / or its forks. They're much better than ml64 IMHO.
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: jj2007 on January 19, 2017, 11:45:34 PM
HJWasm works fine, even with the Microsoft linkers, but beware of incompatibility problems with the set of macros that have been developed by Vasily & Hutch to overcome the lack of invoke in ML64. (http://masm32.com/board/index.php?topic=5662.msg60362#msg60362) Hutch has invested an awful lot of work in the 64-bit equivalent to the Masm32 library, but so far there is no switch that would disable specific macros that collide with valid HJWasm keywords such as "invoke"; as a result, HJWasm will bark at you if it finds invoke macro args in the include files.

Note also that the native invoke macro, in 32-bit code as well as in its jinvoke variant (http://masm32.com/board/index.php?topic=5314.msg59884#msg59884), counts and checks arguments. AFAIK the ML64 substitute developed by Vasily doesn't care if you supply 10 or 11 arguments to CreateWindowEx. Some see that as a feature 8)
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: hutch-- on January 20, 2017, 12:08:56 AM
I would not worry too much, the alternative assemblers are not compatible with 64 bit MASM so you will not be using any of it. Its includes, static libraries and macros are designed to work only with 64 bit MASM, if you use other assemblers, you must use what is provided with them. I don't need to proselytise for the Microsoft assembler, it is probably the most widely distributed assembler in the world as part of Visual Studio.
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: jj2007 on January 20, 2017, 12:16:09 AM
Quote from: hutch-- on January 20, 2017, 12:08:56 AMI would not worry too much, the alternative assemblers are not compatible with 64 bit MASM

Truth is that ML64 is not compatible with ML32 (and HJWasm, AsmC) because it lacks invoke and the high level .if ... .endif etc constructs that Masm introduced 20 years ago.

QuoteI don't need to proselytise for the Microsoft assembler

If you don't have to, why are you doing it then?  ::) ;)
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: hutch-- on January 20, 2017, 12:31:56 AM
I keep hearing noise from people who have not done enough to write 64 bit MASM properly.  :biggrin:

Truth is that 64 bit MASM is a low level tool designed by Microsoft for experienced programmers. The ML design that so many are aping was designed by Microsoft 27 years ago so its not like its leading edge.  :P

Boasting about 16 bit ML compatibility is like boasting about a T model Ford.  :badgrin:
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: TWell on January 20, 2017, 12:57:01 AM
Enjoy how nicely it output errors in commandline
Quoteml64.exe "C:\Users\TWell\Documents\code\foo1.asm"
Microsoft (R) Macro Assembler (x64) Version 14.00.23506.0
Copyright (C) Microsoft Corporation.  All rights reserved.

Assembling: C:\Users\TWell\Documents\code\foo1.asm
C:\Users\TWell\Documents\code\foo1.asm(7)cified size
C:\Users\TWell\Documents\code\foo1.asm(7) : error A2006:undefined s
Easy to read?
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: jj2007 on January 20, 2017, 01:13:20 AM
Quote from: TWell on January 20, 2017, 12:57:01 AM
Enjoy how nicely it output errors in commandline

Yes indeed (http://masm32.com/board/index.php?topic=5678.msg60531#msg60531) - but on the positive side, it's a Microsoft product :icon_mrgreen:

Quote from: rrr314159 on September 25, 2016, 06:49:13 PMAs a child, Bill got his kicks pulling the wings off flies and watching them struggle helplessly. Now he gets his kicks turning out loads of chyte and watching you struggle helplessly trying to install it and get it working. But he still puts in long hours, devising new ways to make you suffer. ML64 was one of his finest creations. The man's a genius: compared to him the Marquis de Sade was a bumbling amateur.
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: Negens on January 20, 2017, 01:20:56 AM
Quote from: hutch-- on January 19, 2017, 12:18:59 PM
It sounds like you are in business with JWASM/JLINK but your problem with ML64 sounds unusual. Hard to tell with no version info but various versions of ML64 run on Win7/8/10 with no problems.

You were absolutely right !
I took an ML64.exe (and a link.exe) a bit older and they work.

:t
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: hutch-- on January 20, 2017, 01:47:11 AM
Negens,

Glad you got it going OK.  :t

For our unhappy friends who don't understand how to write code in a low level assembler, 64 bit MASM has full include files, complete working import libraries, its own static library that just keeps growing and it is already production capable, has its own prologue/epilogue that works just fine and a call automation macro that supports a number of different wrappers including "invoke" that will handle 24 arguments. It is aimed at professional assembler programmers who don't need the hand holding and for the experienced it is a lot faster to develop with by not having to endlessly construct 1990 style prototypes.

Its also a current assembler maintained by Microsoft, is part of Visual Studio and is the most widely distributed assembler in the world. It is also THE release version, its not under constant development and only changes when something needs to be added to it. Must be tough when you are dependent on 1990 technology to hold your hot little hand.  :P
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: vengy on February 21, 2017, 11:26:57 AM
I reported an ml64.exe output corruption bug which I see you're also having:

ml64.exe "C:\Users\TWell\Documents\code\foo1.asm"
Microsoft (R) Macro Assembler (x64) Version 14.00.23506.0
Copyright (C) Microsoft Corporation.  All rights reserved.

Assembling: C:\Users\TWell\Documents\code\foo1.asm
C:\Users\TWell\Documents\code\foo1.asm(7)cified size
C:\Users\TWell\Documents\code\foo1.asm(7) : error A2006:undefined s

It's been fixed in vs2017, but not updated in vs2015.

https://social.msdn.microsoft.com/Forums/vstudio/en-US/335944b0-89d0-4e06-8f28-09eb1f5eaa0e/masm-ml64exe-corrupted-errorswarnings?forum=vclanguage
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: hutch-- on February 21, 2017, 12:15:11 PM
Thanks Vengy,

Some of the error outputs were less than intuitive (garbled nonsense) especially with the include files if there were any errors in them. Will have to get the later version and test it  to see how it works on Win 10. Now our friends using Watcom clones will have one less item to complain about but no doubt they will find something to sob silently in a corner about.  :P
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: jj2007 on February 21, 2017, 12:45:23 PM
Quote from: hutch-- on February 21, 2017, 12:15:11 PMWill have to get the later version

Some later versions have garbled output, see also
http://masm32.com/board/index.php?topic=5662.msg60775#msg60775
http://masm32.com/board/index.php?topic=5678.msg60531#msg60531

Version 19 March 2010, for example, is OK in this respect (but chokes occasionally over valid code, and is not compatible to 32-bit MASM syntax, as we all know :greensml:)

Microsoft (R) Macro Assembler (x64) Version 14.00.24210.0 is extremely slow, unless there is a switch that I haven't found yet. It almost freezes.
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: hutch-- on February 21, 2017, 01:04:03 PM
The problem is with your assumptions of multi-port code using different assemblers. Old 16/32 bit MASM is not compatible with 64 bit MASM which is a separate stand alone tool. I have no problems at all running the current version of 64 bit MASM but then I am not trying to run legacy incompatible code with it, I only assembler Microsoft 64 bit MASM code with 64 bit MASM. MASM in 64 bit does not support either 16 bit or 32 bit MASM code, for that you use 16 or 32 bit ML.EXE which has been around since 1990.

Since VC/VS is the major development environment at a world level, its version of 64 bit MASM is the reference for MASM compatibility, for the little that its worth, 16 bit real mode MASM code does not build with the 64 bit version of MASM either. The Watcom clones under development are not MASM 64 compatible which is of course their right to develop whatever they like.

Since I can tolerate many different tools, FASM is not ML 32 compatible, neither is GAS, Jeremy Gordon's assembler, Bogdan's assembler, there is a 64 bit Russian version of TASM that is 64 bit from memory, all which are not 32 bit MASM compatible.
Title: Re: [RESOLVED] ml64.exe and Windows 7 doesn't produce anything
Post by: hutch-- on February 21, 2017, 02:26:23 PM
I have tracked down the time lag that JJ mentioned. I downloaded the vs 2017 release candidate enterprise edition (all 15 gig of it) and climbed through an archipelago of directories,

C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\VC\Tools\MSVC\14.10.24930\bin>

And found the usual 2 different versions of ML64. The version under "hostX64" is larger and probably a 64 bit version. It had some seconds delay before it will build a simple x64 app. The version under "hostX86" is smaller and probably a 32 bit executable but its much faster than the other and builds 64 bit MASM file just fine.

Here is a simple demo of picking the right version of ML64 for Windows 10 64 bit. Clean simple 64 bit MASM code.  :biggrin:

; ¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤

    include \masm32\include64\masm64rt.inc

    .code

; ¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤

entry_point proc

    conout lf,"Hi hi hi, I am a console app built with",lf, \
              "ML64 version 14.10.24930.0 from VS 2017",lf, \
              "on Windows version 10 professional 64 bit",lf,lf
    waitkey

    invoke ExitProcess,0

    ret

entry_point endp

; ¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤¤

    end


Build output.

Microsoft (R) Macro Assembler (x64) Version 14.10.24930.0
Copyright (C) Microsoft Corporation.  All rights reserved.

Assembling: console.asm
Volume in drive K is disk3_k
Volume Serial Number is 68C7-4DBB

Directory of K:\asm64\console

02/21/2017  02:20 PM               590 console.asm
02/21/2017  02:23 PM             4,096 console.exe
02/21/2017  02:23 PM             2,526 console.obj
               3 File(s)          7,212 bytes
               0 Dir(s)  973,757,313,024 bytes free
Press any key to continue . . .


App output.


Hi hi hi, I am a console app built with
ML64 version 14.10.24930.0 from VS 2017
on Windows version 10 professional 64 bit

Press any key to continue...


Cruel ain't it.  :P