From 6f70b63e6f816cbe6edb154e3100e00f307ce7e0 Mon Sep 17 00:00:00 2001 From: Katayama Hirofumi MZ Date: Thu, 30 Jan 2020 22:45:09 +0900 Subject: [PATCH] improve --- README.md | 4 ++-- build32.bat | 2 +- build64.bat | 2 +- loadtest.exe | Bin 45056 -> 45056 bytes loadtest.exe.txt | 2 +- loadtest64.exe | Bin 66048 -> 66048 bytes loadtest64.exe.txt | 2 +- smalldll.dll | Bin 1536 -> 1024 bytes smalldll.dll.txt | 37 +++++++++++-------------------------- smalldll64.dll | Bin 1536 -> 1024 bytes smalldll64.dll.txt | 37 +++++++++++-------------------------- 11 files changed, 28 insertions(+), 58 deletions(-) diff --git a/README.md b/README.md index ad18517..1bd2891 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ # smalldll --- The Small DLL File -- `smalldll.dll` --- 1.50 KB (1,536 bytes). -- `smalldll64.dll` --- 1.50 KB (1,536 bytes). +- `smalldll.dll` --- 1.00 KB (1,024 bytes). +- `smalldll64.dll` --- 1.00 KB (1,024 bytes). diff --git a/build32.bat b/build32.bat index 39d2bbe..df7f1dc 100644 --- a/build32.bat +++ b/build32.bat @@ -4,7 +4,7 @@ rem NOTE: You needs 32-bit Visual Studio Command Prompt. if exist smalldll.obj del smalldll.obj if exist smalldll.dll del smalldll.dll ml /c /Fosmalldll.obj smalldll.asm -link /machine:X86 /SUBSYSTEM:WINDOWS /DLL /DEF:smalldll.def smalldll.obj +link /machine:X86 /SUBSYSTEM:WINDOWS /DLL /merge:.rdata=.text /DEF:smalldll.def smalldll.obj dumpbin /imports /exports /headers smalldll.dll > smalldll.dll.txt if exist loadtest.exe del loadtest.exe diff --git a/build64.bat b/build64.bat index 7c2c640..89ba92e 100644 --- a/build64.bat +++ b/build64.bat @@ -4,7 +4,7 @@ rem NOTE: You needs 64-bit Visual Studio Command Prompt. if exist smalldll64.obj del smalldll64.obj if exist smalldll64.dll del smalldll64.dll ml64 /c /Fosmalldll64.obj smalldll64.asm -link /machine:X64 /SUBSYSTEM:WINDOWS /DLL /DEF:smalldll64.def smalldll64.obj +link /machine:X64 /SUBSYSTEM:WINDOWS /DLL /merge:.rdata=.text /DEF:smalldll64.def smalldll64.obj dumpbin /imports /exports /headers smalldll64.dll > smalldll64.dll.txt if exist loadtest64.exe del loadtest64.exe diff --git a/loadtest.exe b/loadtest.exe index 19286b46c69bbdb1aad9dc098e94acd8b83eaf59..7a8965a31a60cfc11feb084f5eeae664e184a140 100644 GIT binary patch delta 15 XcmZp8z|`=7X~GSr`nwx%sjUY9Jrf7( delta 15 XcmZp8z|`=7X~GRApW7R6sjUY9JJ$!c diff --git a/loadtest.exe.txt b/loadtest.exe.txt index dca1a48..ae116b2 100644 --- a/loadtest.exe.txt +++ b/loadtest.exe.txt @@ -11,7 +11,7 @@ File Type: EXECUTABLE IMAGE FILE HEADER VALUES 14C machine (x86) 3 number of sections - 5E32DB4C time date stamp Thu Jan 30 22:34:04 2020 + 5E32DD7F time date stamp Thu Jan 30 22:43:27 2020 0 file pointer to symbol table 0 number of symbols E0 size of optional header diff --git a/loadtest64.exe b/loadtest64.exe index 0a1797a32d8b18c9e9313cfc5b2856f85a3146b6..d29c1e015c2dd485f0f18af2c91ae362b8946709 100644 GIT binary patch delta 18 acmZo@VQFY#nec&W<=w_lTR$=KF#-TjqXDRVP2DKapDL?DRVP2DKdbBnI TZyUvdlxQeymScJZ5)%Lb$u}4% diff --git a/smalldll.dll.txt b/smalldll.dll.txt index 79e6c34..0adcfa6 100644 --- a/smalldll.dll.txt +++ b/smalldll.dll.txt @@ -10,8 +10,8 @@ File Type: DLL FILE HEADER VALUES 14C machine (x86) - 2 number of sections - 5E32DB4B time date stamp Thu Jan 30 22:34:03 2020 + 1 number of sections + 5E32DD7E time date stamp Thu Jan 30 22:43:26 2020 0 file pointer to symbol table 0 number of symbols E0 size of optional header @@ -24,20 +24,20 @@ OPTIONAL HEADER VALUES 10B magic # (PE32) 9.00 linker version 200 size of code - 200 size of initialized data + 0 size of initialized data 0 size of uninitialized data 1000 entry point (10001000) 1000 base of code 2000 base of data - 10000000 image base (10000000 to 10002FFF) + 10000000 image base (10000000 to 10001FFF) 1000 section alignment 200 file alignment 5.00 operating system version 0.00 image version 5.00 subsystem version 0 Win32 version - 3000 size of image - 400 size of headers + 2000 size of image + 200 size of headers 0 checksum 2 subsystem (Windows GUI) 0 DLL characteristics @@ -47,7 +47,7 @@ OPTIONAL HEADER VALUES 1000 size of heap commit 0 loader flags 10 number of directories - 2000 [ 35] RVA [size] of Export Directory + 1010 [ 35] RVA [size] of Export Directory 0 [ 0] RVA [size] of Import Directory 0 [ 0] RVA [size] of Resource Directory 0 [ 0] RVA [size] of Exception Directory @@ -67,10 +67,10 @@ OPTIONAL HEADER VALUES SECTION HEADER #1 .text name - C virtual size - 1000 virtual address (10001000 to 1000100B) + 45 virtual size + 1000 virtual address (10001000 to 10001044) 200 size of raw data - 400 file pointer to raw data (00000400 to 000005FF) + 200 file pointer to raw data (00000200 to 000003FF) 0 file pointer to relocation table 0 file pointer to line numbers 0 number of relocations @@ -79,24 +79,10 @@ SECTION HEADER #1 Code Execute Read -SECTION HEADER #2 - .rdata name - 35 virtual size - 2000 virtual address (10002000 to 10002034) - 200 size of raw data - 600 file pointer to raw data (00000600 to 000007FF) - 0 file pointer to relocation table - 0 file pointer to line numbers - 0 number of relocations - 0 number of line numbers -40000040 flags - Initialized Data - Read Only - Section contains the following exports for smalldll.dll 00000000 characteristics - 5E32DB4B time date stamp Thu Jan 30 22:34:03 2020 + 5E32DD7E time date stamp Thu Jan 30 22:43:26 2020 0.00 version 1 ordinal base 0 number of functions @@ -107,5 +93,4 @@ SECTION HEADER #2 Summary - 1000 .rdata 1000 .text diff --git a/smalldll64.dll b/smalldll64.dll index 56a96e5dd7f1ab2a2db2900f75939a179c91606f..5a1c2b610bb11717149aaf325aace62963e829f1 100644 GIT binary patch delta 105 zcmZqRY2cX9Cd0^p3_dXEDRDC~DKapDL?