-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7b2a37a
commit 5dcadbc
Showing
36 changed files
with
905 additions
and
885 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
# Licensed to the Apache Software Foundation (ASF) under one | ||
# or more contributor license agreements. See the NOTICE file | ||
# distributed with this work for additional information | ||
# regarding copyright ownership. The ASF licenses this file | ||
# to you under the Apache License, Version 2.0 (the | ||
# "License"); you may not use this file except in compliance | ||
# with the License. You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, | ||
# software distributed under the License is distributed on an | ||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
# KIND, either express or implied. See the License for the | ||
# specific language governing permissions and limitations | ||
# under the License. | ||
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.4/apache-maven-3.9.4-bin.zip | ||
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar | ||
# Licensed to the Apache Software Foundation (ASF) under one | ||
# or more contributor license agreements. See the NOTICE file | ||
# distributed with this work for additional information | ||
# regarding copyright ownership. The ASF licenses this file | ||
# to you under the Apache License, Version 2.0 (the | ||
# "License"); you may not use this file except in compliance | ||
# with the License. You may obtain a copy of the License at | ||
# | ||
# https://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, | ||
# software distributed under the License is distributed on an | ||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
# KIND, either express or implied. See the License for the | ||
# specific language governing permissions and limitations | ||
# under the License. | ||
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.6/apache-maven-3.9.6-bin.zip | ||
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.1/maven-wrapper-3.1.1.jar |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,70 +1,70 @@ | ||
/* | ||
* Copyright (c) 2021-2023, Adel Noureddine, Université de Pau et des Pays de l'Adour. | ||
* All rights reserved. This program and the accompanying materials | ||
* are made available under the terms of the | ||
* GNU General Public License v3.0 only (GPL-3.0-only) | ||
* which accompanies this distribution, and is available at | ||
* https://www.gnu.org/licenses/gpl-3.0.en.html | ||
* | ||
* Author : Adel Noureddine | ||
*/ | ||
|
||
#include <iostream> | ||
|
||
#include <SDKDDKVer.h> | ||
|
||
#include <stdio.h> | ||
#include <tchar.h> | ||
#include "IntelPowerGadgetLib.h" | ||
|
||
using namespace std; | ||
|
||
int main() { | ||
CIntelPowerGadgetLib energyLib; | ||
|
||
if (energyLib.IntelEnergyLibInitialize() == false) { | ||
return 0; | ||
} | ||
|
||
int nNodes = 0; | ||
int nMsrs = 0; | ||
|
||
energyLib.GetNumNodes(&nNodes); | ||
energyLib.GetNumMsrs(&nMsrs); | ||
|
||
while (true) { | ||
if (!energyLib.ReadSample()) { | ||
return 0; | ||
} | ||
|
||
double data[3]; | ||
int nData, funcId; | ||
double power = 0; | ||
wchar_t szName[MAX_PATH]; | ||
|
||
// Processor (i=0, j=1) | ||
energyLib.GetMsrFunc(1, &funcId); | ||
energyLib.GetMsrName(1, szName); | ||
|
||
if (funcId != 1) { | ||
continue; | ||
} | ||
energyLib.GetPowerData(0, 1, data, &nData); | ||
power += data[0]; // power in W %6.2f | ||
|
||
// Now check for DRAM and add it to total power (i=0, j=4) | ||
energyLib.GetMsrFunc(4, &funcId); | ||
energyLib.GetMsrName(4, szName); | ||
|
||
if (funcId == 1) { | ||
energyLib.GetPowerData(0, 4, data, &nData); | ||
power += data[0]; // power in W %6.2f | ||
} | ||
|
||
cout << power << endl; | ||
|
||
// Sleep for one second | ||
Sleep(1000); | ||
} | ||
return 0; | ||
/* | ||
* Copyright (c) 2021-2024, Adel Noureddine, Université de Pau et des Pays de l'Adour. | ||
* All rights reserved. This program and the accompanying materials | ||
* are made available under the terms of the | ||
* GNU General Public License v3.0 only (GPL-3.0-only) | ||
* which accompanies this distribution, and is available at | ||
* https://www.gnu.org/licenses/gpl-3.0.en.html | ||
* | ||
* Author : Adel Noureddine | ||
*/ | ||
|
||
#include <iostream> | ||
|
||
#include <SDKDDKVer.h> | ||
|
||
#include <stdio.h> | ||
#include <tchar.h> | ||
#include "IntelPowerGadgetLib.h" | ||
|
||
using namespace std; | ||
|
||
int main() { | ||
CIntelPowerGadgetLib energyLib; | ||
|
||
if (energyLib.IntelEnergyLibInitialize() == false) { | ||
return 0; | ||
} | ||
|
||
int nNodes = 0; | ||
int nMsrs = 0; | ||
|
||
energyLib.GetNumNodes(&nNodes); | ||
energyLib.GetNumMsrs(&nMsrs); | ||
|
||
while (true) { | ||
if (!energyLib.ReadSample()) { | ||
return 0; | ||
} | ||
|
||
double data[3]; | ||
int nData, funcId; | ||
double power = 0; | ||
wchar_t szName[MAX_PATH]; | ||
|
||
// Processor (i=0, j=1) | ||
energyLib.GetMsrFunc(1, &funcId); | ||
energyLib.GetMsrName(1, szName); | ||
|
||
if (funcId != 1) { | ||
continue; | ||
} | ||
energyLib.GetPowerData(0, 1, data, &nData); | ||
power += data[0]; // power in W %6.2f | ||
|
||
// Now check for DRAM and add it to total power (i=0, j=4) | ||
energyLib.GetMsrFunc(4, &funcId); | ||
energyLib.GetMsrName(4, szName); | ||
|
||
if (funcId == 1) { | ||
energyLib.GetPowerData(0, 4, data, &nData); | ||
power += data[0]; // power in W %6.2f | ||
} | ||
|
||
cout << power << endl; | ||
|
||
// Sleep for one second | ||
Sleep(1000); | ||
} | ||
return 0; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,26 @@ | ||
:: Copyright (c) 2021-2023, Adel Noureddine, Université de Pau et des Pays de l'Adour. | ||
:: All rights reserved. This program and the accompanying materials | ||
:: are made available under the terms of the | ||
:: GNU General Public License v3.0 only (GPL-3.0-only) | ||
:: which accompanies this distribution, and is available at | ||
:: https://www.gnu.org/licenses/gpl-3.0.en.html | ||
:: | ||
:: Author : Adel Noureddine | ||
|
||
@echo off | ||
title JoularJX Installer Configurator | ||
|
||
echo Compiling and building JoularJX | ||
call mvn clean install | ||
|
||
echo Compiling ProgramMonitor on Windows x64 | ||
set DEVENV_COM=C:\Program Files\Microsoft Visual Studio\2022\Community\Common7\IDE\devenv.com | ||
cd PowerMonitor | ||
"%DEVENV_COM%" PowerMonitor.sln /Build "Release|x64" | ||
cd .. | ||
|
||
echo Copying files to install folder | ||
copy config.properties install | ||
copy target\joularjx-*.jar install | ||
copy PowerMonitor\x64\Release\PowerMonitor.exe install | ||
:: Copyright (c) 2021-2024, Adel Noureddine, Université de Pau et des Pays de l'Adour. | ||
:: All rights reserved. This program and the accompanying materials | ||
:: are made available under the terms of the | ||
:: GNU General Public License v3.0 only (GPL-3.0-only) | ||
:: which accompanies this distribution, and is available at | ||
:: https://www.gnu.org/licenses/gpl-3.0.en.html | ||
:: | ||
:: Author : Adel Noureddine | ||
|
||
@echo off | ||
title JoularJX Installer Configurator | ||
|
||
echo Compiling and building JoularJX | ||
call mvn clean install | ||
|
||
echo Compiling ProgramMonitor on Windows x64 | ||
set DEVENV_COM=C:\Program Files\Microsoft Visual Studio\2022\Community\Common7\IDE\devenv.com | ||
cd PowerMonitor | ||
"%DEVENV_COM%" PowerMonitor.sln /Build "Release|x64" | ||
cd .. | ||
|
||
echo Copying files to install folder | ||
copy config.properties install | ||
copy target\joularjx-*.jar install | ||
copy PowerMonitor\x64\Release\PowerMonitor.exe install | ||
pause |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,23 @@ | ||
#!/bin/sh | ||
|
||
# Copyright (c) 2021-2023, Adel Noureddine, Université de Pau et des Pays de l'Adour. | ||
# All rights reserved. This program and the accompanying materials | ||
# are made available under the terms of the | ||
# GNU General Public License v3.0 only (GPL-3.0-only) | ||
# which accompanies this distribution, and is available at | ||
# https://www.gnu.org/licenses/gpl-3.0.en.html | ||
# | ||
# Author : Adel Noureddine | ||
|
||
INSTALLATION_PATH=/opt/joularjx | ||
|
||
read -p "Installation to $INSTALLATION_PATH. Continue ([y]/n)? " USER_CONFIRMATION | ||
echo | ||
if [ "$USER_CONFIRMATION" = "y" ] | ||
then | ||
mkdir $INSTALLATION_PATH | ||
cp joularjx-*.jar $INSTALLATION_PATH | ||
cp config.properties $INSTALLATION_PATH | ||
|
||
echo "Installation complete. JoularJX files installed in $INSTALLATION_PATH" | ||
#!/bin/sh | ||
|
||
# Copyright (c) 2021-2024, Adel Noureddine, Université de Pau et des Pays de l'Adour. | ||
# All rights reserved. This program and the accompanying materials | ||
# are made available under the terms of the | ||
# GNU General Public License v3.0 only (GPL-3.0-only) | ||
# which accompanies this distribution, and is available at | ||
# https://www.gnu.org/licenses/gpl-3.0.en.html | ||
# | ||
# Author : Adel Noureddine | ||
|
||
INSTALLATION_PATH=/opt/joularjx | ||
|
||
read -p "Installation to $INSTALLATION_PATH. Continue ([y]/n)? " USER_CONFIRMATION | ||
echo | ||
if [ "$USER_CONFIRMATION" = "y" ] | ||
then | ||
mkdir $INSTALLATION_PATH | ||
cp joularjx-*.jar $INSTALLATION_PATH | ||
cp config.properties $INSTALLATION_PATH | ||
|
||
echo "Installation complete. JoularJX files installed in $INSTALLATION_PATH" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,25 @@ | ||
:: Copyright (c) 2021-2023, Adel Noureddine, Université de Pau et des Pays de l'Adour. | ||
:: All rights reserved. This program and the accompanying materials | ||
:: are made available under the terms of the | ||
:: GNU General Public License v3.0 only (GPL-3.0-only) | ||
:: which accompanies this distribution, and is available at | ||
:: https://www.gnu.org/licenses/gpl-3.0.en.html | ||
:: | ||
:: Author : Adel Noureddine | ||
|
||
@echo off | ||
title JoularJX Windows Installer | ||
|
||
set INSTALLATION_PATH=C:\joularjx | ||
|
||
set USER_CONFIRMATION=y | ||
set /p USER_CONFIRMATION=Installation to %INSTALLATION_PATH%. Continue ([y]/n)? | ||
if /i not "%USER_CONFIRMATION%" == "y" goto :eof | ||
|
||
md %INSTALLATION_PATH% | ||
copy joularjx-*.jar %INSTALLATION_PATH% | ||
copy config.properties %INSTALLATION_PATH% | ||
copy PowerMonitor.exe %INSTALLATION_PATH% | ||
|
||
echo Installation complete. JoularJX files installed in %INSTALLATION_PATH% | ||
:: Copyright (c) 2021-2024, Adel Noureddine, Université de Pau et des Pays de l'Adour. | ||
:: All rights reserved. This program and the accompanying materials | ||
:: are made available under the terms of the | ||
:: GNU General Public License v3.0 only (GPL-3.0-only) | ||
:: which accompanies this distribution, and is available at | ||
:: https://www.gnu.org/licenses/gpl-3.0.en.html | ||
:: | ||
:: Author : Adel Noureddine | ||
|
||
@echo off | ||
title JoularJX Windows Installer | ||
|
||
set INSTALLATION_PATH=C:\joularjx | ||
|
||
set USER_CONFIRMATION=y | ||
set /p USER_CONFIRMATION=Installation to %INSTALLATION_PATH%. Continue ([y]/n)? | ||
if /i not "%USER_CONFIRMATION%" == "y" goto :eof | ||
|
||
md %INSTALLATION_PATH% | ||
copy joularjx-*.jar %INSTALLATION_PATH% | ||
copy config.properties %INSTALLATION_PATH% | ||
copy PowerMonitor.exe %INSTALLATION_PATH% | ||
|
||
echo Installation complete. JoularJX files installed in %INSTALLATION_PATH% | ||
pause |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.