| 1 |
#include "symbol-underscore.h" |
| 2 |
|
| 3 |
#if defined(_MSC_VER) && !defined(__clang__) |
| 4 |
|
| 5 |
.386 |
| 6 |
.MODEL FLAT, C |
| 7 |
|
| 8 |
PUBLIC square_unsigned |
| 9 |
_TEXT SEGMENT |
| 10 |
|
| 11 |
square_unsigned PROC var1:DWORD |
| 12 |
mov eax, var1 |
| 13 |
imul eax, eax |
| 14 |
ret |
| 15 |
square_unsigned ENDP |
| 16 |
|
| 17 |
_TEXT ENDS |
| 18 |
END |
| 19 |
|
| 20 |
#else |
| 21 |
|
| 22 |
.text |
| 23 |
.globl SYMBOL_NAME(square_unsigned) |
| 24 |
/* Only supported with GAS */ |
| 25 |
# if defined(__linux__) || defined(__DragonFly__) || defined(__FreeBSD__) || defined(__NetBSD__) |
| 26 |
.type square_unsigned,@function |
| 27 |
# endif |
| 28 |
|
| 29 |
SYMBOL_NAME(square_unsigned): |
| 30 |
movl 4(%esp), %eax |
| 31 |
imull %eax, %eax |
| 32 |
retl |
| 33 |
|
| 34 |
#endif |