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
820f6e3a
Commit
820f6e3a
authored
Oct 05, 1999
by
Michael Meissner
Committed by
Michael Meissner
Oct 05, 1999
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make libgcc1-test.c compile without warnings
From-SVN: r29832
parent
2f9e65b1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
4 deletions
+23
-4
gcc/ChangeLog
+7
-1
gcc/libgcc1-test.c
+16
-3
No files found.
gcc/ChangeLog
View file @
820f6e3a
Tue
Oct
5
15
:
37
:
04
1999
Michael
Meissner
<
meissner
@cygnus
.
com
>
Tue
Oct
5
16
:
14
:
40
1999
Michael
Meissner
<
meissner
@cygnus
.
com
>
*
libgcc1
-
test
.
c
(
toplevel
)
:
Include
stddef
.
h
to
get
size_t
.
({,
d
}
discard
)
:
Add
forward
declarations
.
Declare
parameter
as
unused
.
(
main_without_main
)
:
Explicitly
declare
return
type
to
be
int
.
(
memcpy
)
:
Properly
declare
.
*
libgcc2
.
c
(
toplevel
)
:
If
inhibit_libc
is
defined
and
not
*
libgcc2
.
c
(
toplevel
)
:
If
inhibit_libc
is
defined
and
not
building
the
trampoline
support
,
declare
malloc
,
free
,
and
building
the
trampoline
support
,
declare
malloc
,
free
,
and
...
...
gcc/libgcc1-test.c
View file @
820f6e3a
...
@@ -3,12 +3,17 @@
...
@@ -3,12 +3,17 @@
you have provided replacements for all the libgcc1.c functions that
you have provided replacements for all the libgcc1.c functions that
your target machine needs. */
your target machine needs. */
#include <stddef.h>
int
foo
();
int
foo
();
double
dfoo
();
double
dfoo
();
void
discard
(
int
);
void
ddiscard
(
double
);
/* We don't want __main here because that can drag in atexit (among other
/* We don't want __main here because that can drag in atexit (among other
things) which won't necessarily exist yet. */
things) which won't necessarily exist yet. */
int
main_without__main
()
main_without__main
()
{
{
int
a
=
foo
(),
b
=
foo
();
int
a
=
foo
(),
b
=
foo
();
...
@@ -65,14 +70,17 @@ main_without__main ()
...
@@ -65,14 +70,17 @@ main_without__main ()
return
0
;
return
0
;
}
}
void
discard
(
x
)
discard
(
x
)
int
x
;
int
x
__attribute__
((
__unused__
))
;
{}
{}
void
ddiscard
(
x
)
ddiscard
(
x
)
double
x
;
double
x
__attribute__
((
__unused__
))
;
{}
{}
int
foo
()
foo
()
{
{
static
int
table
[]
=
{
20
,
69
,
4
,
12
};
static
int
table
[]
=
{
20
,
69
,
4
,
12
};
...
@@ -98,7 +106,12 @@ extern void _start() __asm__("_start");
...
@@ -98,7 +106,12 @@ extern void _start() __asm__("_start");
extern
void
__start
()
__asm__
(
"__start"
);
extern
void
__start
()
__asm__
(
"__start"
);
/* Provide functions that might be needed by soft-float emulation routines. */
/* Provide functions that might be needed by soft-float emulation routines. */
void
memcpy
()
{}
void
*
memcpy
(
void
*
to
,
const
void
*
from
__attribute__
((
__unused__
)),
size_t
len
__attribute__
((
__unused__
)))
{
return
to
;
}
void
start
()
{}
void
start
()
{}
void
_start
()
{}
void
_start
()
{}
...
...
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