Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Old compilers do not like this: #7

Open
rschoene opened this issue Aug 15, 2018 · 1 comment
Open

Old compilers do not like this: #7

rschoene opened this issue Aug 15, 2018 · 1 comment
Assignees

Comments

@rschoene
Copy link
Member

Hi,

The things that needed to be done to get this working with icc 2016 (welcome to the HPC world, where the tools are old and the build procedures are scary). Please check whether you can do sth from it.

diff --git a/extern/scorep_plugin_cxx_wrapper b/extern/scorep_plugin_cxx_wrapper
--- a/extern/scorep_plugin_cxx_wrapper
+++ b/extern/scorep_plugin_cxx_wrapper
@@ -1 +1 @@
-Subproject commit 74401d74e634f528b1dff1438f7c3baf488cc0f0
+Subproject commit 74401d74e634f528b1dff1438f7c3baf488cc0f0-dirty
diff --git a/src/x86_energy_measurement_thread.cpp b/src/x86_energy_measurement_thread.cpp
index 035378f..8aa2e2c 100644
--- a/src/x86_energy_measurement_thread.cpp
+++ b/src/x86_energy_measurement_thread.cpp
@@ -5,6 +5,8 @@
  *      Author: gocht
  */
 
+#include <type_traits>
+
 #include <x86_energy_measurement_thread.hpp>
 
 x86_energy_measurement_thread::x86_energy_measurement_thread(std::chrono::microseconds intervall_)
diff --git a/src/x86_energy_plugin.cpp b/src/x86_energy_plugin.cpp
index 10f34a0..85c9724 100644
--- a/src/x86_energy_plugin.cpp
+++ b/src/x86_energy_plugin.cpp
@@ -60,7 +60,10 @@ x86_energy_plugin::x86_energy_plugin()
         {
             source.init();
             logging::debug() << "Add Source: " << source.name();
-            active_sources.push_back(std::make_unique<x86_energy::AccessSource>(std::move(source)));
+            active_sources.push_back(
+               std::unique_ptr<x86_energy::AccessSource> { 
+                  new x86_energy::AccessSource(std::move(source))
+               } );
         }
         catch (std::exception& e)
         {
diff --git a/src/x86_energy_sync_plugin.cpp b/src/x86_energy_sync_plugin.cpp
index 844ca1c..3a7ce3b 100644
--- a/src/x86_energy_sync_plugin.cpp
+++ b/src/x86_energy_sync_plugin.cpp
@@ -94,7 +94,10 @@ x86_energy_sync_plugin::x86_energy_sync_plugin()
         {
             source.init();
             logging::debug() << "Add Source: " << source.name();
-            active_sources.push_back(std::make_unique<x86_energy::AccessSource>(std::move(source)));
+            active_sources.push_back(std::unique_ptr <x86_energy::AccessSource>
+            {
+                new x86_energy::AccessSource(std::move(source))
+            });
         }
         catch (std::exception& e)
         {
@AndreasGocht
Copy link
Collaborator

The problem is not intel2016 but gcc4.8, where the last version is released in 2014. Ass gcc5 is around nearly since 2014 as well, which is C++14 feature complete, I am not sure, if it is a good idea supporting as old compilers.

Best,

Andreas

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants