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
26caf960
Commit
26caf960
authored
May 01, 2005
by
Kazu Hirata
Committed by
Kazu Hirata
May 01, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* global.c (calculate_reg_pav): Use VEC instead of VARRAY.
From-SVN: r99085
parent
ec234842
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
9 deletions
+16
-9
gcc/ChangeLog
+2
-0
gcc/global.c
+14
-9
No files found.
gcc/ChangeLog
View file @
26caf960
...
...
@@ -3,6 +3,8 @@
* gimplify.c (gimplify_compound_lval): Use VEC instead of
VARRAY.
* global.c (calculate_reg_pav): Use VEC instead of VARRAY.
2005-05-01 Mark Mitchell <mark@codesourcery.com>
PR C++/14391
...
...
gcc/global.c
View file @
26caf960
...
...
@@ -2292,6 +2292,9 @@ rpost_cmp (const void *bb1, const void *bb2)
/* Temporary bitmap used for live_pavin, live_pavout calculation. */
static
bitmap
temp_bitmap
;
DEF_VEC_P
(
basic_block
);
DEF_VEC_ALLOC_P
(
basic_block
,
heap
);
/* The function calculates partial register availability according to
the following equations:
...
...
@@ -2307,22 +2310,22 @@ calculate_reg_pav (void)
basic_block
bb
,
succ
;
edge
e
;
int
i
,
nel
;
varray_type
bbs
,
new_bbs
,
temp
;
VEC
(
basic_block
,
heap
)
*
bbs
,
*
new_bbs
,
*
temp
;
basic_block
*
bb_array
;
sbitmap
wset
;
VARRAY_BB_INIT
(
bbs
,
n_basic_blocks
,
"basic blocks"
);
VARRAY_BB_INIT
(
new_bbs
,
n_basic_blocks
,
"basic blocks for the next iter."
);
bbs
=
VEC_alloc
(
basic_block
,
heap
,
n_basic_blocks
);
new_bbs
=
VEC_alloc
(
basic_block
,
heap
,
n_basic_blocks
);
temp_bitmap
=
BITMAP_ALLOC
(
NULL
);
FOR_EACH_BB
(
bb
)
{
V
ARRAY_PUSH_BB
(
bbs
,
bb
);
V
EC_quick_push
(
basic_block
,
bbs
,
bb
);
}
wset
=
sbitmap_alloc
(
n_basic_blocks
+
1
);
while
(
V
ARRAY_ACTIVE_SIZE
(
bbs
))
while
(
V
EC_length
(
basic_block
,
bbs
))
{
bb_array
=
&
VARRAY_BB
(
bbs
,
0
);
nel
=
V
ARRAY_ACTIVE_SIZE
(
bbs
);
bb_array
=
VEC_address
(
basic_block
,
bbs
);
nel
=
V
EC_length
(
basic_block
,
bbs
);
qsort
(
bb_array
,
nel
,
sizeof
(
basic_block
),
rpost_cmp
);
sbitmap_zero
(
wset
);
for
(
i
=
0
;
i
<
nel
;
i
++
)
...
...
@@ -2356,7 +2359,7 @@ calculate_reg_pav (void)
&&
!
TEST_BIT
(
wset
,
succ
->
index
))
{
SET_BIT
(
wset
,
succ
->
index
);
V
ARRAY_PUSH_BB
(
new_bbs
,
succ
);
V
EC_quick_push
(
basic_block
,
new_bbs
,
succ
);
}
}
}
...
...
@@ -2364,10 +2367,12 @@ calculate_reg_pav (void)
temp
=
bbs
;
bbs
=
new_bbs
;
new_bbs
=
temp
;
V
ARRAY_POP_ALL
(
new_bbs
);
V
EC_truncate
(
basic_block
,
new_bbs
,
0
);
}
sbitmap_free
(
wset
);
BITMAP_FREE
(
temp_bitmap
);
VEC_free
(
basic_block
,
heap
,
new_bbs
);
VEC_free
(
basic_block
,
heap
,
bbs
);
}
/* The function modifies partial availability information for two
...
...
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