Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
tsoc
openmm
Commits
bdc8f29e
Commit
bdc8f29e
authored
Sep 02, 2016
by
Peter Eastman
Browse files
If temp directory does not exist, use runtime compiler
parent
3e974a97
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
platforms/cuda/src/CudaContext.cpp
platforms/cuda/src/CudaContext.cpp
+3
-1
No files found.
platforms/cuda/src/CudaContext.cpp
View file @
bdc8f29e
...
@@ -52,6 +52,7 @@
...
@@ -52,6 +52,7 @@
#include <set>
#include <set>
#include <sstream>
#include <sstream>
#include <typeinfo>
#include <typeinfo>
#include <sys/stat.h>
#include <cudaProfiler.h>
#include <cudaProfiler.h>
#ifndef WIN32
#ifndef WIN32
#include <unistd.h>
#include <unistd.h>
...
@@ -127,7 +128,8 @@ CudaContext::CudaContext(const System& system, int deviceIndex, bool useBlocking
...
@@ -127,7 +128,8 @@ CudaContext::CudaContext(const System& system, int deviceIndex, bool useBlocking
string
testCompilerCommand
=
this
->
compiler
+
" --version > /dev/null 2> /dev/null"
;
string
testCompilerCommand
=
this
->
compiler
+
" --version > /dev/null 2> /dev/null"
;
int
res
=
std
::
system
(
testCompilerCommand
.
c_str
());
int
res
=
std
::
system
(
testCompilerCommand
.
c_str
());
#endif
#endif
isNvccAvailable
=
(
res
==
0
);
struct
stat
info
;
isNvccAvailable
=
(
res
==
0
&&
stat
(
tempDir
.
c_str
(),
&
info
)
==
0
);
static
bool
hasShownNvccWarning
=
false
;
static
bool
hasShownNvccWarning
=
false
;
if
(
hasCompilerKernel
&&
!
isNvccAvailable
&&
!
hasShownNvccWarning
)
{
if
(
hasCompilerKernel
&&
!
isNvccAvailable
&&
!
hasShownNvccWarning
)
{
hasShownNvccWarning
=
true
;
hasShownNvccWarning
=
true
;
...
...
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