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
5bf6c0ef
Commit
5bf6c0ef
authored
Oct 25, 2017
by
Jaikrishnan Menon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
CPU: Hook PCH and debuginfo support to the build system
parent
c82d9e9e
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
7 deletions
+6
-7
CMakeLists.txt
src/ngraph/CMakeLists.txt
+4
-0
external_function.cpp
src/ngraph/runtime/cpu/external_function.cpp
+2
-7
No files found.
src/ngraph/CMakeLists.txt
View file @
5bf6c0ef
...
@@ -115,6 +115,10 @@ if(LLVM_INCLUDE_DIR)
...
@@ -115,6 +115,10 @@ if(LLVM_INCLUDE_DIR)
set_source_files_properties
(
codegen/compiler.cpp PROPERTIES COMPILE_FLAGS
"-fno-rtti"
)
set_source_files_properties
(
codegen/compiler.cpp PROPERTIES COMPILE_FLAGS
"-fno-rtti"
)
set_source_files_properties
(
codegen/compiler.cpp PROPERTIES COMPILE_DEFINITIONS
set_source_files_properties
(
codegen/compiler.cpp PROPERTIES COMPILE_DEFINITIONS
"EIGEN_HEADERS_PATH=
\"
${
EIGEN_INCLUDE_DIR
}
\"
;CLANG_BUILTIN_HEADERS_PATH=
\"
${
LLVM_LIB_DIR
}
/clang/5.0.0/include
\"
;NGRAPH_HEADERS_PATH=
\"
${
NGRAPH_INCLUDE_PATH
}
\"
"
)
"EIGEN_HEADERS_PATH=
\"
${
EIGEN_INCLUDE_DIR
}
\"
;CLANG_BUILTIN_HEADERS_PATH=
\"
${
LLVM_LIB_DIR
}
/clang/5.0.0/include
\"
;NGRAPH_HEADERS_PATH=
\"
${
NGRAPH_INCLUDE_PATH
}
\"
"
)
set
(
CPU_ENABLE_PCH 0 CACHE STRING
"Enable pre-compiled headers in the CPU backend"
)
set
(
CPU_ENABLE_DEBUGINFO 0 CACHE STRING
"Enable debuginfo in the CPU backend"
)
set_source_files_properties
(
runtime/cpu/external_function.cpp PROPERTIES COMPILE_DEFINITIONS
"NGCPU_PCH=
${
CPU_ENABLE_PCH
}
;NGCPU_DEBUGINFO=
${
CPU_ENABLE_DEBUGINFO
}
"
)
endif
()
endif
()
add_library
(
ngraph SHARED
${
SRC
}
)
add_library
(
ngraph SHARED
${
SRC
}
)
...
...
src/ngraph/runtime/cpu/external_function.cpp
View file @
5bf6c0ef
...
@@ -59,11 +59,6 @@
...
@@ -59,11 +59,6 @@
#include "ngraph/runtime/cpu/external_function.hpp"
#include "ngraph/runtime/cpu/external_function.hpp"
#include "ngraph/runtime/utils.hpp"
#include "ngraph/runtime/utils.hpp"
// TODO: Decide if we want to ship this or
// just enable it for developer build-test cycles
//#define NGCPU_PCH
//#define NGCPU_DEBUGINFO
using
namespace
std
;
using
namespace
std
;
using
namespace
ngraph
::
runtime
::
cpu
;
using
namespace
ngraph
::
runtime
::
cpu
;
...
@@ -249,11 +244,11 @@ extern "C" void __entrypoint(ngraph::runtime::cpu::CallFrame* call_frame,
...
@@ -249,11 +244,11 @@ extern "C" void __entrypoint(ngraph::runtime::cpu::CallFrame* call_frame,
ngraph
::
codegen
::
execution_state
estate
;
ngraph
::
codegen
::
execution_state
estate
;
#if
defined(NGCPU_PCH)
#if
NGCPU_PCH
estate
.
enable_pch
();
estate
.
enable_pch
();
#endif
#endif
#if
defined(NGCPU_DEBUGINFO)
#if
NGCPU_DEBUGINFO
estate
.
enable_debuginfo
();
estate
.
enable_debuginfo
();
#endif
#endif
...
...
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