Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revision | |
| en:multiasm:papc:chapter_6_9 [2026/05/13 09:05] – [Pure Assembler Applications for Windows CMD] ktokarz | en:multiasm:papc:chapter_6_9 [2026/05/13 09:06] (current) – [Programming in Assembler for Linux] ktokarz |
|---|
| Assembler code exposes functions to the linker using the ''global'' directive. Without it, assembler functions remain "private" and cannot be called, so linking won't succeed if there is a reference to the function from the high-level language part of the code. The following code presents a dummy function that performs integer addition of two arguments. Directives "section" are optional in this example. | Assembler code exposes functions to the linker using the ''global'' directive. Without it, assembler functions remain "private" and cannot be called, so linking won't succeed if there is a reference to the function from the high-level language part of the code. The following code presents a dummy function that performs integer addition of two arguments. Directives "section" are optional in this example. |
| |
| <code assembler asmfunc.asm> | <code asm asmfunc.asm> |
| section .data | section .data |
| section .bss | section .bss |