Commit 4fbc2575 authored by Paul's avatar Paul
Browse files

Use context sync as well

parent add5ea47
...@@ -10,7 +10,11 @@ namespace migraphx { ...@@ -10,7 +10,11 @@ namespace migraphx {
inline namespace MIGRAPHX_INLINE_NS { inline namespace MIGRAPHX_INLINE_NS {
namespace gpu { namespace gpu {
void gpu_sync() { hipDeviceSynchronize(); } void gpu_sync()
{
hipDeviceSynchronize();
hipCtxSynchronize();
}
using hip_ptr = MIGRAPHX_MANAGE_PTR(void, hipFree); using hip_ptr = MIGRAPHX_MANAGE_PTR(void, hipFree);
......
...@@ -34,8 +34,7 @@ struct hip_device ...@@ -34,8 +34,7 @@ struct hip_device
static hip_stream_ptr create_stream() static hip_stream_ptr create_stream()
{ {
hipStream_t result = nullptr; hipStream_t result = nullptr;
auto status = hipStreamCreate(&result); auto status = hipStreamCreateWithFlags(&result, hipStreamNonBlocking);
// auto status = hipStreamCreateWithFlags(&result, hipStreamNonBlocking);
if(status != hipSuccess) if(status != hipSuccess)
MIGRAPHX_THROW("Failed to allocate stream"); MIGRAPHX_THROW("Failed to allocate stream");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment