Recent Posts

Pages: [1] 2 3 ... 10
1
The Workshop / Re: My third 64 bit console app...
« Last post by felipe on Today at 06:58:49 AM »
Thanks again.  :icon14:
2
MASM64 SDK / copy to bin64 batch file
« Last post by zedd151 on Today at 06:26:27 AM »
batch file to simplify moving MS binaries to bin64 folder

Code: [Select]
rem modify paths for your system/folders
rem example: set inpath="D:\x64\bin64"
rem example: set outpath="C:\masm32\bin64"

set inpath="..."
set outpath="..."

set inpath1033="..."
set outpath1033="..."


xcopy %inpath%\cvtres.exe %outpath% /hrky
xcopy %inpath%\dumpbin.exe %outpath% /hrky
xcopy %inpath%\editbin.exe %outpath% /hrky
xcopy %inpath%\lib.exe %outpath% /hrky
xcopy %inpath%\link.exe %outpath% /hrky
xcopy %inpath%\link.exe.config %outpath% /hrky
xcopy %inpath%\ml64.exe %outpath% /hrky
xcopy %inpath%\msobj140.dll %outpath% /hrky
xcopy %inpath%\mspdb140.dll %outpath% /hrky
xcopy %inpath%\mspdbcmf.exe %outpath% /hrky
xcopy %inpath%\mspdbcore.dll %outpath% /hrky
xcopy %inpath%\mspdbsrv.exe %outpath% /hrky
xcopy %inpath%\mspdbst.dll %outpath% /hrky
xcopy %inpath%\mspft140.dll %outpath% /hrky
xcopy %inpath%\msvcdis140.dll %outpath% /hrky
xcopy %inpath%\msvcp140.dll %outpath% /hrky

xcopy %inpath1033%\bscmakeui.dll %outpath1033% /hrky
xcopy %inpath1033%\clui.dll %outpath1033% /hrky
xcopy %inpath1033%\cvtresui.dll %outpath1033% /hrky
xcopy %inpath1033%\linkui.dll %outpath1033% /hrky
xcopy %inpath1033%\LocalESPCui.dll %outpath1033% /hrky
xcopy %inpath1033%\mspdbcmfui.dll %outpath1033% /hrky
xcopy %inpath1033%\mspft140ui.dll %outpath1033% /hrky
xcopy %inpath1033%\pgort140ui.dll %outpath1033% /hrky
xcopy %inpath1033%\pgoui.dll %outpath1033% /hrky
pause


Filenames taken directly from hutch's list of files needed (Microsoft_File_List.txt)
 
Will need to change paths as necessary for your system/masm64 path...

3
The Orphanage / Re: I'll be buying a new computer...
« Last post by zedd151 on Today at 05:11:35 AM »
For those who would like more details for what I have done already...

 The changes I have made to the clean installation of Windows 10 Home:

--------------------------------------------------------------------------------
To enable the hidden "Administrator" account in Windows 10 Home, from an elevated command prompt (run as administrator):

Code: [Select]

Net user administrator /active:yes


To set a password for "Administrator", from an elevated Command Prompt:

Code: [Select]

Net Users Administrator *


and hit Enter. Now you will see new line to type a new password for administrator - and your new Administrator account is all set and ready on the next reboot.

---------------------------------------------------------------------------------
Enabling "Group Policy Editor" in the Home version create a .bat file with the following:

Code: [Select]

@echo off
pushd "%~dp0"
dir /b C:\Windows\servicing\Packages\Microsoft-Windows-GroupPolicy-ClientExtensions-Package~3*.mum >Files.txt
dir /b C:\Windows\servicing\Packages\Microsoft-Windows-GroupPolicy-ClientTools-Package~3*.mum >>Files.txt
echo Installing Group Policy Editor...
for /f %%i in ('findstr /i . Files.txt 2^>nul') do dism /online /norestart /add-package:"C:\Windows\servicing\Packages\%%i"
echo.
echo Installation complete.
echo.
pause

Run from an elevated command prompt. (run as administrator)

Using the above, you enable the Group Policy Editor in Windows 10 Home Edition (8 & 7 too, I believe), which is not enabled by default in the Home version.

----------------------------------------------------------------------------------

The other good thing to use is Easy Context Menu <-- direct download link.
With this program, you can add to the right click context menu "Copy to Folder...", "Move to Folder...",
 and my favorite "Take Ownership", which allows you to delete/change files or folders blocked by "SYSTEM" or "TRUSTEDINSTALLER", plus many
other tweaks.


As a cautionary note: DO NOT MAKE THESE CHANGES unless you have a backup of your system,
and secondly don't do it unless you know what you are doing.

The "Administrator" account enabling is well documented in many places on the internet.

The enabling of "Group Policy Editor" is also well documented...


+++++++++++++++++++++++++++++++++++++++++++++++++++++++

The other changes I have made to MY SYSTEM will not be posted here. Any changes you make
to  Your System are solely your responsibility.


 :biggrin:

4
Game Development / Re: dinofun (more gdi testing)
« Last post by daydreamer on Today at 04:59:59 AM »
hi, yep. It starts with an ascII file for each map. It’s then parsed and compressed by code. When loaded, we have this big array of 0/1. 0 for vaild spaces, 1 for forbiden terrain.


it’s in fact an array of pointers under the hood.


The collision detection is simple, once we convert the xy screen coordinates and compare with what there is in the array for that spot.


It’s slightly harder for my plane’s bullets, since they travel upwards, while the map scrolls downwards. But it’s just simple maths and comparing areas for intersection.


jumping is rather easy too. I usually do as Daydreamer already said.
Thanks for sharing
5
The Laboratory / Re: VMOVQ vs VMOVAPS
« Last post by johnsa on Today at 04:28:15 AM »
Found the problem.. FYI, it's not the vmovaps so much that was causing the issue but rather the subsequent two vmovq writes to the same memory location. This must have caused some sort of partial stall on the vmovaps read waiting for both writes to complete, now that it's replaced with a vmovaps to store as well the write and read complete as expected and the performance is where it should be.
6
The Orphanage / Re: I'll be buying a new computer...
« Last post by zedd151 on Today at 04:24:28 AM »
Hello zedd;
..... Other way is that you can create an image of your hard disk as a backup......

That is the method I use. Drive Snapshot Works well, so if I change anything either inadvertently or not, I can always revert to the way it was before.

I don't keep personal files and/or folders on my C: drive anymore, so the way I keep the backup copy now is perfect for me.

Thanks for the other tips. And yes, I have tamed the Windows 10 beast and killed all sorts of reporting back to Micros**t.   :biggrin: And the system is running well.

One thing that I want to try is creating an image using Dism.exe offline, using this method according to the documentation I have read, I should be able to remove "packages" to create a custom OS install. More on that later when I get up the b***s to try it.  :P  If that works out well, it should help in reducing the overall size of the OS. But research must be done first to avoid removing "System Critical" packages. I will post a detailed (somewhat) accounting of those proceedings if/when I decide to try it.
7
The Workshop / Re: My third 64 bit console app...
« Last post by AW on Today at 03:50:04 AM »
Quote
;I did this based in "the caller is responsible of cleaning the stack". So i thought this must be done until
;   call to a procedure that needs more stack space. Seems like in this simple program case windows clean all for us 
;     when the process is done?
You can do but you should not do, if a procedure calls 1000 times other procedures you will spend a lot of time reserving and clearing stack. So, all should be done in the beginning of the procedure reserving space for the procedure that will use the most stack and keeping in mind that all procedures will be called with the stack aligned.

Quote
So we can only do pushes when we are using a stack frame?
The problem with the pushes is that they change the alignment.
So, if you align in the beginning of the procedure why are going to misalign?

All right, these things take time to understand.  :t

8
MASM64 SDK / Re: Library update May 2018
« Last post by felipe on Today at 03:36:21 AM »
You will need to have the 64 bit add on for MASM32 set up and working properly

Sorry my english hutch, i use the masm64 sdk renaming the masm32 sdk folder temporarily, then renaming the masm64 sdk to masm32 (temporarily too) and both resides in the same disk...Do you mean there's another method to use the masm64 sdk (apart of using different partitions for each sdk)?

Btw, the building process looks to work fine... :t
Code: [Select]
Assembling: low_ascii.asm
 Assembling: ltok.asm
 Assembling: mcopy.asm
 Assembling: MonthByNumber.asm
 Assembling: msgboxi.asm
 Assembling: NameFromPath.asm
 Assembling: onecrlf.asm
 Assembling: opendlg.asm
 Assembling: preparse.asm
 Assembling: progress.asm
 Assembling: radiobutton.asm
 Assembling: rawssort.asm
 Assembling: realloc.asm
 Assembling: recopyall.asm
 Assembling: reselectall.asm
 Assembling: ResImageLoad.asm
 Assembling: restreamin.asm
 Assembling: restreamout.asm
 Assembling: rrand.asm
 Assembling: savedlg.asm
 Assembling: save_file.asm
 Assembling: shell.asm
 Assembling: statcntr.asm
 Assembling: statleft.asm
 Assembling: statrght.asm
 Assembling: stdout.asm
 Assembling: string_clean.asm
 Assembling: stripcc.asm
 Assembling: strlen.asm
 Assembling: str_strip.asm
 Assembling: syslink.asm
 Assembling: szappend.asm
 Assembling: szcatstr.asm
 Assembling: szcmp.asm
 Assembling: szCmpi.asm
 Assembling: szcopy.asm
 Assembling: szLeft$.asm
 Assembling: szleft.asm
 Assembling: szlen.asm
 Assembling: szlower.asm
 Assembling: szltrim.asm
 Assembling: szmono.asm
 Assembling: szmulticat.asm
 Assembling: szremove.asm
 Assembling: szrep.asm
 Assembling: szRev.asm
 Assembling: szRight$.asm
 Assembling: szright.asm
 Assembling: szrtrim.asm
 Assembling: szSpace.asm
 Assembling: szTrim.asm
 Assembling: szupper.asm
 Assembling: szwcnt.asm
 Assembling: txt2mem.asm
 Assembling: waitkey.asm
 Assembling: wordtok.asm
 Assembling: xmmcopya.asm
 Assembling: xor_data.asm
 Assembling: ymmcopya.asm
 Assembling: zerofill.asm

Microsoft (R) Library Manager Version 14.13.26129.0
Copyright (C) Microsoft Corporation.  All rights reserved.

appath.obj
appname.obj
arrev.obj
ascii_dump.obj
aspect_ratio.obj
atou_ex.obj
bcopy.obj
bff.obj
bin2hex.obj
bintable.obj
bitmap_image.obj
block_ltrim.obj
block_monospace.obj
block_rtrim.obj
block_trim.obj
button.obj
chartype.obj
char_count.obj
checkbox.obj
chfilter.obj
CloseMMF.obj
cmd_tail.obj
cpu_id_string.obj
CreateMMF.obj
dbcompact.obj
editbox.obj
errout.obj
execute.obj
exist.obj
findstr.obj
fixed_array.obj
fonthandle.obj
GetPathOnly.obj
getpercent.obj
getvendor.obj
get_ext.obj
get_unique_seed.obj
group_box.obj
hexdump.obj
hexstream.obj
hex_table.obj
inbin.obj
intdiv.obj
intmul.obj
irand.obj
lfcnt.obj
listbox.obj
lntok.obj
LoadGdiImage.obj
load_file.obj
low_ascii.obj
ltok.obj
mcopy.obj
MonthByNumber.obj
msgboxi.obj
NameFromPath.obj
onecrlf.obj
opendlg.obj
preparse.obj
progress.obj
radiobutton.obj
rawssort.obj
realloc.obj
recopyall.obj
reselectall.obj
ResImageLoad.obj
restreamin.obj
restreamout.obj
rrand.obj
savedlg.obj
save_file.obj
shell.obj
statcntr.obj
statleft.obj
statrght.obj
stdout.obj
string_clean.obj
stripcc.obj
strlen.obj
str_strip.obj
syslink.obj
szappend.obj
szcatstr.obj
szcmp.obj
szCmpi.obj
szcopy.obj
szLeft$.obj
szleft.obj
szlen.obj
szlower.obj
szltrim.obj
szmono.obj
szmulticat.obj
szremove.obj
szrep.obj
szRev.obj
szRight$.obj
szright.obj
szrtrim.obj
szSpace.obj
szTrim.obj
szupper.obj
szwcnt.obj
txt2mem.obj
waitkey.obj
wordtok.obj
xmmcopya.obj
xor_data.obj
ymmcopya.obj
zerofill.obj
 El volumen de la unidad C no tiene etiqueta.
 El número de serie del volumen es: B2C1-CB3E

 Directorio de C:\masm32\m64lib

24-05-2018  13:28           179.620 m64lib.lib
               1 archivos        179.620 bytes
               0 dirs  70.563.930.112 bytes libres
 El volumen de la unidad C no tiene etiqueta.
 El número de serie del volumen es: B2C1-CB3E

 Directorio de C:\masm32\m64lib

12-08-2016  05:23               755 appath.asm
12-08-2016  05:23             1.060 appname.asm
11-07-2017  01:25               913 arrev.asm
18-09-2016  19:04             5.405 ascii_dump.asm
27-08-2016  21:25               651 aspect_ratio.asm
06-09-2016  00:16             3.334 atou_ex.asm
11-02-2018  09:18               650 bcopy.asm
28-08-2016  20:05             3.152 bff.asm
20-09-2016  23:28             2.291 bin2hex.asm
18-09-2016  21:21             2.919 bintable.asm
14-02-2017  11:07               662 bitmap_image.asm
04-07-2017  21:41             1.501 block_ltrim.asm
16-02-2018  21:08             2.376 block_monospace.asm
04-07-2017  21:37             1.581 block_rtrim.asm
02-07-2017  21:45               504 block_trim.asm
01-03-2017  20:20               692 button.asm
10-08-2017  12:12             2.067 chartype.asm
27-06-2017  05:57             1.517 char_count.asm
20-09-2016  03:59               690 checkbox.asm
18-02-2018  17:02             2.399 chfilter.asm
06-11-2016  11:58               513 CloseMMF.asm
14-08-2016  19:46             2.069 cmd_tail.asm
08-08-2017  13:23             1.647 cpu_id_string.asm
08-11-2016  08:59             1.307 CreateMMF.asm
18-09-2016  19:06               908 dbcompact.asm
20-09-2016  04:02               691 editbox.asm
20-08-2016  23:26             1.010 errout.asm
30-08-2017  07:59               876 execute.asm
27-08-2016  21:25               705 exist.asm
15-06-2017  11:52             3.197 findstr.asm
08-09-2016  21:28             2.940 fixed_array.asm
27-08-2016  21:26               582 fonthandle.asm
11-10-2017  00:18             1.141 GetPathOnly.asm
27-08-2016  21:26               554 getpercent.asm
19-12-2016  20:39               986 getvendor.asm
12-03-2018  10:50             2.022 get_ext.asm
08-08-2017  10:02             1.213 get_unique_seed.asm
29-10-2016  23:19               673 group_box.asm
10-09-2016  11:45             3.302 hexdump.asm
21-09-2016  14:03             4.557 hexstream.asm
10-09-2016  11:44               965 hex_table.asm
21-09-2016  01:10             2.869 inbin.asm
14-08-2016  19:45               566 intdiv.asm
14-08-2016  19:46               572 intmul.asm
13-08-2017  21:04             1.224 irand.asm
24-06-2017  00:58             1.192 lfcnt.asm
20-08-2017  05:33               726 listbox.asm
15-06-2017  23:42             5.761 lntok.asm
15-02-2017  21:46             1.148 LoadGdiImage.asm
09-01-2017  22:55             1.631 load_file.asm
24-06-2017  07:46             2.681 low_ascii.asm
27-08-2016  21:26             3.023 ltok.asm
14-08-2016  19:40               807 mcopy.asm
29-09-2016  22:00             1.115 MonthByNumber.asm
11-09-2016  05:51             1.389 msgboxi.asm
10-10-2017  20:55             1.400 NameFromPath.asm
01-07-2017  07:12             1.558 onecrlf.asm
09-11-2017  13:30             2.032 opendlg.asm
02-07-2017  22:07             2.685 preparse.asm
04-11-2016  11:06               699 progress.asm
20-09-2016  03:57               699 radiobutton.asm
20-08-2017  05:25             5.493 rawssort.asm
04-11-2016  11:06               997 realloc.asm
22-12-2016  00:48               602 recopyall.asm
22-12-2016  00:46               697 reselectall.asm
11-02-2017  14:30             1.409 ResImageLoad.asm
27-08-2016  21:27             1.390 restreamin.asm
27-08-2016  21:28             1.403 restreamout.asm
07-02-2018  06:02             1.390 rrand.asm
16-03-2017  14:50             2.016 savedlg.asm
12-08-2016  05:56               830 save_file.asm
04-08-2017  22:46             1.590 shell.asm
21-12-2017  19:15               785 statcntr.asm
21-12-2017  19:13               783 statleft.asm
21-12-2017  19:16               784 statrght.asm
19-02-2018  00:22             1.148 stdout.asm
17-02-2018  00:00               518 string_clean.asm
21-09-2016  04:50             1.661 stripcc.asm
10-02-2018  20:10             1.596 strlen.asm
24-06-2017  07:46             3.168 str_strip.asm
01-11-2016  10:38               743 syslink.asm
27-08-2016  21:29             1.106 szappend.asm
28-08-2016  08:48               934 szcatstr.asm
14-08-2016  19:41               988 szcmp.asm
30-07-2017  02:02             2.564 szCmpi.asm
14-08-2016  19:38               809 szcopy.asm
11-10-2017  02:56             1.026 szLeft$.asm
14-08-2016  19:41               883 szleft.asm
30-07-2017  01:57               662 szlen.asm
14-08-2016  19:42               655 szlower.asm
07-01-2018  19:59             1.125 szltrim.asm
02-07-2017  21:26             1.813 szmono.asm
27-08-2016  21:32             1.126 szmulticat.asm
14-08-2016  19:43             1.771 szremove.asm
27-08-2016  21:33             2.420 szrep.asm
01-08-2017  02:33             2.047 szRev.asm
11-10-2017  02:58             1.324 szRight$.asm
14-08-2016  19:44             1.552 szright.asm
14-08-2016  19:44               881 szrtrim.asm
27-09-2017  05:30               755 szSpace.asm
12-08-2016  05:34               568 szTrim.asm
14-08-2016  19:44               655 szupper.asm
27-08-2016  21:34             1.535 szwcnt.asm
13-08-2017  05:11             1.941 txt2mem.asm
12-08-2016  05:35               631 waitkey.asm
23-05-2018  02:40             1.798 wordtok.asm
16-03-2017  15:31             1.081 xmmcopya.asm
11-09-2016  05:59             2.090 xor_data.asm
23-09-2016  10:24               997 ymmcopya.asm
16-03-2017  14:46               949 zerofill.asm
             110 archivos        166.443 bytes
               0 dirs  70.563.930.112 bytes libres
Presione una tecla para continuar . . .
9
MASM64 SDK / Re: Library update May 2018
« Last post by felipe on Today at 03:20:35 AM »
Thanks hutch. You have done a great job with the masm64 sdk.  :greenclp:
10
The Workshop / Re: My third 64 bit console app...
« Last post by felipe on Today at 03:15:02 AM »
Code: [Select]
option casemap:none
include \masm32\include64\win64.inc
include \masm32\include64\kernel32.inc
includelib  \masm32\lib64\kernel32.lib

.data
inbuff      byte    256 dup(" ")

.data?
chrsread    dword   ?

.code
start   proc
        sub     rsp,40      ; Shadow space + stack alignment + STACK VARIABLES SPACE FOR THE WHOLE PROCEDURE. Ok i think i understand             
                                  ;    this. The extra parameters go "above" the shadow space.
        call    AllocConsole

        mov     rcx,STD_INPUT_HANDLE
        call    GetStdHandle

        ;add     rsp,40      ; WRONG   I did this based in "the caller is responsible of cleaning the stack". So i thought this must be done until
                                    ;   call to a procedure that needs more stack space. Seems like in this simple program case windows clean all for us 
                                    ;     when the process is done?
        ;push    NULL        ; Reserved. DON't DO PUSHES. So we can only do pushes when we are using a stack frame?

        ;sub     rsp,40      ; Shadow space + stack alignment. NO

  mov qword ptr [RSP+32], NULL ; LIKE THIS.
        mov     rcx,rax     ; stdin.   
        lea     rdx,inbuff
        mov     r8,256      ; Chars to read.
        lea     r9,chrsread
        call    ReadConsole

        ;add     rsp,8 ; WRONG

        call    FreeConsole

        xor     rcx,rcx
        call    ExitProcess

        ;add     rsp,40      ; WRONG. YOU WILL NOT COME HERE. I know, but i thought it would be good coding practice (not too efficient 
                                    ;   really).
start   endp
        end

Thanks, i have a lot to learn with this (i mean 64 bits programming), so i will not expect all the answers for my questions right now. But thank you very much to both anyway.  :icon14: :icon14:
Pages: [1] 2 3 ... 10