You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|**/AT**|Enables tiny-memory-model support. Enables error messages for code constructs that violate the requirements for .com format files. This option isn't equivalent to the [.MODEL](dot-model.md)**TINY** directive.<br /><br /> Not available in ml64.exe.|
29
-
|**/Bl***filename*|Selects an alternate linker.|
30
-
|**/c**|Assembles only. Does no linking.|
31
-
|**/coff**|Generates common object file format (COFF) type of object module. Required for Win32 assembly language development.<br /><br /> Not available in ml64.exe.|
32
-
|**/Cp**|Preserves case of all user identifiers.|
33
-
|**/Cu**|Maps all identifiers to upper case (default).<br /><br /> Not available in ml64.exe.|
34
-
|**/Cx**|Preserves case in public and extern symbols.|
35
-
|**/D***symbol*⟦=*value*⟧|Defines a text macro with the given name. If *value* is missing, it's blank. Multiple tokens separated by spaces must be enclosed in quotation marks.|
36
-
|**/EP**|Generates a preprocessed source listing (sent to STDOUT). See **/Sf**.|
37
-
|**/ERRORREPORT**[**NONE**|**PROMPT**|**QUEUE**|**SEND**]| Deprecated. Error reporting is controlled by [Windows Error Reporting (WER)](/windows/win32/wer/windows-error-reporting) settings. |
38
-
|**/F***hexnum*|Sets stack size to *hexnum* bytes (the same as **/link /STACK**:*number*). The value must be expressed in hexadecimal notation. There must be a space between **/F** and *hexnum*.|
39
-
|**/Fe***filename*|Names the executable file.|
40
-
|**/Fl**⟦*filename*⟧|Generates an assembled code listing. See **/Sf**.|
41
-
|**/Fm**⟦*filename*⟧|Creates a linker map file.|
42
-
|**/Fo***filename*|Names an object file. For more information, see [Remarks](#remarks).|
43
-
|**/FPi**|Generates emulator fix-ups for floating-point arithmetic (mixed language only).<br /><br /> Not available in ml64.exe.|
44
-
|**/Fr**⟦*filename*⟧|Generates a source browser .sbr file.|
45
-
|**/FR**⟦*filename*⟧|Generates an extended form of a source browser .sbr file.|
46
-
|**/Gc**|Specifies use of FORTRAN- or Pascal-style function calling and naming conventions. Same as **OPTION LANGUAGE:PASCAL**.<br /><br /> Not available in ml64.exe.|
47
-
|**/Gd**|Specifies use of C-style function calling and naming conventions. Same as **OPTION LANGUAGE:C**.<br /><br /> Not available in ml64.exe.|
48
-
|**/GZ**|Specifies use of __stdcall function calling and naming conventions. Same as **OPTION LANGUAGE:STCALL**.<br /><br /> Not available in ml64.exe.|
49
-
|**/H***number*|Restricts external names to number significant characters. The default is 31 characters.<br /><br /> Not available in ml64.exe.|
50
-
|**/help**|Calls QuickHelp for help on ML.|
51
-
|**/I***pathname*|Sets path for include file. A maximum of 10 **/I** options is allowed.|
52
-
|**/nologo**|Suppresses messages for successful assembly.|
53
-
|**/omf**|Generates object module file format (OMF) type of object module. **/omf** implies **/c**; ML.exe doesn't support linking OMF objects.<br /><br /> Not available in ml64.exe.|
54
-
|**/Sa**|Turns on listing of all available information.|
55
-
|**/safeseh**|Marks the object as either containing no exception handlers or containing exception handlers that are all declared with [.SAFESEH](dot-safeseh.md).<br /><br /> Not available in ml64.exe.|
56
-
|**/Sf**|Adds first-pass listing to listing file.|
57
-
|**/Sl***width*|Sets the line width of source listing in characters per line. Range is 60 to 255 or 0. Default is 0. Same as [PAGE](page.md) width.|
58
-
|**/Sn**|Turns off symbol table when producing a listing.|
59
-
|**/Sp***length*|Sets the page length of source listing in lines per page. Range is 10 to 255 or 0. Default is 0. Same as [PAGE](page.md) length.|
60
-
|**/Ss***text*|Specifies text for source listing. Same as [SUBTITLE](subtitle.md) text.|
61
-
|**/St***text*|Specifies title for source listing. Same as [TITLE](title.md) text.|
62
-
|**/Sx**|Turns on false conditionals in listing.|
63
-
|**/Ta***filename*|Assembles source file whose name doesn't end with the .asm extension.|
64
-
|**/w**|Same as **/W0/WX**.|
65
-
|**/W***level*|Sets the warning level, where *level* = 0, 1, 2, or 3.|
66
-
|**/WX**|Returns an error code if warnings are generated.|
67
-
|**/X**|Ignore INCLUDE environment path.|
68
-
|**/Zd**|Generates line-number information in object file.|
69
-
|**/Zf**|Makes all symbols public.|
70
-
|**/Zi**|Generates CodeView information in object file.|
71
-
|**/Zm**|Enables**M510** option for maximum compatibility with MASM 5.1.<br /><br /> Not available in ml64.exe.|
72
-
|**/Zp**⟦*alignment*⟧|Packs structures on the specified byte boundary. The *alignment* can be 1, 2, or 4.|
73
-
|**/Zs**|Performs a syntax check only.|
74
-
|**/?**|Displays a summary of ML command-line syntax.|
75
-
76
-
*filename*\
23
+
*`options`*\
24
+
The options listed in the following table:
25
+
26
+
| Option | Action |
27
+
|--|--|
28
+
|**`/AT`**| Enables tiny-memory-model support. Enables error messages for code constructs that violate the requirements for *`.com`* format files. This option isn't equivalent to the [`.MODEL`](dot-model.md)**`TINY`** directive.<br /> Not available in ml64.exe. |
29
+
|**`/Bl`***`filename`*| Selects an alternate linker in *`filename`*. |
30
+
|**`/c`**| Assembles only. Does no linking. |
31
+
|**`/coff`**| Generates common object file format (COFF) type of object module. Required for Win32 assembly language development.<br /> Not available in ml64.exe. |
32
+
|**`/Cp`**| Preserves case of all user identifiers. |
33
+
|**`/Cu`**| Maps all identifiers to upper case (default).<br /> Not available in ml64.exe. |
34
+
|**`/Cx`**| Preserves case in public and extern symbols. |
35
+
|**`/D`***`symbol`*⟦=*`value`*⟧ | Defines a text macro with the given name *`symbol`*. If *`value`* is missing, it's blank. Multiple tokens separated by spaces must be enclosed in quotation marks. |
36
+
|**`/EP`**| Generates a preprocessed source listing (sent to `STDOUT`). See **`/Sf`**. |
37
+
|**`/ERRORREPORT`**[**`NONE`**|**`PROMPT`**|**`QUEUE`**|**`SEND`**]| Deprecated. Error reporting is controlled by [Windows Error Reporting (WER)](/windows/win32/wer/windows-error-reporting) settings. |
38
+
|**`/F`***`hexnum`*| Sets stack size to *`hexnum`* bytes (the same as **`/link /STACK:<number>`**). The value must be expressed in hexadecimal notation. There must be a space between **`/F`** and *`hexnum`*. |
39
+
|**`/Fe`***`filename`*| Names the executable file. |
40
+
|**`/Fl`**⟦*`filename`*⟧ | Generates an assembled code listing. See **/Sf**. |
41
+
|**`/Fm`**⟦*`filename`*⟧ | Creates a linker map file. |
42
+
|**`/Fo`***`filename`*| Names an object file. For more information, see [Remarks](#remarks). |
43
+
|**`/FPi`**| Generates emulator fix-ups for floating-point arithmetic (mixed language only).<br /> Not available in ml64.exe. |
44
+
|**`/Fr`**⟦*`filename`*⟧ | Generates a source browser *`.sbr`* file. |
45
+
|**`/FR`**⟦*`filename`*⟧ | Generates an extended form of a source browser *`.sbr`* file. |
46
+
|**`/Gc`**| Specifies use of FORTRAN- or Pascal-style conventions for function calls and names. Same as **`OPTION LANGUAGE:PASCAL`**.<br /> Not available in ml64.exe. |
47
+
|**`/Gd`**| Specifies use of C-style conventions for function calls and names. Same as **`OPTION LANGUAGE:C`**.<br /> Not available in ml64.exe. |
48
+
|**`/GZ`**| Specifies use of `__stdcall` conventions for function calls and names. Same as **`OPTION LANGUAGE:STDCALL`**.<br /> Not available in ml64.exe. |
49
+
|**`/H`***`number`*| Restricts external names to *`number`* significant characters. The default is 31 characters.<br /> Not available in ml64.exe. |
50
+
|**`/help`**| Displays a summary of ML command-line syntax and options. |
51
+
|**`/I`***`pathname`*| Sets path for include file. A maximum of 10 **`/I`** options is allowed. |
52
+
|**`/nologo`**| Suppresses messages for successful assembly. |
53
+
|**`/omf`**| Generates object module file format (OMF) type of object module. **`/omf`** implies **`/c`**. ML.exe doesn't support linking OMF objects.<br /> Not available in ml64.exe. |
54
+
|**`/Sa`**| Turns on listing of all available information. |
55
+
|**`/safeseh`**| Marks the object file: either it contains no exception handlers, or it contains exception handlers that are all declared with [`.SAFESEH`](dot-safeseh.md).<br /> Not available in ml64.exe. |
56
+
|**`/Sf`**| Adds the first-pass listing to the listing file. |
57
+
|**`/Sl`***`width`*| Sets the line width of source listing in characters per line to *`width`*. Range is 60-255 or 0. Default is 0. Same as [`PAGE`](page.md)*`width`*. |
58
+
|**`/Sn`**| Turns off symbol table when a listing is produced. |
59
+
|**`/Sp`***`length`*| Sets the page length of source listing in lines per page to *`length`*. Range is 10-255 or 0. Default is 0. Same as [`PAGE`](page.md)*`length`*. |
60
+
|**`/Ss`***`text`*| Specifies text for source listing. Same as [`SUBTITLE`](subtitle.md) text. |
61
+
|**`/St`***`text`*| Specifies title for source listing. Same as [`TITLE`](title.md) text. |
62
+
|**`/Sx`**| Turns on false conditionals in listing. |
63
+
|**`/Ta`***`filename`*| Assembles source file whose name doesn't end with the *`.asm`* extension. |
64
+
|**`/w`**| Same as **`/W0 /WX`**. |
65
+
|**`/W`***`level`*| Sets the warning level, where *`level`* = 0, 1, 2, or 3. |
66
+
|**`/WX`**| If warnings are generated, returns an error code. |
67
+
|**`/X`**| Ignore `INCLUDE` environment path. |
68
+
|**`/Zd`**| Generates line-number information in object file. |
69
+
|**`/Zf`**| Makes all symbols public. |
70
+
|**`/ZH:MD5`**| Use MD5 for checksum in debug info. |
71
+
|**`/ZH:SHA_256`**| Use SHA256 for checksum in debug info (default in Visual Studio 2022 version 17.0 and later). |
72
+
|**`/Zi`**| Generates CodeView information in object file. |
73
+
|**`/Zm`**| Enables **`M510`** option for maximum compatibility with MASM 5.1.<br /> Not available in ml64.exe. |
74
+
|**`/Zp`**⟦*`alignment`*⟧ | Packs structures on the specified byte boundary. The *`alignment`* can be 1, 2, or 4. |
75
+
|**`/Zs`**| Performs a syntax check only. |
76
+
|**`/?`**| Displays a summary of ML command-line syntax and options. |
77
+
78
+
*`filename`*\
77
79
The name of the file.
78
80
79
-
*link_options*\
81
+
*`link_options`*\
80
82
The link options. For more information, see [Linker options](../../build/reference/linker-options.md).
81
83
82
84
## Remarks
83
85
84
-
Some command-line options to ML and ML64 are placement-sensitive. For example, because ML and ML64 can accept several **/c** options, any corresponding **/Fo** options must be specified before **/c**. The following command-line example illustrates an object file specification for each assembly file specification:
86
+
Some command-line options to ML and ML64 are placement-sensitive. For example, because ML and ML64 can accept several **`/c`** options, any corresponding **`/Fo`** options must be specified before **`/c`**. The following command-line example illustrates an object file specification for each assembly file specification:
85
87
86
88
```cmd
87
89
ml.exe /Fo a1.obj /c a.asm /Fo b1.obj /c b.asm
88
90
```
89
91
90
92
## Environment Variables
91
93
92
-
|Variable|Description|
93
-
|--------------|-----------------|
94
-
|INCLUDE|Specifies search path for include files.|
95
-
|ML|Specifies default command-line options.|
96
-
|TMP|Specifies path for temporary files.|
94
+
|Variable|Description|
95
+
|--|--|
96
+
|`INCLUDE`|Specifies search path for include files.|
# /ZH (Hash algorithm for calculation of file checksum in debug info)
8
+
# `/ZH` (Hash algorithm for calculation of file checksum in debug info)
9
9
10
10
Specifies which cryptographic hash algorithm to use to generate a checksum of each source file.
11
11
12
12
## Syntax
13
13
14
-
> **/ZH:**{**MD5**|**SHA1**|**SHA_256**}
14
+
> **`/ZH:MD5`**\
15
+
> **`/ZH:SHA1`**\
16
+
> **`/ZH:SHA_256`**
15
17
16
18
## Arguments
17
19
18
-
**/ZH:MD5**\
19
-
Use an MD5 hash for the checksum. This option is the default.
20
+
**`/ZH:MD5`**\
21
+
Use an MD5 hash for the checksum. This option is the default in Visual Studio 2019.
20
22
21
-
**/ZH:SHA1**\
23
+
**`/ZH:SHA1`**\
22
24
Use an SHA-1 hash for the checksum.
23
25
24
-
**/ZH:SHA_256**\
25
-
Use an SHA-256 hash for the checksum.
26
+
**`/ZH:SHA_256`**\
27
+
Use an SHA-256 hash for the checksum. This option is the default in Visual Studio 2022 version 17.0 and later.
26
28
27
29
## Remarks
28
30
29
-
PDB files store a checksum for each source file compiled into the object code in the associated executable. The checksum allows the debugger to verify that the source code it loads matches the executable. The compiler and debugger support MD5, SHA-1, and SHA-256 hash algorithms. By default, the compiler uses an MD5 hash to generate the checksum. You can specify this option explicitly by using the **/ZH:MD5** option.
31
+
PDB files store a checksum for each source file, compiled into the object code in the associated executable. The checksum allows the debugger to verify that the source code it loads matches the executable. The compiler and debugger support MD5, SHA-1, and SHA-256 hash algorithms. By default, in Visual Studio 2019 the compiler uses an MD5 hash to generate the checksum. To specify this hash algorithm explicitly, use the **`/ZH:MD5`** option.
30
32
31
-
Because of a risk of collision problems in MD5 and SHA-1, Microsoft recommends you use the **/ZH:SHA_256** option. The SHA-256 hash may result in a small increase in compile times.
33
+
Because of a risk of collision problems in MD5 and SHA-1, Microsoft recommends you use the **`/ZH:SHA_256`** option. The SHA-256 hash might result in a small increase in compile times. The **`/ZH:SHA_256`** option is the default in Visual Studio 2022 version 17.0 and later.
32
34
33
-
When more than one **/ZH** option is specified, the last option is used.
35
+
When more than one **`/ZH`** option is specified, the last option is used.
34
36
35
-
The **/ZH** option is available starting in Visual Studio 2019 version 16.4.
37
+
The **`/ZH`** option is available in Visual Studio 2019 version 16.4 and later.
36
38
37
39
### To set this compiler option in the Visual Studio development environment
38
40
39
-
1. Open the project's **Property Pages** dialog box. For details, see [Set C++ compiler and build properties in Visual Studio](../working-with-project-properties.md).
41
+
1. Open the **Property Pages** dialog box for the project. For details, see [Set C++ compiler and build properties in Visual Studio](../working-with-project-properties.md).
40
42
41
-
1. Set the **Configuration** drop-down to **All Configurations**.
43
+
1. Set the **Configuration** drop-down to **All Configurations**. Set the **Platform** drop-down to **All Platforms**.
0 commit comments