Posted July 9, 200916 yr in visual c++ 2005 x64 it doesn't support the inline assembly __asm so to write assembly i must write it in a .asm file then call it from my code i need a tutorials for writing x64 assembly and how to call it as a function from c++or at least i nead an x64 IDE assemblerthnx in advance
July 9, 200916 yr Hi,You can use fasm for x64 asm coding .Or you can code x64 asm in masm and link the generated .obj file with your application, i don't have x64 compiler to test but i think it's the same as linking x86 .obj files .
July 19, 200916 yr Author thanx for ur reply I have added a file .asm to my x64 VS2005 project it compiles well using masm compiler but when linking it gives me this error fatal error LNK1112: module machine type 'X86' conflicts with target machine type 'x64'even the project build well (previous error didn't appear)in x64 without the file .asmdo any one what is the solution for this
July 19, 200916 yr Hi,You can use fasm for x64 asm coding .Or you can code x64 asm in masm and link the generated .obj file with your application, i don't have x64 compiler to test but i think it's the same as linking x86 .obj files .Last time I compiled a x64 app, it is. You just select the x64 building option in your project settings, if you have the x64 compile set installed.Though, I use MSVC2008, which supports x64 fully, and even when cross-compiling....
July 19, 200916 yr Author Hi,You can use fasm for x64 asm coding .Or you can code x64 asm in masm and link the generated .obj file with your application, i don't have x64 compiler to test but i think it's the same as linking x86 .obj files .Last time I compiled a x64 app, it is. You just select the x64 building option in your project settings, if you have the x64 compile set installed.Though, I use MSVC2008, which supports x64 fully, and even when cross-compiling....i had done all what u said but it still give me the same error fatal error LNK1112: module machine type 'X86' conflicts with target machine type 'x64'even the assembly file i added in the project is in another project which compile & link (Build) successfully
July 19, 200916 yr there are 2 version of masm,masm x86 and masm x64.ml.exe and ml64.exeMicrosoft ® Macro Assembler (x64) Version 9.00.21022.08maybe use proper one. Edited July 19, 200916 yr by human
July 19, 200916 yr Author there are 2 version of masm,masm x86 and masm x64. ml.exe and ml64.exe Microsoft ® Macro Assembler (x64) Version 9.00.21022.08 maybe use proper one. Great thanks to all of you i figured the solution at last right click on the asm file - properties in the custom build step write this in the command line ml64.exe /DWIN_X64 /Zi /c /Fl /Fo $(IntDir)\$(InputName).obj $(InputName).asm
Create an account or sign in to comment