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
cc46ae8e
Commit
cc46ae8e
authored
Apr 07, 1998
by
Jeffrey A Law
Committed by
Jeff Law
Apr 07, 1998
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* pa.h (LEGITIMIZE_RELOAD_ADDRESS): Define.
From-SVN: r19036
parent
0b3d64d2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
62 additions
and
0 deletions
+62
-0
gcc/ChangeLog
+4
-0
gcc/config/pa/pa.h
+58
-0
No files found.
gcc/ChangeLog
View file @
cc46ae8e
Tue Apr 7 21:48:52 1998 Jeffrey A Law (law@cygnus.com)
* pa.h (LEGITIMIZE_RELOAD_ADDRESS): Define.
1998-04-07 Ken Raeburn <raeburn@cygnus.com>
1998-04-07 Ken Raeburn <raeburn@cygnus.com>
* config/mips/mips.c (siginfo): Deleted.
* config/mips/mips.c (siginfo): Deleted.
...
...
gcc/config/pa/pa.h
View file @
cc46ae8e
...
@@ -1615,6 +1615,64 @@ extern struct rtx_def *hppa_builtin_saveregs ();
...
@@ -1615,6 +1615,64 @@ extern struct rtx_def *hppa_builtin_saveregs ();
&& GET_CODE (XEXP (X, 1)) == UNSPEC) \
&& GET_CODE (XEXP (X, 1)) == UNSPEC) \
goto ADDR; \
goto ADDR; \
}
}
/* Look for machine dependent ways to make the invalid address AD a
valid address.
For the PA, transform:
memory(X + <large int>)
into:
if (<large int> & mask) >= 16
Y = (<large int> & ~mask) + mask + 1 Round up.
else
Y = (<large int> & ~mask) Round down.
Z = X + Y
memory (Z + (<large int> - Y));
This makes reload inheritance and reload_cse work better since Z
can be reused.
There may be more opportunities to improve code with this hook. */
#define LEGITIMIZE_RELOAD_ADDRESS(AD, MODE, OPNUM, TYPE, IND, WIN) \
do { \
int offset, newoffset, mask; \
mask = GET_MODE_CLASS (MODE) == MODE_FLOAT ? 0x1f : 0x3fff; \
\
if (GET_CODE (AD) == PLUS \
&& GET_CODE (XEXP (AD, 0)) == REG \
&& GET_CODE (XEXP (AD, 1)) == CONST_INT) \
{ \
offset = INTVAL (XEXP ((AD), 1)); \
\
/* Choose rounding direction. Round up if we are >= halfway. */
\
if ((offset & mask) >= ((mask + 1) / 2)) \
newoffset = (offset & ~mask) + mask + 1; \
else \
newoffset = offset & ~mask; \
\
if (newoffset != 0 \
&& VAL_14_BITS_P (newoffset)) \
{ \
rtx temp; \
\
/* Unshare the sum as well. */
\
AD = copy_rtx (AD); \
temp = gen_rtx_PLUS (Pmode, XEXP (AD, 0), \
GEN_INT (newoffset)); \
AD = gen_rtx_PLUS (Pmode, temp, GEN_INT (offset - newoffset));\
push_reload (XEXP (AD, 0), 0, &XEXP (AD, 0), 0, \
BASE_REG_CLASS, Pmode, VOIDmode, 0, 0, \
(OPNUM), (TYPE)); \
goto WIN; \
} \
} \
} while (0)
/* Try machine-dependent ways of modifying an illegitimate address
/* Try machine-dependent ways of modifying an illegitimate address
to be legitimate. If we find one, return the new, valid address.
to be legitimate. If we find one, return the new, valid address.
...
...
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