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
ba641b7e
Commit
ba641b7e
authored
Feb 20, 2012
by
Georg-Johann Lay
Committed by
Georg-Johann Lay
Feb 20, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pr52132.c: Fix FAIL on 16-bit int platforms.
* gcc.dg/pr52132.c: Fix FAIL on 16-bit int platforms. From-SVN: r184393
parent
a19db3f2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
0 deletions
+13
-0
gcc/testsuite/ChangeLog
+4
-0
gcc/testsuite/gcc.dg/pr52132.c
+9
-0
No files found.
gcc/testsuite/ChangeLog
View file @
ba641b7e
2012-02-20 Georg-Johann Lay <avr@gjlay.de>
* gcc.dg/pr52132.c: Fix FAIL on 16-bit int platforms.
2012-02-20 Jakub Jelinek <jakub@redhat.com>
2012-02-20 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/52286
PR tree-optimization/52286
...
...
gcc/testsuite/gcc.dg/pr52132.c
View file @
ba641b7e
...
@@ -2,6 +2,11 @@
...
@@ -2,6 +2,11 @@
/* { dg-do compile } */
/* { dg-do compile } */
/* { dg-options "-std=c99 -O2 -g" } */
/* { dg-options "-std=c99 -O2 -g" } */
#if (__SIZEOF_INT__ < __SIZEOF_FLOAT__) \
&& (__SIZEOF_LONG__ == __SIZEOF_FLOAT__)
#define int long
#endif
int
l
;
int
l
;
void
bar
(
void
);
void
bar
(
void
);
...
@@ -10,7 +15,11 @@ foo (int *x, float y)
...
@@ -10,7 +15,11 @@ foo (int *x, float y)
{
{
float
b
;
float
b
;
union
{
float
f
;
int
i
;
}
u
=
{
.
f
=
y
};
union
{
float
f
;
int
i
;
}
u
=
{
.
f
=
y
};
#if (__SIZEOF_INT__ < __SIZEOF_FLOAT__)
u
.
i
+=
127L
<<
23
;
#else
u
.
i
+=
127
<<
23
;
u
.
i
+=
127
<<
23
;
#endif
u
.
f
=
((
-
1
.
0
f
/
3
)
*
u
.
f
+
2
)
*
u
.
f
-
2
.
0
f
/
3
;
u
.
f
=
((
-
1
.
0
f
/
3
)
*
u
.
f
+
2
)
*
u
.
f
-
2
.
0
f
/
3
;
b
=
0
.
5
*
(
u
.
f
+
l
);
b
=
0
.
5
*
(
u
.
f
+
l
);
if
(
b
>=
*
x
)
if
(
b
>=
*
x
)
...
...
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