Index: uspace/lib/softfloat/Makefile
===================================================================
--- uspace/lib/softfloat/Makefile	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/Makefile	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -29,5 +29,5 @@
 
 USPACE_PREFIX = ../..
-EXTRA_CFLAGS = -Iinclude -Iarch/$(UARCH)/include/
+EXTRA_CFLAGS = -Iinclude
 LIBRARY = libsoftfloat
 
Index: uspace/lib/softfloat/arch/abs32le/include/functions.h
===================================================================
--- uspace/lib/softfloat/arch/abs32le/include/functions.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ 	(revision )
@@ -1,92 +1,0 @@
-/*
- * Copyright (c) 2010 Martin Decky
- * Copyright (c) 2011 Petr Koupy
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/** @addtogroup softfloatabs32le abs32le
- * @ingroup sfl
- * @brief softfloat architecture dependent definitions
- * @{
- */
-/** @file
- */
-
-#ifndef __SOFTFLOAT_FUNCTIONS_H__
-#define __SOFTFLOAT_FUNCTIONS_H__
-
-#define float32_to_int(X) float32_to_int32(X);
-#define float32_to_long(X) float32_to_int32(X);
-#define float32_to_longlong(X) float32_to_int64(X);
-
-#define float64_to_int(X) float64_to_int32(X);
-#define float64_to_long(X) float64_to_int32(X);
-#define float64_to_longlong(X) float64_to_int64(X);
-
-#define float128_to_int(X) float128_to_int32(X);
-#define float128_to_long(X) float128_to_int32(X);
-#define float128_to_longlong(X) float128_to_int64(X);
-
-#define float32_to_uint(X) float32_to_uint32(X);
-#define float32_to_ulong(X) float32_to_uint32(X);
-#define float32_to_ulonglong(X) float32_to_uint64(X);
-
-#define float64_to_uint(X) float64_to_uint32(X);
-#define float64_to_ulong(X) float64_to_uint32(X);
-#define float64_to_ulonglong(X) float64_to_uint64(X);
-
-#define float128_to_uint(X) float128_to_uint32(X);
-#define float128_to_ulong(X) float128_to_uint32(X);
-#define float128_to_ulonglong(X) float128_to_uint64(X);
-
-#define int_to_float32(X) int32_to_float32(X);
-#define long_to_float32(X) int32_to_float32(X);
-#define longlong_to_float32(X) int64_to_float32(X);
-
-#define int_to_float64(X) int32_to_float64(X);
-#define long_to_float64(X) int32_to_float64(X);
-#define longlong_to_float64(X) int64_to_float64(X);
-
-#define int_to_float128(X) int32_to_float128(X);
-#define long_to_float128(X) int32_to_float128(X);
-#define longlong_to_float128(X) int64_to_float128(X);
-
-#define uint_to_float32(X) uint32_to_float32(X);
-#define ulong_to_float32(X) uint32_to_float32(X);
-#define ulonglong_to_float32(X) uint64_to_float32(X);
-
-#define uint_to_float64(X) uint32_to_float64(X);
-#define ulong_to_float64(X) uint32_to_float64(X);
-#define ulonglong_to_float64(X) uint64_to_float64(X);
-
-#define uint_to_float128(X) uint32_to_float128(X);
-#define ulong_to_float128(X) uint32_to_float128(X);
-#define ulonglong_to_float128(X) uint64_to_float128(X);
-
-#endif
-
-/** @}
- */
Index: uspace/lib/softfloat/arch/amd64/include/functions.h
===================================================================
--- uspace/lib/softfloat/arch/amd64/include/functions.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ 	(revision )
@@ -1,92 +1,0 @@
-/*
- * Copyright (c) 2006 Josef Cejka
- * Copyright (c) 2011 Petr Koupy
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/** @addtogroup softfloatamd64 amd64	
- * @ingroup sfl 
- * @brief softfloat architecture dependent definitions 
- * @{
- */
-/** @file
- */
-
-#ifndef __SOFTFLOAT_FUNCTIONS_H__
-#define __SOFTFLOAT_FUNCTIONS_H__
-
-#define float32_to_int(X) float32_to_int32(X);
-#define float32_to_long(X) float32_to_int64(X);
-#define float32_to_longlong(X) float32_to_int64(X);
-
-#define float64_to_int(X) float64_to_int32(X);
-#define float64_to_long(X) float64_to_int64(X);
-#define float64_to_longlong(X) float64_to_int64(X);
-
-#define float128_to_int(X) float128_to_int32(X);
-#define float128_to_long(X) float128_to_int64(X);
-#define float128_to_longlong(X) float128_to_int64(X);
-
-#define float32_to_uint(X) float32_to_uint32(X);
-#define float32_to_ulong(X) float32_to_uint64(X);
-#define float32_to_ulonglong(X) float32_to_uint64(X);
-
-#define float64_to_uint(X) float64_to_uint32(X);
-#define float64_to_ulong(X) float64_to_uint64(X);
-#define float64_to_ulonglong(X) float64_to_uint64(X);
-
-#define float128_to_uint(X) float128_to_uint32(X);
-#define float128_to_ulong(X) float128_to_uint64(X);
-#define float128_to_ulonglong(X) float128_to_uint64(X);
-
-#define int_to_float32(X) int32_to_float32(X);
-#define long_to_float32(X) int64_to_float32(X);
-#define longlong_to_float32(X) int64_to_float32(X);
-
-#define int_to_float64(X) int32_to_float64(X);
-#define long_to_float64(X) int64_to_float64(X);
-#define longlong_to_float64(X) int64_to_float64(X);
-
-#define int_to_float128(X) int32_to_float128(X);
-#define long_to_float128(X) int64_to_float128(X);
-#define longlong_to_float128(X) int64_to_float128(X);
-
-#define uint_to_float32(X) uint32_to_float32(X);
-#define ulong_to_float32(X) uint64_to_float32(X);
-#define ulonglong_to_float32(X) uint64_to_float32(X);
-
-#define uint_to_float64(X) uint32_to_float64(X);
-#define ulong_to_float64(X) uint64_to_float64(X);
-#define ulonglong_to_float64(X) uint64_to_float64(X);
-
-#define uint_to_float128(X) uint32_to_float128(X);
-#define ulong_to_float128(X) uint64_to_float128(X);
-#define ulonglong_to_float128(X) uint64_to_float128(X);
-
-#endif
-
-/** @}
- */
Index: uspace/lib/softfloat/arch/arm32/include/functions.h
===================================================================
--- uspace/lib/softfloat/arch/arm32/include/functions.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ 	(revision )
@@ -1,92 +1,0 @@
-/*
- * Copyright (c) 2006 Josef Cejka
- * Copyright (c) 2011 Petr Koupy
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/** @addtogroup softfloatarm32 arm32	
- * @ingroup sfl
- * @brief Softfloat architecture dependent definitions.
- * @{
- */
-/** @file 
- */
-
-#ifndef __SOFTFLOAT_FUNCTIONS_H__
-#define __SOFTFLOAT_FUNCTIONS_H__
-
-#define float32_to_int(X) float32_to_int32(X);
-#define float32_to_long(X) float32_to_int32(X);
-#define float32_to_longlong(X) float32_to_int64(X);
-
-#define float64_to_int(X) float64_to_int32(X);
-#define float64_to_long(X) float64_to_int32(X);
-#define float64_to_longlong(X) float64_to_int64(X);
-
-#define float128_to_int(X) float128_to_int32(X);
-#define float128_to_long(X) float128_to_int32(X);
-#define float128_to_longlong(X) float128_to_int64(X);
-
-#define float32_to_uint(X) float32_to_uint32(X);
-#define float32_to_ulong(X) float32_to_uint32(X);
-#define float32_to_ulonglong(X) float32_to_uint64(X);
-
-#define float64_to_uint(X) float64_to_uint32(X);
-#define float64_to_ulong(X) float64_to_uint32(X);
-#define float64_to_ulonglong(X) float64_to_uint64(X);
-
-#define float128_to_uint(X) float128_to_uint32(X);
-#define float128_to_ulong(X) float128_to_uint32(X);
-#define float128_to_ulonglong(X) float128_to_uint64(X);
-
-#define int_to_float32(X) int32_to_float32(X);
-#define long_to_float32(X) int32_to_float32(X);
-#define longlong_to_float32(X) int64_to_float32(X);
-
-#define int_to_float64(X) int32_to_float64(X);
-#define long_to_float64(X) int32_to_float64(X);
-#define longlong_to_float64(X) int64_to_float64(X);
-
-#define int_to_float128(X) int32_to_float128(X);
-#define long_to_float128(X) int32_to_float128(X);
-#define longlong_to_float128(X) int64_to_float128(X);
-
-#define uint_to_float32(X) uint32_to_float32(X);
-#define ulong_to_float32(X) uint32_to_float32(X);
-#define ulonglong_to_float32(X) uint64_to_float32(X);
-
-#define uint_to_float64(X) uint32_to_float64(X);
-#define ulong_to_float64(X) uint32_to_float64(X);
-#define ulonglong_to_float64(X) uint64_to_float64(X);
-
-#define uint_to_float128(X) uint32_to_float128(X);
-#define ulong_to_float128(X) uint32_to_float128(X);
-#define ulonglong_to_float128(X) uint64_to_float128(X);
-
-#endif
-
-/** @}
- */
Index: uspace/lib/softfloat/arch/ia32/include/functions.h
===================================================================
--- uspace/lib/softfloat/arch/ia32/include/functions.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ 	(revision )
@@ -1,92 +1,0 @@
-/*
- * Copyright (c) 2006 Josef Cejka
- * Copyright (c) 2011 Petr Koupy
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/** @addtogroup softfloatia32 ia32	
- * @ingroup sfl
- * @brief softfloat architecture dependent definitions 
- * @{
- */
-/** @file
- */
-
-#ifndef __SOFTFLOAT_FUNCTIONS_H__
-#define __SOFTFLOAT_FUNCTIONS_H__
-
-#define float32_to_int(X) float32_to_int32(X);
-#define float32_to_long(X) float32_to_int32(X);
-#define float32_to_longlong(X) float32_to_int64(X);
-
-#define float64_to_int(X) float64_to_int32(X);
-#define float64_to_long(X) float64_to_int32(X);
-#define float64_to_longlong(X) float64_to_int64(X);
-
-#define float128_to_int(X) float128_to_int32(X);
-#define float128_to_long(X) float128_to_int32(X);
-#define float128_to_longlong(X) float128_to_int64(X);
-
-#define float32_to_uint(X) float32_to_uint32(X);
-#define float32_to_ulong(X) float32_to_uint32(X);
-#define float32_to_ulonglong(X) float32_to_uint64(X);
-
-#define float64_to_uint(X) float64_to_uint32(X);
-#define float64_to_ulong(X) float64_to_uint32(X);
-#define float64_to_ulonglong(X) float64_to_uint64(X);
-
-#define float128_to_uint(X) float128_to_uint32(X);
-#define float128_to_ulong(X) float128_to_uint32(X);
-#define float128_to_ulonglong(X) float128_to_uint64(X);
-
-#define int_to_float32(X) int32_to_float32(X);
-#define long_to_float32(X) int32_to_float32(X);
-#define longlong_to_float32(X) int64_to_float32(X);
-
-#define int_to_float64(X) int32_to_float64(X);
-#define long_to_float64(X) int32_to_float64(X);
-#define longlong_to_float64(X) int64_to_float64(X);
-
-#define int_to_float128(X) int32_to_float128(X);
-#define long_to_float128(X) int32_to_float128(X);
-#define longlong_to_float128(X) int64_to_float128(X);
-
-#define uint_to_float32(X) uint32_to_float32(X);
-#define ulong_to_float32(X) uint32_to_float32(X);
-#define ulonglong_to_float32(X) uint64_to_float32(X);
-
-#define uint_to_float64(X) uint32_to_float64(X);
-#define ulong_to_float64(X) uint32_to_float64(X);
-#define ulonglong_to_float64(X) uint64_to_float64(X);
-
-#define uint_to_float128(X) uint32_to_float128(X);
-#define ulong_to_float128(X) uint32_to_float128(X);
-#define ulonglong_to_float128(X) uint64_to_float128(X);
-
-#endif
-
-/** @}
- */
Index: uspace/lib/softfloat/arch/ia64/include/functions.h
===================================================================
--- uspace/lib/softfloat/arch/ia64/include/functions.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ 	(revision )
@@ -1,92 +1,0 @@
-/*
- * Copyright (c) 2006 Josef Cejka
- * Copyright (c) 2011 Petr Koupy
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
- /** @addtogroup softfloatia64 ia64
- * @ingroup sfl 
- * @brief softfloat architecture dependent definitions 
- * @{
- */
-/** @file
- */
-
-#ifndef __SOFTFLOAT_FUNCTIONS_H__
-#define __SOFTFLOAT_FUNCTIONS_H__
-
-#define float32_to_int(X) float32_to_int32(X);
-#define float32_to_long(X) float32_to_int64(X);
-#define float32_to_longlong(X) float32_to_int64(X);
-
-#define float64_to_int(X) float64_to_int32(X);
-#define float64_to_long(X) float64_to_int64(X);
-#define float64_to_longlong(X) float64_to_int64(X);
-
-#define float128_to_int(X) float128_to_int32(X);
-#define float128_to_long(X) float128_to_int64(X);
-#define float128_to_longlong(X) float128_to_int64(X);
-
-#define float32_to_uint(X) float32_to_uint32(X);
-#define float32_to_ulong(X) float32_to_uint64(X);
-#define float32_to_ulonglong(X) float32_to_uint64(X);
-
-#define float64_to_uint(X) float64_to_uint32(X);
-#define float64_to_ulong(X) float64_to_uint64(X);
-#define float64_to_ulonglong(X) float64_to_uint64(X);
-
-#define float128_to_uint(X) float128_to_uint32(X);
-#define float128_to_ulong(X) float128_to_uint64(X);
-#define float128_to_ulonglong(X) float128_to_uint64(X);
-
-#define int_to_float32(X) int32_to_float32(X);
-#define long_to_float32(X) int64_to_float32(X);
-#define longlong_to_float32(X) int64_to_float32(X);
-
-#define int_to_float64(X) int32_to_float64(X);
-#define long_to_float64(X) int64_to_float64(X);
-#define longlong_to_float64(X) int64_to_float64(X);
-
-#define int_to_float128(X) int32_to_float128(X);
-#define long_to_float128(X) int64_to_float128(X);
-#define longlong_to_float128(X) int64_to_float128(X);
-
-#define uint_to_float32(X) uint32_to_float32(X);
-#define ulong_to_float32(X) uint64_to_float32(X);
-#define ulonglong_to_float32(X) uint64_to_float32(X);
-
-#define uint_to_float64(X) uint32_to_float64(X);
-#define ulong_to_float64(X) uint64_to_float64(X);
-#define ulonglong_to_float64(X) uint64_to_float64(X);
-
-#define uint_to_float128(X) uint32_to_float128(X);
-#define ulong_to_float128(X) uint64_to_float128(X);
-#define ulonglong_to_float128(X) uint64_to_float128(X);
-
-#endif
-
- /** @}
- */
Index: uspace/lib/softfloat/arch/mips32/include/functions.h
===================================================================
--- uspace/lib/softfloat/arch/mips32/include/functions.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ 	(revision )
@@ -1,92 +1,0 @@
-/*
- * Copyright (c) 2006 Josef Cejka
- * Copyright (c) 2011 Petr Koupy
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/** @addtogroup softfloatmips32 mips32
- * @ingroup sfl
- * @brief softfloat architecture dependent definitions 
- * @{
- */
-/** @file
- */
-
-#ifndef __SOFTFLOAT_FUNCTIONS_H__
-#define __SOFTFLOAT_FUNCTIONS_H__
-
-#define float32_to_int(X) float32_to_int32(X);
-#define float32_to_long(X) float32_to_int32(X);
-#define float32_to_longlong(X) float32_to_int64(X);
-
-#define float64_to_int(X) float64_to_int32(X);
-#define float64_to_long(X) float64_to_int32(X);
-#define float64_to_longlong(X) float64_to_int64(X);
-
-#define float128_to_int(X) float128_to_int32(X);
-#define float128_to_long(X) float128_to_int32(X);
-#define float128_to_longlong(X) float128_to_int64(X);
-
-#define float32_to_uint(X) float32_to_uint32(X);
-#define float32_to_ulong(X) float32_to_uint32(X);
-#define float32_to_ulonglong(X) float32_to_uint64(X);
-
-#define float64_to_uint(X) float64_to_uint32(X);
-#define float64_to_ulong(X) float64_to_uint32(X);
-#define float64_to_ulonglong(X) float64_to_uint64(X);
-
-#define float128_to_uint(X) float128_to_uint32(X);
-#define float128_to_ulong(X) float128_to_uint32(X);
-#define float128_to_ulonglong(X) float128_to_uint64(X);
-
-#define int_to_float32(X) int32_to_float32(X);
-#define long_to_float32(X) int32_to_float32(X);
-#define longlong_to_float32(X) int64_to_float32(X);
-
-#define int_to_float64(X) int32_to_float64(X);
-#define long_to_float64(X) int32_to_float64(X);
-#define longlong_to_float64(X) int64_to_float64(X);
-
-#define int_to_float128(X) int32_to_float128(X);
-#define long_to_float128(X) int32_to_float128(X);
-#define longlong_to_float128(X) int64_to_float128(X);
-
-#define uint_to_float32(X) uint32_to_float32(X);
-#define ulong_to_float32(X) uint32_to_float32(X);
-#define ulonglong_to_float32(X) uint64_to_float32(X);
-
-#define uint_to_float64(X) uint32_to_float64(X);
-#define ulong_to_float64(X) uint32_to_float64(X);
-#define ulonglong_to_float64(X) uint64_to_float64(X);
-
-#define uint_to_float128(X) uint32_to_float128(X);
-#define ulong_to_float128(X) uint32_to_float128(X);
-#define ulonglong_to_float128(X) uint64_to_float128(X);
-
-#endif
-
-/** @}
- */
Index: uspace/lib/softfloat/arch/mips32eb/include/functions.h
===================================================================
--- uspace/lib/softfloat/arch/mips32eb/include/functions.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ 	(revision )
@@ -1,92 +1,0 @@
-/*
- * Copyright (c) 2006 Josef Cejka
- * Copyright (c) 2011 Petr Koupy
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
- /** @addtogroup softfloatmipseb32 mipseb32	
- * @ingroup sfl
- * @brief softfloat architecture dependent definitions 
- * * @{
- */
-/** @file
- */
-
-#ifndef __SOFTFLOAT_FUNCTIONS_H__
-#define __SOFTFLOAT_FUNCTIONS_H__
-
-#define float32_to_int(X) float32_to_int32(X);
-#define float32_to_long(X) float32_to_int32(X);
-#define float32_to_longlong(X) float32_to_int64(X);
-
-#define float64_to_int(X) float64_to_int32(X);
-#define float64_to_long(X) float64_to_int32(X);
-#define float64_to_longlong(X) float64_to_int64(X);
-
-#define float128_to_int(X) float128_to_int32(X);
-#define float128_to_long(X) float128_to_int32(X);
-#define float128_to_longlong(X) float128_to_int64(X);
-
-#define float32_to_uint(X) float32_to_uint32(X);
-#define float32_to_ulong(X) float32_to_uint32(X);
-#define float32_to_ulonglong(X) float32_to_uint64(X);
-
-#define float64_to_uint(X) float64_to_uint32(X);
-#define float64_to_ulong(X) float64_to_uint32(X);
-#define float64_to_ulonglong(X) float64_to_uint64(X);
-
-#define float128_to_uint(X) float128_to_uint32(X);
-#define float128_to_ulong(X) float128_to_uint32(X);
-#define float128_to_ulonglong(X) float128_to_uint64(X);
-
-#define int_to_float32(X) int32_to_float32(X);
-#define long_to_float32(X) int32_to_float32(X);
-#define longlong_to_float32(X) int64_to_float32(X);
-
-#define int_to_float64(X) int32_to_float64(X);
-#define long_to_float64(X) int32_to_float64(X);
-#define longlong_to_float64(X) int64_to_float64(X);
-
-#define int_to_float128(X) int32_to_float128(X);
-#define long_to_float128(X) int32_to_float128(X);
-#define longlong_to_float128(X) int64_to_float128(X);
-
-#define uint_to_float32(X) uint32_to_float32(X);
-#define ulong_to_float32(X) uint32_to_float32(X);
-#define ulonglong_to_float32(X) uint64_to_float32(X);
-
-#define uint_to_float64(X) uint32_to_float64(X);
-#define ulong_to_float64(X) uint32_to_float64(X);
-#define ulonglong_to_float64(X) uint64_to_float64(X);
-
-#define uint_to_float128(X) uint32_to_float128(X);
-#define ulong_to_float128(X) uint32_to_float128(X);
-#define ulonglong_to_float128(X) uint64_to_float128(X);
-
-#endif
-
- /** @}
- */
Index: uspace/lib/softfloat/arch/mips64/include/functions.h
===================================================================
--- uspace/lib/softfloat/arch/mips64/include/functions.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ 	(revision )
@@ -1,92 +1,0 @@
-/*
- * Copyright (c) 2006 Josef Cejka
- * Copyright (c) 2011 Petr Koupy
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/** @addtogroup softfloatmips64 mips64
- * @ingroup sfl
- * @brief softfloat architecture dependent definitions
- * @{
- */
-/** @file
- */
-
-#ifndef __SOFTFLOAT_FUNCTIONS_H__
-#define __SOFTFLOAT_FUNCTIONS_H__
-
-#define float32_to_int(X) float32_to_int32(X);
-#define float32_to_long(X) float32_to_int64(X);
-#define float32_to_longlong(X) float32_to_int64(X);
-
-#define float64_to_int(X) float64_to_int32(X);
-#define float64_to_long(X) float64_to_int64(X);
-#define float64_to_longlong(X) float64_to_int64(X);
-
-#define float128_to_int(X) float128_to_int32(X);
-#define float128_to_long(X) float128_to_int64(X);
-#define float128_to_longlong(X) float128_to_int64(X);
-
-#define float32_to_uint(X) float32_to_uint32(X);
-#define float32_to_ulong(X) float32_to_uint64(X);
-#define float32_to_ulonglong(X) float32_to_uint64(X);
-
-#define float64_to_uint(X) float64_to_uint32(X);
-#define float64_to_ulong(X) float64_to_uint64(X);
-#define float64_to_ulonglong(X) float64_to_uint64(X);
-
-#define float128_to_uint(X) float128_to_uint32(X);
-#define float128_to_ulong(X) float128_to_uint64(X);
-#define float128_to_ulonglong(X) float128_to_uint64(X);
-
-#define int_to_float32(X) int32_to_float32(X);
-#define long_to_float32(X) int64_to_float32(X);
-#define longlong_to_float32(X) int64_to_float32(X);
-
-#define int_to_float64(X) int32_to_float64(X);
-#define long_to_float64(X) int64_to_float64(X);
-#define longlong_to_float64(X) int64_to_float64(X);
-
-#define int_to_float128(X) int32_to_float128(X);
-#define long_to_float128(X) int64_to_float128(X);
-#define longlong_to_float128(X) int64_to_float128(X);
-
-#define uint_to_float32(X) uint32_to_float32(X);
-#define ulong_to_float32(X) uint64_to_float32(X);
-#define ulonglong_to_float32(X) uint64_to_float32(X);
-
-#define uint_to_float64(X) uint32_to_float64(X);
-#define ulong_to_float64(X) uint64_to_float64(X);
-#define ulonglong_to_float64(X) uint64_to_float64(X);
-
-#define uint_to_float128(X) uint32_to_float128(X);
-#define ulong_to_float128(X) uint64_to_float128(X);
-#define ulonglong_to_float128(X) uint64_to_float128(X);
-
-#endif
-
-/** @}
- */
Index: uspace/lib/softfloat/arch/ppc32/include/functions.h
===================================================================
--- uspace/lib/softfloat/arch/ppc32/include/functions.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ 	(revision )
@@ -1,92 +1,0 @@
-/*
- * Copyright (c) 2006 Josef Cejka
- * Copyright (c) 2011 Petr Koupy
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
- /** @addtogroup softfloatppc32 ppc32	
- * @ingroup sfl
- * @brief softfloat architecture dependent definitions 
- * @{
- */
-/** @file
- */
-
-#ifndef __SOFTFLOAT_FUNCTIONS_H__
-#define __SOFTFLOAT_FUNCTIONS_H__
-
-#define float32_to_int(X) float32_to_int32(X);
-#define float32_to_long(X) float32_to_int32(X);
-#define float32_to_longlong(X) float32_to_int64(X);
-
-#define float64_to_int(X) float64_to_int32(X);
-#define float64_to_long(X) float64_to_int32(X);
-#define float64_to_longlong(X) float64_to_int64(X);
-
-#define float128_to_int(X) float128_to_int32(X);
-#define float128_to_long(X) float128_to_int32(X);
-#define float128_to_longlong(X) float128_to_int64(X);
-
-#define float32_to_uint(X) float32_to_uint32(X);
-#define float32_to_ulong(X) float32_to_uint32(X);
-#define float32_to_ulonglong(X) float32_to_uint64(X);
-
-#define float64_to_uint(X) float64_to_uint32(X);
-#define float64_to_ulong(X) float64_to_uint32(X);
-#define float64_to_ulonglong(X) float64_to_uint64(X);
-
-#define float128_to_uint(X) float128_to_uint32(X);
-#define float128_to_ulong(X) float128_to_uint32(X);
-#define float128_to_ulonglong(X) float128_to_uint64(X);
-
-#define int_to_float32(X) int32_to_float32(X);
-#define long_to_float32(X) int32_to_float32(X);
-#define longlong_to_float32(X) int64_to_float32(X);
-
-#define int_to_float64(X) int32_to_float64(X);
-#define long_to_float64(X) int32_to_float64(X);
-#define longlong_to_float64(X) int64_to_float64(X);
-
-#define int_to_float128(X) int32_to_float128(X);
-#define long_to_float128(X) int32_to_float128(X);
-#define longlong_to_float128(X) int64_to_float128(X);
-
-#define uint_to_float32(X) uint32_to_float32(X);
-#define ulong_to_float32(X) uint32_to_float32(X);
-#define ulonglong_to_float32(X) uint64_to_float32(X);
-
-#define uint_to_float64(X) uint32_to_float64(X);
-#define ulong_to_float64(X) uint32_to_float64(X);
-#define ulonglong_to_float64(X) uint64_to_float64(X);
-
-#define uint_to_float128(X) uint32_to_float128(X);
-#define ulong_to_float128(X) uint32_to_float128(X);
-#define ulonglong_to_float128(X) uint64_to_float128(X);
-
-#endif
-
- /** @}
- */
Index: uspace/lib/softfloat/arch/sparc64/include/functions.h
===================================================================
--- uspace/lib/softfloat/arch/sparc64/include/functions.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ 	(revision )
@@ -1,94 +1,0 @@
-/*
- * Copyright (c) 2006 Josef Cejka
- * Copyright (c) 2011 Petr Koupy
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
- /** @addtogroup softfloatsparc64 sparc64	
- * @ingroup sfl
- * @brief softfloat architecture dependent definitions 
- * @{
- */
-/** @file
- */
-
-#ifndef __SOFTFLOAT_FUNCTIONS_H__
-#define __SOFTFLOAT_FUNCTIONS_H__
-
-#define SPARC_SOFTFLOAT
-
-#define float32_to_int(X) float32_to_int32(X);
-#define float32_to_long(X) float32_to_int64(X);
-#define float32_to_longlong(X) float32_to_int64(X);
-
-#define float64_to_int(X) float64_to_int32(X);
-#define float64_to_long(X) float64_to_int64(X);
-#define float64_to_longlong(X) float64_to_int64(X);
-
-#define float128_to_int(X) float128_to_int32(X);
-#define float128_to_long(X) float128_to_int64(X);
-#define float128_to_longlong(X) float128_to_int64(X);
-
-#define float32_to_uint(X) float32_to_uint32(X);
-#define float32_to_ulong(X) float32_to_uint64(X);
-#define float32_to_ulonglong(X) float32_to_uint64(X);
-
-#define float64_to_uint(X) float64_to_uint32(X);
-#define float64_to_ulong(X) float64_to_uint64(X);
-#define float64_to_ulonglong(X) float64_to_uint64(X);
-
-#define float128_to_uint(X) float128_to_uint32(X);
-#define float128_to_ulong(X) float128_to_uint64(X);
-#define float128_to_ulonglong(X) float128_to_uint64(X);
-
-#define int_to_float32(X) int32_to_float32(X);
-#define long_to_float32(X) int64_to_float32(X);
-#define longlong_to_float32(X) int64_to_float32(X);
-
-#define int_to_float64(X) int32_to_float64(X);
-#define long_to_float64(X) int64_to_float64(X);
-#define longlong_to_float64(X) int64_to_float64(X);
-
-#define int_to_float128(X) int32_to_float128(X);
-#define long_to_float128(X) int64_to_float128(X);
-#define longlong_to_float128(X) int64_to_float128(X);
-
-#define uint_to_float32(X) uint32_to_float32(X);
-#define ulong_to_float32(X) uint64_to_float32(X);
-#define ulonglong_to_float32(X) uint64_to_float32(X);
-
-#define uint_to_float64(X) uint32_to_float64(X);
-#define ulong_to_float64(X) uint64_to_float64(X);
-#define ulonglong_to_float64(X) uint64_to_float64(X);
-
-#define uint_to_float128(X) uint32_to_float128(X);
-#define ulong_to_float128(X) uint64_to_float128(X);
-#define ulonglong_to_float128(X) uint64_to_float128(X);
-
-#endif
-
- /** @}
- */
Index: uspace/lib/softfloat/generic/add.c
===================================================================
--- uspace/lib/softfloat/generic/add.c	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/generic/add.c	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -39,6 +39,5 @@
 #include <common.h>
 
-/**
- * Add two single-precision floats with the same signs.
+/** Add two single-precision floats with the same sign.
  *
  * @param a First input operand.
@@ -46,5 +45,5 @@
  * @return Result of addition.
  */
-float32 addFloat32(float32 a, float32 b)
+float32 add_float32(float32 a, float32 b)
 {
 	int expdiff;
@@ -53,7 +52,7 @@
 	expdiff = a.parts.exp - b.parts.exp;
 	if (expdiff < 0) {
-		if (isFloat32NaN(b)) {
-			/* TODO: fix SigNaN */
-			if (isFloat32SigNaN(b)) {
+		if (is_float32_nan(b)) {
+			/* TODO: fix SigNaN */
+			if (is_float32_signan(b)) {
 			}
 
@@ -71,9 +70,9 @@
 		expdiff *= -1;
 	} else {
-		if ((isFloat32NaN(a)) || (isFloat32NaN(b))) {
-			/* TODO: fix SigNaN */
-			if (isFloat32SigNaN(a) || isFloat32SigNaN(b)) {
-			}
-			return (isFloat32NaN(a) ? a : b);
+		if ((is_float32_nan(a)) || (is_float32_nan(b))) {
+			/* TODO: fix SigNaN */
+			if (is_float32_signan(a) || is_float32_signan(b)) {
+			}
+			return (is_float32_nan(a) ? a : b);
 		}
 		
@@ -150,6 +149,5 @@
 }
 
-/**
- * Add two double-precision floats with the same signs.
+/** Add two double-precision floats with the same sign.
  *
  * @param a First input operand.
@@ -157,5 +155,5 @@
  * @return Result of addition.
  */
-float64 addFloat64(float64 a, float64 b)
+float64 add_float64(float64 a, float64 b)
 {
 	int expdiff;
@@ -165,14 +163,14 @@
 	expdiff = ((int) a.parts.exp) - b.parts.exp;
 	if (expdiff < 0) {
-		if (isFloat64NaN(b)) {
-			/* TODO: fix SigNaN */
-			if (isFloat64SigNaN(b)) {
-			}
-
-			return b;
-		}
-		
-		/* b is infinity and a not */	
-		if (b.parts.exp == FLOAT64_MAX_EXPONENT) { 
+		if (is_float64_nan(b)) {
+			/* TODO: fix SigNaN */
+			if (is_float64_signan(b)) {
+			}
+
+			return b;
+		}
+		
+		/* b is infinity and a not */
+		if (b.parts.exp == FLOAT64_MAX_EXPONENT) {
 			return b;
 		}
@@ -184,7 +182,7 @@
 		expdiff *= -1;
 	} else {
-		if (isFloat64NaN(a)) {
-			/* TODO: fix SigNaN */
-			if (isFloat64SigNaN(a) || isFloat64SigNaN(b)) {
+		if (is_float64_nan(a)) {
+			/* TODO: fix SigNaN */
+			if (is_float64_signan(a) || is_float64_signan(b)) {
 			}
 			return a;
@@ -265,6 +263,5 @@
 }
 
-/**
- * Add two quadruple-precision floats with the same signs.
+/** Add two quadruple-precision floats with the same sign.
  *
  * @param a First input operand.
@@ -272,5 +269,5 @@
  * @return Result of addition.
  */
-float128 addFloat128(float128 a, float128 b)
+float128 add_float128(float128 a, float128 b)
 {
 	int expdiff;
@@ -280,7 +277,7 @@
 	expdiff = ((int) a.parts.exp) - b.parts.exp;
 	if (expdiff < 0) {
-		if (isFloat128NaN(b)) {
-			/* TODO: fix SigNaN */
-			if (isFloat128SigNaN(b)) {
+		if (is_float128_nan(b)) {
+			/* TODO: fix SigNaN */
+			if (is_float128_signan(b)) {
 			}
 
@@ -301,7 +298,7 @@
 		expdiff *= -1;
 	} else {
-		if (isFloat128NaN(a)) {
-			/* TODO: fix SigNaN */
-			if (isFloat128SigNaN(a) || isFloat128SigNaN(b)) {
+		if (is_float128_nan(a)) {
+			/* TODO: fix SigNaN */
+			if (is_float128_signan(a) || is_float128_signan(b)) {
 			}
 			return a;
Index: uspace/lib/softfloat/generic/common.c
===================================================================
--- uspace/lib/softfloat/generic/common.c	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/generic/common.c	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -66,5 +66,5 @@
  * @return Finished double-precision float.
  */
-float64 finishFloat64(int32_t cexp, uint64_t cfrac, char sign)
+float64 finish_float64(int32_t cexp, uint64_t cfrac, char sign)
 {
 	float64 result;
@@ -140,5 +140,5 @@
  * @return Finished quadruple-precision float.
  */
-float128 finishFloat128(int32_t cexp, uint64_t cfrac_hi, uint64_t cfrac_lo, 
+float128 finish_float128(int32_t cexp, uint64_t cfrac_hi, uint64_t cfrac_lo, 
     char sign, uint64_t shift_out)
 {
@@ -238,5 +238,5 @@
  * @return Number of detected leading zeroes.
  */
-int countZeroes8(uint8_t i)
+int count_zeroes8(uint8_t i)
 {
 	return zeroTable[i];
@@ -249,10 +249,10 @@
  * @return Number of detected leading zeroes.
  */
-int countZeroes32(uint32_t i)
+int count_zeroes32(uint32_t i)
 {
 	int j;
 	for (j = 0; j < 32; j += 8) {
 		if (i & (0xFF << (24 - j))) {
-			return (j + countZeroes8(i >> (24 - j)));
+			return (j + count_zeroes8(i >> (24 - j)));
 		}
 	}
@@ -267,10 +267,10 @@
  * @return Number of detected leading zeroes.
  */
-int countZeroes64(uint64_t i)
+int count_zeroes64(uint64_t i)
 {
 	int j;
 	for (j = 0; j < 64; j += 8) {
 		if (i & (0xFFll << (56 - j))) {
-			return (j + countZeroes8(i >> (56 - j)));
+			return (j + count_zeroes8(i >> (56 - j)));
 		}
 	}
@@ -286,5 +286,5 @@
  * @param fraction Fraction with hidden bit shifted to 30th bit.
  */
-void roundFloat32(int32_t *exp, uint32_t *fraction)
+void round_float32(int32_t *exp, uint32_t *fraction)
 {
 	/* rounding - if first bit after fraction is set then round up */
@@ -312,5 +312,5 @@
  * @param fraction Fraction with hidden bit shifted to 62nd bit.
  */
-void roundFloat64(int32_t *exp, uint64_t *fraction)
+void round_float64(int32_t *exp, uint64_t *fraction)
 {
 	/* rounding - if first bit after fraction is set then round up */
@@ -339,5 +339,5 @@
  * @param frac_lo Low part of fraction part with hidden bit shifted to 126th bit.
  */
-void roundFloat128(int32_t *exp, uint64_t *frac_hi, uint64_t *frac_lo)
+void round_float128(int32_t *exp, uint64_t *frac_hi, uint64_t *frac_lo)
 {
 	uint64_t tmp_hi, tmp_lo;
Index: uspace/lib/softfloat/generic/comparison.c
===================================================================
--- uspace/lib/softfloat/generic/comparison.c	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/generic/comparison.c	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -45,5 +45,5 @@
  * @return 1 if float is NaN, 0 otherwise.
  */
-int isFloat32NaN(float32 f)
+int is_float32_nan(float32 f)
 {
 	/* NaN : exp = 0xff and nonzero fraction */
@@ -58,5 +58,5 @@
  * @return 1 if float is NaN, 0 otherwise.
  */
-int isFloat64NaN(float64 d)
+int is_float64_nan(float64 d)
 {
 	/* NaN : exp = 0x7ff and nonzero fraction */
@@ -71,5 +71,5 @@
  * @return 1 if float is NaN, 0 otherwise.
  */
-int isFloat128NaN(float128 ld)
+int is_float128_nan(float128 ld)
 {
 	/* NaN : exp = 0x7fff and nonzero fraction */
@@ -84,5 +84,5 @@
  * @return 1 if float is signalling NaN, 0 otherwise.
  */
-int isFloat32SigNaN(float32 f)
+int is_float32_signan(float32 f)
 {
 	/* SigNaN : exp = 0xff and fraction = 0xxxxx..x (binary),
@@ -98,5 +98,5 @@
  * @return 1 if float is signalling NaN, 0 otherwise.
  */
-int isFloat64SigNaN(float64 d)
+int is_float64_signan(float64 d)
 {
 	/* SigNaN : exp = 0x7ff and fraction = 0xxxxx..x (binary),
@@ -112,5 +112,5 @@
  * @return 1 if float is signalling NaN, 0 otherwise.
  */
-int isFloat128SigNaN(float128 ld)
+int is_float128_signan(float128 ld)
 {
 	/* SigNaN : exp = 0x7fff and fraction = 0xxxxx..x (binary),
@@ -128,5 +128,5 @@
  * @return 1 if float is infinite, 0 otherwise.
  */
-int isFloat32Infinity(float32 f)
+int is_float32_infinity(float32 f)
 {
 	/* NaN : exp = 0x7ff and zero fraction */
@@ -140,5 +140,5 @@
  * @return 1 if float is infinite, 0 otherwise.
  */
-int isFloat64Infinity(float64 d) 
+int is_float64_infinity(float64 d)
 {
 	/* NaN : exp = 0x7ff and zero fraction */
@@ -152,5 +152,5 @@
  * @return 1 if float is infinite, 0 otherwise.
  */
-int isFloat128Infinity(float128 ld)
+int is_float128_infinity(float128 ld)
 {
 	/* NaN : exp = 0x7fff and zero fraction */
@@ -165,7 +165,7 @@
  * @return 1 if float is zero, 0 otherwise.
  */
-int isFloat32Zero(float32 f)
-{
-	return (((f.binary) & 0x7FFFFFFF) == 0);
+int is_float32_zero(float32 f)
+{
+	return (((f.bin) & 0x7FFFFFFF) == 0);
 }
 
@@ -176,7 +176,7 @@
  * @return 1 if float is zero, 0 otherwise.
  */
-int isFloat64Zero(float64 d)
-{
-	return (((d.binary) & 0x7FFFFFFFFFFFFFFFll) == 0);
+int is_float64_zero(float64 d)
+{
+	return (((d.bin) & 0x7FFFFFFFFFFFFFFFll) == 0);
 }
 
@@ -187,12 +187,12 @@
  * @return 1 if float is zero, 0 otherwise.
  */
-int isFloat128Zero(float128 ld)
+int is_float128_zero(float128 ld)
 {
 	uint64_t tmp_hi;
 	uint64_t tmp_lo;
-
-	and128(ld.binary.hi, ld.binary.lo,
+	
+	and128(ld.bin.hi, ld.bin.lo,
 	    0x7FFFFFFFFFFFFFFFll, 0xFFFFFFFFFFFFFFFFll, &tmp_hi, &tmp_lo);
-
+	
 	return eq128(tmp_hi, tmp_lo, 0x0ll, 0x0ll);
 }
@@ -205,9 +205,9 @@
  * @return 1 if both floats are equal, 0 otherwise.
  */
-int isFloat32eq(float32 a, float32 b)
+int is_float32_eq(float32 a, float32 b)
 {
 	/* a equals to b or both are zeros (with any sign) */
-	return ((a.binary == b.binary) ||
-	    (((a.binary | b.binary) & 0x7FFFFFFF) == 0));
+	return ((a.bin == b.bin) ||
+	    (((a.bin | b.bin) & 0x7FFFFFFF) == 0));
 }
 
@@ -219,9 +219,9 @@
  * @return 1 if both floats are equal, 0 otherwise.
  */
-int isFloat64eq(float64 a, float64 b)
+int is_float64_eq(float64 a, float64 b)
 {
 	/* a equals to b or both are zeros (with any sign) */
-	return ((a.binary == b.binary) ||
-	    (((a.binary | b.binary) & 0x7FFFFFFFFFFFFFFFll) == 0));
+	return ((a.bin == b.bin) ||
+	    (((a.bin | b.bin) & 0x7FFFFFFFFFFFFFFFll) == 0));
 }
 
@@ -233,12 +233,12 @@
  * @return 1 if both floats are equal, 0 otherwise.
  */
-int isFloat128eq(float128 a, float128 b)
+int is_float128_eq(float128 a, float128 b)
 {
 	uint64_t tmp_hi;
 	uint64_t tmp_lo;
-
+	
 	/* both are zeros (with any sign) */
-	or128(a.binary.hi, a.binary.lo,
-	    b.binary.hi, b.binary.lo, &tmp_hi, &tmp_lo);
+	or128(a.bin.hi, a.bin.lo,
+	    b.bin.hi, b.bin.lo, &tmp_hi, &tmp_lo);
 	and128(tmp_hi, tmp_lo,
 	    0x7FFFFFFFFFFFFFFFll, 0xFFFFFFFFFFFFFFFFll, &tmp_hi, &tmp_lo);
@@ -246,6 +246,6 @@
 	
 	/* a equals to b */
-	int are_equal = eq128(a.binary.hi, a.binary.lo, b.binary.hi, b.binary.lo);
-
+	int are_equal = eq128(a.bin.hi, a.bin.lo, b.bin.hi, b.bin.lo);
+	
 	return are_equal || both_zero;
 }
@@ -258,20 +258,24 @@
  * @return 1 if a is lower than b, 0 otherwise.
  */
-int isFloat32lt(float32 a, float32 b) 
-{
-	if (((a.binary | b.binary) & 0x7FFFFFFF) == 0) {
-		return 0; /* +- zeroes */
+int is_float32_lt(float32 a, float32 b) 
+{
+	if (((a.bin | b.bin) & 0x7FFFFFFF) == 0) {
+		/* +- zeroes */
+		return 0;
 	}
 	
 	if ((a.parts.sign) && (b.parts.sign)) {
 		/* if both are negative, smaller is that with greater binary value */
-		return (a.binary > b.binary);
-	}
-	
-	/* lets negate signs - now will be positive numbers allways bigger than
-	 * negative (first bit will be set for unsigned integer comparison) */
-	a.parts.sign = !a.parts.sign;
-	b.parts.sign = !b.parts.sign;
-	return (a.binary < b.binary);
+		return (a.bin > b.bin);
+	}
+	
+	/*
+	 * lets negate signs - now will be positive numbers always
+	 * bigger than negative (first bit will be set for unsigned
+	 * integer comparison)
+	 */
+	a.parts.sign = !a.parts.sign;
+	b.parts.sign = !b.parts.sign;
+	return (a.bin < b.bin);
 }
 
@@ -283,20 +287,24 @@
  * @return 1 if a is lower than b, 0 otherwise.
  */
-int isFloat64lt(float64 a, float64 b)
-{
-	if (((a.binary | b.binary) & 0x7FFFFFFFFFFFFFFFll) == 0) {
-		return 0; /* +- zeroes */
-	}
-
+int is_float64_lt(float64 a, float64 b)
+{
+	if (((a.bin | b.bin) & 0x7FFFFFFFFFFFFFFFll) == 0) {
+		/* +- zeroes */
+		return 0;
+	}
+	
 	if ((a.parts.sign) && (b.parts.sign)) {
 		/* if both are negative, smaller is that with greater binary value */
-		return (a.binary > b.binary);
-	}
-
-	/* lets negate signs - now will be positive numbers allways bigger than
-	 * negative (first bit will be set for unsigned integer comparison) */
-	a.parts.sign = !a.parts.sign;
-	b.parts.sign = !b.parts.sign;
-	return (a.binary < b.binary);
+		return (a.bin > b.bin);
+	}
+	
+	/*
+	 * lets negate signs - now will be positive numbers always
+	 * bigger than negative (first bit will be set for unsigned
+	 * integer comparison)
+	 */
+	a.parts.sign = !a.parts.sign;
+	b.parts.sign = !b.parts.sign;
+	return (a.bin < b.bin);
 }
 
@@ -308,27 +316,31 @@
  * @return 1 if a is lower than b, 0 otherwise.
  */
-int isFloat128lt(float128 a, float128 b)
+int is_float128_lt(float128 a, float128 b)
 {
 	uint64_t tmp_hi;
 	uint64_t tmp_lo;
-
-	or128(a.binary.hi, a.binary.lo,
-	    b.binary.hi, b.binary.lo, &tmp_hi, &tmp_lo);
+	
+	or128(a.bin.hi, a.bin.lo,
+	    b.bin.hi, b.bin.lo, &tmp_hi, &tmp_lo);
 	and128(tmp_hi, tmp_lo,
 	    0x7FFFFFFFFFFFFFFFll, 0xFFFFFFFFFFFFFFFFll, &tmp_hi, &tmp_lo);
 	if (eq128(tmp_hi, tmp_lo, 0x0ll, 0x0ll)) {
-		return 0; /* +- zeroes */
-	}
-
+		/* +- zeroes */
+		return 0;
+	}
+	
 	if ((a.parts.sign) && (b.parts.sign)) {
 		/* if both are negative, smaller is that with greater binary value */
-		return lt128(b.binary.hi, b.binary.lo, a.binary.hi, a.binary.lo);
-	}
-
-	/* lets negate signs - now will be positive numbers allways bigger than
-	 * negative (first bit will be set for unsigned integer comparison) */
-	a.parts.sign = !a.parts.sign;
-	b.parts.sign = !b.parts.sign;
-	return lt128(a.binary.hi, a.binary.lo, b.binary.hi, b.binary.lo);
+		return lt128(b.bin.hi, b.bin.lo, a.bin.hi, a.bin.lo);
+	}
+	
+	/*
+	 * lets negate signs - now will be positive numbers always
+	 * bigger than negative (first bit will be set for unsigned
+	 * integer comparison)
+	 */
+	a.parts.sign = !a.parts.sign;
+	b.parts.sign = !b.parts.sign;
+	return lt128(a.bin.hi, a.bin.lo, b.bin.hi, b.bin.lo);
 }
 
@@ -340,20 +352,24 @@
  * @return 1 if a is greater than b, 0 otherwise.
  */
-int isFloat32gt(float32 a, float32 b) 
-{
-	if (((a.binary | b.binary) & 0x7FFFFFFF) == 0) {
-		return 0; /* zeroes are equal with any sign */
+int is_float32_gt(float32 a, float32 b) 
+{
+	if (((a.bin | b.bin) & 0x7FFFFFFF) == 0) {
+		/* zeroes are equal with any sign */
+		return 0;
 	}
 	
 	if ((a.parts.sign) && (b.parts.sign)) {
 		/* if both are negative, greater is that with smaller binary value */
-		return (a.binary < b.binary);
-	}
-	
-	/* lets negate signs - now will be positive numbers allways bigger than
-	 *  negative (first bit will be set for unsigned integer comparison) */
-	a.parts.sign = !a.parts.sign;
-	b.parts.sign = !b.parts.sign;
-	return (a.binary > b.binary);
+		return (a.bin < b.bin);
+	}
+	
+	/*
+	 * lets negate signs - now will be positive numbers always
+	 * bigger than negative (first bit will be set for unsigned
+	 * integer comparison)
+	 */
+	a.parts.sign = !a.parts.sign;
+	b.parts.sign = !b.parts.sign;
+	return (a.bin > b.bin);
 }
 
@@ -365,20 +381,24 @@
  * @return 1 if a is greater than b, 0 otherwise.
  */
-int isFloat64gt(float64 a, float64 b)
-{
-	if (((a.binary | b.binary) & 0x7FFFFFFFFFFFFFFFll) == 0) {
-		return 0; /* zeroes are equal with any sign */
-	}
-
+int is_float64_gt(float64 a, float64 b)
+{
+	if (((a.bin | b.bin) & 0x7FFFFFFFFFFFFFFFll) == 0) {
+		/* zeroes are equal with any sign */
+		return 0;
+	}
+	
 	if ((a.parts.sign) && (b.parts.sign)) {
 		/* if both are negative, greater is that with smaller binary value */
-		return (a.binary < b.binary);
-	}
-
-	/* lets negate signs - now will be positive numbers allways bigger than
-	 *  negative (first bit will be set for unsigned integer comparison) */
-	a.parts.sign = !a.parts.sign;
-	b.parts.sign = !b.parts.sign;
-	return (a.binary > b.binary);
+		return (a.bin < b.bin);
+	}
+	
+	/*
+	 * lets negate signs - now will be positive numbers always
+	 * bigger than negative (first bit will be set for unsigned
+	 * integer comparison)
+	 */
+	a.parts.sign = !a.parts.sign;
+	b.parts.sign = !b.parts.sign;
+	return (a.bin > b.bin);
 }
 
@@ -390,27 +410,31 @@
  * @return 1 if a is greater than b, 0 otherwise.
  */
-int isFloat128gt(float128 a, float128 b)
+int is_float128_gt(float128 a, float128 b)
 {
 	uint64_t tmp_hi;
 	uint64_t tmp_lo;
-
-	or128(a.binary.hi, a.binary.lo,
-	    b.binary.hi, b.binary.lo, &tmp_hi, &tmp_lo);
+	
+	or128(a.bin.hi, a.bin.lo,
+	    b.bin.hi, b.bin.lo, &tmp_hi, &tmp_lo);
 	and128(tmp_hi, tmp_lo,
 	    0x7FFFFFFFFFFFFFFFll, 0xFFFFFFFFFFFFFFFFll, &tmp_hi, &tmp_lo);
 	if (eq128(tmp_hi, tmp_lo, 0x0ll, 0x0ll)) {
-		return 0; /* zeroes are equal with any sign */
-	}
-
+		/* zeroes are equal with any sign */
+		return 0;
+	}
+	
 	if ((a.parts.sign) && (b.parts.sign)) {
 		/* if both are negative, greater is that with smaller binary value */
-		return lt128(a.binary.hi, a.binary.lo, b.binary.hi, b.binary.lo);
-	}
-
-	/* lets negate signs - now will be positive numbers allways bigger than
-	 *  negative (first bit will be set for unsigned integer comparison) */
-	a.parts.sign = !a.parts.sign;
-	b.parts.sign = !b.parts.sign;
-	return lt128(b.binary.hi, b.binary.lo, a.binary.hi, a.binary.lo);
+		return lt128(a.bin.hi, a.bin.lo, b.bin.hi, b.bin.lo);
+	}
+	
+	/*
+	 * lets negate signs - now will be positive numbers always
+	 * bigger than negative (first bit will be set for unsigned
+	 * integer comparison)
+	 */
+	a.parts.sign = !a.parts.sign;
+	b.parts.sign = !b.parts.sign;
+	return lt128(b.bin.hi, b.bin.lo, a.bin.hi, a.bin.lo);
 }
 
Index: uspace/lib/softfloat/generic/conversion.c
===================================================================
--- uspace/lib/softfloat/generic/conversion.c	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/generic/conversion.c	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -39,5 +39,5 @@
 #include <common.h>
 
-float64 convertFloat32ToFloat64(float32 a) 
+float64 float32_to_float64(float32 a)
 {
 	float64 result;
@@ -48,7 +48,7 @@
 	result.parts.fraction <<= (FLOAT64_FRACTION_SIZE - FLOAT32_FRACTION_SIZE);
 	
-	if ((isFloat32Infinity(a)) || (isFloat32NaN(a))) {
+	if ((is_float32_infinity(a)) || (is_float32_nan(a))) {
 		result.parts.exp = FLOAT64_MAX_EXPONENT;
-		/* TODO; check if its correct for SigNaNs*/
+		// TODO; check if its correct for SigNaNs
 		return result;
 	}
@@ -57,5 +57,5 @@
 	if (a.parts.exp == 0) {
 		/* normalize denormalized numbers */
-
+		
 		if (result.parts.fraction == 0) { /* fix zero */
 			result.parts.exp = 0;
@@ -77,10 +77,10 @@
 }
 
-float128 convertFloat32ToFloat128(float32 a)
+float128 float32_to_float128(float32 a)
 {
 	float128 result;
 	uint64_t frac_hi, frac_lo;
 	uint64_t tmp_hi, tmp_lo;
-
+	
 	result.parts.sign = a.parts.sign;
 	result.parts.frac_hi = 0;
@@ -91,15 +91,15 @@
 	result.parts.frac_hi = frac_hi;
 	result.parts.frac_lo = frac_lo;
-
-	if ((isFloat32Infinity(a)) || (isFloat32NaN(a))) {
+	
+	if ((is_float32_infinity(a)) || (is_float32_nan(a))) {
 		result.parts.exp = FLOAT128_MAX_EXPONENT;
-		/* TODO; check if its correct for SigNaNs*/
-		return result;
-	}
-
+		// TODO; check if its correct for SigNaNs
+		return result;
+	}
+	
 	result.parts.exp = a.parts.exp + ((int) FLOAT128_BIAS - FLOAT32_BIAS);
 	if (a.parts.exp == 0) {
 		/* normalize denormalized numbers */
-
+		
 		if (eq128(result.parts.frac_hi,
 		    result.parts.frac_lo, 0x0ll, 0x0ll)) { /* fix zero */
@@ -107,8 +107,8 @@
 			return result;
 		}
-
+		
 		frac_hi = result.parts.frac_hi;
 		frac_lo = result.parts.frac_lo;
-
+		
 		and128(frac_hi, frac_lo,
 		    FLOAT128_HIDDEN_BIT_MASK_HI, FLOAT128_HIDDEN_BIT_MASK_LO,
@@ -118,19 +118,19 @@
 			--result.parts.exp;
 		}
-
+		
 		++result.parts.exp;
 		result.parts.frac_hi = frac_hi;
 		result.parts.frac_lo = frac_lo;
 	}
-
-	return result;
-}
-
-float128 convertFloat64ToFloat128(float64 a)
+	
+	return result;
+}
+
+float128 float64_to_float128(float64 a)
 {
 	float128 result;
 	uint64_t frac_hi, frac_lo;
 	uint64_t tmp_hi, tmp_lo;
-
+	
 	result.parts.sign = a.parts.sign;
 	result.parts.frac_hi = 0;
@@ -141,15 +141,15 @@
 	result.parts.frac_hi = frac_hi;
 	result.parts.frac_lo = frac_lo;
-
-	if ((isFloat64Infinity(a)) || (isFloat64NaN(a))) {
+	
+	if ((is_float64_infinity(a)) || (is_float64_nan(a))) {
 		result.parts.exp = FLOAT128_MAX_EXPONENT;
-		/* TODO; check if its correct for SigNaNs*/
-		return result;
-	}
-
+		// TODO; check if its correct for SigNaNs
+		return result;
+	}
+	
 	result.parts.exp = a.parts.exp + ((int) FLOAT128_BIAS - FLOAT64_BIAS);
 	if (a.parts.exp == 0) {
 		/* normalize denormalized numbers */
-
+		
 		if (eq128(result.parts.frac_hi,
 		    result.parts.frac_lo, 0x0ll, 0x0ll)) { /* fix zero */
@@ -157,8 +157,8 @@
 			return result;
 		}
-
+		
 		frac_hi = result.parts.frac_hi;
 		frac_lo = result.parts.frac_lo;
-
+		
 		and128(frac_hi, frac_lo,
 		    FLOAT128_HIDDEN_BIT_MASK_HI, FLOAT128_HIDDEN_BIT_MASK_LO,
@@ -168,14 +168,14 @@
 			--result.parts.exp;
 		}
-
+		
 		++result.parts.exp;
 		result.parts.frac_hi = frac_hi;
 		result.parts.frac_lo = frac_lo;
 	}
-
-	return result;
-}
-
-float32 convertFloat64ToFloat32(float64 a) 
+	
+	return result;
+}
+
+float32 float64_to_float32(float64 a)
 {
 	float32 result;
@@ -185,24 +185,24 @@
 	result.parts.sign = a.parts.sign;
 	
-	if (isFloat64NaN(a)) {
+	if (is_float64_nan(a)) {
 		result.parts.exp = FLOAT32_MAX_EXPONENT;
 		
-		if (isFloat64SigNaN(a)) {
+		if (is_float64_signan(a)) {
 			/* set first bit of fraction nonzero */
 			result.parts.fraction = FLOAT32_HIDDEN_BIT_MASK >> 1;
 			return result;
 		}
-
+		
 		/* fraction nonzero but its first bit is zero */
 		result.parts.fraction = 0x1;
 		return result;
 	}
-
-	if (isFloat64Infinity(a)) {
+	
+	if (is_float64_infinity(a)) {
 		result.parts.fraction = 0;
 		result.parts.exp = FLOAT32_MAX_EXPONENT;
 		return result;
 	}
-
+	
 	exp = (int) a.parts.exp - FLOAT64_BIAS + FLOAT32_BIAS;
 	
@@ -239,5 +239,5 @@
 		return result;
 	}
-
+	
 	result.parts.exp = exp;
 	result.parts.fraction =
@@ -246,34 +246,34 @@
 }
 
-float32 convertFloat128ToFloat32(float128 a)
+float32 float128_to_float32(float128 a)
 {
 	float32 result;
 	int32_t exp;
 	uint64_t frac_hi, frac_lo;
-
+	
 	result.parts.sign = a.parts.sign;
-
-	if (isFloat128NaN(a)) {
+	
+	if (is_float128_nan(a)) {
 		result.parts.exp = FLOAT32_MAX_EXPONENT;
-
-		if (isFloat128SigNaN(a)) {
+		
+		if (is_float128_signan(a)) {
 			/* set first bit of fraction nonzero */
 			result.parts.fraction = FLOAT32_HIDDEN_BIT_MASK >> 1;
 			return result;
 		}
-
+		
 		/* fraction nonzero but its first bit is zero */
 		result.parts.fraction = 0x1;
 		return result;
 	}
-
-	if (isFloat128Infinity(a)) {
+	
+	if (is_float128_infinity(a)) {
 		result.parts.fraction = 0;
 		result.parts.exp = FLOAT32_MAX_EXPONENT;
 		return result;
 	}
-
+	
 	exp = (int) a.parts.exp - FLOAT128_BIAS + FLOAT32_BIAS;
-
+	
 	if (exp >= FLOAT32_MAX_EXPONENT) {
 		/* FIXME: overflow */
@@ -283,7 +283,7 @@
 	} else if (exp <= 0) {
 		/* underflow or denormalized */
-
+		
 		result.parts.exp = 0;
-
+		
 		exp *= -1;
 		if (exp > FLOAT32_FRACTION_SIZE) {
@@ -292,17 +292,17 @@
 			return result;
 		}
-
+		
 		/* denormalized */
-
+		
 		frac_hi = a.parts.frac_hi;
 		frac_lo = a.parts.frac_lo;
-
+		
 		/* denormalize and set hidden bit */
 		frac_hi |= FLOAT128_HIDDEN_BIT_MASK_HI;
-
+		
 		rshift128(frac_hi, frac_lo,
 		    (FLOAT128_FRACTION_SIZE - FLOAT32_FRACTION_SIZE + 1),
 		    &frac_hi, &frac_lo);
-
+		
 		while (exp > 0) {
 			--exp;
@@ -310,8 +310,8 @@
 		}
 		result.parts.fraction = frac_lo;
-
-		return result;
-	}
-
+		
+		return result;
+	}
+	
 	result.parts.exp = exp;
 	frac_hi = a.parts.frac_hi;
@@ -324,34 +324,34 @@
 }
 
-float64 convertFloat128ToFloat64(float128 a)
+float64 float128_to_float64(float128 a)
 {
 	float64 result;
 	int32_t exp;
 	uint64_t frac_hi, frac_lo;
-
+	
 	result.parts.sign = a.parts.sign;
-
-	if (isFloat128NaN(a)) {
+	
+	if (is_float128_nan(a)) {
 		result.parts.exp = FLOAT64_MAX_EXPONENT;
-
-		if (isFloat128SigNaN(a)) {
+		
+		if (is_float128_signan(a)) {
 			/* set first bit of fraction nonzero */
 			result.parts.fraction = FLOAT64_HIDDEN_BIT_MASK >> 1;
 			return result;
 		}
-
+		
 		/* fraction nonzero but its first bit is zero */
 		result.parts.fraction = 0x1;
 		return result;
 	}
-
-	if (isFloat128Infinity(a)) {
+	
+	if (is_float128_infinity(a)) {
 		result.parts.fraction = 0;
 		result.parts.exp = FLOAT64_MAX_EXPONENT;
 		return result;
 	}
-
+	
 	exp = (int) a.parts.exp - FLOAT128_BIAS + FLOAT64_BIAS;
-
+	
 	if (exp >= FLOAT64_MAX_EXPONENT) {
 		/* FIXME: overflow */
@@ -361,7 +361,7 @@
 	} else if (exp <= 0) {
 		/* underflow or denormalized */
-
+		
 		result.parts.exp = 0;
-
+		
 		exp *= -1;
 		if (exp > FLOAT64_FRACTION_SIZE) {
@@ -370,17 +370,17 @@
 			return result;
 		}
-
+		
 		/* denormalized */
-
+		
 		frac_hi = a.parts.frac_hi;
 		frac_lo = a.parts.frac_lo;
-
+		
 		/* denormalize and set hidden bit */
 		frac_hi |= FLOAT128_HIDDEN_BIT_MASK_HI;
-
+		
 		rshift128(frac_hi, frac_lo,
 		    (FLOAT128_FRACTION_SIZE - FLOAT64_FRACTION_SIZE + 1),
 		    &frac_hi, &frac_lo);
-
+		
 		while (exp > 0) {
 			--exp;
@@ -388,8 +388,8 @@
 		}
 		result.parts.fraction = frac_lo;
-
-		return result;
-	}
-
+		
+		return result;
+	}
+	
 	result.parts.exp = exp;
 	frac_hi = a.parts.frac_hi;
@@ -402,7 +402,5 @@
 }
 
-
-/** 
- * Helping procedure for converting float32 to uint32.
+/** Helper procedure for converting float32 to uint32.
  *
  * @param a Floating point number in normalized form
@@ -424,5 +422,5 @@
 	/* shift fraction to left so hidden bit will be the most significant bit */
 	frac <<= 32 - FLOAT32_FRACTION_SIZE - 1; 
-
+	
 	frac >>= 32 - (a.parts.exp - FLOAT32_BIAS) - 1;
 	if ((a.parts.sign == 1) && (frac != 0)) {
@@ -434,14 +432,14 @@
 }
 
-/* 
- * FIXME: Im not sure what to return if overflow/underflow happens 
- * 	- now its the biggest or the smallest int
- */ 
+/*
+ * FIXME: Im not sure what to return if overflow/underflow happens
+ *  - now its the biggest or the smallest int
+ */
 uint32_t float32_to_uint32(float32 a)
 {
-	if (isFloat32NaN(a))
+	if (is_float32_nan(a))
 		return UINT32_MAX;
 	
-	if (isFloat32Infinity(a) || (a.parts.exp >= (32 + FLOAT32_BIAS))) {
+	if (is_float32_infinity(a) || (a.parts.exp >= (32 + FLOAT32_BIAS))) {
 		if (a.parts.sign)
 			return UINT32_MIN;
@@ -453,14 +451,14 @@
 }
 
-/* 
- * FIXME: Im not sure what to return if overflow/underflow happens 
- * 	- now its the biggest or the smallest int
- */ 
+/*
+ * FIXME: Im not sure what to return if overflow/underflow happens
+ *  - now its the biggest or the smallest int
+ */
 int32_t float32_to_int32(float32 a)
 {
-	if (isFloat32NaN(a))
+	if (is_float32_nan(a))
 		return INT32_MAX;
 	
-	if (isFloat32Infinity(a) || (a.parts.exp >= (32 + FLOAT32_BIAS))) {
+	if (is_float32_infinity(a) || (a.parts.exp >= (32 + FLOAT32_BIAS))) {
 		if (a.parts.sign)
 			return INT32_MIN;
@@ -472,7 +470,5 @@
 }
 
-
-/**
- * Helping procedure for converting float32 to uint64.
+/** Helper procedure for converting float32 to uint64.
  *
  * @param a Floating point number in normalized form
@@ -483,16 +479,16 @@
 {
 	uint64_t frac;
-
+	
 	if (a.parts.exp < FLOAT32_BIAS) {
-		/*TODO: rounding*/
+		// TODO: rounding
 		return 0;
 	}
-
+	
 	frac = a.parts.fraction;
-
+	
 	frac |= FLOAT32_HIDDEN_BIT_MASK;
 	/* shift fraction to left so hidden bit will be the most significant bit */
 	frac <<= 64 - FLOAT32_FRACTION_SIZE - 1;
-
+	
 	frac >>= 64 - (a.parts.exp - FLOAT32_BIAS) - 1;
 	if ((a.parts.sign == 1) && (frac != 0)) {
@@ -500,50 +496,47 @@
 		++frac;
 	}
-
+	
 	return frac;
 }
 
-/* 
+/*
  * FIXME: Im not sure what to return if overflow/underflow happens
- * 	- now its the biggest or the smallest int
+ *  - now its the biggest or the smallest int
  */
 uint64_t float32_to_uint64(float32 a)
 {
-	if (isFloat32NaN(a))
+	if (is_float32_nan(a))
 		return UINT64_MAX;
-
-
-	if (isFloat32Infinity(a) || (a.parts.exp >= (64 + FLOAT32_BIAS))) {
+	
+	if (is_float32_infinity(a) || (a.parts.exp >= (64 + FLOAT32_BIAS))) {
 		if (a.parts.sign)
 			return UINT64_MIN;
-
+		
 		return UINT64_MAX;
 	}
-
+	
 	return _float32_to_uint64_helper(a);
 }
 
-/* 
+/*
  * FIXME: Im not sure what to return if overflow/underflow happens
- * 	- now its the biggest or the smallest int
+ *  - now its the biggest or the smallest int
  */
 int64_t float32_to_int64(float32 a)
 {
-	if (isFloat32NaN(a))
+	if (is_float32_nan(a))
 		return INT64_MAX;
-
-	if (isFloat32Infinity(a) || (a.parts.exp >= (64 + FLOAT32_BIAS))) {
+	
+	if (is_float32_infinity(a) || (a.parts.exp >= (64 + FLOAT32_BIAS))) {
 		if (a.parts.sign)
 			return INT64_MIN;
-
+		
 		return INT64_MAX;
 	}
-
+	
 	return _float32_to_uint64_helper(a);
 }
 
-
-/**
- * Helping procedure for converting float64 to uint64.
+/** Helper procedure for converting float64 to uint64.
  *
  * @param a Floating point number in normalized form
@@ -554,16 +547,16 @@
 {
 	uint64_t frac;
-
+	
 	if (a.parts.exp < FLOAT64_BIAS) {
-		/*TODO: rounding*/
+		// TODO: rounding
 		return 0;
 	}
-
+	
 	frac = a.parts.fraction;
-
+	
 	frac |= FLOAT64_HIDDEN_BIT_MASK;
 	/* shift fraction to left so hidden bit will be the most significant bit */
 	frac <<= 64 - FLOAT64_FRACTION_SIZE - 1;
-
+	
 	frac >>= 64 - (a.parts.exp - FLOAT64_BIAS) - 1;
 	if ((a.parts.sign == 1) && (frac != 0)) {
@@ -571,5 +564,5 @@
 		++frac;
 	}
-
+	
 	return frac;
 }
@@ -577,18 +570,18 @@
 /*
  * FIXME: Im not sure what to return if overflow/underflow happens
- * 	- now its the biggest or the smallest int
+ *  - now its the biggest or the smallest int
  */
 uint32_t float64_to_uint32(float64 a)
 {
-	if (isFloat64NaN(a))
+	if (is_float64_nan(a))
 		return UINT32_MAX;
-
-	if (isFloat64Infinity(a) || (a.parts.exp >= (32 + FLOAT64_BIAS))) {
+	
+	if (is_float64_infinity(a) || (a.parts.exp >= (32 + FLOAT64_BIAS))) {
 		if (a.parts.sign)
 			return UINT32_MIN;
-
+		
 		return UINT32_MAX;
 	}
-
+	
 	return (uint32_t) _float64_to_uint64_helper(a);
 }
@@ -596,32 +589,31 @@
 /*
  * FIXME: Im not sure what to return if overflow/underflow happens
- * 	- now its the biggest or the smallest int
+ *  - now its the biggest or the smallest int
  */
 int32_t float64_to_int32(float64 a)
 {
-	if (isFloat64NaN(a))
+	if (is_float64_nan(a))
 		return INT32_MAX;
-
-	if (isFloat64Infinity(a) || (a.parts.exp >= (32 + FLOAT64_BIAS))) {
+	
+	if (is_float64_infinity(a) || (a.parts.exp >= (32 + FLOAT64_BIAS))) {
 		if (a.parts.sign)
 			return INT32_MIN;
-
+		
 		return INT32_MAX;
 	}
-
+	
 	return (int32_t) _float64_to_uint64_helper(a);
 }
 
-
-/* 
+/*
  * FIXME: Im not sure what to return if overflow/underflow happens 
- * 	- now its the biggest or the smallest int
- */ 
+ *  - now its the biggest or the smallest int
+ */
 uint64_t float64_to_uint64(float64 a)
 {
-	if (isFloat64NaN(a))
+	if (is_float64_nan(a))
 		return UINT64_MAX;
 	
-	if (isFloat64Infinity(a) || (a.parts.exp >= (64 + FLOAT64_BIAS))) {
+	if (is_float64_infinity(a) || (a.parts.exp >= (64 + FLOAT64_BIAS))) {
 		if (a.parts.sign)
 			return UINT64_MIN;
@@ -633,14 +625,14 @@
 }
 
-/* 
+/*
  * FIXME: Im not sure what to return if overflow/underflow happens 
- * 	- now its the biggest or the smallest int
- */ 
+ *  - now its the biggest or the smallest int
+ */
 int64_t float64_to_int64(float64 a)
 {
-	if (isFloat64NaN(a))
+	if (is_float64_nan(a))
 		return INT64_MAX;
 	
-	if (isFloat64Infinity(a) || (a.parts.exp >= (64 + FLOAT64_BIAS))) {
+	if (is_float64_infinity(a) || (a.parts.exp >= (64 + FLOAT64_BIAS))) {
 		if (a.parts.sign)
 			return INT64_MIN;
@@ -652,7 +644,5 @@
 }
 
-
-/**
- * Helping procedure for converting float128 to uint64.
+/** Helper procedure for converting float128 to uint64.
  *
  * @param a Floating point number in normalized form
@@ -663,18 +653,18 @@
 {
 	uint64_t frac_hi, frac_lo;
-
+	
 	if (a.parts.exp < FLOAT128_BIAS) {
-		/*TODO: rounding*/
+		// TODO: rounding
 		return 0;
 	}
-
+	
 	frac_hi = a.parts.frac_hi;
 	frac_lo = a.parts.frac_lo;
-
+	
 	frac_hi |= FLOAT128_HIDDEN_BIT_MASK_HI;
 	/* shift fraction to left so hidden bit will be the most significant bit */
 	lshift128(frac_hi, frac_lo,
 	    (128 - FLOAT128_FRACTION_SIZE - 1), &frac_hi, &frac_lo);
-
+	
 	rshift128(frac_hi, frac_lo,
 	    (128 - (a.parts.exp - FLOAT128_BIAS) - 1), &frac_hi, &frac_lo);
@@ -683,5 +673,5 @@
 		add128(frac_hi, frac_lo, 0x0ll, 0x1ll, &frac_hi, &frac_lo);
 	}
-
+	
 	return frac_lo;
 }
@@ -689,18 +679,18 @@
 /*
  * FIXME: Im not sure what to return if overflow/underflow happens
- * 	- now its the biggest or the smallest int
+ *  - now its the biggest or the smallest int
  */
 uint32_t float128_to_uint32(float128 a)
 {
-	if (isFloat128NaN(a))
+	if (is_float128_nan(a))
 		return UINT32_MAX;
-
-	if (isFloat128Infinity(a) || (a.parts.exp >= (32 + FLOAT128_BIAS))) {
+	
+	if (is_float128_infinity(a) || (a.parts.exp >= (32 + FLOAT128_BIAS))) {
 		if (a.parts.sign)
 			return UINT32_MIN;
-
+		
 		return UINT32_MAX;
 	}
-
+	
 	return (uint32_t) _float128_to_uint64_helper(a);
 }
@@ -708,38 +698,37 @@
 /*
  * FIXME: Im not sure what to return if overflow/underflow happens
- * 	- now its the biggest or the smallest int
+ *  - now its the biggest or the smallest int
  */
 int32_t float128_to_int32(float128 a)
 {
-	if (isFloat128NaN(a))
+	if (is_float128_nan(a))
 		return INT32_MAX;
-
-	if (isFloat128Infinity(a) || (a.parts.exp >= (32 + FLOAT128_BIAS))) {
+	
+	if (is_float128_infinity(a) || (a.parts.exp >= (32 + FLOAT128_BIAS))) {
 		if (a.parts.sign)
 			return INT32_MIN;
-
+		
 		return INT32_MAX;
 	}
-
+	
 	return (int32_t) _float128_to_uint64_helper(a);
 }
 
-
 /*
  * FIXME: Im not sure what to return if overflow/underflow happens
- * 	- now its the biggest or the smallest int
+ *  - now its the biggest or the smallest int
  */
 uint64_t float128_to_uint64(float128 a)
 {
-	if (isFloat128NaN(a))
+	if (is_float128_nan(a))
 		return UINT64_MAX;
-
-	if (isFloat128Infinity(a) || (a.parts.exp >= (64 + FLOAT128_BIAS))) {
+	
+	if (is_float128_infinity(a) || (a.parts.exp >= (64 + FLOAT128_BIAS))) {
 		if (a.parts.sign)
 			return UINT64_MIN;
-
+		
 		return UINT64_MAX;
 	}
-
+	
 	return _float128_to_uint64_helper(a);
 }
@@ -747,21 +736,20 @@
 /*
  * FIXME: Im not sure what to return if overflow/underflow happens
- * 	- now its the biggest or the smallest int
+ *  - now its the biggest or the smallest int
  */
 int64_t float128_to_int64(float128 a)
 {
-	if (isFloat128NaN(a))
+	if (is_float128_nan(a))
 		return INT64_MAX;
-
-	if (isFloat128Infinity(a) || (a.parts.exp >= (64 + FLOAT128_BIAS))) {
+	
+	if (is_float128_infinity(a) || (a.parts.exp >= (64 + FLOAT128_BIAS))) {
 		if (a.parts.sign)
 			return INT64_MIN;
-
+		
 		return INT64_MAX;
 	}
-
+	
 	return _float128_to_uint64_helper(a);
 }
-
 
 float32 uint32_to_float32(uint32_t i)
@@ -773,11 +761,11 @@
 	result.parts.sign = 0;
 	result.parts.fraction = 0;
-
-	counter = countZeroes32(i);
-
+	
+	counter = count_zeroes32(i);
+	
 	exp = FLOAT32_BIAS + 32 - counter - 1;
 	
 	if (counter == 32) {
-		result.binary = 0;
+		result.bin = 0;
 		return result;
 	}
@@ -788,30 +776,28 @@
 		i >>= 1;
 	}
-
-	roundFloat32(&exp, &i);
-
+	
+	round_float32(&exp, &i);
+	
 	result.parts.fraction = i >> (32 - FLOAT32_FRACTION_SIZE - 2);
 	result.parts.exp = exp;
-
-	return result;
-}
-
-float32 int32_to_float32(int32_t i) 
+	
+	return result;
+}
+
+float32 int32_to_float32(int32_t i)
 {
 	float32 result;
-
-	if (i < 0) {
+	
+	if (i < 0)
 		result = uint32_to_float32((uint32_t) (-i));
-	} else {
+	else
 		result = uint32_to_float32((uint32_t) i);
-	}
 	
 	result.parts.sign = i < 0;
-
- 	return result;
-}
-
-
-float32 uint64_to_float32(uint64_t i) 
+	
+	return result;
+}
+
+float32 uint64_to_float32(uint64_t i)
 {
 	int counter;
@@ -822,11 +808,11 @@
 	result.parts.sign = 0;
 	result.parts.fraction = 0;
-
-	counter = countZeroes64(i);
-
+	
+	counter = count_zeroes64(i);
+	
 	exp = FLOAT32_BIAS + 64 - counter - 1;
 	
 	if (counter == 64) {
-		result.binary = 0;
+		result.bin = 0;
 		return result;
 	}
@@ -840,6 +826,6 @@
 	
 	j = (uint32_t) i;
-	roundFloat32(&exp, &j);
-
+	round_float32(&exp, &j);
+	
 	result.parts.fraction = j >> (32 - FLOAT32_FRACTION_SIZE - 2);
 	result.parts.exp = exp;
@@ -847,17 +833,16 @@
 }
 
-float32 int64_to_float32(int64_t i) 
+float32 int64_to_float32(int64_t i)
 {
 	float32 result;
-
-	if (i < 0) {
+	
+	if (i < 0)
 		result = uint64_to_float32((uint64_t) (-i));
-	} else {
+	else
 		result = uint64_to_float32((uint64_t) i);
-	}
 	
 	result.parts.sign = i < 0;
-
- 	return result;
+	
+	return result;
 }
 
@@ -871,42 +856,41 @@
 	result.parts.sign = 0;
 	result.parts.fraction = 0;
-
-	counter = countZeroes32(i);
-
+	
+	counter = count_zeroes32(i);
+	
 	exp = FLOAT64_BIAS + 32 - counter - 1;
 	
 	if (counter == 32) {
-		result.binary = 0;
+		result.bin = 0;
 		return result;
 	}
 	
 	frac = i;
-	frac <<= counter + 32 - 1; 
-
-	roundFloat64(&exp, &frac);
-
+	frac <<= counter + 32 - 1;
+	
+	round_float64(&exp, &frac);
+	
 	result.parts.fraction = frac >> (64 - FLOAT64_FRACTION_SIZE - 2);
 	result.parts.exp = exp;
-
-	return result;
-}
-
-float64 int32_to_float64(int32_t i) 
+	
+	return result;
+}
+
+float64 int32_to_float64(int32_t i)
 {
 	float64 result;
-
-	if (i < 0) {
+	
+	if (i < 0)
 		result = uint32_to_float64((uint32_t) (-i));
-	} else {
+	else
 		result = uint32_to_float64((uint32_t) i);
-	}
 	
 	result.parts.sign = i < 0;
-
- 	return result;
-}
-
-
-float64 uint64_to_float64(uint64_t i) 
+	
+	return result;
+}
+
+
+float64 uint64_to_float64(uint64_t i)
 {
 	int counter;
@@ -916,11 +900,11 @@
 	result.parts.sign = 0;
 	result.parts.fraction = 0;
-
-	counter = countZeroes64(i);
-
+	
+	counter = count_zeroes64(i);
+	
 	exp = FLOAT64_BIAS + 64 - counter - 1;
 	
 	if (counter == 64) {
-		result.binary = 0;
+		result.bin = 0;
 		return result;
 	}
@@ -931,7 +915,7 @@
 		i >>= 1;
 	}
-
-	roundFloat64(&exp, &i);
-
+	
+	round_float64(&exp, &i);
+	
 	result.parts.fraction = i >> (64 - FLOAT64_FRACTION_SIZE - 2);
 	result.parts.exp = exp;
@@ -939,19 +923,17 @@
 }
 
-float64 int64_to_float64(int64_t i) 
+float64 int64_to_float64(int64_t i)
 {
 	float64 result;
-
-	if (i < 0) {
+	
+	if (i < 0)
 		result = uint64_to_float64((uint64_t) (-i));
-	} else {
+	else
 		result = uint64_to_float64((uint64_t) i);
-	}
 	
 	result.parts.sign = i < 0;
-
- 	return result;
-}
-
+	
+	return result;
+}
 
 float128 uint32_to_float128(uint32_t i)
@@ -961,25 +943,25 @@
 	float128 result;
 	uint64_t frac_hi, frac_lo;
-
+	
 	result.parts.sign = 0;
 	result.parts.frac_hi = 0;
 	result.parts.frac_lo = 0;
-
-	counter = countZeroes32(i);
-
+	
+	counter = count_zeroes32(i);
+	
 	exp = FLOAT128_BIAS + 32 - counter - 1;
-
+	
 	if (counter == 32) {
-		result.binary.hi = 0;
-		result.binary.lo = 0;
-		return result;
-	}
-
+		result.bin.hi = 0;
+		result.bin.lo = 0;
+		return result;
+	}
+	
 	frac_hi = 0;
 	frac_lo = i;
 	lshift128(frac_hi, frac_lo, (counter + 96 - 1), &frac_hi, &frac_lo);
-
-	roundFloat128(&exp, &frac_hi, &frac_lo);
-
+	
+	round_float128(&exp, &frac_hi, &frac_lo);
+	
 	rshift128(frac_hi, frac_lo,
 	    (128 - FLOAT128_FRACTION_SIZE - 2), &frac_hi, &frac_lo);
@@ -987,5 +969,5 @@
 	result.parts.frac_lo = frac_lo;
 	result.parts.exp = exp;
-
+	
 	return result;
 }
@@ -994,14 +976,13 @@
 {
 	float128 result;
-
-	if (i < 0) {
+	
+	if (i < 0)
 		result = uint32_to_float128((uint32_t) (-i));
-	} else {
+	else
 		result = uint32_to_float128((uint32_t) i);
-	}
-
+	
 	result.parts.sign = i < 0;
-
- 	return result;
+	
+	return result;
 }
 
@@ -1013,25 +994,25 @@
 	float128 result;
 	uint64_t frac_hi, frac_lo;
-
+	
 	result.parts.sign = 0;
 	result.parts.frac_hi = 0;
 	result.parts.frac_lo = 0;
-
-	counter = countZeroes64(i);
-
+	
+	counter = count_zeroes64(i);
+	
 	exp = FLOAT128_BIAS + 64 - counter - 1;
-
+	
 	if (counter == 64) {
-		result.binary.hi = 0;
-		result.binary.lo = 0;
-		return result;
-	}
-
+		result.bin.hi = 0;
+		result.bin.lo = 0;
+		return result;
+	}
+	
 	frac_hi = 0;
 	frac_lo = i;
 	lshift128(frac_hi, frac_lo, (counter + 64 - 1), &frac_hi, &frac_lo);
-
-	roundFloat128(&exp, &frac_hi, &frac_lo);
-
+	
+	round_float128(&exp, &frac_hi, &frac_lo);
+	
 	rshift128(frac_hi, frac_lo,
 	    (128 - FLOAT128_FRACTION_SIZE - 2), &frac_hi, &frac_lo);
@@ -1039,5 +1020,5 @@
 	result.parts.frac_lo = frac_lo;
 	result.parts.exp = exp;
-
+	
 	return result;
 }
@@ -1046,14 +1027,13 @@
 {
 	float128 result;
-
-	if (i < 0) {
+	
+	if (i < 0)
 		result = uint64_to_float128((uint64_t) (-i));
-	} else {
+	else
 		result = uint64_to_float128((uint64_t) i);
-	}
-
+	
 	result.parts.sign = i < 0;
-
- 	return result;
+	
+	return result;
 }
 
Index: uspace/lib/softfloat/generic/div.c
===================================================================
--- uspace/lib/softfloat/generic/div.c	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/generic/div.c	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -41,12 +41,13 @@
 #include <common.h>
 
-/**
- * Divide two single-precision floats.
- * 
+/** Divide two single-precision floats.
+ *
  * @param a Nominator.
  * @param b Denominator.
+ *
  * @return Result of division.
- */
-float32 divFloat32(float32 a, float32 b) 
+ *
+ */
+float32 div_float32(float32 a, float32 b)
 {
 	float32 result;
@@ -56,24 +57,24 @@
 	result.parts.sign = a.parts.sign ^ b.parts.sign;
 	
-	if (isFloat32NaN(a)) {
-		if (isFloat32SigNaN(a)) {
-			/*FIXME: SigNaN*/
-		}
-		/*NaN*/
+	if (is_float32_nan(a)) {
+		if (is_float32_signan(a)) {
+			// FIXME: SigNaN
+		}
+		/* NaN */
 		return a;
 	}
 	
-	if (isFloat32NaN(b)) {
-		if (isFloat32SigNaN(b)) {
-			/*FIXME: SigNaN*/
-		}
-		/*NaN*/
+	if (is_float32_nan(b)) {
+		if (is_float32_signan(b)) {
+			// FIXME: SigNaN
+		}
+		/* NaN */
 		return b;
 	}
 	
-	if (isFloat32Infinity(a)) {
-		if (isFloat32Infinity(b)) {
+	if (is_float32_infinity(a)) {
+		if (is_float32_infinity(b)) {
 			/*FIXME: inf / inf */
-			result.binary = FLOAT32_NAN;
+			result.bin = FLOAT32_NAN;
 			return result;
 		}
@@ -83,7 +84,7 @@
 		return result;
 	}
-
-	if (isFloat32Infinity(b)) {
-		if (isFloat32Zero(a)) {
+	
+	if (is_float32_infinity(b)) {
+		if (is_float32_zero(a)) {
 			/* FIXME 0 / inf */
 			result.parts.exp = 0;
@@ -97,8 +98,8 @@
 	}
 	
-	if (isFloat32Zero(b)) {
-		if (isFloat32Zero(a)) {
+	if (is_float32_zero(b)) {
+		if (is_float32_zero(a)) {
 			/*FIXME: 0 / 0*/
-			result.binary = FLOAT32_NAN;
+			result.bin = FLOAT32_NAN;
 			return result;
 		}
@@ -121,8 +122,8 @@
 			return result;
 		}
-
+		
 		/* normalize it*/
 		afrac <<= 1;
-		/* afrac is nonzero => it must stop */	
+		/* afrac is nonzero => it must stop */
 		while (!(afrac & FLOAT32_HIDDEN_BIT_MASK)) {
 			afrac <<= 1;
@@ -130,8 +131,8 @@
 		}
 	}
-
+	
 	if (bexp == 0) {
 		bfrac <<= 1;
-		/* bfrac is nonzero => it must stop */	
+		/* bfrac is nonzero => it must stop */
 		while (!(bfrac & FLOAT32_HIDDEN_BIT_MASK)) {
 			bfrac <<= 1;
@@ -139,8 +140,8 @@
 		}
 	}
-
-	afrac =	(afrac | FLOAT32_HIDDEN_BIT_MASK) << (32 - FLOAT32_FRACTION_SIZE - 1);
-	bfrac =	(bfrac | FLOAT32_HIDDEN_BIT_MASK) << (32 - FLOAT32_FRACTION_SIZE);
-
+	
+	afrac = (afrac | FLOAT32_HIDDEN_BIT_MASK) << (32 - FLOAT32_FRACTION_SIZE - 1);
+	bfrac = (bfrac | FLOAT32_HIDDEN_BIT_MASK) << (32 - FLOAT32_FRACTION_SIZE);
+	
 	if (bfrac <= (afrac << 1)) {
 		afrac >>= 1;
@@ -169,6 +170,6 @@
 		++cexp;
 		cfrac >>= 1;
-	}	
-
+	}
+	
 	/* check overflow */
 	if (cexp >= FLOAT32_MAX_EXPONENT) {
@@ -178,5 +179,5 @@
 		return result;
 	}
-
+	
 	if (cexp < 0) {
 		/* FIXME: underflow */
@@ -190,5 +191,5 @@
 			cexp++;
 			cfrac >>= 1;
-		}	
+		}
 	} else {
 		result.parts.exp = (uint32_t) cexp;
@@ -197,15 +198,16 @@
 	result.parts.fraction = ((cfrac >> 6) & (~FLOAT32_HIDDEN_BIT_MASK)); 
 	
-	return result;	
+	return result;
 }
 
-/**
- * Divide two double-precision floats.
+/** Divide two double-precision floats.
  *
  * @param a Nominator.
  * @param b Denominator.
+ *
  * @return Result of division.
- */
-float64 divFloat64(float64 a, float64 b) 
+ *
+ */
+float64 div_float64(float64 a, float64 b) 
 {
 	float64 result;
@@ -217,29 +219,29 @@
 	result.parts.sign = a.parts.sign ^ b.parts.sign;
 	
-	if (isFloat64NaN(a)) {
-		if (isFloat64SigNaN(b)) {
-			/*FIXME: SigNaN*/
+	if (is_float64_nan(a)) {
+		if (is_float64_signan(b)) {
+			// FIXME: SigNaN
 			return b;
 		}
 		
-		if (isFloat64SigNaN(a)) {
-			/*FIXME: SigNaN*/
-		}
-		/*NaN*/
+		if (is_float64_signan(a)) {
+			// FIXME: SigNaN
+		}
+		/* NaN */
 		return a;
 	}
 	
-	if (isFloat64NaN(b)) {
-		if (isFloat64SigNaN(b)) {
-			/*FIXME: SigNaN*/
-		}
-		/*NaN*/
+	if (is_float64_nan(b)) {
+		if (is_float64_signan(b)) {
+			// FIXME: SigNaN
+		}
+		/* NaN */
 		return b;
 	}
 	
-	if (isFloat64Infinity(a)) {
-		if (isFloat64Infinity(b) || isFloat64Zero(b)) {
-			/*FIXME: inf / inf */
-			result.binary = FLOAT64_NAN;
+	if (is_float64_infinity(a)) {
+		if (is_float64_infinity(b) || is_float64_zero(b)) {
+			// FIXME: inf / inf
+			result.bin = FLOAT64_NAN;
 			return result;
 		}
@@ -249,7 +251,7 @@
 		return result;
 	}
-
-	if (isFloat64Infinity(b)) {
-		if (isFloat64Zero(a)) {
+	
+	if (is_float64_infinity(b)) {
+		if (is_float64_zero(a)) {
 			/* FIXME 0 / inf */
 			result.parts.exp = 0;
@@ -263,8 +265,8 @@
 	}
 	
-	if (isFloat64Zero(b)) {
-		if (isFloat64Zero(a)) {
+	if (is_float64_zero(b)) {
+		if (is_float64_zero(a)) {
 			/*FIXME: 0 / 0*/
-			result.binary = FLOAT64_NAN;
+			result.bin = FLOAT64_NAN;
 			return result;
 		}
@@ -274,5 +276,5 @@
 		return result;
 	}
-
+	
 	afrac = a.parts.fraction;
 	aexp = a.parts.exp;
@@ -287,5 +289,5 @@
 			return result;
 		}
-
+		
 		/* normalize it*/
 		aexp++;
@@ -296,5 +298,5 @@
 		}
 	}
-
+	
 	if (bexp == 0) {
 		bexp++;
@@ -305,8 +307,8 @@
 		}
 	}
-
-	afrac =	(afrac | FLOAT64_HIDDEN_BIT_MASK) << (64 - FLOAT64_FRACTION_SIZE - 2);
-	bfrac =	(bfrac | FLOAT64_HIDDEN_BIT_MASK) << (64 - FLOAT64_FRACTION_SIZE - 1);
-
+	
+	afrac = (afrac | FLOAT64_HIDDEN_BIT_MASK) << (64 - FLOAT64_FRACTION_SIZE - 2);
+	bfrac = (bfrac | FLOAT64_HIDDEN_BIT_MASK) << (64 - FLOAT64_FRACTION_SIZE - 1);
+	
 	if (bfrac <= (afrac << 1)) {
 		afrac >>= 1;
@@ -330,16 +332,17 @@
 	
 	/* round and shift */
-	result = finishFloat64(cexp, cfrac, result.parts.sign);
+	result = finish_float64(cexp, cfrac, result.parts.sign);
 	return result;
 }
 
-/**
- * Divide two quadruple-precision floats.
+/** Divide two quadruple-precision floats.
  *
  * @param a Nominator.
  * @param b Denominator.
+ *
  * @return Result of division.
- */
-float128 divFloat128(float128 a, float128 b)
+ *
+ */
+float128 div_float128(float128 a, float128 b)
 {
 	float128 result;
@@ -349,33 +352,33 @@
 	uint64_t rem_hihi, rem_hilo, rem_lohi, rem_lolo;
 	uint64_t tmp_hihi, tmp_hilo, tmp_lohi, tmp_lolo;
-
+	
 	result.parts.sign = a.parts.sign ^ b.parts.sign;
-
-	if (isFloat128NaN(a)) {
-		if (isFloat128SigNaN(b)) {
-			/*FIXME: SigNaN*/
+	
+	if (is_float128_nan(a)) {
+		if (is_float128_signan(b)) {
+			// FIXME: SigNaN
 			return b;
 		}
-
-		if (isFloat128SigNaN(a)) {
-			/*FIXME: SigNaN*/
-		}
-		/*NaN*/
+		
+		if (is_float128_signan(a)) {
+			// FIXME: SigNaN
+		}
+		/* NaN */
 		return a;
 	}
-
-	if (isFloat128NaN(b)) {
-		if (isFloat128SigNaN(b)) {
-			/*FIXME: SigNaN*/
-		}
-		/*NaN*/
+	
+	if (is_float128_nan(b)) {
+		if (is_float128_signan(b)) {
+			// FIXME: SigNaN
+		}
+		/* NaN */
 		return b;
 	}
-
-	if (isFloat128Infinity(a)) {
-		if (isFloat128Infinity(b) || isFloat128Zero(b)) {
-			/*FIXME: inf / inf */
-			result.binary.hi = FLOAT128_NAN_HI;
-			result.binary.lo = FLOAT128_NAN_LO;
+	
+	if (is_float128_infinity(a)) {
+		if (is_float128_infinity(b) || is_float128_zero(b)) {
+			// FIXME: inf / inf
+			result.bin.hi = FLOAT128_NAN_HI;
+			result.bin.lo = FLOAT128_NAN_LO;
 			return result;
 		}
@@ -386,8 +389,8 @@
 		return result;
 	}
-
-	if (isFloat128Infinity(b)) {
-		if (isFloat128Zero(a)) {
-			/* FIXME 0 / inf */
+	
+	if (is_float128_infinity(b)) {
+		if (is_float128_zero(a)) {
+			// FIXME 0 / inf
 			result.parts.exp = 0;
 			result.parts.frac_hi = 0;
@@ -395,5 +398,5 @@
 			return result;
 		}
-		/* FIXME: num / inf*/
+		// FIXME: num / inf
 		result.parts.exp = 0;
 		result.parts.frac_hi = 0;
@@ -401,13 +404,13 @@
 		return result;
 	}
-
-	if (isFloat128Zero(b)) {
-		if (isFloat128Zero(a)) {
-			/*FIXME: 0 / 0*/
-			result.binary.hi = FLOAT128_NAN_HI;
-			result.binary.lo = FLOAT128_NAN_LO;
-			return result;
-		}
-		/* FIXME: division by zero */
+	
+	if (is_float128_zero(b)) {
+		if (is_float128_zero(a)) {
+			// FIXME: 0 / 0
+			result.bin.hi = FLOAT128_NAN_HI;
+			result.bin.lo = FLOAT128_NAN_LO;
+			return result;
+		}
+		// FIXME: division by zero
 		result.parts.exp = 0;
 		result.parts.frac_hi = 0;
@@ -415,5 +418,5 @@
 		return result;
 	}
-
+	
 	afrac_hi = a.parts.frac_hi;
 	afrac_lo = a.parts.frac_lo;
@@ -422,5 +425,5 @@
 	bfrac_lo = b.parts.frac_lo;
 	bexp = b.parts.exp;
-
+	
 	/* denormalized numbers */
 	if (aexp == 0) {
@@ -431,5 +434,5 @@
 			return result;
 		}
-
+		
 		/* normalize it*/
 		aexp++;
@@ -443,5 +446,5 @@
 		}
 	}
-
+	
 	if (bexp == 0) {
 		bexp++;
@@ -455,5 +458,5 @@
 		}
 	}
-
+	
 	or128(afrac_hi, afrac_lo,
 	    FLOAT128_HIDDEN_BIT_MASK_HI, FLOAT128_HIDDEN_BIT_MASK_LO,
@@ -466,18 +469,18 @@
 	lshift128(bfrac_hi, bfrac_lo,
 	    (128 - FLOAT128_FRACTION_SIZE - 1), &bfrac_hi, &bfrac_lo);
-
+	
 	if (le128(bfrac_hi, bfrac_lo, afrac_hi, afrac_lo)) {
 		rshift128(afrac_hi, afrac_lo, 1, &afrac_hi, &afrac_lo);
 		aexp++;
 	}
-
+	
 	cexp = aexp - bexp + FLOAT128_BIAS - 2;
-
+	
 	cfrac_hi = div128est(afrac_hi, afrac_lo, bfrac_hi);
-
+	
 	mul128(bfrac_hi, bfrac_lo, 0x0ll, cfrac_hi,
 	    &tmp_lolo /* dummy */, &tmp_hihi, &tmp_hilo, &tmp_lohi);
-
-	/* sub192(afrac_hi, afrac_lo, 0, 
+	
+	/* sub192(afrac_hi, afrac_lo, 0,
 	 *     tmp_hihi, tmp_hilo, tmp_lohi
 	 *     &rem_hihi, &rem_hilo, &rem_lohi); */
@@ -487,8 +490,8 @@
 	}
 	rem_lohi = -tmp_lohi;
-
+	
 	while ((int64_t) rem_hihi < 0) {
 		--cfrac_hi;
-		/* add192(rem_hihi, rem_hilo, rem_lohi, 
+		/* add192(rem_hihi, rem_hilo, rem_lohi,
 		 *     0, bfrac_hi, bfrac_lo,
 		 *     &rem_hihi, &rem_hilo, &rem_lohi); */
@@ -498,11 +501,11 @@
 		}
 	}
-
+	
 	cfrac_lo = div128est(rem_hilo, rem_lohi, bfrac_lo);
-
+	
 	if ((cfrac_lo & 0x3FFF) <= 4) {
 		mul128(bfrac_hi, bfrac_lo, 0x0ll, cfrac_lo,
-	        &tmp_hihi /* dummy */, &tmp_hilo, &tmp_lohi, &tmp_lolo);
-
+		    &tmp_hihi /* dummy */, &tmp_hilo, &tmp_lohi, &tmp_lolo);
+		
 		/* sub192(rem_hilo, rem_lohi, 0,
 		 *     tmp_hilo, tmp_lohi, tmp_lolo,
@@ -513,5 +516,5 @@
 		}
 		rem_lolo = -tmp_lolo;
-
+		
 		while ((int64_t) rem_hilo < 0) {
 			--cfrac_lo;
@@ -524,13 +527,13 @@
 			}
 		}
-
+		
 		cfrac_lo |= ((rem_hilo | rem_lohi | rem_lolo) != 0 );
 	}
-
+	
 	shift_out = cfrac_lo << (64 - (128 - FLOAT128_FRACTION_SIZE - 1));
 	rshift128(cfrac_hi, cfrac_lo, (128 - FLOAT128_FRACTION_SIZE - 1),
 	    &cfrac_hi, &cfrac_lo);
-
-	result = finishFloat128(cexp, cfrac_hi, cfrac_lo, result.parts.sign, shift_out);
+	
+	result = finish_float128(cexp, cfrac_hi, cfrac_lo, result.parts.sign, shift_out);
 	return result;
 }
Index: uspace/lib/softfloat/generic/mul.c
===================================================================
--- uspace/lib/softfloat/generic/mul.c	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/generic/mul.c	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -39,27 +39,28 @@
 #include <common.h>
 
-/**
- * Multiply two single-precision floats.
+/** Multiply two single-precision floats.
  *
  * @param a First input operand.
  * @param b Second input operand.
+ *
  * @return Result of multiplication.
- */
-float32 mulFloat32(float32 a, float32 b)
+ *
+ */
+float32 mul_float32(float32 a, float32 b)
 {
 	float32 result;
 	uint64_t frac1, frac2;
 	int32_t exp;
-
+	
 	result.parts.sign = a.parts.sign ^ b.parts.sign;
 	
-	if (isFloat32NaN(a) || isFloat32NaN(b)) {
+	if (is_float32_nan(a) || is_float32_nan(b)) {
 		/* TODO: fix SigNaNs */
-		if (isFloat32SigNaN(a)) {
+		if (is_float32_signan(a)) {
 			result.parts.fraction = a.parts.fraction;
 			result.parts.exp = a.parts.exp;
 			return result;
 		}
-		if (isFloat32SigNaN(b)) { /* TODO: fix SigNaN */
+		if (is_float32_signan(b)) { /* TODO: fix SigNaN */
 			result.parts.fraction = b.parts.fraction;
 			result.parts.exp = b.parts.exp;
@@ -67,12 +68,12 @@
 		}
 		/* set NaN as result */
-		result.binary = FLOAT32_NAN;
-		return result;
-	}
-		
-	if (isFloat32Infinity(a)) { 
-		if (isFloat32Zero(b)) {
-			/* FIXME: zero * infinity */
-			result.binary = FLOAT32_NAN;
+		result.bin = FLOAT32_NAN;
+		return result;
+	}
+	
+	if (is_float32_infinity(a)) {
+		if (is_float32_zero(b)) {
+			/* FIXME: zero * infinity */
+			result.bin = FLOAT32_NAN;
 			return result;
 		}
@@ -81,9 +82,9 @@
 		return result;
 	}
-
-	if (isFloat32Infinity(b)) { 
-		if (isFloat32Zero(a)) {
-			/* FIXME: zero * infinity */
-			result.binary = FLOAT32_NAN;
+	
+	if (is_float32_infinity(b)) {
+		if (is_float32_zero(a)) {
+			/* FIXME: zero * infinity */
+			result.bin = FLOAT32_NAN;
 			return result;
 		}
@@ -92,5 +93,5 @@
 		return result;
 	}
-
+	
 	/* exp is signed so we can easy detect underflow */
 	exp = a.parts.exp + b.parts.exp;
@@ -100,5 +101,5 @@
 		/* FIXME: overflow */
 		/* set infinity as result */
-		result.binary = FLOAT32_INF;
+		result.bin = FLOAT32_INF;
 		result.parts.sign = a.parts.sign ^ b.parts.sign;
 		return result;
@@ -121,5 +122,5 @@
 	
 	frac2 = b.parts.fraction;
-
+	
 	if (b.parts.exp > 0) {
 		frac2 |= FLOAT32_HIDDEN_BIT_MASK;
@@ -127,26 +128,28 @@
 		++exp;
 	}
-
+	
 	frac1 <<= 1; /* one bit space for rounding */
-
+	
 	frac1 = frac1 * frac2;
-
+	
 	/* round and return */
-	while ((exp < FLOAT32_MAX_EXPONENT) && (frac1 >= (1 << (FLOAT32_FRACTION_SIZE + 2)))) { 
+	while ((exp < FLOAT32_MAX_EXPONENT) &&
+	    (frac1 >= (1 << (FLOAT32_FRACTION_SIZE + 2)))) {
 		/* 23 bits of fraction + one more for hidden bit (all shifted 1 bit left) */
 		++exp;
 		frac1 >>= 1;
 	}
-
+	
 	/* rounding */
 	/* ++frac1; FIXME: not works - without it is ok */
 	frac1 >>= 1; /* shift off rounding space */
 	
-	if ((exp < FLOAT32_MAX_EXPONENT) && (frac1 >= (1 << (FLOAT32_FRACTION_SIZE + 1)))) {
+	if ((exp < FLOAT32_MAX_EXPONENT) &&
+	    (frac1 >= (1 << (FLOAT32_FRACTION_SIZE + 1)))) {
 		++exp;
 		frac1 >>= 1;
 	}
-
-	if (exp >= FLOAT32_MAX_EXPONENT) {	
+	
+	if (exp >= FLOAT32_MAX_EXPONENT) {
 		/* TODO: fix overflow */
 		/* return infinity*/
@@ -157,6 +160,6 @@
 	
 	exp -= FLOAT32_FRACTION_SIZE;
-
-	if (exp <= FLOAT32_FRACTION_SIZE) { 
+	
+	if (exp <= FLOAT32_FRACTION_SIZE) {
 		/* denormalized number */
 		frac1 >>= 1; /* denormalize */
@@ -175,30 +178,31 @@
 	result.parts.fraction = frac1 & ((1 << FLOAT32_FRACTION_SIZE) - 1);
 	
-	return result;	
+	return result;
 }
 
-/**
- * Multiply two double-precision floats.
+/** Multiply two double-precision floats.
  *
  * @param a First input operand.
  * @param b Second input operand.
+ *
  * @return Result of multiplication.
- */
-float64 mulFloat64(float64 a, float64 b)
+ *
+ */
+float64 mul_float64(float64 a, float64 b)
 {
 	float64 result;
 	uint64_t frac1, frac2;
 	int32_t exp;
-
+	
 	result.parts.sign = a.parts.sign ^ b.parts.sign;
 	
-	if (isFloat64NaN(a) || isFloat64NaN(b)) {
+	if (is_float64_nan(a) || is_float64_nan(b)) {
 		/* TODO: fix SigNaNs */
-		if (isFloat64SigNaN(a)) {
+		if (is_float64_signan(a)) {
 			result.parts.fraction = a.parts.fraction;
 			result.parts.exp = a.parts.exp;
 			return result;
 		}
-		if (isFloat64SigNaN(b)) { /* TODO: fix SigNaN */
+		if (is_float64_signan(b)) { /* TODO: fix SigNaN */
 			result.parts.fraction = b.parts.fraction;
 			result.parts.exp = b.parts.exp;
@@ -206,12 +210,12 @@
 		}
 		/* set NaN as result */
-		result.binary = FLOAT64_NAN;
-		return result;
-	}
-		
-	if (isFloat64Infinity(a)) { 
-		if (isFloat64Zero(b)) {
-			/* FIXME: zero * infinity */
-			result.binary = FLOAT64_NAN;
+		result.bin = FLOAT64_NAN;
+		return result;
+	}
+	
+	if (is_float64_infinity(a)) {
+		if (is_float64_zero(b)) {
+			/* FIXME: zero * infinity */
+			result.bin = FLOAT64_NAN;
 			return result;
 		}
@@ -220,9 +224,9 @@
 		return result;
 	}
-
-	if (isFloat64Infinity(b)) { 
-		if (isFloat64Zero(a)) {
-			/* FIXME: zero * infinity */
-			result.binary = FLOAT64_NAN;
+	
+	if (is_float64_infinity(b)) {
+		if (is_float64_zero(a)) {
+			/* FIXME: zero * infinity */
+			result.bin = FLOAT64_NAN;
 			return result;
 		}
@@ -231,10 +235,10 @@
 		return result;
 	}
-
+	
 	/* exp is signed so we can easy detect underflow */
 	exp = a.parts.exp + b.parts.exp - FLOAT64_BIAS;
 	
 	frac1 = a.parts.fraction;
-
+	
 	if (a.parts.exp > 0) {
 		frac1 |= FLOAT64_HIDDEN_BIT_MASK;
@@ -244,5 +248,5 @@
 	
 	frac2 = b.parts.fraction;
-
+	
 	if (b.parts.exp > 0) {
 		frac2 |= FLOAT64_HIDDEN_BIT_MASK;
@@ -250,10 +254,10 @@
 		++exp;
 	}
-
+	
 	frac1 <<= (64 - FLOAT64_FRACTION_SIZE - 1);
 	frac2 <<= (64 - FLOAT64_FRACTION_SIZE - 2);
-
+	
 	mul64(frac1, frac2, &frac1, &frac2);
-
+	
 	frac1 |= (frac2 != 0);
 	if (frac1 & (0x1ll << 62)) {
@@ -261,27 +265,28 @@
 		exp--;
 	}
-
-	result = finishFloat64(exp, frac1, result.parts.sign);
+	
+	result = finish_float64(exp, frac1, result.parts.sign);
 	return result;
 }
 
-/**
- * Multiply two quadruple-precision floats.
+/** Multiply two quadruple-precision floats.
  *
  * @param a First input operand.
  * @param b Second input operand.
+ *
  * @return Result of multiplication.
- */
-float128 mulFloat128(float128 a, float128 b)
+ *
+ */
+float128 mul_float128(float128 a, float128 b)
 {
 	float128 result;
 	uint64_t frac1_hi, frac1_lo, frac2_hi, frac2_lo, tmp_hi, tmp_lo;
 	int32_t exp;
-
+	
 	result.parts.sign = a.parts.sign ^ b.parts.sign;
-
-	if (isFloat128NaN(a) || isFloat128NaN(b)) {
+	
+	if (is_float128_nan(a) || is_float128_nan(b)) {
 		/* TODO: fix SigNaNs */
-		if (isFloat128SigNaN(a)) {
+		if (is_float128_signan(a)) {
 			result.parts.frac_hi = a.parts.frac_hi;
 			result.parts.frac_lo = a.parts.frac_lo;
@@ -289,5 +294,5 @@
 			return result;
 		}
-		if (isFloat128SigNaN(b)) { /* TODO: fix SigNaN */
+		if (is_float128_signan(b)) { /* TODO: fix SigNaN */
 			result.parts.frac_hi = b.parts.frac_hi;
 			result.parts.frac_lo = b.parts.frac_lo;
@@ -296,14 +301,14 @@
 		}
 		/* set NaN as result */
-		result.binary.hi = FLOAT128_NAN_HI;
-		result.binary.lo = FLOAT128_NAN_LO;
-		return result;
-	}
-
-	if (isFloat128Infinity(a)) {
-		if (isFloat128Zero(b)) {
-			/* FIXME: zero * infinity */
-			result.binary.hi = FLOAT128_NAN_HI;
-			result.binary.lo = FLOAT128_NAN_LO;
+		result.bin.hi = FLOAT128_NAN_HI;
+		result.bin.lo = FLOAT128_NAN_LO;
+		return result;
+	}
+	
+	if (is_float128_infinity(a)) {
+		if (is_float128_zero(b)) {
+			/* FIXME: zero * infinity */
+			result.bin.hi = FLOAT128_NAN_HI;
+			result.bin.lo = FLOAT128_NAN_LO;
 			return result;
 		}
@@ -313,10 +318,10 @@
 		return result;
 	}
-
-	if (isFloat128Infinity(b)) {
-		if (isFloat128Zero(a)) {
-			/* FIXME: zero * infinity */
-			result.binary.hi = FLOAT128_NAN_HI;
-			result.binary.lo = FLOAT128_NAN_LO;
+	
+	if (is_float128_infinity(b)) {
+		if (is_float128_zero(a)) {
+			/* FIXME: zero * infinity */
+			result.bin.hi = FLOAT128_NAN_HI;
+			result.bin.lo = FLOAT128_NAN_LO;
 			return result;
 		}
@@ -326,22 +331,22 @@
 		return result;
 	}
-
+	
 	/* exp is signed so we can easy detect underflow */
 	exp = a.parts.exp + b.parts.exp - FLOAT128_BIAS - 1;
-
+	
 	frac1_hi = a.parts.frac_hi;
 	frac1_lo = a.parts.frac_lo;
-
+	
 	if (a.parts.exp > 0) {
 		or128(frac1_hi, frac1_lo,
-	        FLOAT128_HIDDEN_BIT_MASK_HI, FLOAT128_HIDDEN_BIT_MASK_LO,
-	        &frac1_hi, &frac1_lo);
-	} else {
-		++exp;
-	}
-
+		    FLOAT128_HIDDEN_BIT_MASK_HI, FLOAT128_HIDDEN_BIT_MASK_LO,
+		    &frac1_hi, &frac1_lo);
+	} else {
+		++exp;
+	}
+	
 	frac2_hi = b.parts.frac_hi;
 	frac2_lo = b.parts.frac_lo;
-
+	
 	if (b.parts.exp > 0) {
 		or128(frac2_hi, frac2_lo,
@@ -351,8 +356,8 @@
 		++exp;
 	}
-
+	
 	lshift128(frac2_hi, frac2_lo,
 	    128 - FLOAT128_FRACTION_SIZE, &frac2_hi, &frac2_lo);
-
+	
 	tmp_hi = frac1_hi;
 	tmp_lo = frac1_lo;
@@ -361,5 +366,5 @@
 	add128(frac1_hi, frac1_lo, tmp_hi, tmp_lo, &frac1_hi, &frac1_lo);
 	frac2_hi |= (frac2_lo != 0x0ll);
-
+	
 	if ((FLOAT128_HIDDEN_BIT_MASK_HI << 1) <= frac1_hi) {
 		frac2_hi >>= 1;
@@ -370,6 +375,6 @@
 		++exp;
 	}
-
-	result = finishFloat128(exp, frac1_hi, frac1_lo, result.parts.sign, frac2_hi);
+	
+	result = finish_float128(exp, frac1_hi, frac1_lo, result.parts.sign, frac2_hi);
 	return result;
 }
Index: uspace/lib/softfloat/generic/softfloat.c
===================================================================
--- uspace/lib/softfloat/generic/softfloat.c	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/generic/softfloat.c	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -48,494 +48,609 @@
 #include <other.h>
 
-#include <functions.h>
-
 /* Arithmetic functions */
 
 float __addsf3(float a, float b)
 {
-	float32 fa, fb;
-	fa.f = a;
-	fb.f = b;
-	if (fa.parts.sign != fb.parts.sign) {
-		if (fa.parts.sign) {
-			fa.parts.sign = 0;
-			return subFloat32(fb, fa).f;
-		};
-		fb.parts.sign = 0;
-		return subFloat32(fa, fb).f;
-	}
-	return addFloat32(fa, fb).f;
+	float_t fa;
+	float_t fb;
+	float_t res;
+	
+	fa.val = a;
+	fb.val = b;
+	
+	if (fa.data.parts.sign != fb.data.parts.sign) {
+		if (fa.data.parts.sign) {
+			fa.data.parts.sign = 0;
+			res.data = sub_float(fb.data, fa.data);
+			
+			return res.val;
+		}
+		
+		fb.data.parts.sign = 0;
+		res.data = sub_float(fa.data, fb.data);
+		
+		return res.val;
+	}
+	
+	res.data = add_float(fa.data, fb.data);
+	return res.val;
 }
 
 double __adddf3(double a, double b)
 {
-	float64 da, db;
-	da.d = a;
-	db.d = b;
-	if (da.parts.sign != db.parts.sign) {
-		if (da.parts.sign) {
-			da.parts.sign = 0;
-			return subFloat64(db, da).d;
-		};
-		db.parts.sign = 0;
-		return subFloat64(da, db).d;
-	}
-	return addFloat64(da, db).d;
+	double_t da;
+	double_t db;
+	double_t res;
+	
+	da.val = a;
+	db.val = b;
+	
+	if (da.data.parts.sign != db.data.parts.sign) {
+		if (da.data.parts.sign) {
+			da.data.parts.sign = 0;
+			res.data = sub_double(db.data, da.data);
+			
+			return res.val;
+		}
+		
+		db.data.parts.sign = 0;
+		res.data = sub_double(da.data, db.data);
+		
+		return res.val;
+	}
+	
+	res.data = add_double(da.data, db.data);
+	return res.val;
 }
 
 long double __addtf3(long double a, long double b)
 {
-	float128 ta, tb;
-	ta.ld = a;
-	tb.ld = b;
-	if (ta.parts.sign != tb.parts.sign) {
-		if (ta.parts.sign) {
-			ta.parts.sign = 0;
-			return subFloat128(tb, ta).ld;
-		};
-		tb.parts.sign = 0;
-		return subFloat128(ta, tb).ld;
-	}
-	return addFloat128(ta, tb).ld;
+	long_double_t ta;
+	long_double_t tb;
+	long_double_t res;
+	
+	ta.val = a;
+	tb.val = b;
+	
+	if (ta.data.parts.sign != tb.data.parts.sign) {
+		if (ta.data.parts.sign) {
+			ta.data.parts.sign = 0;
+			res.data = sub_long_double(tb.data, ta.data);
+			
+			return res.val;
+		}
+		
+		tb.data.parts.sign = 0;
+		res.data = sub_long_double(ta.data, tb.data);
+		
+		return res.val;
+	}
+	
+	res.data = add_long_double(ta.data, tb.data);
+	return res.val;
 }
 
 float __subsf3(float a, float b)
 {
-	float32 fa, fb;
-	fa.f = a;
-	fb.f = b;
-	if (fa.parts.sign != fb.parts.sign) {
-		fb.parts.sign = !fb.parts.sign;
-		return addFloat32(fa, fb).f;
-	}
-	return subFloat32(fa, fb).f;
+	float_t fa;
+	float_t fb;
+	float_t res;
+	
+	fa.val = a;
+	fb.val = b;
+	
+	if (fa.data.parts.sign != fb.data.parts.sign) {
+		fb.data.parts.sign = !fb.data.parts.sign;
+		res.data = add_float(fa.data, fb.data);
+		
+		return res.val;
+	}
+	
+	res.data = sub_float(fa.data, fb.data);
+	return res.val;
 }
 
 double __subdf3(double a, double b)
 {
-	float64 da, db;
-	da.d = a;
-	db.d = b;
-	if (da.parts.sign != db.parts.sign) {
-		db.parts.sign = !db.parts.sign;
-		return addFloat64(da, db).d;
-	}
-	return subFloat64(da, db).d;
+	double_t da;
+	double_t db;
+	double_t res;
+	
+	da.val = a;
+	db.val = b;
+	
+	if (da.data.parts.sign != db.data.parts.sign) {
+		db.data.parts.sign = !db.data.parts.sign;
+		res.data = add_double(da.data, db.data);
+		
+		return res.val;
+	}
+	
+	res.data = sub_double(da.data, db.data);
+	return res.val;
 }
 
 long double __subtf3(long double a, long double b)
 {
-	float128 ta, tb;
-	ta.ld = a;
-	tb.ld = b;
-	if (ta.parts.sign != tb.parts.sign) {
-		tb.parts.sign = !tb.parts.sign;
-		return addFloat128(ta, tb).ld;
-	}
-	return subFloat128(ta, tb).ld;
-}
-
-float __mulsf3(float a, float b) 
-{
-	float32 fa, fb;
-	fa.f = a;
-	fb.f = b;
-	return 	mulFloat32(fa, fb).f;
-}
-
-double __muldf3(double a, double b) 
-{
-	float64 da, db;
-	da.d = a;
-	db.d = b;
-	return 	mulFloat64(da, db).d;
+	long_double_t ta;
+	long_double_t tb;
+	long_double_t res;
+	
+	ta.val = a;
+	tb.val = b;
+	
+	if (ta.data.parts.sign != tb.data.parts.sign) {
+		tb.data.parts.sign = !tb.data.parts.sign;
+		res.data = add_long_double(ta.data, tb.data);
+		
+		return res.val;
+	}
+	
+	res.data = sub_long_double(ta.data, tb.data);
+	return res.val;
+}
+
+float __mulsf3(float a, float b)
+{
+	float_t fa;
+	float_t fb;
+	float_t res;
+	
+	fa.val = a;
+	fb.val = b;
+	
+	res.data = mul_float(fa.data, fb.data);
+	return res.val;
+}
+
+double __muldf3(double a, double b)
+{
+	double_t da;
+	double_t db;
+	double_t res;
+	
+	da.val = a;
+	db.val = b;
+	
+	res.data = mul_double(da.data, db.data);
+	return res.val;
 }
 
 long double __multf3(long double a, long double b)
 {
-	float128 ta, tb;
-	ta.ld = a;
-	tb.ld = b;
-	return 	mulFloat128(ta, tb).ld;
-}
-
-float __divsf3(float a, float b) 
-{
-	float32 fa, fb;
-	fa.f = a;
-	fb.f = b;
-	return 	divFloat32(fa, fb).f;
-}
-
-double __divdf3(double a, double b) 
-{
-	float64 da, db;
-	da.d = a;
-	db.d = b;
-	return 	divFloat64(da, db).d;
+	long_double_t ta;
+	long_double_t tb;
+	long_double_t res;
+	
+	ta.val = a;
+	tb.val = b;
+	
+	res.data = mul_long_double(ta.data, tb.data);
+	return res.val;
+}
+
+float __divsf3(float a, float b)
+{
+	float_t fa;
+	float_t fb;
+	float_t res;
+	
+	fa.val = a;
+	fb.val = b;
+	
+	res.data = div_float(fa.data, fb.data);
+	return res.val;
+}
+
+double __divdf3(double a, double b)
+{
+	double_t da;
+	double_t db;
+	double_t res;
+	
+	da.val = a;
+	db.val = b;
+	
+	res.data = div_double(da.data, db.data);
+	return res.val;
 }
 
 long double __divtf3(long double a, long double b)
 {
-	float128 ta, tb;
-	ta.ld = a;
-	tb.ld = b;
-	return 	divFloat128(ta, tb).ld;
+	long_double_t ta;
+	long_double_t tb;
+	long_double_t res;
+	
+	ta.val = a;
+	tb.val = b;
+	
+	res.data = div_long_double(ta.data, tb.data);
+	return res.val;
 }
 
 float __negsf2(float a)
 {
-	float32 fa;
-	fa.f = a;
-	fa.parts.sign = !fa.parts.sign;
-	return fa.f;
+	float_t fa;
+	
+	fa.val = a;
+	fa.data.parts.sign = !fa.data.parts.sign;
+	
+	return fa.val;
 }
 
 double __negdf2(double a)
 {
-	float64 da;
-	da.d = a;
-	da.parts.sign = !da.parts.sign;
-	return da.d;
+	double_t da;
+	
+	da.val = a;
+	da.data.parts.sign = !da.data.parts.sign;
+	
+	return da.val;
 }
 
 long double __negtf2(long double a)
 {
-	float128 ta;
-	ta.ld = a;
-	ta.parts.sign = !ta.parts.sign;
-	return ta.ld;
+	long_double_t ta;
+	
+	ta.val = a;
+	ta.data.parts.sign = !ta.data.parts.sign;
+	
+	return ta.val;
 }
 
 /* Conversion functions */
 
-double __extendsfdf2(float a) 
-{
-	float32 fa;
-	fa.f = a;
-	return convertFloat32ToFloat64(fa).d;
+double __extendsfdf2(float a)
+{
+	float_t fa;
+	double_t res;
+	
+	fa.val = a;
+	res.data = float_to_double(fa.data);
+	
+	return res.val;
 }
 
 long double __extendsftf2(float a)
 {
-	float32 fa;
-	fa.f = a;
-	return convertFloat32ToFloat128(fa).ld;
+	float_t fa;
+	long_double_t res;
+	
+	fa.val = a;
+	res.data = float_to_long_double(fa.data);
+	
+	return res.val;
 }
 
 long double __extenddftf2(double a)
 {
-	float64 da;
-	da.d = a;
-	return convertFloat64ToFloat128(da).ld;
-}
-
-float __truncdfsf2(double a) 
-{
-	float64 da;
-	da.d = a;
-	return convertFloat64ToFloat32(da).f;
+	double_t da;
+	long_double_t res;
+	
+	da.val = a;
+	res.data = double_to_long_double(da.data);
+	
+	return res.val;
+}
+
+float __truncdfsf2(double a)
+{
+	double_t da;
+	float_t res;
+	
+	da.val = a;
+	res.data = double_to_float(da.data);
+	
+	return res.val;
 }
 
 float __trunctfsf2(long double a)
 {
-	float128 ta;
-	ta.ld = a;
-	return convertFloat128ToFloat32(ta).f;
+	long_double_t ta;
+	float_t res;
+	
+	ta.val = a;
+	res.data = long_double_to_float(ta.data);
+	
+	return res.val;
 }
 
 double __trunctfdf2(long double a)
 {
-	float128 ta;
-	ta.ld = a;
-	return convertFloat128ToFloat64(ta).d;
+	long_double_t ta;
+	double_t res;
+	
+	ta.val = a;
+	res.data = long_double_to_double(ta.data);
+	
+	return res.val;
 }
 
 int __fixsfsi(float a)
 {
-	float32 fa;
-	fa.f = a;
-	
-	return float32_to_int(fa);
+	float_t fa;
+	
+	fa.val = a;
+	return float_to_int(fa.data);
 }
 
 int __fixdfsi(double a)
 {
-	float64 da;
-	da.d = a;
-	
-	return float64_to_int(da);
+	double_t da;
+	
+	da.val = a;
+	return double_to_int(da.data);
 }
 
 int __fixtfsi(long double a)
 {
-	float128 ta;
-	ta.ld = a;
-
-	return float128_to_int(ta);
+	long_double_t ta;
+	
+	ta.val = a;
+	return long_double_to_int(ta.data);
 }
  
 long __fixsfdi(float a)
 {
-	float32 fa;
-	fa.f = a;
-	
-	return float32_to_long(fa);
+	float_t fa;
+	
+	fa.val = a;
+	return float_to_long(fa.data);
 }
 
 long __fixdfdi(double a)
 {
-	float64 da;
-	da.d = a;
-	
-	return float64_to_long(da);
+	double_t da;
+	
+	da.val = a;
+	return double_to_long(da.data);
 }
 
 long __fixtfdi(long double a)
 {
-	float128 ta;
-	ta.ld = a;
-
-	return float128_to_long(ta);
+	long_double_t ta;
+	
+	ta.val = a;
+	return long_double_to_long(ta.data);
 }
  
 long long __fixsfti(float a)
 {
-	float32 fa;
-	fa.f = a;
-	
-	return float32_to_longlong(fa);
+	float_t fa;
+	
+	fa.val = a;
+	return float_to_llong(fa.data);
 }
 
 long long __fixdfti(double a)
 {
-	float64 da;
-	da.d = a;
-	
-	return float64_to_longlong(da);
+	double_t da;
+	
+	da.val = a;
+	return double_to_llong(da.data);
 }
 
 long long __fixtfti(long double a)
 {
-	float128 ta;
-	ta.ld = a;
-
-	return float128_to_longlong(ta);
+	long_double_t ta;
+	
+	ta.val = a;
+	return long_double_to_llong(ta.data);
 }
 
 unsigned int __fixunssfsi(float a)
 {
-	float32 fa;
-	fa.f = a;
-	
-	return float32_to_uint(fa);
+	float_t fa;
+	
+	fa.val = a;
+	return float_to_uint(fa.data);
 }
 
 unsigned int __fixunsdfsi(double a)
 {
-	float64 da;
-	da.d = a;
-	
-	return float64_to_uint(da);
+	double_t da;
+	
+	da.val = a;
+	return double_to_uint(da.data);
 }
 
 unsigned int __fixunstfsi(long double a)
 {
-	float128 ta;
-	ta.ld = a;
-
-	return float128_to_uint(ta);
+	long_double_t ta;
+	
+	ta.val = a;
+	return long_double_to_uint(ta.data);
 }
  
 unsigned long __fixunssfdi(float a)
 {
-	float32 fa;
-	fa.f = a;
-	
-	return float32_to_ulong(fa);
+	float_t fa;
+	
+	fa.val = a;
+	return float_to_ulong(fa.data);
 }
 
 unsigned long __fixunsdfdi(double a)
 {
-	float64 da;
-	da.d = a;
-	
-	return float64_to_ulong(da);
+	double_t da;
+	
+	da.val = a;
+	return double_to_ulong(da.data);
 }
 
 unsigned long __fixunstfdi(long double a)
 {
-	float128 ta;
-	ta.ld = a;
-
-	return float128_to_ulong(ta);
+	long_double_t ta;
+	
+	ta.val = a;
+	return long_double_to_ulong(ta.data);
 }
  
 unsigned long long __fixunssfti(float a)
 {
-	float32 fa;
-	fa.f = a;
-	
-	return float32_to_ulonglong(fa);
+	float_t fa;
+	
+	fa.val = a;
+	return float_to_ullong(fa.data);
 }
 
 unsigned long long __fixunsdfti(double a)
 {
-	float64 da;
-	da.d = a;
-	
-	return float64_to_ulonglong(da);
+	double_t da;
+	
+	da.val = a;
+	return double_to_ullong(da.data);
 }
 
 unsigned long long __fixunstfti(long double a)
 {
-	float128 ta;
-	ta.ld = a;
-
-	return float128_to_ulonglong(ta);
+	long_double_t ta;
+	
+	ta.val = a;
+	return long_double_to_ullong(ta.data);
 }
  
 float __floatsisf(int i)
 {
-	float32 fa;
-	
-	fa = int_to_float32(i);
-	return fa.f;
+	float_t res;
+	
+	res.data = int_to_float(i);
+	return res.val;
 }
 
 double __floatsidf(int i)
 {
-	float64 da;
-	
-	da = int_to_float64(i);
-	return da.d;
+	double_t res;
+	
+	res.data = int_to_double(i);
+	return res.val;
 }
 
 long double __floatsitf(int i)
 {
-	float128 ta;
-
-	ta = int_to_float128(i);
-	return ta.ld;
+	long_double_t res;
+	
+	res.data = int_to_long_double(i);
+	return res.val;
 }
  
 float __floatdisf(long i)
 {
-	float32 fa;
-	
-	fa = long_to_float32(i);
-	return fa.f;
+	float_t res;
+	
+	res.data = long_to_float(i);
+	return res.val;
 }
 
 double __floatdidf(long i)
 {
-	float64 da;
-	
-	da = long_to_float64(i);
-	return da.d;
+	double_t res;
+	
+	res.data = long_to_double(i);
+	return res.val;
 }
 
 long double __floatditf(long i)
 {
-	float128 ta;
-
-	ta = long_to_float128(i);
-	return ta.ld;
-}
- 
+	long_double_t res;
+	
+	res.data = long_to_long_double(i);
+	return res.val;
+}
+
 float __floattisf(long long i)
 {
-	float32 fa;
-	
-	fa = longlong_to_float32(i);
-	return fa.f;
+	float_t res;
+	
+	res.data = llong_to_float(i);
+	return res.val;
 }
 
 double __floattidf(long long i)
 {
-	float64 da;
-	
-	da = longlong_to_float64(i);
-	return da.d;
+	double_t res;
+	
+	res.data = llong_to_double(i);
+	return res.val;
 }
 
 long double __floattitf(long long i)
 {
-	float128 ta;
-
-	ta = longlong_to_float128(i);
-	return ta.ld;
+	long_double_t res;
+	
+	res.data = llong_to_long_double(i);
+	return res.val;
 }
 
 float __floatunsisf(unsigned int i)
 {
-	float32 fa;
-	
-	fa = uint_to_float32(i);
-	return fa.f;
+	float_t res;
+	
+	res.data = uint_to_float(i);
+	return res.val;
 }
 
 double __floatunsidf(unsigned int i)
 {
-	float64 da;
-	
-	da = uint_to_float64(i);
-	return da.d;
+	double_t res;
+	
+	res.data = uint_to_double(i);
+	return res.val;
 }
 
 long double __floatunsitf(unsigned int i)
 {
-	float128 ta;
-
-	ta = uint_to_float128(i);
-	return ta.ld;
+	long_double_t res;
+	
+	res.data = uint_to_long_double(i);
+	return res.val;
 }
  
 float __floatundisf(unsigned long i)
 {
-	float32 fa;
-	
-	fa = ulong_to_float32(i);
-	return fa.f;
+	float_t res;
+	
+	res.data = ulong_to_float(i);
+	return res.val;
 }
 
 double __floatundidf(unsigned long i)
 {
-	float64 da;
-	
-	da = ulong_to_float64(i);
-	return da.d;
+	double_t res;
+	
+	res.data = ulong_to_double(i);
+	return res.val;
 }
 
 long double __floatunditf(unsigned long i)
 {
-	float128 ta;
-
-	ta = ulong_to_float128(i);
-	return ta.ld;
+	long_double_t res;
+	
+	res.data = ulong_to_long_double(i);
+	return res.val;
 }
  
 float __floatuntisf(unsigned long long i)
 {
-	float32 fa;
-	
-	fa = ulonglong_to_float32(i);
-	return fa.f;
+	float_t res;
+	
+	res.data = ullong_to_float(i);
+	return res.val;
 }
 
 double __floatuntidf(unsigned long long i)
 {
-	float64 da;
-	
-	da = ulonglong_to_float64(i);
-	return da.d;
+	double_t res;
+	
+	res.data = ullong_to_double(i);
+	return res.val;
 }
 
 long double __floatuntitf(unsigned long long i)
 {
-	float128 ta;
-
-	ta = ulonglong_to_float128(i);
-	return ta.ld;
+	long_double_t res;
+	
+	res.data = ullong_to_long_double(i);
+	return res.val;
 }
 
@@ -544,20 +659,21 @@
 int __cmpsf2(float a, float b) 
 {
-	float32 fa, fb;
-	fa.f = a;
-	fb.f = b;
-
-	if ((isFloat32NaN(fa)) || (isFloat32NaN(fb))) {
-		return 1; /* no special constant for unordered - maybe signaled? */
-	}
-	
-	if (isFloat32eq(fa, fb)) {
-		return 0;
-	}
-	
-	if (isFloat32lt(fa, fb)) {
-		return -1;
-	}
-
+	float_t fa;
+	float_t fb;
+	
+	fa.val = a;
+	fb.val = b;
+	
+	if ((is_float_nan(fa.data)) || (is_float_nan(fb.data))) {
+		/* no special constant for unordered - maybe signaled? */
+		return 1;
+	}
+	
+	if (is_float_eq(fa.data, fb.data))
+		return 0;
+	
+	if (is_float_lt(fa.data, fb.data))
+		return -1;
+	
 	return 1;
 }
@@ -565,20 +681,21 @@
 int __cmpdf2(double a, double b)
 {
-	float64 da, db;
-	da.d = a;
-	db.d = b;
-
-	if ((isFloat64NaN(da)) || (isFloat64NaN(db))) {
-		return 1; /* no special constant for unordered - maybe signaled? */
-	}
-
-	if (isFloat64eq(da, db)) {
-		return 0;
-	}
-
-	if (isFloat64lt(da, db)) {
-		return -1;
-	}
-
+	double_t da;
+	double_t db;
+	
+	da.val = a;
+	db.val = b;
+	
+	if ((is_double_nan(da.data)) || (is_double_nan(db.data))) {
+		/* no special constant for unordered - maybe signaled? */
+		return 1;
+	}
+	
+	if (is_double_eq(da.data, db.data))
+		return 0;
+	
+	if (is_double_lt(da.data, db.data))
+		return -1;
+	
 	return 1;
 }
@@ -586,84 +703,106 @@
 int __cmptf2(long double a, long double b)
 {
-	float128 ta, tb;
-	ta.ld = a;
-	tb.ld = b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		return 1; /* no special constant for unordered - maybe signaled? */
-	}
-
-	if (isFloat128eq(ta, tb)) {
-		return 0;
-	}
-
-	if (isFloat128lt(ta, tb)) {
-		return -1;
-	}
-
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = a;
+	tb.val = b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data))) {
+		/* no special constant for unordered - maybe signaled? */
+		return 1;
+	}
+	
+	if (is_long_double_eq(ta.data, tb.data))
+		return 0;
+	
+	if (is_long_double_lt(ta.data, tb.data))
+		return -1;
+	
 	return 1;
 }
 
-int __unordsf2(float a, float b) 
-{
-	float32 fa, fb;
-	fa.f = a;
-	fb.f = b;
-	return ((isFloat32NaN(fa)) || (isFloat32NaN(fb)));
+int __unordsf2(float a, float b)
+{
+	float_t fa;
+	float_t fb;
+	
+	fa.val = a;
+	fb.val = b;
+	
+	return ((is_float_nan(fa.data)) || (is_float_nan(fb.data)));
 }
 
 int __unorddf2(double a, double b)
 {
-	float64 da, db;
-	da.d = a;
-	db.d = b;
-	return ((isFloat64NaN(da)) || (isFloat64NaN(db)));
+	double_t da;
+	double_t db;
+	
+	da.val = a;
+	db.val = b;
+	
+	return ((is_double_nan(da.data)) || (is_double_nan(db.data)));
 }
 
 int __unordtf2(long double a, long double b)
 {
-	float128 ta, tb;
-	ta.ld = a;
-	tb.ld = b;
-	return ((isFloat128NaN(ta)) || (isFloat128NaN(tb)));
-}
-
-int __eqsf2(float a, float b) 
-{
-	float32 fa, fb;
-	fa.f = a;
-	fb.f = b;
-	if ((isFloat32NaN(fa)) || (isFloat32NaN(fb))) {
-		/* TODO: sigNaNs */
-		return 1;
-	}
-	return isFloat32eq(fa, fb) - 1;
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = a;
+	tb.val = b;
+	
+	return ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data)));
+}
+
+int __eqsf2(float a, float b)
+{
+	float_t fa;
+	float_t fb;
+	
+	fa.val = a;
+	fb.val = b;
+	
+	if ((is_float_nan(fa.data)) || (is_float_nan(fb.data))) {
+		// TODO: sigNaNs
+		return 1;
+	}
+	
+	return is_float_eq(fa.data, fb.data) - 1;
 }
 
 int __eqdf2(double a, double b)
 {
-	float64 da, db;
-	da.d = a;
-	db.d = b;
-	if ((isFloat64NaN(da)) || (isFloat64NaN(db))) {
-		/* TODO: sigNaNs */
-		return 1;
-	}
-	return isFloat64eq(da, db) - 1;
+	double_t da;
+	double_t db;
+	
+	da.val = a;
+	db.val = b;
+	
+	if ((is_double_nan(da.data)) || (is_double_nan(db.data))) {
+		// TODO: sigNaNs
+		return 1;
+	}
+	
+	return is_double_eq(da.data, db.data) - 1;
 }
 
 int __eqtf2(long double a, long double b)
 {
-	float128 ta, tb;
-	ta.ld = a;
-	tb.ld = b;
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		/* TODO: sigNaNs */
-		return 1;
-	}
-	return isFloat128eq(ta, tb) - 1;
-}
-
-int __nesf2(float a, float b) 
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = a;
+	tb.val = b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data))) {
+		// TODO: sigNaNs
+		return 1;
+	}
+	
+	return is_long_double_eq(ta.data, tb.data) - 1;
+}
+
+int __nesf2(float a, float b)
 {
 	/* strange behavior, but it was in gcc documentation */
@@ -685,20 +824,20 @@
 int __gesf2(float a, float b)
 {
-	float32 fa, fb;
-	fa.f = a;
-	fb.f = b;
-
-	if ((isFloat32NaN(fa)) || (isFloat32NaN(fb))) {
-		/* TODO: sigNaNs */
-		return -1;
-	}
-	
-	if (isFloat32eq(fa, fb)) {
-		return 0;
-	}
-	
-	if (isFloat32gt(fa, fb)) {
-		return 1;
-	}
+	float_t fa;
+	float_t fb;
+	
+	fa.val = a;
+	fb.val = b;
+	
+	if ((is_float_nan(fa.data)) || (is_float_nan(fb.data))) {
+		// TODO: sigNaNs
+		return -1;
+	}
+	
+	if (is_float_eq(fa.data, fb.data))
+		return 0;
+	
+	if (is_float_gt(fa.data, fb.data))
+		return 1;
 	
 	return -1;
@@ -707,21 +846,21 @@
 int __gedf2(double a, double b)
 {
-	float64 da, db;
-	da.d = a;
-	db.d = b;
-
-	if ((isFloat64NaN(da)) || (isFloat64NaN(db))) {
-		/* TODO: sigNaNs */
-		return -1;
-	}
-
-	if (isFloat64eq(da, db)) {
-		return 0;
-	}
-
-	if (isFloat64gt(da, db)) {
-		return 1;
-	}
-
+	double_t da;
+	double_t db;
+	
+	da.val = a;
+	db.val = b;
+	
+	if ((is_double_nan(da.data)) || (is_double_nan(db.data))) {
+		// TODO: sigNaNs
+		return -1;
+	}
+	
+	if (is_double_eq(da.data, db.data))
+		return 0;
+	
+	if (is_double_gt(da.data, db.data))
+		return 1;
+	
 	return -1;
 }
@@ -729,21 +868,21 @@
 int __getf2(long double a, long double b)
 {
-	float128 ta, tb;
-	ta.ld = a;
-	tb.ld = b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		/* TODO: sigNaNs */
-		return -1;
-	}
-
-	if (isFloat128eq(ta, tb)) {
-		return 0;
-	}
-
-	if (isFloat128gt(ta, tb)) {
-		return 1;
-	}
-
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = a;
+	tb.val = b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data))) {
+		// TODO: sigNaNs
+		return -1;
+	}
+	
+	if (is_long_double_eq(ta.data, tb.data))
+		return 0;
+	
+	if (is_long_double_gt(ta.data, tb.data))
+		return 1;
+	
 	return -1;
 }
@@ -751,17 +890,18 @@
 int __ltsf2(float a, float b)
 {
-	float32 fa, fb;
-	fa.f = a;
-	fb.f = b;
-
-	if ((isFloat32NaN(fa)) || (isFloat32NaN(fb))) {
-		/* TODO: sigNaNs */
-		return 1;
-	}
-
-	if (isFloat32lt(fa, fb)) {
-		return -1;
-	}
-
+	float_t fa;
+	float_t fb;
+	
+	fa.val = a;
+	fb.val = b;
+	
+	if ((is_float_nan(fa.data)) || (is_float_nan(fb.data))) {
+		// TODO: sigNaNs
+		return 1;
+	}
+	
+	if (is_float_lt(fa.data, fb.data))
+		return -1;
+	
 	return 0;
 }
@@ -769,17 +909,18 @@
 int __ltdf2(double a, double b)
 {
-	float64 da, db;
-	da.d = a;
-	db.d = b;
-
-	if ((isFloat64NaN(da)) || (isFloat64NaN(db))) {
-		/* TODO: sigNaNs */
-		return 1;
-	}
-
-	if (isFloat64lt(da, db)) {
-		return -1;
-	}
-
+	double_t da;
+	double_t db;
+	
+	da.val = a;
+	db.val = b;
+	
+	if ((is_double_nan(da.data)) || (is_double_nan(db.data))) {
+		// TODO: sigNaNs
+		return 1;
+	}
+	
+	if (is_double_lt(da.data, db.data))
+		return -1;
+	
 	return 0;
 }
@@ -787,17 +928,18 @@
 int __lttf2(long double a, long double b)
 {
-	float128 ta, tb;
-	ta.ld = a;
-	tb.ld = b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		/* TODO: sigNaNs */
-		return 1;
-	}
-
-	if (isFloat128lt(ta, tb)) {
-		return -1;
-	}
-
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = a;
+	tb.val = b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data))) {
+		// TODO: sigNaNs
+		return 1;
+	}
+	
+	if (is_long_double_lt(ta.data, tb.data))
+		return -1;
+	
 	return 0;
 }
@@ -805,20 +947,20 @@
 int __lesf2(float a, float b)
 {
-	float32 fa, fb;
-	fa.f = a;
-	fb.f = b;
-
-	if ((isFloat32NaN(fa)) || (isFloat32NaN(fb))) {
-		/* TODO: sigNaNs */
-		return 1;
-	}
-	
-	if (isFloat32eq(fa, fb)) {
-		return 0;
-	}
-	
-	if (isFloat32lt(fa, fb)) {
-		return -1;
-	}
+	float_t fa;
+	float_t fb;
+	
+	fa.val = a;
+	fb.val = b;
+	
+	if ((is_float_nan(fa.data)) || (is_float_nan(fb.data))) {
+		// TODO: sigNaNs
+		return 1;
+	}
+	
+	if (is_float_eq(fa.data, fb.data))
+		return 0;
+	
+	if (is_float_lt(fa.data, fb.data))
+		return -1;
 	
 	return 1;
@@ -827,21 +969,21 @@
 int __ledf2(double a, double b)
 {
-	float64 da, db;
-	da.d = a;
-	db.d = b;
-
-	if ((isFloat64NaN(da)) || (isFloat64NaN(db))) {
-		/* TODO: sigNaNs */
-		return 1;
-	}
-
-	if (isFloat64eq(da, db)) {
-		return 0;
-	}
-
-	if (isFloat64lt(da, db)) {
-		return -1;
-	}
-
+	double_t da;
+	double_t db;
+	
+	da.val = a;
+	db.val = b;
+	
+	if ((is_double_nan(da.data)) || (is_double_nan(db.data))) {
+		// TODO: sigNaNs
+		return 1;
+	}
+	
+	if (is_double_eq(da.data, db.data))
+		return 0;
+	
+	if (is_double_lt(da.data, db.data))
+		return -1;
+	
 	return 1;
 }
@@ -849,21 +991,21 @@
 int __letf2(long double a, long double b)
 {
-	float128 ta, tb;
-	ta.ld = a;
-	tb.ld = b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		/* TODO: sigNaNs */
-		return 1;
-	}
-
-	if (isFloat128eq(ta, tb)) {
-		return 0;
-	}
-
-	if (isFloat128lt(ta, tb)) {
-		return -1;
-	}
-
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = a;
+	tb.val = b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data))) {
+		// TODO: sigNaNs
+		return 1;
+	}
+	
+	if (is_long_double_eq(ta.data, tb.data))
+		return 0;
+	
+	if (is_long_double_lt(ta.data, tb.data))
+		return -1;
+	
 	return 1;
 }
@@ -871,17 +1013,18 @@
 int __gtsf2(float a, float b)
 {
-	float32 fa, fb;
-	fa.f = a;
-	fb.f = b;
-
-	if ((isFloat32NaN(fa)) || (isFloat32NaN(fb))) {
-		/* TODO: sigNaNs */
-		return -1;
-	}
-
-	if (isFloat32gt(fa, fb)) {
-		return 1;
-	}
-
+	float_t fa;
+	float_t fb;
+	
+	fa.val = a;
+	fb.val = b;
+	
+	if ((is_float_nan(fa.data)) || (is_float_nan(fb.data))) {
+		// TODO: sigNaNs
+		return -1;
+	}
+	
+	if (is_float_gt(fa.data, fb.data))
+		return 1;
+	
 	return 0;
 }
@@ -889,17 +1032,18 @@
 int __gtdf2(double a, double b)
 {
-	float64 da, db;
-	da.d = a;
-	db.d = b;
-
-	if ((isFloat64NaN(da)) || (isFloat64NaN(db))) {
-		/* TODO: sigNaNs */
-		return -1;
-	}
-
-	if (isFloat64gt(da, db)) {
-		return 1;
-	}
-
+	double_t da;
+	double_t db;
+	
+	da.val = a;
+	db.val = b;
+	
+	if ((is_double_nan(da.data)) || (is_double_nan(db.data))) {
+		// TODO: sigNaNs
+		return -1;
+	}
+	
+	if (is_double_gt(da.data, db.data))
+		return 1;
+	
 	return 0;
 }
@@ -907,24 +1051,21 @@
 int __gttf2(long double a, long double b)
 {
-	float128 ta, tb;
-	ta.ld = a;
-	tb.ld = b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		/* TODO: sigNaNs */
-		return -1;
-	}
-
-	if (isFloat128gt(ta, tb)) {
-		return 1;
-	}
-
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = a;
+	tb.val = b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data))) {
+		// TODO: sigNaNs
+		return -1;
+	}
+	
+	if (is_long_double_gt(ta.data, tb.data))
+		return 1;
+	
 	return 0;
 }
 
-
-
-#ifdef SPARC_SOFTFLOAT
-
 /* SPARC quadruple-precision wrappers */
 
@@ -1016,20 +1157,19 @@
 int _Qp_cmp(long double *a, long double *b)
 {
-	float128 ta, tb;
-	ta.ld = *a;
-	tb.ld = *b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = *a;
+	tb.val = *b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data)))
 		return 3;
-	}
-
-	if (isFloat128eq(ta, tb)) {
-		return 0;
-	}
-
-	if (isFloat128lt(ta, tb)) {
-		return 1;
-	}
-
+	
+	if (is_long_double_eq(ta.data, tb.data))
+		return 0;
+	
+	if (is_long_double_lt(ta.data, tb.data))
+		return 1;
+	
 	return 2;
 }
@@ -1043,81 +1183,87 @@
 int _Qp_feq(long double *a, long double *b)
 {
-	float128 ta, tb;
-	ta.ld = *a;
-	tb.ld = *b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		return 0;
-	}
-
-	return isFloat128eq(ta, tb);
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = *a;
+	tb.val = *b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data)))
+		return 0;
+	
+	return is_long_double_eq(ta.data, tb.data);
 }
 
 int _Qp_fge(long double *a, long double *b)
 {
-	float128 ta, tb;
-	ta.ld = *a;
-	tb.ld = *b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		return 0;
-	}
-
-	return isFloat128eq(ta, tb) || isFloat128gt(ta, tb);
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = *a;
+	tb.val = *b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data)))
+		return 0;
+	
+	return is_long_double_eq(ta.data, tb.data) ||
+	    is_long_double_gt(ta.data, tb.data);
 }
 
 int _Qp_fgt(long double *a, long double *b)
 {
-	float128 ta, tb;
-	ta.ld = *a;
-	tb.ld = *b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		return 0;
-	}
-
-	return isFloat128gt(ta, tb);
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = *a;
+	tb.val = *b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data)))
+		return 0;
+	
+	return is_long_double_gt(ta.data, tb.data);
 }
 
 int _Qp_fle(long double*a, long double *b)
 {
-	float128 ta, tb;
-	ta.ld = *a;
-	tb.ld = *b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		return 0;
-	}
-
-	return isFloat128eq(ta, tb) || isFloat128lt(ta, tb);
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = *a;
+	tb.val = *b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data)))
+		return 0;
+	
+	return is_long_double_eq(ta.data, tb.data) ||
+	    is_long_double_lt(ta.data, tb.data);
 }
 
 int _Qp_flt(long double *a, long double *b)
 {
-	float128 ta, tb;
-	ta.ld = *a;
-	tb.ld = *b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		return 0;
-	}
-
-	return isFloat128lt(ta, tb);
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = *a;
+	tb.val = *b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data)))
+		return 0;
+	
+	return is_long_double_lt(ta.data, tb.data);
 }
 
 int _Qp_fne(long double *a, long double *b)
 {
-	float128 ta, tb;
-	ta.ld = *a;
-	tb.ld = *b;
-
-	if ((isFloat128NaN(ta)) || (isFloat128NaN(tb))) {
-		return 1;
-	}
-
-	return !isFloat128eq(ta, tb);
-}
-
-#endif
+	long_double_t ta;
+	long_double_t tb;
+	
+	ta.val = *a;
+	tb.val = *b;
+	
+	if ((is_long_double_nan(ta.data)) || (is_long_double_nan(tb.data)))
+		return 0;
+	
+	return !is_long_double_eq(ta.data, tb.data);
+}
 
 /** @}
Index: uspace/lib/softfloat/generic/sub.c
===================================================================
--- uspace/lib/softfloat/generic/sub.c	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/generic/sub.c	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -39,34 +39,38 @@
 #include <common.h>
 
-/**
- * Subtract two single-precision floats with the same signs.
+/** Subtract two single-precision floats with the same sign.
  *
  * @param a First input operand.
  * @param b Second input operand.
+ *
  * @return Result of substraction.
- */
-float32 subFloat32(float32 a, float32 b)
+ *
+ */
+float32 sub_float32(float32 a, float32 b)
 {
 	int expdiff;
 	uint32_t exp1, exp2, frac1, frac2;
 	float32 result;
-
-	result.f = 0;
+	
+	result.bin = 0;
 	
 	expdiff = a.parts.exp - b.parts.exp;
-	if ((expdiff < 0 ) || ((expdiff == 0) && (a.parts.fraction < b.parts.fraction))) {
-		if (isFloat32NaN(b)) {
-			/* TODO: fix SigNaN */
-			if (isFloat32SigNaN(b)) {
-			}
-			return b;
-		}
-		
-		if (b.parts.exp == FLOAT32_MAX_EXPONENT) { 
-			b.parts.sign = !b.parts.sign; /* num -(+-inf) = -+inf */
-			return b;
-		}
-		
-		result.parts.sign = !a.parts.sign; 
+	if ((expdiff < 0 ) || ((expdiff == 0) &&
+	    (a.parts.fraction < b.parts.fraction))) {
+		if (is_float32_nan(b)) {
+			if (is_float32_signan(b)) {
+				// TODO: fix SigNaN
+			}
+			
+			return b;
+		}
+		
+		if (b.parts.exp == FLOAT32_MAX_EXPONENT) {
+			/* num -(+-inf) = -+inf */
+			b.parts.sign = !b.parts.sign;
+			return b;
+		}
+		
+		result.parts.sign = !a.parts.sign;
 		
 		frac1 = b.parts.fraction;
@@ -76,18 +80,20 @@
 		expdiff *= -1;
 	} else {
-		if (isFloat32NaN(a)) {
-			/* TODO: fix SigNaN */
-			if (isFloat32SigNaN(a) || isFloat32SigNaN(b)) {
-			}
-			return a;
-		}
-		
-		if (a.parts.exp == FLOAT32_MAX_EXPONENT) { 
+		if (is_float32_nan(a)) {
+			if ((is_float32_signan(a)) || (is_float32_signan(b))) {
+				// TODO: fix SigNaN
+			}
+			
+			return a;
+		}
+		
+		if (a.parts.exp == FLOAT32_MAX_EXPONENT) {
 			if (b.parts.exp == FLOAT32_MAX_EXPONENT) {
 				/* inf - inf => nan */
-				/* TODO: fix exception */
-				result.binary = FLOAT32_NAN;
+				// TODO: fix exception
+				result.bin = FLOAT32_NAN;
 				return result;
 			}
+			
 			return a;
 		}
@@ -98,5 +104,5 @@
 		exp1 = a.parts.exp;
 		frac2 = b.parts.fraction;
-		exp2 = b.parts.exp;	
+		exp2 = b.parts.exp;
 	}
 	
@@ -105,17 +111,18 @@
 		result.parts.fraction = frac1 - frac2;
 		if (result.parts.fraction > frac1) {
-			/* TODO: underflow exception */
+			// TODO: underflow exception
 			return result;
 		}
+		
 		result.parts.exp = 0;
 		return result;
 	}
-
+	
 	/* add hidden bit */
-	frac1 |= FLOAT32_HIDDEN_BIT_MASK; 
+	frac1 |= FLOAT32_HIDDEN_BIT_MASK;
 	
 	if (exp2 == 0) {
 		/* denormalized */
-		--expdiff;	
+		--expdiff;
 	} else {
 		/* normalized */
@@ -127,10 +134,9 @@
 	frac2 <<= 6;
 	
-	if (expdiff > FLOAT32_FRACTION_SIZE + 1) {
+	if (expdiff > FLOAT32_FRACTION_SIZE + 1)
 		goto done;
-	}
 	
 	frac1 = frac1 - (frac2 >> expdiff);
-
+	
 done:
 	/* TODO: find first nonzero digit and shift result and detect possibly underflow */
@@ -143,5 +149,5 @@
 	/* rounding - if first bit after fraction is set then round up */
 	frac1 += 0x20;
-
+	
 	if (frac1 & (FLOAT32_HIDDEN_BIT_MASK << 7)) {
 		++exp1;
@@ -150,5 +156,5 @@
 	
 	/* Clear hidden bit and shift */
-	result.parts.fraction = ((frac1 >> 6) & (~FLOAT32_HIDDEN_BIT_MASK)); 
+	result.parts.fraction = ((frac1 >> 6) & (~FLOAT32_HIDDEN_BIT_MASK));
 	result.parts.exp = exp1;
 	
@@ -156,12 +162,13 @@
 }
 
-/**
- * Subtract two double-precision floats with the same signs.
+/** Subtract two double-precision floats with the same sign.
  *
  * @param a First input operand.
  * @param b Second input operand.
+ *
  * @return Result of substraction.
- */
-float64 subFloat64(float64 a, float64 b)
+ *
+ */
+float64 sub_float64(float64 a, float64 b)
 {
 	int expdiff;
@@ -169,22 +176,25 @@
 	uint64_t frac1, frac2;
 	float64 result;
-
-	result.d = 0;
+	
+	result.bin = 0;
 	
 	expdiff = a.parts.exp - b.parts.exp;
-	if ((expdiff < 0 ) || ((expdiff == 0) && (a.parts.fraction < b.parts.fraction))) {
-		if (isFloat64NaN(b)) {
-			/* TODO: fix SigNaN */
-			if (isFloat64SigNaN(b)) {
-			}
-			return b;
-		}
-		
-		if (b.parts.exp == FLOAT64_MAX_EXPONENT) { 
-			b.parts.sign = !b.parts.sign; /* num -(+-inf) = -+inf */
-			return b;
-		}
-		
-		result.parts.sign = !a.parts.sign; 
+	if ((expdiff < 0 ) ||
+	    ((expdiff == 0) && (a.parts.fraction < b.parts.fraction))) {
+		if (is_float64_nan(b)) {
+			if (is_float64_signan(b)) {
+				// TODO: fix SigNaN
+			}
+			
+			return b;
+		}
+		
+		if (b.parts.exp == FLOAT64_MAX_EXPONENT) {
+			/* num -(+-inf) = -+inf */
+			b.parts.sign = !b.parts.sign;
+			return b;
+		}
+		
+		result.parts.sign = !a.parts.sign;
 		
 		frac1 = b.parts.fraction;
@@ -194,18 +204,20 @@
 		expdiff *= -1;
 	} else {
-		if (isFloat64NaN(a)) {
-			/* TODO: fix SigNaN */
-			if (isFloat64SigNaN(a) || isFloat64SigNaN(b)) {
-			}
-			return a;
-		}
-		
-		if (a.parts.exp == FLOAT64_MAX_EXPONENT) { 
+		if (is_float64_nan(a)) {
+			if (is_float64_signan(a) || is_float64_signan(b)) {
+				// TODO: fix SigNaN
+			}
+			
+			return a;
+		}
+		
+		if (a.parts.exp == FLOAT64_MAX_EXPONENT) {
 			if (b.parts.exp == FLOAT64_MAX_EXPONENT) {
 				/* inf - inf => nan */
-				/* TODO: fix exception */
-				result.binary = FLOAT64_NAN;
+				// TODO: fix exception
+				result.bin = FLOAT64_NAN;
 				return result;
 			}
+			
 			return a;
 		}
@@ -216,5 +228,5 @@
 		exp1 = a.parts.exp;
 		frac2 = b.parts.fraction;
-		exp2 = b.parts.exp;	
+		exp2 = b.parts.exp;
 	}
 	
@@ -223,17 +235,18 @@
 		result.parts.fraction = frac1 - frac2;
 		if (result.parts.fraction > frac1) {
-			/* TODO: underflow exception */
+			// TODO: underflow exception
 			return result;
 		}
+		
 		result.parts.exp = 0;
 		return result;
 	}
-
+	
 	/* add hidden bit */
-	frac1 |= FLOAT64_HIDDEN_BIT_MASK; 
+	frac1 |= FLOAT64_HIDDEN_BIT_MASK;
 	
 	if (exp2 == 0) {
 		/* denormalized */
-		--expdiff;	
+		--expdiff;
 	} else {
 		/* normalized */
@@ -245,10 +258,9 @@
 	frac2 <<= 6;
 	
-	if (expdiff > FLOAT64_FRACTION_SIZE + 1) {
+	if (expdiff > FLOAT64_FRACTION_SIZE + 1)
 		goto done;
-	}
 	
 	frac1 = frac1 - (frac2 >> expdiff);
-
+	
 done:
 	/* TODO: find first nonzero digit and shift result and detect possibly underflow */
@@ -261,5 +273,5 @@
 	/* rounding - if first bit after fraction is set then round up */
 	frac1 += 0x20;
-
+	
 	if (frac1 & (FLOAT64_HIDDEN_BIT_MASK << 7)) {
 		++exp1;
@@ -268,5 +280,5 @@
 	
 	/* Clear hidden bit and shift */
-	result.parts.fraction = ((frac1 >> 6) & (~FLOAT64_HIDDEN_BIT_MASK)); 
+	result.parts.fraction = ((frac1 >> 6) & (~FLOAT64_HIDDEN_BIT_MASK));
 	result.parts.exp = exp1;
 	
@@ -274,12 +286,13 @@
 }
 
-/**
- * Subtract two quadruple-precision floats with the same signs.
+/** Subtract two quadruple-precision floats with the same sign.
  *
  * @param a First input operand.
  * @param b Second input operand.
+ *
  * @return Result of substraction.
- */
-float128 subFloat128(float128 a, float128 b)
+ *
+ */
+float128 sub_float128(float128 a, float128 b)
 {
 	int expdiff;
@@ -287,25 +300,27 @@
 	uint64_t frac1_hi, frac1_lo, frac2_hi, frac2_lo, tmp_hi, tmp_lo;
 	float128 result;
-
-	result.binary.hi = 0;
-	result.binary.lo = 0;
-
+	
+	result.bin.hi = 0;
+	result.bin.lo = 0;
+	
 	expdiff = a.parts.exp - b.parts.exp;
 	if ((expdiff < 0 ) || ((expdiff == 0) &&
 	    lt128(a.parts.frac_hi, a.parts.frac_lo, b.parts.frac_hi, b.parts.frac_lo))) {
-		if (isFloat128NaN(b)) {
-			/* TODO: fix SigNaN */
-			if (isFloat128SigNaN(b)) {
-			}
-			return b;
-		}
-
+		if (is_float128_nan(b)) {
+			if (is_float128_signan(b)) {
+				// TODO: fix SigNaN
+			}
+			
+			return b;
+		}
+		
 		if (b.parts.exp == FLOAT128_MAX_EXPONENT) {
-			b.parts.sign = !b.parts.sign; /* num -(+-inf) = -+inf */
-			return b;
-		}
-
+			/* num -(+-inf) = -+inf */
+			b.parts.sign = !b.parts.sign;
+			return b;
+		}
+		
 		result.parts.sign = !a.parts.sign;
-
+		
 		frac1_hi = b.parts.frac_hi;
 		frac1_lo = b.parts.frac_lo;
@@ -316,24 +331,25 @@
 		expdiff *= -1;
 	} else {
-		if (isFloat128NaN(a)) {
-			/* TODO: fix SigNaN */
-			if (isFloat128SigNaN(a) || isFloat128SigNaN(b)) {
-			}
-			return a;
-		}
-
+		if (is_float128_nan(a)) {
+			if (is_float128_signan(a) || is_float128_signan(b)) {
+				// TODO: fix SigNaN
+			}
+			
+			return a;
+		}
+		
 		if (a.parts.exp == FLOAT128_MAX_EXPONENT) {
 			if (b.parts.exp == FLOAT128_MAX_EXPONENT) {
 				/* inf - inf => nan */
-				/* TODO: fix exception */
-				result.binary.hi = FLOAT128_NAN_HI;
-				result.binary.lo = FLOAT128_NAN_LO;
+				// TODO: fix exception
+				result.bin.hi = FLOAT128_NAN_HI;
+				result.bin.lo = FLOAT128_NAN_LO;
 				return result;
 			}
 			return a;
 		}
-
+		
 		result.parts.sign = a.parts.sign;
-
+		
 		frac1_hi = a.parts.frac_hi;
 		frac1_lo = a.parts.frac_lo;
@@ -343,5 +359,5 @@
 		exp2 = b.parts.exp;
 	}
-
+	
 	if (exp1 == 0) {
 		/* both are denormalized */
@@ -350,16 +366,17 @@
 		result.parts.frac_lo = tmp_lo;
 		if (lt128(frac1_hi, frac1_lo, result.parts.frac_hi, result.parts.frac_lo)) {
-			/* TODO: underflow exception */
+			// TODO: underflow exception
 			return result;
 		}
+		
 		result.parts.exp = 0;
 		return result;
 	}
-
+	
 	/* add hidden bit */
 	or128(frac1_hi, frac1_lo,
 	    FLOAT128_HIDDEN_BIT_MASK_HI, FLOAT128_HIDDEN_BIT_MASK_LO,
 	    &frac1_hi, &frac1_lo);
-
+	
 	if (exp2 == 0) {
 		/* denormalized */
@@ -371,16 +388,15 @@
 		    &frac2_hi, &frac2_lo);
 	}
-
+	
 	/* create some space for rounding */
 	lshift128(frac1_hi, frac1_lo, 6, &frac1_hi, &frac1_lo);
 	lshift128(frac2_hi, frac2_lo, 6, &frac2_hi, &frac2_lo);
-
-	if (expdiff > FLOAT128_FRACTION_SIZE + 1) {
+	
+	if (expdiff > FLOAT128_FRACTION_SIZE + 1)
 		goto done;
-	}
-
+	
 	rshift128(frac2_hi, frac2_lo, expdiff, &tmp_hi, &tmp_lo);
 	sub128(frac1_hi, frac1_lo, tmp_hi, tmp_lo, &frac1_hi, &frac1_lo);
-
+	
 done:
 	/* TODO: find first nonzero digit and shift result and detect possibly underflow */
@@ -392,13 +408,13 @@
 		lshift128(frac1_hi, frac1_lo, 1, &frac1_hi, &frac1_lo);
 		/* TODO: fix underflow - frac1 == 0 does not necessary means underflow... */
-
+		
 		lshift128(FLOAT128_HIDDEN_BIT_MASK_HI, FLOAT128_HIDDEN_BIT_MASK_LO, 6,
 		    &tmp_hi, &tmp_lo);
 		and128(frac1_hi, frac1_lo, tmp_hi, tmp_lo, &tmp_hi, &tmp_lo);
 	}
-
+	
 	/* rounding - if first bit after fraction is set then round up */
 	add128(frac1_hi, frac1_lo, 0x0ll, 0x20ll, &frac1_hi, &frac1_lo);
-
+	
 	lshift128(FLOAT128_HIDDEN_BIT_MASK_HI, FLOAT128_HIDDEN_BIT_MASK_LO, 7,
 	   &tmp_hi, &tmp_lo);
@@ -408,5 +424,5 @@
 		rshift128(frac1_hi, frac1_lo, 1, &frac1_hi, &frac1_lo);
 	}
-
+	
 	/* Clear hidden bit and shift */
 	rshift128(frac1_hi, frac1_lo, 6, &frac1_hi, &frac1_lo);
@@ -416,7 +432,7 @@
 	result.parts.frac_hi = tmp_hi;
 	result.parts.frac_lo = tmp_lo;
-
+	
 	result.parts.exp = exp1;
-
+	
 	return result;
 }
Index: uspace/lib/softfloat/include/add.h
===================================================================
--- uspace/lib/softfloat/include/add.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/include/add.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -37,7 +37,8 @@
 #define __ADD_H__
 
-extern float32 addFloat32(float32, float32);
-extern float64 addFloat64(float64, float64);
-extern float128 addFloat128(float128, float128);
+extern float32 add_float32(float32, float32);
+extern float64 add_float64(float64, float64);
+extern float96 add_float96(float96, float96);
+extern float128 add_float128(float128, float128);
 
 #endif
Index: uspace/lib/softfloat/include/common.h
===================================================================
--- uspace/lib/softfloat/include/common.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/include/common.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -39,14 +39,14 @@
 #include <sftypes.h>
 
-extern float64 finishFloat64(int32_t, uint64_t, char);
-extern float128 finishFloat128(int32_t, uint64_t, uint64_t, char, uint64_t);
+extern float64 finish_float64(int32_t, uint64_t, char);
+extern float128 finish_float128(int32_t, uint64_t, uint64_t, char, uint64_t);
 
-extern int countZeroes8(uint8_t);
-extern int countZeroes32(uint32_t);
-extern int countZeroes64(uint64_t);
+extern int count_zeroes8(uint8_t);
+extern int count_zeroes32(uint32_t);
+extern int count_zeroes64(uint64_t);
 
-extern void roundFloat32(int32_t *, uint32_t *);
-extern void roundFloat64(int32_t *, uint64_t *);
-extern void roundFloat128(int32_t *, uint64_t *, uint64_t *);
+extern void round_float32(int32_t *, uint32_t *);
+extern void round_float64(int32_t *, uint64_t *);
+extern void round_float128(int32_t *, uint64_t *, uint64_t *);
 
 extern void lshift128(uint64_t, uint64_t, int, uint64_t *, uint64_t *);
Index: uspace/lib/softfloat/include/comparison.h
===================================================================
--- uspace/lib/softfloat/include/comparison.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/include/comparison.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -37,33 +37,43 @@
 #define __COMPARISON_H__
 
-extern int isFloat32NaN(float32);
-extern int isFloat32SigNaN(float32);
+extern int is_float32_nan(float32);
+extern int is_float32_signan(float32);
 
-extern int isFloat32Infinity(float32);
-extern int isFloat32Zero(float32);
+extern int is_float32_infinity(float32);
+extern int is_float32_zero(float32);
 
-extern int isFloat32eq(float32, float32);
-extern int isFloat32lt(float32, float32);
-extern int isFloat32gt(float32, float32);
+extern int is_float32_eq(float32, float32);
+extern int is_float32_lt(float32, float32);
+extern int is_float32_gt(float32, float32);
 
-extern int isFloat64NaN(float64);
-extern int isFloat64SigNaN(float64);
+extern int is_float64_nan(float64);
+extern int is_float64_signan(float64);
 
-extern int isFloat64Infinity(float64);
-extern int isFloat64Zero(float64);
+extern int is_float64_infinity(float64);
+extern int is_float64_zero(float64);
 
-extern int isFloat64eq(float64, float64);
-extern int isFloat64lt(float64, float64);
-extern int isFloat64gt(float64, float64);
+extern int is_float64_eq(float64, float64);
+extern int is_float64_lt(float64, float64);
+extern int is_float64_gt(float64, float64);
 
-extern int isFloat128NaN(float128);
-extern int isFloat128SigNaN(float128);
+extern int is_float96_nan(float96);
+extern int is_float96_signan(float96);
 
-extern int isFloat128Infinity(float128);
-extern int isFloat128Zero(float128);
+extern int is_float96_infinity(float96);
+extern int is_float96_zero(float96);
 
-extern int isFloat128eq(float128, float128);
-extern int isFloat128lt(float128, float128);
-extern int isFloat128gt(float128, float128);
+extern int is_float96_eq(float96, float96);
+extern int is_float96_lt(float96, float96);
+extern int is_float96_gt(float96, float96);
+
+extern int is_float128_nan(float128);
+extern int is_float128_signan(float128);
+
+extern int is_float128_infinity(float128);
+extern int is_float128_zero(float128);
+
+extern int is_float128_eq(float128, float128);
+extern int is_float128_lt(float128, float128);
+extern int is_float128_gt(float128, float128);
 
 #endif
Index: uspace/lib/softfloat/include/conversion.h
===================================================================
--- uspace/lib/softfloat/include/conversion.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/include/conversion.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -37,13 +37,17 @@
 #define __CONVERSION_H__
 
-extern float64 convertFloat32ToFloat64(float32);
-extern float128 convertFloat32ToFloat128(float32);
-extern float128 convertFloat64ToFloat128(float64);
+extern float64 float32_to_float64(float32);
+extern float96 float32_to_float96(float32);
+extern float128 float32_to_float128(float32);
+extern float96 float64_to_float96(float64);
+extern float128 float64_to_float128(float64);
+extern float128 float96_to_float128(float96);
 
-
-extern float32 convertFloat64ToFloat32(float64);
-extern float32 convertFloat128ToFloat32(float128);
-extern float64 convertFloat128ToFloat64(float128);
-
+extern float32 float64_to_float32(float64);
+extern float32 float96_to_float32(float96);
+extern float64 float96_to_float64(float96);
+extern float32 float128_to_float32(float128);
+extern float64 float128_to_float64(float128);
+extern float96 float128_to_float96(float128);
 
 extern uint32_t float32_to_uint32(float32);
@@ -59,4 +63,10 @@
 extern int64_t float64_to_int64(float64);
 
+extern uint32_t float96_to_uint32(float96);
+extern int32_t float96_to_int32(float96);
+
+extern uint64_t float96_to_uint64(float96);
+extern int64_t float96_to_int64(float96);
+
 extern uint32_t float128_to_uint32(float128);
 extern int32_t float128_to_int32(float128);
@@ -64,5 +74,4 @@
 extern uint64_t float128_to_uint64(float128);
 extern int64_t float128_to_int64(float128);
-
 
 extern float32 uint32_to_float32(uint32_t);
@@ -78,4 +87,10 @@
 extern float64 int64_to_float64(int64_t);
 
+extern float96 uint32_to_float96(uint32_t);
+extern float96 int32_to_float96(int32_t);
+
+extern float96 uint64_to_float96(uint64_t);
+extern float96 int64_to_float96(int64_t);
+
 extern float128 uint32_to_float128(uint32_t);
 extern float128 int32_to_float128(int32_t);
Index: uspace/lib/softfloat/include/div.h
===================================================================
--- uspace/lib/softfloat/include/div.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/include/div.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -37,7 +37,8 @@
 #define __DIV_H__
 
-extern float32 divFloat32(float32, float32);
-extern float64 divFloat64(float64, float64);
-extern float128 divFloat128(float128, float128);
+extern float32 div_float32(float32, float32);
+extern float64 div_float64(float64, float64);
+extern float96 div_float96(float96, float96);
+extern float128 div_float128(float128, float128);
 
 #endif
Index: uspace/lib/softfloat/include/mul.h
===================================================================
--- uspace/lib/softfloat/include/mul.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/include/mul.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -37,7 +37,8 @@
 #define __MUL_H__
 
-extern float32 mulFloat32(float32, float32);
-extern float64 mulFloat64(float64, float64);
-extern float128 mulFloat128(float128, float128);
+extern float32 mul_float32(float32, float32);
+extern float64 mul_float64(float64, float64);
+extern float96 mul_float96(float96, float96);
+extern float128 mul_float128(float128, float128);
 
 #endif
Index: uspace/lib/softfloat/include/sftypes.h
===================================================================
--- uspace/lib/softfloat/include/sftypes.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/include/sftypes.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -40,112 +40,566 @@
 #include <stdint.h>
 
-typedef union {
-	float f;
-	uint32_t binary;
-	
-	struct {
+/*
+ * For recognizing NaNs or infinity use specialized comparison
+ * functions, comparing with these constants is not sufficient.
+ */
+
+#define FLOAT32_NAN     UINT32_C(0x7FC00001)
+#define FLOAT32_SIGNAN  UINT32_C(0x7F800001)
+#define FLOAT32_INF     UINT32_C(0x7F800000)
+
+#define FLOAT64_NAN     UINT64_C(0x7FF8000000000001)
+#define FLOAT64_SIGNAN  UINT64_C(0x7FF0000000000001)
+#define FLOAT64_INF     UINT64_C(0x7FF0000000000000)
+
+#define FLOAT96_NAN_HI     UINT64_C(0x7FFF80000000)
+#define FLOAT96_NAN_LO     UINT32_C(0x00010000)
+#define FLOAT96_SIGNAN_HI  UINT64_C(0x7FFF00000000)
+#define FLOAT96_SIGNAN_LO  UINT32_C(0x00010000)
+
+#define FLOAT128_NAN_HI     UINT64_C(0x7FFF800000000000)
+#define FLOAT128_NAN_LO     UINT64_C(0x0000000000000001)
+#define FLOAT128_SIGNAN_HI  UINT64_C(0x7FFF000000000000)
+#define FLOAT128_SIGNAN_LO  UINT64_C(0x0000000000000001)
+#define FLOAT128_INF_HI     UINT64_C(0x7FFF000000000000)
+#define FLOAT128_INF_LO     UINT64_C(0x0000000000000000)
+
+#define FLOAT32_FRACTION_SIZE   23
+#define FLOAT64_FRACTION_SIZE   52
+#define FLOAT96_FRACTION_SIZE   64
+#define FLOAT128_FRACTION_SIZE  112
+#define FLOAT128_FRAC_HI_SIZE   48
+#define FLOAT128_FRAC_LO_SIZE   64
+
+#define FLOAT32_HIDDEN_BIT_MASK      UINT32_C(0x800000)
+#define FLOAT64_HIDDEN_BIT_MASK      UINT64_C(0x10000000000000)
+#define FLOAT128_HIDDEN_BIT_MASK_HI  UINT64_C(0x1000000000000)
+#define FLOAT128_HIDDEN_BIT_MASK_LO  UINT64_C(0x0000000000000000)
+
+#define FLOAT32_MAX_EXPONENT   0xFF
+#define FLOAT64_MAX_EXPONENT   0x7FF
+#define FLOAT96_MAX_EXPONENT   0x7FFF
+#define FLOAT128_MAX_EXPONENT  0x7FFF
+
+#define FLOAT32_BIAS   0x7F
+#define FLOAT64_BIAS   0x3FF
+#define FLOAT96_BIAS   0x3FFF
+#define FLOAT128_BIAS  0x3FFF
+
 #if defined(__BE__)
+
+typedef union {
+	uint32_t bin;
+	
+	struct {
 		uint32_t sign : 1;
 		uint32_t exp : 8;
 		uint32_t fraction : 23;
-#elif defined(__LE__)
-		uint32_t fraction : 23;
-		uint32_t exp : 8;
-		uint32_t sign : 1;
-#else
-	#error Unknown endianess
-#endif
-	} parts __attribute__ ((packed));
+	} parts __attribute__((packed));
 } float32;
 
 typedef union {
-	double d;
-	uint64_t binary;
-	
-	struct {
-#if defined(__BE__)
+	uint64_t bin;
+	
+	struct {
 		uint64_t sign : 1;
 		uint64_t exp : 11;
 		uint64_t fraction : 52;
-#elif defined(__LE__)
-		uint64_t fraction : 52;
-		uint64_t exp : 11;
+	} parts __attribute__((packed));
+} float64;
+
+typedef union {
+	struct {
+		uint64_t hi;
+		uint32_t lo;
+	} bin __attribute__((packed));
+	
+	struct {
+		uint64_t padding : 16;
 		uint64_t sign : 1;
-#else
-	#error Unknown endianess
-#endif
-	} parts __attribute__ ((packed));
-} float64;
-
-typedef union {
-	long double ld;
-	struct {
-#if defined(__BE__)
+		uint64_t exp : 15;
+		uint64_t fraction : 64;
+	} parts __attribute__((packed));
+} float96;
+
+typedef union {
+	struct {
 		uint64_t hi;
 		uint64_t lo;
-#elif defined(__LE__)
-		uint64_t lo;
-		uint64_t hi;
-#else
-	#error Unknown endianess
-#endif
-	} binary;
-
-	struct {
-#if defined(__BE__)
+	} bin __attribute__((packed));
+	
+	struct {
 		uint64_t sign : 1;
 		uint64_t exp : 15;
 		uint64_t frac_hi : 48;
 		uint64_t frac_lo : 64;
+	} parts __attribute__((packed));
+} float128;
+
 #elif defined(__LE__)
+
+typedef union {
+	uint32_t bin;
+	
+	struct {
+		uint32_t fraction : 23;
+		uint32_t exp : 8;
+		uint32_t sign : 1;
+	} parts __attribute__((packed));
+} float32;
+
+typedef union {
+	uint64_t bin;
+	
+	struct {
+		uint64_t fraction : 52;
+		uint64_t exp : 11;
+		uint64_t sign : 1;
+	} parts __attribute__((packed));
+} float64;
+
+typedef union {
+	struct {
+		uint32_t lo;
+		uint64_t hi;
+	} bin __attribute__((packed));
+	
+	struct {
+		uint64_t fraction : 64;
+		uint64_t exp : 15;
+		uint64_t sign : 1;
+		uint64_t padding : 16;
+	} parts __attribute__((packed));
+} float96;
+
+typedef union {
+	struct {
+		uint64_t lo;
+		uint64_t hi;
+	} bin __attribute__((packed));
+	
+	struct {
 		uint64_t frac_lo : 64;
 		uint64_t frac_hi : 48;
 		uint64_t exp : 15;
 		uint64_t sign : 1;
+	} parts __attribute__((packed));
+} float128;
+
 #else
 	#error Unknown endianess
 #endif
-	} parts __attribute__ ((packed));
-} float128;
-
-/*
- * For recognizing NaNs or infinity use specialized comparison functions,
- * comparing with these constants is not sufficient.
- */
-
-#define FLOAT32_NAN     0x7FC00001
-#define FLOAT32_SIGNAN  0x7F800001
-#define FLOAT32_INF     0x7F800000
-
-#define FLOAT64_NAN     0x7FF8000000000001ll
-#define FLOAT64_SIGNAN  0x7FF0000000000001ll
-#define FLOAT64_INF     0x7FF0000000000000ll
-
-#define FLOAT128_NAN_HI     0x7FFF800000000000ll
-#define FLOAT128_NAN_LO     0x0000000000000001ll
-#define FLOAT128_SIGNAN_HI  0x7FFF000000000000ll
-#define FLOAT128_SIGNAN_LO  0x0000000000000001ll
-#define FLOAT128_INF_HI     0x7FFF000000000000ll
-#define FLOAT128_INF_LO     0x0000000000000000ll
-
-#define FLOAT32_FRACTION_SIZE   23
-#define FLOAT64_FRACTION_SIZE   52
-#define FLOAT128_FRACTION_SIZE 112
-#define FLOAT128_FRAC_HI_SIZE   48
-#define FLOAT128_FRAC_LO_SIZE   64
-
-#define FLOAT32_HIDDEN_BIT_MASK      0x800000
-#define FLOAT64_HIDDEN_BIT_MASK      0x10000000000000ll
-#define FLOAT128_HIDDEN_BIT_MASK_HI  0x1000000000000ll
-#define FLOAT128_HIDDEN_BIT_MASK_LO  0x0000000000000000ll
-
-#define FLOAT32_MAX_EXPONENT  0xFF
-#define FLOAT64_MAX_EXPONENT  0x7FF
-#define FLOAT128_MAX_EXPONENT 0x7FFF
-
-#define FLOAT32_BIAS  0x7F
-#define FLOAT64_BIAS  0x3FF
-#define FLOAT80_BIAS  0x3FFF
-#define FLOAT128_BIAS 0x3FFF
+
+typedef union {
+	float val;
+	
+#if defined(FLOAT_SIZE_32)
+	float32 data;
+#elif defined(FLOAT_SIZE_64)
+	float64 data;
+#elif defined(FLOAT_SIZE_96)
+	float96 data;
+#elif defined(FLOAT_SIZE_128)
+	float128 data;
+#else
+	#error Unsupported float size
+#endif
+} float_t;
+
+typedef union {
+	double val;
+	
+#if defined(DOUBLE_SIZE_32)
+	float32 data;
+#elif defined(DOUBLE_SIZE_64)
+	float64 data;
+#elif defined(DOUBLE_SIZE_96)
+	float96 data;
+#elif defined(DOUBLE_SIZE_128)
+	float128 data;
+#else
+	#error Unsupported double size
+#endif
+} double_t;
+
+typedef union {
+	long double val;
+	
+#if defined(LONG_DOUBLE_SIZE_32)
+	float32 data;
+#elif defined(LONG_DOUBLE_SIZE_64)
+	float64 data;
+#elif defined(LONG_DOUBLE_SIZE_96)
+	float96 data;
+#elif defined(LONG_DOUBLE_SIZE_128)
+	float128 data;
+#else
+	#error Unsupported long double size
+#endif
+} long_double_t;
+
+
+#if defined(INT_SIZE_8)
+
+#define _to_int   _to_int8
+#define from_int  int8
+
+#elif defined(INT_SIZE_16)
+
+#define _to_int   _to_int16
+#define from_int  int16
+
+#elif defined(INT_SIZE_32)
+
+#define _to_int   _to_int32
+#define from_int  int32
+
+#elif defined(INT_SIZE_64)
+
+#define _to_int   _to_int64
+#define from_int  int64
+
+#endif
+
+
+#if defined(UINT_SIZE_8)
+
+#define _to_uint   _to_uint8
+#define from_uint  uint8
+
+#elif defined(UINT_SIZE_16)
+
+#define _to_uint   _to_uint16
+#define from_uint  uint16
+
+#elif defined(UINT_SIZE_32)
+
+#define _to_uint   _to_uint32
+#define from_uint  uint32
+
+#elif defined(UINT_SIZE_64)
+
+#define _to_uint   _to_uint64
+#define from_uint  uint64
+
+#endif
+
+
+#if defined(LONG_SIZE_8)
+
+#define _to_long   _to_int8
+#define from_long  int8
+
+#elif defined(LONG_SIZE_16)
+
+#define _to_long   _to_int16
+#define from_long  int16
+
+#elif defined(LONG_SIZE_32)
+
+#define _to_long   _to_int32
+#define from_long  int32
+
+#elif defined(LONG_SIZE_64)
+
+#define _to_long   _to_int64
+#define from_long  int64
+
+#endif
+
+
+#if defined(ULONG_SIZE_8)
+
+#define _to_ulong   _to_uint8
+#define from_ulong  uint8
+
+#elif defined(ULONG_SIZE_16)
+
+#define _to_ulong   _to_uint16
+#define from_ulong  uint16
+
+#elif defined(ULONG_SIZE_32)
+
+#define _to_ulong   _to_uint32
+#define from_ulong  uint32
+
+#elif defined(ULONG_SIZE_64)
+
+#define _to_ulong   _to_uint64
+#define from_ulong  uint64
+
+#endif
+
+
+#if defined(LLONG_SIZE_8)
+
+#define _to_llong   _to_int8
+#define from_llong  int8
+
+#elif defined(LLONG_SIZE_16)
+
+#define _to_llong   _to_int16
+#define from_llong  int16
+
+#elif defined(LLONG_SIZE_32)
+
+#define _to_llong   _to_int32
+#define from_llong  int32
+
+#elif defined(LLONG_SIZE_64)
+
+#define _to_llong   _to_int64
+#define from_llong  int64
+
+#endif
+
+
+#if defined(ULLONG_SIZE_8)
+
+#define _to_ullong   _to_uint8
+#define from_ullong  uint8
+
+#elif defined(ULLONG_SIZE_16)
+
+#define _to_ullong   _to_uint16
+#define from_ullong  uint16
+
+#elif defined(ULLONG_SIZE_32)
+
+#define _to_ullong   _to_uint32
+#define from_ullong  uint32
+
+#elif defined(ULLONG_SIZE_64)
+
+#define _to_ullong   _to_uint64
+#define from_ullong  uint64
+
+#endif
+
+
+#if defined(FLOAT_SIZE_32)
+
+#define add_float     add_float32
+#define sub_float     sub_float32
+#define mul_float     mul_float32
+#define div_float     div_float32
+#define _to_float     _to_float32
+#define from_float    float32
+#define is_float_nan  is_float32_nan
+#define is_float_eq   is_float32_eq
+#define is_float_lt   is_float32_lt
+#define is_float_gt   is_float32_gt
+
+#elif defined(FLOAT_SIZE_64)
+
+#define add_float     add_float64
+#define sub_float     sub_float64
+#define mul_float     mul_float64
+#define div_float     div_float64
+#define _to_float     _to_float64
+#define from_float    float64
+#define is_float_nan  is_float64_nan
+#define is_float_eq   is_float64_eq
+#define is_float_lt   is_float64_lt
+#define is_float_gt   is_float64_gt
+
+#elif defined(FLOAT_SIZE_96)
+
+#define add_float     add_float96
+#define sub_float     sub_float96
+#define mul_float     mul_float96
+#define div_float     div_float96
+#define _to_float     _to_float96
+#define from_float    float96
+#define is_float_nan  is_float96_nan
+#define is_float_eq   is_float96_eq
+#define is_float_lt   is_float96_lt
+#define is_float_gt   is_float96_gt
+
+#elif defined(FLOAT_SIZE_128)
+
+#define add_float     add_float128
+#define sub_float     sub_float128
+#define mul_float     mul_float128
+#define div_float     div_float128
+#define _to_float     _to_float128
+#define from_float    float128
+#define is_float_nan  is_float128_nan
+#define is_float_eq   is_float128_eq
+#define is_float_lt   is_float128_lt
+#define is_float_gt   is_float128_gt
+
+#endif
+
+
+#if defined(DOUBLE_SIZE_32)
+
+#define add_double     add_float32
+#define sub_double     sub_float32
+#define mul_double     mul_float32
+#define div_double     div_float32
+#define _to_double     _to_float32
+#define from_double    float32
+#define is_double_nan  is_float32_nan
+#define is_double_eq   is_float32_eq
+#define is_double_lt   is_float32_lt
+#define is_double_gt   is_float32_gt
+
+#elif defined(DOUBLE_SIZE_64)
+
+#define add_double     add_float64
+#define sub_double     sub_float64
+#define mul_double     mul_float64
+#define div_double     div_float64
+#define _to_double     _to_float64
+#define from_double    float64
+#define is_double_nan  is_float64_nan
+#define is_double_eq   is_float64_eq
+#define is_double_lt   is_float64_lt
+#define is_double_gt   is_float64_gt
+
+#elif defined(DOUBLE_SIZE_96)
+
+#define add_double     add_float96
+#define sub_double     sub_float96
+#define mul_double     mul_float96
+#define div_double     div_float96
+#define _to_double     _to_float96
+#define from_double    float96
+#define is_double_nan  is_float96_nan
+#define is_double_eq   is_float96_eq
+#define is_double_lt   is_float96_lt
+#define is_double_gt   is_float96_gt
+
+#elif defined(DOUBLE_SIZE_128)
+
+#define add_double     add_float128
+#define sub_double     sub_float128
+#define mul_double     mul_float128
+#define div_double     div_float128
+#define _to_double     _to_float128
+#define from_double    float128
+#define is_double_nan  is_float128_nan
+#define is_double_eq   is_float128_eq
+#define is_double_lt   is_float128_lt
+#define is_double_gt   is_float128_gt
+
+#endif
+
+
+#if defined(LONG_DOUBLE_SIZE_32)
+
+#define add_long_double     add_float32
+#define sub_long_double     sub_float32
+#define mul_long_double     mul_float32
+#define div_long_double     div_float32
+#define _to_long_double     _to_float32
+#define from_long_double    float32
+#define is_long_double_nan  is_float32_nan
+#define is_long_double_eq   is_float32_eq
+#define is_long_double_lt   is_float32_lt
+#define is_long_double_gt   is_float32_gt
+
+#elif defined(LONG_DOUBLE_SIZE_64)
+
+#define add_long_double     add_float64
+#define sub_long_double     sub_float64
+#define mul_long_double     mul_float64
+#define div_long_double     div_float64
+#define _to_long_double     _to_float64
+#define from_long_double    float64
+#define is_long_double_nan  is_float64_nan
+#define is_long_double_eq   is_float64_eq
+#define is_long_double_lt   is_float64_lt
+#define is_long_double_gt   is_float64_gt
+
+#elif defined(LONG_DOUBLE_SIZE_96)
+
+#define add_long_double     add_float96
+#define sub_long_double     sub_float96
+#define mul_long_double     mul_float96
+#define div_long_double     div_float96
+#define _to_long_double     _to_float96
+#define from_long_double    float96
+#define is_long_double_nan  is_float96_nan
+#define is_long_double_eq   is_float96_eq
+#define is_long_double_lt   is_float96_lt
+#define is_long_double_gt   is_float96_gt
+
+#elif defined(LONG_DOUBLE_SIZE_128)
+
+#define add_long_double     add_float128
+#define sub_long_double     sub_float128
+#define mul_long_double     mul_float128
+#define div_long_double     div_float128
+#define _to_long_double     _to_float128
+#define from_long_double    float128
+#define is_long_double_nan  is_float128_nan
+#define is_long_double_eq   is_float128_eq
+#define is_long_double_lt   is_float128_lt
+#define is_long_double_gt   is_float128_gt
+
+#endif
+
+
+#define CONCAT(a, b)       CONCAT_ARGS(a, b)
+#define CONCAT_ARGS(a, b)  a ## b
+
+#define float32_to_float32(arg)    (arg)
+#define float64_to_float64(arg)    (arg)
+#define float96_to_float96(arg)    (arg)
+#define float128_to_float128(arg)  (arg)
+
+#define float_to_double       CONCAT(from_float, _to_double)
+#define float_to_long_double  CONCAT(from_float, _to_long_double)
+#define float_to_int          CONCAT(from_float, _to_int)
+#define float_to_uint         CONCAT(from_float, _to_uint)
+#define float_to_long         CONCAT(from_float, _to_long)
+#define float_to_ulong        CONCAT(from_float, _to_ulong)
+#define float_to_llong        CONCAT(from_float, _to_llong)
+#define float_to_ullong       CONCAT(from_float, _to_ullong)
+
+#define double_to_float        CONCAT(from_double, _to_float)
+#define double_to_long_double  CONCAT(from_double, _to_long_double)
+#define double_to_int          CONCAT(from_double, _to_int)
+#define double_to_uint         CONCAT(from_double, _to_uint)
+#define double_to_long         CONCAT(from_double, _to_long)
+#define double_to_ulong        CONCAT(from_double, _to_ulong)
+#define double_to_llong        CONCAT(from_double, _to_llong)
+#define double_to_ullong       CONCAT(from_double, _to_ullong)
+
+#define long_double_to_float   CONCAT(from_long_double, _to_float)
+#define long_double_to_double  CONCAT(from_long_double, _to_double)
+#define long_double_to_int     CONCAT(from_long_double, _to_int)
+#define long_double_to_uint    CONCAT(from_long_double, _to_uint)
+#define long_double_to_long    CONCAT(from_long_double, _to_long)
+#define long_double_to_ulong   CONCAT(from_long_double, _to_ulong)
+#define long_double_to_llong   CONCAT(from_long_double, _to_llong)
+#define long_double_to_ullong  CONCAT(from_long_double, _to_ullong)
+
+#define int_to_float        CONCAT(from_int, _to_float)
+#define int_to_double       CONCAT(from_int, _to_double)
+#define int_to_long_double  CONCAT(from_int, _to_long_double)
+
+#define uint_to_float        CONCAT(from_uint, _to_float)
+#define uint_to_double       CONCAT(from_uint, _to_double)
+#define uint_to_long_double  CONCAT(from_uint, _to_long_double)
+
+#define long_to_float        CONCAT(from_long, _to_float)
+#define long_to_double       CONCAT(from_long, _to_double)
+#define long_to_long_double  CONCAT(from_long, _to_long_double)
+
+#define ulong_to_float        CONCAT(from_ulong, _to_float)
+#define ulong_to_double       CONCAT(from_ulong, _to_double)
+#define ulong_to_long_double  CONCAT(from_ulong, _to_long_double)
+
+#define llong_to_float        CONCAT(from_llong, _to_float)
+#define llong_to_double       CONCAT(from_llong, _to_double)
+#define llong_to_long_double  CONCAT(from_llong, _to_long_double)
+
+#define ullong_to_float        CONCAT(from_ullong, _to_float)
+#define ullong_to_double       CONCAT(from_ullong, _to_double)
+#define ullong_to_long_double  CONCAT(from_ullong, _to_long_double)
+
 
 #endif
Index: uspace/lib/softfloat/include/softfloat.h
===================================================================
--- uspace/lib/softfloat/include/softfloat.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/include/softfloat.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -169,8 +169,6 @@
 extern float __powisf2(float, int);
 extern double __powidf2 (double, int);
-extern long double __powitf2 (long double, int);
-extern long double __powixf2 (long double, int);
-
-
+extern long double __powitf2(long double, int);
+extern long double __powixf2(long double, int);
 
 /* SPARC quadruple-precision wrappers */
Index: uspace/lib/softfloat/include/sub.h
===================================================================
--- uspace/lib/softfloat/include/sub.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softfloat/include/sub.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -37,7 +37,8 @@
 #define __SUB_H__
 
-extern float32 subFloat32(float32, float32);
-extern float64 subFloat64(float64, float64);
-extern float128 subFloat128(float128, float128);
+extern float32 sub_float32(float32, float32);
+extern float64 sub_float64(float64, float64);
+extern float96 sub_float96(float96, float96);
+extern float128 sub_float128(float128, float128);
 
 #endif
Index: uspace/lib/softint/generic/division.c
===================================================================
--- uspace/lib/softint/generic/division.c	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softint/generic/division.c	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -188,4 +188,18 @@
 }
 
+int __divmodsi3(int a, int b, int *c)
+{
+	unsigned int rem;
+	int result = (int) divandmod32(ABSVAL(a), ABSVAL(b), &rem);
+	
+	if (SGN(a) == SGN(b)) {
+		*c = rem;
+		return result;
+	}
+	
+	*c = -rem;
+	return -result;
+}
+
 unsigned int __udivmodsi3(unsigned int a, unsigned int b,
     unsigned int *c)
@@ -194,4 +208,18 @@
 }
 
+long long __divmoddi3(long long a, long long b, long long *c)
+{
+	unsigned long long rem;
+	long long result = (int) divandmod64(ABSVAL(a), ABSVAL(b), &rem);
+	
+	if (SGN(a) == SGN(b)) {
+		*c = rem;
+		return result;
+	}
+	
+	*c = -rem;
+	return -result;
+}
+
 unsigned long long __udivmoddi3(unsigned long long a, unsigned long long b,
     unsigned long long *c)
Index: uspace/lib/softint/include/comparison.h
===================================================================
--- uspace/lib/softint/include/comparison.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softint/include/comparison.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -38,8 +38,8 @@
 
 /* Signed comparison (a < b => 0, a == b => 1, a > b => 2). */
-int __cmpdi2 (long long a, long long b);
+extern int __cmpdi2(long long, long long);
 
 /* Unsigned comparison (a < b => 0, a == b => 1, a > b => 2). */
-int __ucmpdi2 (unsigned long long a, unsigned long long b);
+extern int __ucmpdi2(unsigned long long, unsigned long long);
 
 #endif
Index: uspace/lib/softint/include/division.h
===================================================================
--- uspace/lib/softint/include/division.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softint/include/division.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -29,5 +29,5 @@
 /** @addtogroup softint
  * @{
- */ 
+ */
 /**
  * @file
@@ -49,5 +49,8 @@
 extern unsigned long long __umoddi3(unsigned long long, unsigned long long);
 
+extern int __divmodsi3(int, int, int *);
 extern unsigned int __udivmodsi3(unsigned int, unsigned int, unsigned int *);
+
+extern long long __divmoddi3(long long, long long, long long *);
 extern unsigned long long __udivmoddi3(unsigned long long, unsigned long long,
     unsigned long long *);
Index: uspace/lib/softint/include/lltype.h
===================================================================
--- uspace/lib/softint/include/lltype.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softint/include/lltype.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -39,6 +39,6 @@
 #include <stdint.h>
 
-#define HALF_BIT_CNT (sizeof(int32_t) * sizeof(char))
-#define WHOLE_BIT_CNT (sizeof(int64_t) * sizeof(char))
+#define HALF_BIT_CNT   (sizeof(int32_t) * sizeof(char))
+#define WHOLE_BIT_CNT  (sizeof(int64_t) * sizeof(char))
 
 #ifdef __BE__
Index: uspace/lib/softint/include/multiplication.h
===================================================================
--- uspace/lib/softint/include/multiplication.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softint/include/multiplication.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -29,5 +29,5 @@
 /** @addtogroup softint
  * @{
- */ 
+ */
 /**
  * @file
@@ -38,5 +38,5 @@
 
 /* 64 bit multiplication */
-long long __muldi3(long long a, long long b);
+extern long long __muldi3(long long, long long);
 
 #endif
Index: uspace/lib/softint/include/shift.h
===================================================================
--- uspace/lib/softint/include/shift.h	(revision 8e893aeb5653f1350d4daa8ac443ec24ef6449cd)
+++ uspace/lib/softint/include/shift.h	(revision dcffe95201630b897ab409dd34d42835214b1345)
@@ -38,11 +38,11 @@
 
 /* Arithmetic/logical shift left. */
-long long __ashldi3 (long long val, int shift);
+extern long long __ashldi3(long long, int);
 
 /* Arithmetic shift right. */
-long long __ashrdi3 (long long val, int shift);
+extern long long __ashrdi3(long long, int);
 
 /* Logical shift right. */
-long long __lshrdi3 (long long val, int shift);
+extern long long __lshrdi3(long long, int);
 
 #endif
