OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [libgcc/] [config/] [h8300/] [fixunssfsi.c] - Blame information for rev 734

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 734 jeremybenn
/* More subroutines needed by GCC output code on some machines.  */
2
/* Compile this one with gcc.  */
3
/* Copyright (C) 1989, 1992, 2001, 2002, 2003, 2004, 2009, 2011
4
   Free Software Foundation, Inc.
5
 
6
This file is part of GCC.
7
 
8
GCC is free software; you can redistribute it and/or modify
9
it under the terms of the GNU General Public License as published by
10
the Free Software Foundation; either version 3, or (at your option)
11
any later version.
12
 
13
GCC is distributed in the hope that it will be useful,
14
but WITHOUT ANY WARRANTY; without even the implied warranty of
15
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16
GNU General Public License for more details.
17
 
18
Under Section 7 of GPL version 3, you are granted additional
19
permissions described in the GCC Runtime Library Exception, version
20
3.1, as published by the Free Software Foundation.
21
 
22
You should have received a copy of the GNU General Public License and
23
a copy of the GCC Runtime Library Exception along with this program;
24
see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
25
<http://www.gnu.org/licenses/>.  */
26
 
27
/* The libgcc2.c implementation gets confused by our type setup and creates
28
   a directly recursive call, so we do our own implementation.  For
29
   the H8/300, that's in lib1funcs.S, for H8/300H and H8S, it's here.  */
30
 
31
#ifndef __H8300__
32
long __fixunssfsi (float a);
33
 
34
long
35
__fixunssfsi (float a)
36
{
37
  if (a >= (float) 32768L)
38
    return (long) (a - 32768L) + 32768L;
39
  return (long) a;
40
}
41
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.