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
6680889f
Commit
6680889f
authored
Feb 27, 1994
by
Richard Kenner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(qty_compare{,_1}): Give multi-word regs higher priority, as stated in
the comments. From-SVN: r6649
parent
0a5152d0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
8 deletions
+10
-8
gcc/local-alloc.c
+10
-8
No files found.
gcc/local-alloc.c
View file @
6680889f
...
...
@@ -1503,12 +1503,12 @@ qty_compare (q1, q2)
times a register can occur in one insn (surely less than 100).
Multiplying this by 10000 can't overflow. */
register
int
pri1
=
(((
double
)
(
floor_log2
(
qty_n_refs
[
q1
])
*
qty_n_refs
[
q1
])
/
(
(
qty_death
[
q1
]
-
qty_birth
[
q1
])
*
qty_size
[
q1
]))
=
(((
double
)
(
floor_log2
(
qty_n_refs
[
q1
])
*
qty_n_refs
[
q1
]
*
qty_size
[
q1
]
)
/
(
qty_death
[
q1
]
-
qty_birth
[
q1
]))
*
10000
);
register
int
pri2
=
(((
double
)
(
floor_log2
(
qty_n_refs
[
q2
])
*
qty_n_refs
[
q2
])
/
(
(
qty_death
[
q2
]
-
qty_birth
[
q2
])
*
qty_size
[
q2
]))
=
(((
double
)
(
floor_log2
(
qty_n_refs
[
q2
])
*
qty_n_refs
[
q2
]
*
qty_size
[
q2
]
)
/
(
qty_death
[
q2
]
-
qty_birth
[
q2
]))
*
10000
);
return
pri2
-
pri1
;
}
...
...
@@ -1524,12 +1524,14 @@ qty_compare_1 (q1, q2)
times a register can occur in one insn (surely less than 100).
Multiplying this by 10000 can't overflow. */
register
int
pri1
=
(((
double
)
(
floor_log2
(
qty_n_refs
[
*
q1
])
*
qty_n_refs
[
*
q1
])
/
((
qty_death
[
*
q1
]
-
qty_birth
[
*
q1
])
*
qty_size
[
*
q1
]))
=
(((
double
)
(
floor_log2
(
qty_n_refs
[
*
q1
])
*
qty_n_refs
[
*
q1
]
*
qty_size
[
*
q1
])
/
(
qty_death
[
*
q1
]
-
qty_birth
[
*
q1
]))
*
10000
);
register
int
pri2
=
(((
double
)
(
floor_log2
(
qty_n_refs
[
*
q2
])
*
qty_n_refs
[
*
q2
])
/
((
qty_death
[
*
q2
]
-
qty_birth
[
*
q2
])
*
qty_size
[
*
q2
]))
=
(((
double
)
(
floor_log2
(
qty_n_refs
[
*
q2
])
*
qty_n_refs
[
*
q2
]
*
qty_size
[
*
q2
])
/
(
qty_death
[
*
q2
]
-
qty_birth
[
*
q2
]))
*
10000
);
tem
=
pri2
-
pri1
;
...
...
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