Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dune-codegen
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
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
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
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
Christian Heinigk
dune-codegen
Commits
b4c1beab
Commit
b4c1beab
authored
6 years ago
by
Dominic Kempf
Browse files
Options
Downloads
Patches
Plain Diff
[skip ci] more fixup of autotune setup
parent
9400453f
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
python/dune/codegen/sumfact/autotune.py
+4
-4
4 additions, 4 deletions
python/dune/codegen/sumfact/autotune.py
with
4 additions
and
4 deletions
python/dune/codegen/sumfact/autotune.py
+
4
−
4
View file @
b4c1beab
...
@@ -194,10 +194,10 @@ def autotune_realization(sf):
...
@@ -194,10 +194,10 @@ def autotune_realization(sf):
basename
=
"
autotune_sumfact_{}
"
.
format
(
sf
.
function_name
)
basename
=
"
autotune_sumfact_{}
"
.
format
(
sf
.
function_name
)
basename
=
hashlib
.
sha256
(
basename
.
encode
()).
hexdigest
()
basename
=
hashlib
.
sha256
(
basename
.
encode
()).
hexdigest
()
basename
=
os
.
path
.
join
(
dir
,
basename
)
filename
=
os
.
path
.
join
(
dir
,
"
{}.cc
"
.
format
(
basename
))
filename
=
os
.
path
.
join
(
dir
,
"
{}.cc
"
.
format
(
basename
))
logname
=
os
.
path
.
join
(
dir
,
"
{}.log
"
.
format
(
basename
))
logname
=
os
.
path
.
join
(
dir
,
"
{}.log
"
.
format
(
basename
))
lock
=
"
{}.lock
"
.
format
(
basename
)
lock
=
os
.
path
.
join
(
dir
,
"
{}.lock
"
.
format
(
basename
)
)
# Generate and compile a benchmark program
# Generate and compile a benchmark program
with
cache_restoring
():
with
cache_restoring
():
...
@@ -205,7 +205,7 @@ def autotune_realization(sf):
...
@@ -205,7 +205,7 @@ def autotune_realization(sf):
if
not
os
.
path
.
isfile
(
logname
):
if
not
os
.
path
.
isfile
(
logname
):
generate_standalone_code
(
sf
,
filename
)
generate_standalone_code
(
sf
,
filename
)
ret
=
subprocess
.
call
(
compiler_invocation
(
name
,
filename
))
ret
=
subprocess
.
call
(
compiler_invocation
(
base
name
,
filename
))
if
ret
!=
0
:
if
ret
!=
0
:
raise
CodegenAutotuneError
(
"
Compilation of autotune executable failed. Invocation: {}
"
.
format
(
"
"
.
join
(
compiler_invocation
(
name
,
filename
))))
raise
CodegenAutotuneError
(
"
Compilation of autotune executable failed. Invocation: {}
"
.
format
(
"
"
.
join
(
compiler_invocation
(
name
,
filename
))))
...
@@ -216,7 +216,7 @@ def autotune_realization(sf):
...
@@ -216,7 +216,7 @@ def autotune_realization(sf):
call
.
append
(
wrapper
)
call
.
append
(
wrapper
)
# Run the benchmark program
# Run the benchmark program
call
.
append
(
name
)
call
.
append
(
base
name
)
call
.
append
(
logname
)
call
.
append
(
logname
)
devnull
=
open
(
os
.
devnull
,
'
w
'
)
devnull
=
open
(
os
.
devnull
,
'
w
'
)
ret
=
subprocess
.
call
(
call
,
stdout
=
devnull
,
stderr
=
subprocess
.
STDOUT
)
ret
=
subprocess
.
call
(
call
,
stdout
=
devnull
,
stderr
=
subprocess
.
STDOUT
)
...
...
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