Skip to content
This repository has been archived by the owner on Apr 24, 2022. It is now read-only.

Update Hunter, Boost, ethash libraries and adds gfx902 kernels #2284

Open
wants to merge 10 commits into
base: master
Choose a base branch
from
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ cable_configure_toolchain(DEFAULT cxx11)
set(HUNTER_CONFIGURATION_TYPES Release CACHE STRING "Build type of Hunter packages")
set(HUNTER_JOBS_NUMBER 6 CACHE STRING "Number of parallel builds used by Hunter")
HunterGate(
URL "https://github.com/ruslo/hunter/archive/v0.23.112.tar.gz"
SHA1 "4b894e1d5d203f0cc9a77431dbb1b486ab6f4430"
URL "https://github.com/cpp-pm/hunter/archive/v0.23.300.tar.gz"
SHA1 "1151d539465d9cdbc880ee30f794864aec11c448"
LOCAL
)

Expand Down Expand Up @@ -68,7 +68,7 @@ hunter_add_package(jsoncpp)
find_package(jsoncpp CONFIG REQUIRED)

hunter_add_package(ethash)
find_package(ethash CONFIG REQUIRED)
find_package(ethash 0.6.0 CONFIG REQUIRED)

configureProject()

Expand Down
19 changes: 17 additions & 2 deletions cmake/Hunter/config.cmake
Original file line number Diff line number Diff line change
@@ -1,2 +1,17 @@
hunter_config(CURL VERSION ${HUNTER_CURL_VERSION} CMAKE_ARGS HTTP_ONLY=ON CMAKE_USE_OPENSSL=OFF CMAKE_USE_LIBSSH2=OFF CURL_CA_PATH=none)
hunter_config(Boost VERSION 1.66.0)
hunter_config(
CURL
VERSION ${HUNTER_CURL_VERSION}
CMAKE_ARGS HTTP_ONLY=ON CMAKE_USE_OPENSSL=OFF CMAKE_USE_LIBSSH2=OFF CURL_CA_PATH=none
)

hunter_config(
Boost
VERSION 1.76.0
)

hunter_config(
ethash
VERSION 0.6.0
SHA1 4bfa26b389d1f89a60053de04b2a29feab20f67b
URL https://github.com/chfast/ethash/archive/refs/tags/v0.6.0.tar.gz
)
2 changes: 1 addition & 1 deletion libapicore/ApiServer.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#include <regex>

#include <boost/asio.hpp>
#include <boost/bind.hpp>
#include <boost/bind/bind.hpp>
#include <boost/shared_ptr.hpp>

#include <json/json.h>
Expand Down
8 changes: 6 additions & 2 deletions libethash-cl/kernels/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ ASFLAGS=-I$(SDIR)
AS=clrxasm

.PHONY: all
all: ellesmere tonga baffin gfx900 gfx901 gfx906
@echo "Built ethash kernel for Ellesmere, Tonga, Baffin, Gfx900 and Gfx901 architectures."
all: ellesmere tonga baffin gfx900 gfx901 gfx902 gfx906
@echo "Built ethash kernel for Ellesmere, Tonga, Baffin, Gfx900 Gfx901 Gfx902 and Gfx906 architectures."

.PHONY: clean
clean:
Expand Down Expand Up @@ -38,6 +38,10 @@ gfx900: gfx900_lws64.bin gfx900_lws128.bin gfx900_lws256.bin
gfx901: gfx901_lws64.bin gfx901_lws128.bin gfx901_lws256.bin
@echo "Built gfx901 kernels..."

.PHONY: gfx902
gfx902: gfx902_lws64.bin gfx902_lws128.bin gfx902_lws256.bin
@echo "Built gfx902 kernels..."

.PHONY: gfx906
gfx906: gfx906_lws64.bin gfx906_lws128.bin gfx906_lws256.bin
@echo "Built gfx906 kernels..."
Binary file added libethash-cl/kernels/bin/ethash_gfx902_lws128.bin
Binary file not shown.
Binary file not shown.
Binary file added libethash-cl/kernels/bin/ethash_gfx902_lws256.bin
Binary file not shown.
Binary file not shown.
Binary file added libethash-cl/kernels/bin/ethash_gfx902_lws64.bin
Binary file not shown.
Binary file not shown.
4 changes: 4 additions & 0 deletions libethash-cl/kernels/isa/GCN_ethash.isa
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@
.driver_version 257000
.include "GCN_ethash_globaldata.isa"
.include "GCN5_ethash_search.isa"
.elseifgpu gfx902
.driver_version 257000
.include "GCN_ethash_globaldata.isa"
.include "GCN5_ethash_search.isa"
.elseifgpu gfx906
.driver_version 2906007
.include "GCN_ethash_globaldata.isa"
Expand Down
2 changes: 1 addition & 1 deletion libethcore/Farm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ void Farm::restart()
*/
void Farm::restart_async()
{
m_io_strand.get_io_service().post(m_io_strand.wrap(boost::bind(&Farm::restart, this)));
m_io_strand.context().post(m_io_strand.wrap(boost::bind(&Farm::restart, this)));
}

/**
Expand Down
2 changes: 1 addition & 1 deletion libethcore/Farm.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#include <thread>

#include <boost/asio.hpp>
#include <boost/bind.hpp>
#include <boost/bind/bind.hpp>
#include <boost/dll.hpp>
#include <boost/filesystem.hpp>
#include <boost/process.hpp>
Expand Down
2 changes: 1 addition & 1 deletion libpoolprotocols/getwork/EthGetworkClient.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ void EthGetworkClient::begin_connect()
// Eventually endpoints get discarded on connection errors
m_endpoint = m_endpoints.front();
m_socket.async_connect(
m_endpoint, m_io_strand.wrap(boost::bind(&EthGetworkClient::handle_connect, this, _1)));
m_endpoint, m_io_strand.wrap(boost::bind(&EthGetworkClient::handle_connect, this, boost::placeholders::_1)));
}
else
{
Expand Down
4 changes: 2 additions & 2 deletions libpoolprotocols/stratum/EthStratumClient.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -344,12 +344,12 @@ void EthStratumClient::start_connect()
if (m_conn->SecLevel() != SecureLevel::NONE)
{
m_securesocket->lowest_layer().async_connect(m_endpoint,
m_io_strand.wrap(boost::bind(&EthStratumClient::connect_handler, this, _1)));
m_io_strand.wrap(boost::bind(&EthStratumClient::connect_handler, this, boost::placeholders::_1)));
}
else
{
m_socket->async_connect(m_endpoint,
m_io_strand.wrap(boost::bind(&EthStratumClient::connect_handler, this, _1)));
m_io_strand.wrap(boost::bind(&EthStratumClient::connect_handler, this, boost::placeholders::_1)));
}
}
else
Expand Down
2 changes: 1 addition & 1 deletion libpoolprotocols/stratum/EthStratumClient.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#include <boost/array.hpp>
#include <boost/asio.hpp>
#include <boost/asio/ssl.hpp>
#include <boost/bind.hpp>
#include <boost/bind/bind.hpp>
#include <boost/lockfree/queue.hpp>

#include <json/json.h>
Expand Down