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
815cdc52
Commit
815cdc52
authored
Jan 22, 1999
by
Michael Meissner
Committed by
Michael Meissner
Jan 22, 1999
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use alternate crs if cr0 not available
From-SVN: r24821
parent
d062c304
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
60 additions
and
13 deletions
+60
-13
gcc/ChangeLog
+25
-0
gcc/config/rs6000/rs6000.c
+21
-7
gcc/config/rs6000/rs6000.h
+11
-3
gcc/config/rs6000/rs6000.md
+0
-0
gcc/config/rs6000/sysv4.h
+3
-3
No files found.
gcc/ChangeLog
View file @
815cdc52
1999
-
01
-
22
Michael
Meissner
<
meissner
@cygnus
.
com
>
*
rs6000
.
h
(
CR0_REGNO_P
)
:
New
macro
to
test
if
cr0
.
(
CR_REGNO_NOT_CR0_P
)
:
New
macro
to
test
if
cr
,
but
not
cr0
.
(
PREDICATE_CODES
)
:
Add
cc_reg_not_cr0_operand
.
(
cc_reg_not_cr0_operand
)
:
Add
declaration
.
*
rs6000
.
c
(
cc_reg_not_cr0_operand
)
:
Return
true
if
register
is
a
pseudo
register
,
or
a
control
register
that
is
not
CR0
.
*
rs6000
.
md
(
all
combiner
patterns
building
.
instructions
)
:
For
all
`
.
'
instructions
that
do
something
and
set
cr0
,
add
an
alternative
that
does
the
operation
,
and
then
sets
a
different
flag
,
in
order
to
avoid
using
the
costly
mcrf
instruction
and
also
allow
cr0
to
be
clobbered
in
asm
statements
.
Also
fix
a
few
patterns
that
used
the
wrong
register
.
*
rs6000
.
h
(
rs6000_cpu_select
)
:
Make
string
,
names
be
const
char
*
.
(
rs6000_debug_name
)
:
Make
const
char
*
,
not
char
*
.
*
sysv4
.
h
(
rs6000_
{
abi
,
sdata
}
_name
)
:
Make
const
char
*
.
*
rs6000
.
c
(
rs6000_
{
debug
,
abi
,
sdata
}
_name
)
:
Make
const
char
*
.
(
rs6000_select
)
:
Use
const
char
*
in
casts
.
Fri
Jan
22
07
:
43
:
01
1999
Jeffrey
A
Law
(
law
@cygnus
.
com
)
*
Makefile
.
in
(
gcc_tooldir
)
:
Move
before
first
reference
.
...
...
gcc/config/rs6000/rs6000.c
View file @
815cdc52
...
...
@@ -54,10 +54,10 @@ extern int profile_block_flag;
enum
processor_type
rs6000_cpu
;
struct
rs6000_cpu_select
rs6000_select
[
3
]
=
{
/* switch name, tune arch */
{
(
char
*
)
0
,
"--with-cpu="
,
1
,
1
},
{
(
char
*
)
0
,
"-mcpu="
,
1
,
1
},
{
(
char
*
)
0
,
"-mtune="
,
1
,
0
},
/* switch
name, tune arch */
{
(
c
onst
c
har
*
)
0
,
"--with-cpu="
,
1
,
1
},
{
(
c
onst
c
har
*
)
0
,
"-mcpu="
,
1
,
1
},
{
(
c
onst
c
har
*
)
0
,
"-mtune="
,
1
,
0
},
};
/* Set to non-zero by "fix" operation to indicate that itrunc and
...
...
@@ -84,13 +84,13 @@ int rs6000_pic_labelno;
int
rs6000_pic_func_labelno
;
/* Which abi to adhere to */
char
*
rs6000_abi_name
=
RS6000_ABI_NAME
;
c
onst
c
har
*
rs6000_abi_name
=
RS6000_ABI_NAME
;
/* Semantics of the small data area */
enum
rs6000_sdata_type
rs6000_sdata
=
SDATA_DATA
;
/* Which small data model to use */
char
*
rs6000_sdata_name
=
(
char
*
)
0
;
c
onst
c
har
*
rs6000_sdata_name
=
(
char
*
)
0
;
#endif
/* Whether a System V.4 varargs area was created. */
...
...
@@ -105,7 +105,7 @@ int rs6000_fpmem_offset;
int
rs6000_fpmem_size
;
/* Debug flags */
char
*
rs6000_debug_name
;
c
onst
c
har
*
rs6000_debug_name
;
int
rs6000_debug_stack
;
/* debug stack applications */
int
rs6000_debug_arg
;
/* debug argument handling */
...
...
@@ -559,6 +559,20 @@ cc_reg_operand (op, mode)
||
CR_REGNO_P
(
REGNO
(
op
))));
}
/* Returns 1 if OP is either a pseudo-register or a register denoting a
CR field that isn't CR0. */
int
cc_reg_not_cr0_operand
(
op
,
mode
)
register
rtx
op
;
enum
machine_mode
mode
;
{
return
(
register_operand
(
op
,
mode
)
&&
(
GET_CODE
(
op
)
!=
REG
||
REGNO
(
op
)
>=
FIRST_PSEUDO_REGISTER
||
CR_REGNO_NOT_CR0_P
(
REGNO
(
op
))));
}
/* Returns 1 if OP is either a constant integer valid for a D-field or a
non-special register. If a register, it must be in the proper mode unless
MODE is VOIDmode. */
...
...
gcc/config/rs6000/rs6000.h
View file @
815cdc52
...
...
@@ -461,8 +461,8 @@ extern enum processor_type rs6000_cpu;
/* rs6000_select[0] is reserved for the default cpu defined via --with-cpu */
struct
rs6000_cpu_select
{
char
*
string
;
char
*
name
;
c
onst
c
har
*
string
;
c
onst
c
har
*
name
;
int
set_tune_p
;
int
set_arch_p
;
};
...
...
@@ -470,7 +470,7 @@ struct rs6000_cpu_select
extern
struct
rs6000_cpu_select
rs6000_select
[];
/* Debug support */
extern
char
*
rs6000_debug_name
;
/* Name for -mdebug-xxxx option */
extern
c
onst
c
har
*
rs6000_debug_name
;
/* Name for -mdebug-xxxx option */
extern
int
rs6000_debug_stack
;
/* debug stack applications */
extern
int
rs6000_debug_arg
;
/* debug argument handling */
...
...
@@ -765,6 +765,12 @@ extern int rs6000_debug_arg; /* debug argument handling */
/* True if register is a condition register. */
#define CR_REGNO_P(N) ((N) >= 68 && (N) <= 75)
/* True if register is condition register 0. */
#define CR0_REGNO_P(N) ((N) == 68)
/* True if register is a condition register, but not cr0. */
#define CR_REGNO_NOT_CR0_P(N) ((N) >= 69 && (N) <= 75)
/* True if register is an integer register. */
#define INT_REGNO_P(N) ((N) <= 31 || (N) == 67)
...
...
@@ -3208,6 +3214,7 @@ do { \
{"non_short_cint_operand", {CONST_INT}}, \
{"gpc_reg_operand", {SUBREG, REG}}, \
{"cc_reg_operand", {SUBREG, REG}}, \
{"cc_reg_not_cr0_operand", {SUBREG, REG}}, \
{"reg_or_short_operand", {SUBREG, REG, CONST_INT}}, \
{"reg_or_neg_short_operand", {SUBREG, REG, CONST_INT}}, \
{"reg_or_u_short_operand", {SUBREG, REG, CONST_INT}}, \
...
...
@@ -3272,6 +3279,7 @@ extern int u_short_cint_operand ();
extern
int
non_short_cint_operand
();
extern
int
gpc_reg_operand
();
extern
int
cc_reg_operand
();
extern
int
cc_reg_not_cr0_operand
();
extern
int
reg_or_short_operand
();
extern
int
reg_or_neg_short_operand
();
extern
int
reg_or_u_short_operand
();
...
...
gcc/config/rs6000/rs6000.md
View file @
815cdc52
This source diff could not be displayed because it is too large. You can
view the blob
instead.
gcc/config/rs6000/sysv4.h
View file @
815cdc52
/* Target definitions for GNU compiler for PowerPC running System V.4
Copyright (C) 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
Copyright (C) 1995, 1996, 1997, 1998
, 1999
Free Software Foundation, Inc.
Contributed by Cygnus Support.
This file is part of GNU CC.
...
...
@@ -107,8 +107,8 @@ extern enum rs6000_sdata_type rs6000_sdata;
#define RS6000_ABI_NAME "sysv"
/* Strings provided by SUBTARGET_OPTIONS */
extern
char
*
rs6000_abi_name
;
extern
char
*
rs6000_sdata_name
;
extern
c
onst
c
har
*
rs6000_abi_name
;
extern
c
onst
c
har
*
rs6000_sdata_name
;
#define SUBTARGET_OPTIONS \
{ "call-", &rs6000_abi_name}, \
...
...
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