The Meson Build System
http://mesonbuild.com/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
40 lines
611 B
40 lines
611 B
8 years ago
|
#include "symbol-underscore.h"
|
||
|
|
||
|
#include "symbol-underscore.h"
|
||
|
|
||
|
#ifdef _MSC_VER /* MSVC on Windows */
|
||
|
|
||
|
PUBLIC SYMBOL_NAME(square_unsigned)
|
||
|
_TEXT SEGMENT
|
||
|
|
||
|
SYMBOL_NAME(square_unsigned) PROC
|
||
|
mov eax, ecx
|
||
|
imul eax, eax
|
||
|
ret
|
||
|
SYMBOL_NAME(square_unsigned) ENDP
|
||
|
|
||
|
_TEXT ENDS
|
||
|
END
|
||
|
|
||
|
#else
|
||
|
|
||
|
.text
|
||
|
.globl SYMBOL_NAME(square_unsigned)
|
||
|
# ifndef __APPLE__
|
||
|
.type square_unsigned,@function
|
||
|
# endif
|
||
|
|
||
|
# ifdef _WIN32 /* MinGW */
|
||
|
SYMBOL_NAME(square_unsigned):
|
||
|
imull %ecx, %ecx
|
||
|
movl %ecx, %eax
|
||
|
retq
|
||
|
# else /* Linux and OS X */
|
||
|
SYMBOL_NAME(square_unsigned):
|
||
|
imull %edi, %edi
|
||
|
movl %edi, %eax
|
||
|
retq
|
||
|
# endif
|
||
|
|
||
|
#endif
|