Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
Hercules
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
llvm
Hercules
Commits
3c8eaae2
Commit
3c8eaae2
authored
4 weeks ago
by
Aaron Councilman
Browse files
Options
Downloads
Patches
Plain Diff
add_node only adds to def use map if not already present
parent
205e68e2
No related branches found
No related tags found
1 merge request
!205
Fork reshape
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
hercules_opt/src/editor.rs
+1
-1
1 addition, 1 deletion
hercules_opt/src/editor.rs
with
1 addition
and
1 deletion
hercules_opt/src/editor.rs
+
1
−
1
View file @
3c8eaae2
...
...
@@ -457,7 +457,7 @@ impl<'a, 'b> FunctionEdit<'a, 'b> {
pub
fn
add_node
(
&
mut
self
,
node
:
Node
)
->
NodeID
{
let
id
=
NodeID
::
new
(
self
.num_node_ids
());
// Added nodes need to have an entry in the def-use map.
self
.updated_def_use
.insert
(
id
,
HashSet
::
new
());
self
.updated_def_use
.
entry
(
id
)
.or_
insert
(
HashSet
::
new
());
// Added nodes use other nodes, and we need to update their def-use
// entries.
for
u
in
get_uses
(
&
node
)
.as_ref
()
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment