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
01ae8930
Commit
01ae8930
authored
Apr 07, 2005
by
Steven G. Kargl
Committed by
Steven G. Kargl
Apr 07, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
simplify.c (gfc_simplify_exponent): Fix exponent(tiny(x))
From-SVN: r97792
parent
03359b57
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
0 deletions
+11
-0
gcc/fortran/ChangeLog
+4
-0
gcc/fortran/simplify.c
+7
-0
No files found.
gcc/fortran/ChangeLog
View file @
01ae8930
2005-04-07 Steven G. Kargl <kargls@comcast.net>
* simplify.c (gfc_simplify_exponent): Fix exponent(tiny(x))
2005-04-06 Steven G. Kargl <kargls@comcast.net>
* invoke.texi: Remove documentation of -std=f90
...
...
gcc/fortran/simplify.c
View file @
01ae8930
...
...
@@ -967,6 +967,7 @@ gfc_simplify_exp (gfc_expr * x)
gfc_expr
*
gfc_simplify_exponent
(
gfc_expr
*
x
)
{
int
i
;
mpfr_t
tmp
;
gfc_expr
*
result
;
...
...
@@ -991,6 +992,12 @@ gfc_simplify_exponent (gfc_expr * x)
gfc_mpfr_to_mpz
(
result
->
value
.
integer
,
tmp
);
/* The model number for tiny(x) is b**(emin - 1) where b is the base and emin
is the smallest exponent value. So, we need to add 1 if x is tiny(x). */
i
=
gfc_validate_kind
(
x
->
ts
.
type
,
x
->
ts
.
kind
,
false
);
if
(
mpfr_cmp
(
x
->
value
.
real
,
gfc_real_kinds
[
i
].
tiny
)
==
0
)
mpz_add_ui
(
result
->
value
.
integer
,
result
->
value
.
integer
,
1
);
mpfr_clear
(
tmp
);
return
range_check
(
result
,
"EXPONENT"
);
...
...
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