Click here to Skip to main content
15,881,588 members
Articles / High Performance Computing / Vectorization

Bird Programming Language: Part 1

Rate me:
Please Sign up or sign in to vote.
4.92/5 (129 votes)
1 Jan 2013GPL312 min read 373K   2.7K   153  
A new general purpose language that aims to be fast, high level and simple to use.
	format MS COFF
	
section "code" code readable executable

_as_FloatToULong:
	sub esp, 8
	fld dword[esp + 12]
	fcomp dword[_3]
	fnstsw ax
	sahf
	ja _10
	fld dword[esp + 12]
	fistp qword[esp]
	mov eax, dword[esp]
	mov edx, dword[esp + 4]
	jmp _1
_10:
	fld dword[esp + 12]
	fcomp dword[_4]
	fnstsw ax
	sahf
	ja _13
	xor eax, eax
	mov edx, 2147483648
	fld dword[esp + 12]
	fsub qword[_5]
	fistp qword[esp]
	or eax, dword[esp]
	or edx, dword[esp + 4]
	jmp _1
_13:
	mov eax, 4294967295
	mov edx, 4294967295
_1:
	add esp, 8
	ret 4

_as_DoubleToULong:
	sub esp, 8
	fld qword[esp + 12]
	fcomp qword[_6]
	fnstsw ax
	sahf
	ja _17
	fld qword[esp + 12]
	fistp qword[esp]
	mov eax, dword[esp]
	mov edx, dword[esp + 4]
	jmp _2
_17:
	fld qword[esp + 12]
	fcomp qword[_7]
	fnstsw ax
	sahf
	ja _20
	xor eax, eax
	mov edx, 2147483648
	fld qword[esp + 12]
	fsub qword[_5]
	fistp qword[esp]
	or eax, dword[esp]
	or edx, dword[esp + 4]
	jmp _2
_20:
	mov eax, 4294967295
	mov edx, 4294967295
_2:
	add esp, 8
	ret 8

section "data" data readable writeable

_3:
	dd 1593835520
_4:
	dd 1602224128
_5:
	dq 4890909195324358656
_6:
	dq 4890909195324358655
_7:
	dq 4895412794951729151

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The GNU General Public License (GPLv3)


Written By
Software Developer
Hungary Hungary
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions