Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
N
ngraph
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
ngraph
Commits
505a0c3d
Unverified
Commit
505a0c3d
authored
Jul 09, 2019
by
Scott Cyphers
Committed by
GitHub
Jul 09, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #3182 from NervanaSystems/pruthvi/fix_segfautl_mem_allocator
Fix Onnx CI seg fault
parents
68d4d196
ae0c80e9
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
4 deletions
+5
-4
allocator.cpp
src/ngraph/runtime/allocator.cpp
+3
-2
allocator.hpp
src/ngraph/runtime/allocator.hpp
+1
-1
cpu_backend.cpp
src/ngraph/runtime/cpu/cpu_backend.cpp
+1
-1
No files found.
src/ngraph/runtime/allocator.cpp
View file @
505a0c3d
...
@@ -49,7 +49,8 @@ public:
...
@@ -49,7 +49,8 @@ public:
}
}
};
};
std
::
unique_ptr
<
ngraph
::
runtime
::
Allocator
>
ngraph
::
runtime
::
create
_default_allocator
()
ngraph
::
runtime
::
Allocator
*
ngraph
::
runtime
::
get
_default_allocator
()
{
{
return
std
::
unique_ptr
<
DefaultAllocator
>
(
new
DefaultAllocator
());
static
std
::
unique_ptr
<
DefaultAllocator
>
allocator
(
new
DefaultAllocator
());
return
allocator
.
get
();
}
}
src/ngraph/runtime/allocator.hpp
View file @
505a0c3d
...
@@ -30,7 +30,7 @@ namespace ngraph
...
@@ -30,7 +30,7 @@ namespace ngraph
class
DefaultAllocator
;
class
DefaultAllocator
;
/// \brief Create a default allocator that calls into system
/// \brief Create a default allocator that calls into system
/// allocation libraries
/// allocation libraries
std
::
unique_ptr
<
Allocator
>
create
_default_allocator
();
ngraph
::
runtime
::
Allocator
*
get
_default_allocator
();
}
}
}
}
...
...
src/ngraph/runtime/cpu/cpu_backend.cpp
View file @
505a0c3d
...
@@ -185,7 +185,7 @@ runtime::Allocator* runtime::cpu::CPU_Backend::get_host_memory_allocator()
...
@@ -185,7 +185,7 @@ runtime::Allocator* runtime::cpu::CPU_Backend::get_host_memory_allocator()
{
{
if
(
!
m_allocator
)
if
(
!
m_allocator
)
{
{
m_allocator
=
create
_default_allocator
();
return
runtime
::
get
_default_allocator
();
}
}
return
m_allocator
.
get
();
return
m_allocator
.
get
();
}
}
...
...
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