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
35d4ce90
Unverified
Commit
35d4ce90
authored
May 29, 2026
by
Tom Benson
Committed by
GitHub
May 29, 2026
Browse files
Handle hipErrorFileNotFound gracefully in ROCm 7 (#5303)
parent
fc21fd19
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
1 deletion
+11
-1
platforms/hip/src/HipContext.cpp
platforms/hip/src/HipContext.cpp
+11
-1
No files found.
platforms/hip/src/HipContext.cpp
View file @
35d4ce90
...
...
@@ -184,7 +184,7 @@ HipContext::HipContext(const System& system, int deviceIndex, bool useBlockingSy
hostMallocFlags
=
hipHostMallocDefault
;
#if !defined(WIN32)
// hipHostMallocNumaUser may not be allowed in some conditions, for example, if docker container
// hipHostMallocNumaUser may not be allowed in some conditions, for example, if docker container
// is created without --security-opt seccomp=unconfined or --cap-add=SYS_NICE
int
*
tmpHostBuffer
;
if
(
hipHostMalloc
(
&
tmpHostBuffer
,
sizeof
(
*
tmpHostBuffer
),
hipHostMallocNumaUser
)
==
hipSuccess
)
{
...
...
@@ -589,6 +589,16 @@ hipModule_t HipContext::createModule(const string source, const map<string, stri
loadedModules
.
push_back
(
module
);
return
module
;
}
else
{
// Need to call hipGetLastError to clear the error code
hipError_t
last_error
=
hipGetLastError
();
if
(
last_error
!=
hipErrorFileNotFound
)
{
std
::
ostringstream
msg
;
msg
<<
"Detected HIP error: "
<<
hipGetErrorString
(
last_error
)
<<
"("
<<
last_error
<<
") at "
<<
__FILE__
<<
":"
<<
__LINE__
;
throw
OpenMMException
(
msg
.
str
());
}
}
// Select names for the various temporary files.
...
...
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