mailman-lists-archive/pipermail/general/2019/000089.html

118 lines
5.1 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD>
<TITLE> [ZcF-general] Grant project update - new PoW scheme
</TITLE>
<LINK REL="Index" HREF="/pipermail/general/2019/index.html" >
<LINK REL="made" HREF="mailto:general%40lists.zfnd.org?Subject=Re%3A%20%5BZcF-general%5D%20Grant%20project%20update%20-%20new%20PoW%20scheme&In-Reply-To=%3C20190627161446.GA30976%40openwall.com%3E">
<META NAME="robots" CONTENT="index,nofollow">
<style type="text/css">
pre {
white-space: pre-wrap; /* css-2.1, curent FF, Opera, Safari */
}
</style>
<META http-equiv="Content-Type" content="text/html; charset=us-ascii">
<LINK REL="Previous" HREF="000082.html">
<LINK REL="Next" HREF="000093.html">
</HEAD>
<BODY BGCOLOR="#ffffff">
<H1>[ZcF-general] Grant project update - new PoW scheme</H1>
<B>Solar Designer</B>
<A HREF="mailto:general%40lists.zfnd.org?Subject=Re%3A%20%5BZcF-general%5D%20Grant%20project%20update%20-%20new%20PoW%20scheme&In-Reply-To=%3C20190627161446.GA30976%40openwall.com%3E"
TITLE="[ZcF-general] Grant project update - new PoW scheme">solar at openwall.com
</A><BR>
<I>Thu Jun 27 12:14:46 EDT 2019</I>
<P><UL>
<LI>Previous message (by thread): <A HREF="000082.html">[ZcF-general] Grant project update - new PoW scheme
</A></li>
<LI>Next message (by thread): <A HREF="000093.html">[ZcF-general] Grant project update - new PoW scheme
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#89">[ date ]</a>
<a href="thread.html#89">[ thread ]</a>
<a href="subject.html#89">[ subject ]</a>
<a href="author.html#89">[ author ]</a>
</LI>
</UL>
<HR>
<!--beginarticle-->
<PRE>Hi,
This is another update on GrantProposals-2018Q2 #25 &quot;review, tweaks, and
maybe design of a new PoW scheme for Zcash.&quot;
<A HREF="https://github.com/ZcashFoundation/GrantProposals-2018Q2/issues/25">https://github.com/ZcashFoundation/GrantProposals-2018Q2/issues/25</A>
Upstream/reference ProgPoW implementation does not include a mode where
it'd output the computed hashes. Rather, it is a hack of an Ethereum
miner, so it tries to mine, and expects to never find a hash below the
target (if it does, it fails, because its verification on CPU hasn't
been updated from Ethash's). With this, there was no way of knowing
whether it actually computes the hashes correctly. Further, I had no
means to test my tweaks for correct computation either.
To get around this, I wrote my own debugging code as a hack to upstream
ProgPoW, now proposed here:
Add progpow-debug.diff, which outputs digest for a fixed header and nonce
<A HREF="https://github.com/ifdefelse/ProgPOW/pull/46">https://github.com/ifdefelse/ProgPOW/pull/46</A>
Then I proceeded with additional correctness testing of ProgPoW upstream
implementation against c-progpow and of upstream's CUDA against OpenCL.
This uncovered issues with the OpenCL implementation: the kernel was
being built for a wrong ProgPoW period most of the time (a bug in
ProgPoW), and further it was often miscompiled when targeting AMD GPUs
(a bug in AMD's &quot;driver&quot;). The issues turned out to be semi-known, yet
unfixed and undocumented. This partially invalidates some earlier
OpenCL benchmarks.
Since last update, I got 5 PRs merged into upstream ProgPoW, including 2
fixing the issues mentioned above:
Compile OpenCL kernels for correct ProgPoW period seed
<A HREF="https://github.com/ifdefelse/ProgPOW/pull/44">https://github.com/ifdefelse/ProgPOW/pull/44</A>
Workaround miscompiles with AMD OpenCL
<A HREF="https://github.com/ifdefelse/ProgPOW/pull/45">https://github.com/ifdefelse/ProgPOW/pull/45</A>
and 3 more with cleanups that do not affect computation:
Don't redefine and misuse ETHASH_MIX_BYTES
<A HREF="https://github.com/ifdefelse/ProgPOW/pull/35">https://github.com/ifdefelse/ProgPOW/pull/35</A>
Have progPowHash() (pseudo-)code return &quot;result&quot;, not &quot;digest&quot;
<A HREF="https://github.com/ifdefelse/ProgPOW/pull/39">https://github.com/ifdefelse/ProgPOW/pull/39</A>
Add &quot;Build and Test Instructions&quot;
<A HREF="https://github.com/ifdefelse/ProgPOW/pull/47">https://github.com/ifdefelse/ProgPOW/pull/47</A>
I also rebased my tweaked ProgPoW on top of the revised upstream code.
I intend to wrap up this project soon, but I'm not done yet.
Alexander
</PRE>
<!--endarticle-->
<HR>
<P><UL>
<!--threads-->
<LI>Previous message (by thread): <A HREF="000082.html">[ZcF-general] Grant project update - new PoW scheme
</A></li>
<LI>Next message (by thread): <A HREF="000093.html">[ZcF-general] Grant project update - new PoW scheme
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#89">[ date ]</a>
<a href="thread.html#89">[ thread ]</a>
<a href="subject.html#89">[ subject ]</a>
<a href="author.html#89">[ author ]</a>
</LI>
</UL>
<hr>
<a href="/mailman/listinfo/general">More information about the general
mailing list</a><br>
</body></html>