Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
riscv-gcc-1
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
riscv-gcc-1
Commits
6bce1b78
Commit
6bce1b78
authored
Feb 04, 1992
by
Richard Kenner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
*** empty log message ***
From-SVN: r277
parent
91f7b55f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
37 additions
and
15 deletions
+37
-15
gcc/optabs.c
+37
-15
No files found.
gcc/optabs.c
View file @
6bce1b78
...
@@ -99,6 +99,18 @@ rtx gtdf2_libfunc;
...
@@ -99,6 +99,18 @@ rtx gtdf2_libfunc;
rtx
gedf2_libfunc
;
rtx
gedf2_libfunc
;
rtx
ltdf2_libfunc
;
rtx
ltdf2_libfunc
;
rtx
ledf2_libfunc
;
rtx
ledf2_libfunc
;
rtx
floatdisf_libfunc
;
rtx
floatsisf_libfunc
;
rtx
floatdidf_libfunc
;
rtx
floatsidf_libfunc
;
rtx
fixsfsi_libfunc
;
rtx
fixsfdi_libfunc
;
rtx
fixdfsi_libfunc
;
rtx
fixdfdi_libfunc
;
rtx
fixunssfsi_libfunc
;
rtx
fixunssfdi_libfunc
;
rtx
fixunsdfsi_libfunc
;
rtx
fixunsdfdi_libfunc
;
/* Indexed by the rtx-code for a conditional (eg. EQ, LT,...)
/* Indexed by the rtx-code for a conditional (eg. EQ, LT,...)
gives the gen_function to make a branch to test that condition. */
gives the gen_function to make a branch to test that condition. */
...
@@ -2508,7 +2520,7 @@ expand_float (to, from, unsignedp)
...
@@ -2508,7 +2520,7 @@ expand_float (to, from, unsignedp)
/* No hardware instruction available; call a library
/* No hardware instruction available; call a library
to convert from SImode or DImode into SFmode or DFmode. */
to convert from SImode or DImode into SFmode or DFmode. */
{
{
char
*
fnname
;
rtx
libfcn
;
rtx
insns
;
rtx
insns
;
to
=
protect_from_queue
(
to
,
1
);
to
=
protect_from_queue
(
to
,
1
);
...
@@ -2524,18 +2536,18 @@ expand_float (to, from, unsignedp)
...
@@ -2524,18 +2536,18 @@ expand_float (to, from, unsignedp)
if
(
GET_MODE
(
to
)
==
SFmode
)
if
(
GET_MODE
(
to
)
==
SFmode
)
{
{
if
(
GET_MODE
(
from
)
==
SImode
)
if
(
GET_MODE
(
from
)
==
SImode
)
fnname
=
"__floatsisf"
;
libfcn
=
floatsisf_libfunc
;
else
if
(
GET_MODE
(
from
)
==
DImode
)
else
if
(
GET_MODE
(
from
)
==
DImode
)
fnname
=
"__floatdisf"
;
libfcn
=
floatdisf_libfunc
;
else
else
abort
();
abort
();
}
}
else
if
(
GET_MODE
(
to
)
==
DFmode
)
else
if
(
GET_MODE
(
to
)
==
DFmode
)
{
{
if
(
GET_MODE
(
from
)
==
SImode
)
if
(
GET_MODE
(
from
)
==
SImode
)
fnname
=
"__floatsidf"
;
libfcn
=
floatsidf_libfunc
;
else
if
(
GET_MODE
(
from
)
==
DImode
)
else
if
(
GET_MODE
(
from
)
==
DImode
)
fnname
=
"__floatdidf"
;
libfcn
=
floatdidf_libfunc
;
else
else
abort
();
abort
();
}
}
...
@@ -2544,8 +2556,7 @@ expand_float (to, from, unsignedp)
...
@@ -2544,8 +2556,7 @@ expand_float (to, from, unsignedp)
start_sequence
();
start_sequence
();
emit_library_call
(
gen_rtx
(
SYMBOL_REF
,
Pmode
,
fnname
),
emit_library_call
(
libfcn
,
0
,
GET_MODE
(
to
),
1
,
from
,
GET_MODE
(
from
));
0
,
GET_MODE
(
to
),
1
,
from
,
GET_MODE
(
from
));
insns
=
get_insns
();
insns
=
get_insns
();
end_sequence
();
end_sequence
();
...
@@ -2585,7 +2596,7 @@ expand_fix (to, from, unsignedp)
...
@@ -2585,7 +2596,7 @@ expand_fix (to, from, unsignedp)
register
rtx
target
=
to
;
register
rtx
target
=
to
;
enum
machine_mode
fmode
,
imode
;
enum
machine_mode
fmode
,
imode
;
int
must_trunc
=
0
;
int
must_trunc
=
0
;
char
*
fnname
=
0
;
rtx
libfcn
=
0
;
/* We first try to find a pair of modes, one real and one integer, at
/* We first try to find a pair of modes, one real and one integer, at
least as wide as FROM and TO, respectively, in which we can open-code
least as wide as FROM and TO, respectively, in which we can open-code
...
@@ -2711,25 +2722,25 @@ expand_fix (to, from, unsignedp)
...
@@ -2711,25 +2722,25 @@ expand_fix (to, from, unsignedp)
else
if
(
GET_MODE
(
from
)
==
SFmode
)
else
if
(
GET_MODE
(
from
)
==
SFmode
)
{
{
if
(
GET_MODE
(
to
)
==
SImode
)
if
(
GET_MODE
(
to
)
==
SImode
)
fnname
=
unsignedp
?
"__fixunssfsi"
:
"__fixsfsi"
;
libfcn
=
unsignedp
?
fixunssfsi_libfunc
:
fixsfsi_libfunc
;
else
if
(
GET_MODE
(
to
)
==
DImode
)
else
if
(
GET_MODE
(
to
)
==
DImode
)
fnname
=
unsignedp
?
"__fixunssfdi"
:
"__fixsfdi"
;
libfcn
=
unsignedp
?
fixunssfdi_libfunc
:
fixsfdi_libfunc
;
else
else
abort
();
abort
();
}
}
else
if
(
GET_MODE
(
from
)
==
DFmode
)
else
if
(
GET_MODE
(
from
)
==
DFmode
)
{
{
if
(
GET_MODE
(
to
)
==
SImode
)
if
(
GET_MODE
(
to
)
==
SImode
)
fnname
=
unsignedp
?
"__fixunsdfsi"
:
"__fixdfsi"
;
libfcn
=
unsignedp
?
fixunsdfsi_libfunc
:
fixdfsi_libfunc
;
else
if
(
GET_MODE
(
to
)
==
DImode
)
else
if
(
GET_MODE
(
to
)
==
DImode
)
fnname
=
unsignedp
?
"__fixunsdfdi"
:
"__fixdfdi"
;
libfcn
=
unsignedp
?
fixunsdfdi_libfunc
:
fixdfdi_libfunc
;
else
else
abort
();
abort
();
}
}
else
else
abort
();
abort
();
if
(
fnname
)
if
(
libfcn
)
{
{
rtx
insns
;
rtx
insns
;
...
@@ -2741,8 +2752,7 @@ expand_fix (to, from, unsignedp)
...
@@ -2741,8 +2752,7 @@ expand_fix (to, from, unsignedp)
start_sequence
();
start_sequence
();
emit_library_call
(
gen_rtx
(
SYMBOL_REF
,
Pmode
,
fnname
),
emit_library_call
(
libfcn
,
0
,
GET_MODE
(
to
),
1
,
from
,
GET_MODE
(
from
));
0
,
GET_MODE
(
to
),
1
,
from
,
GET_MODE
(
from
));
insns
=
get_insns
();
insns
=
get_insns
();
end_sequence
();
end_sequence
();
...
@@ -3972,4 +3982,16 @@ init_optabs ()
...
@@ -3972,4 +3982,16 @@ init_optabs ()
gedf2_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__gedf2"
);
gedf2_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__gedf2"
);
ltdf2_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__ltdf2"
);
ltdf2_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__ltdf2"
);
ledf2_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__ledf2"
);
ledf2_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__ledf2"
);
floatdisf_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__floatdisf"
);
floatsisf_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__floatsisf"
);
floatdidf_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__floatdidf"
);
floatsidf_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__floatsidf"
);
fixsfsi_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__fixsfsi"
);
fixsfdi_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__fixsfdi"
);
fixdfsi_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__fixdfsi"
);
fixdfdi_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__fixdfdi"
);
fixunssfsi_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__fixunssfsi"
);
fixunssfdi_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__fixunssfdi"
);
fixunsdfsi_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__fixunsdfsi"
);
fixunsdfdi_libfunc
=
gen_rtx
(
SYMBOL_REF
,
Pmode
,
"__fixunsdfdi"
);
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment