Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
loopy
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
Model registry
Operate
Environments
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
Ben Sepanski
loopy
Commits
fde0acae
Commit
fde0acae
authored
13 years ago
by
Tim Warburton
Browse files
Options
Downloads
Patches
Plain Diff
Remove old, unused code from CSE generation.
parent
4f6b046c
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
loopy/cse.py
+0
-50
0 additions, 50 deletions
loopy/cse.py
with
0 additions
and
50 deletions
loopy/cse.py
+
0
−
50
View file @
fde0acae
...
@@ -520,55 +520,5 @@ def realize_cse(kernel, cse_tag, dtype, independent_inames=[],
...
@@ -520,55 +520,5 @@ def realize_cse(kernel, cse_tag, dtype, independent_inames=[],
def
realize_cse_old
(
kernel
,
cse_tag
,
dtype
,
duplicate_inames
=
[],
parallel_inames
=
None
,
dup_iname_to_tag
=
{},
new_inames
=
None
,
default_tag_class
=
AutoFitLocalIndexTag
):
"""
:arg duplicate_inames: which inames are supposed to be separate loops
in the CSE. Also determines index order of temporary array.
:arg parallel_inames: only a convenient interface for dup_iname_to_tag
"""
dtype
=
np
.
dtype
(
dtype
)
cse_lookup_table
=
[]
cse_result_insns
=
[]
def
map_cse
(
cse
,
rec
):
# {{{ concoct new inner and outer expressions
# }}}
cse_result_insns
.
append
(
new_insn
)
cse_lookup_table
.
append
((
cse
.
child
,
new_outer_expr
))
return
new_outer_expr
from
loopy.symbolic
import
CSECallbackMapper
cse_cb_mapper
=
CSECallbackMapper
(
map_cse
)
new_insns
=
[]
for
insn
in
kernel
.
instructions
:
was_empty
=
not
bool
(
cse_result_insns
)
new_expr
=
cse_cb_mapper
(
insn
.
expression
)
if
was_empty
and
cse_result_insns
:
new_insns
.
append
(
insn
.
copy
(
expression
=
new_expr
))
else
:
new_insns
.
append
(
insn
)
new_insns
.
extend
(
cse_result_insns
)
# build new domain, duplicating each constraint on duplicated inames
new_iname_to_tag
=
kernel
.
iname_to_tag
.
copy
()
for
old_iname
,
new_iname
in
zip
(
duplicate_inames
,
new_inames
):
new_iname_to_tag
[
new_iname
]
=
dup_iname_to_tag
[
old_iname
]
# vim: foldmethod=marker
# vim: foldmethod=marker
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