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
84c52463
Commit
84c52463
authored
12 years ago
by
Andreas Klöckner
Browse files
Options
Downloads
Patches
Plain Diff
Fix a few isl parameter domain screwups.
parent
b955f7c4
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
loopy/check.py
+7
-3
7 additions, 3 deletions
loopy/check.py
loopy/codegen/__init__.py
+1
-1
1 addition, 1 deletion
loopy/codegen/__init__.py
loopy/kernel.py
+3
-3
3 additions, 3 deletions
loopy/kernel.py
with
11 additions
and
7 deletions
loopy/check.py
+
7
−
3
View file @
84c52463
from
__future__
import
division
from
islpy
import
dim_type
import
islpy
as
isl
...
...
@@ -219,15 +220,18 @@ def check_implemented_domains(kernel, implemented_domains):
insn_impl_domain
=
idomains
[
0
]
for
idomain
in
idomains
[
1
:]:
insn_impl_domain
=
insn_impl_domain
|
idomain
assumptions
=
align_spaces
(
kernel
.
assumptions
,
insn_impl_domain
,
obj_bigger_ok
=
True
)
assumption_non_param
=
isl
.
BasicSet
.
from_params
(
kernel
.
assumptions
)
assumptions
=
align_spaces
(
assumption_non_param
,
insn_impl_domain
,
obj_bigger_ok
=
True
)
insn_impl_domain
=
(
(
insn_impl_domain
&
assumptions
)
.
project_out_except
(
kernel
.
insn_inames
(
insn
),
[
dim_type
.
set
]))
insn_inames
=
kernel
.
insn_inames
(
insn
)
insn_domain
=
kernel
.
get_inames_domain
(
insn_inames
)
assumptions
=
align_spaces
(
kernel
.
assumptions
,
insn_domain
,
assumptions
=
align_spaces
(
assumption_non_param
,
insn_domain
,
obj_bigger_ok
=
True
)
desired_domain
=
((
insn_domain
&
assumptions
)
.
project_out_except
(
kernel
.
insn_inames
(
insn
),
[
dim_type
.
set
]))
...
...
This diff is collapsed.
Click to expand it.
loopy/codegen/__init__.py
+
1
−
1
View file @
84c52463
...
...
@@ -292,7 +292,7 @@ def generate_code(kernel, with_annotation=False,
# }}}
initial_implemented_domain
=
kernel
.
assumptions
initial_implemented_domain
=
isl
.
BasicSet
.
from_params
(
kernel
.
assumptions
)
codegen_state
=
CodeGenerationState
(
initial_implemented_domain
,
c_code_mapper
=
ccm
)
from
loopy.codegen.loop
import
set_up_hw_parallel_loops
...
...
This diff is collapsed.
Click to expand it.
loopy/kernel.py
+
3
−
3
View file @
84c52463
...
...
@@ -915,7 +915,7 @@ class LoopKernel(Record):
for
i
in
xrange
(
dom0_space
.
dim
(
dim_type
.
param
)):
assumptions_space
=
assumptions_space
.
set_dim_name
(
dim_type
.
param
,
i
,
dom0_space
.
get_dim_name
(
dim_type
.
param
,
i
))
assumptions
=
isl
.
Set
.
universe
(
assumptions_space
)
assumptions
=
isl
.
Basic
Set
.
universe
(
assumptions_space
)
elif
isinstance
(
assumptions
,
str
):
all_inames
=
set
()
...
...
@@ -1144,8 +1144,8 @@ class LoopKernel(Record):
assert
isinstance
(
domains
,
tuple
)
# for caching
if
not
domains
:
return
isl
.
BasicSet
.
universe
(
isl
.
Space
.
alloc
(
self
.
isl_context
,
0
,
0
,
0
))
return
isl
.
BasicSet
.
universe
(
isl
.
Space
.
set_
alloc
(
self
.
isl_context
,
0
,
0
))
result
=
None
for
dom_index
in
domains
:
...
...
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