142 lines
6.8 KiB
HTML
142 lines
6.8 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=%3C20190506201521.GA16401%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="000073.html">
|
|
<LINK REL="Next" HREF="000089.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=%3C20190506201521.GA16401%40openwall.com%3E"
|
|
TITLE="[ZcF-general] Grant project update - new PoW scheme">solar at openwall.com
|
|
</A><BR>
|
|
<I>Mon May 6 16:15:21 EDT 2019</I>
|
|
<P><UL>
|
|
<LI>Previous message (by thread): <A HREF="000073.html">[ZcF-general] Grant project update - new PoW scheme
|
|
</A></li>
|
|
<LI>Next message (by thread): <A HREF="000089.html">[ZcF-general] Grant project update - new PoW scheme
|
|
</A></li>
|
|
<LI> <B>Messages sorted by:</B>
|
|
<a href="date.html#82">[ date ]</a>
|
|
<a href="thread.html#82">[ thread ]</a>
|
|
<a href="subject.html#82">[ subject ]</a>
|
|
<a href="author.html#82">[ author ]</a>
|
|
</LI>
|
|
</UL>
|
|
<HR>
|
|
<!--beginarticle-->
|
|
<PRE>Hi,
|
|
|
|
This is another update on GrantProposals-2018Q2 #25 "review, tweaks, and
|
|
maybe design of a new PoW scheme for Zcash."
|
|
|
|
<A HREF="https://github.com/ZcashFoundation/GrantProposals-2018Q2/issues/25">https://github.com/ZcashFoundation/GrantProposals-2018Q2/issues/25</A>
|
|
|
|
This time, I thought of and experimented with a floating-point hack of
|
|
ProgPoW. As expected, it's complicated to get it right. I arrived at
|
|
some conclusions I recently posted as comments to:
|
|
|
|
On Sat, Apr 06, 2019 at 04:12:20PM +0200, Solar Designer wrote:
|
|
><i> "Make greater use of MADs"
|
|
</I>><i> <A HREF="https://github.com/ifdefelse/ProgPOW/issues/34">https://github.com/ifdefelse/ProgPOW/issues/34</A>
|
|
</I>
|
|
Specifically, to reasonably switch to using FP it appears that ProgPoW
|
|
needs to be redesigned to no longer have its one and the same inner
|
|
loop, but to have a larger "unrolled" function generated by its
|
|
"compiler", where floating-point constraints could be enforced at
|
|
irregular intervals just as needed to meet the constraints on never
|
|
potentially getting unsafe values (uncertainty or fatal entropy loss).
|
|
Also, to continue indexing the ProgPoW cache - which is an important
|
|
component of ProgPoW's computational cost - a few (perhaps very few)
|
|
registers would need to remain with integers. I included more detail,
|
|
along with pros and cons of this approach, in a comment to the issue.
|
|
|
|
As I shared in another comment, while staying with integers only I'm
|
|
only able to get to a (geometric) middle point between official
|
|
ProgPoW's MUL/s rate and theoretical maximum FP32 MUL/s rate: ~7x
|
|
higher than original, but still ~9x lower than theoretical maximum.
|
|
(Of course, that theoretical maximum is for FP32 and not INT32, and it
|
|
assumes not doing any other work, whereas we need to do lots of that.)
|
|
|
|
><i> On (repairing) Ethash's and ProgPoW's performance drop on older GPUs:
|
|
</I>[...]
|
|
><i> I experimented with it some more, and got success at recovering the
|
|
</I>><i> speed on NVIDIA Maxwell (aka GTX 9xx series GPUs, or two generations
|
|
</I>><i> behind from latest RTX 2xxx):
|
|
</I>><i>
|
|
</I>><i> <A HREF="https://github.com/ifdefelse/ProgPOW/issues/26#issuecomment-480382319">https://github.com/ifdefelse/ProgPOW/issues/26#issuecomment-480382319</A>
|
|
</I>><i>
|
|
</I>><i> Specifically, combining a minor cleanup to untie the different
|
|
</I>><i> parameters, a parameters tweak, and a code hack (not yet final, but
|
|
</I>><i> works for proof-of-concept), I got a 3x+ speedup on Titan X Maxwell
|
|
</I>
|
|
I've started to maintain an unofficial fork of ProgPoW with a more
|
|
elaborate revision of this change and more in the "maxwell" branch here:
|
|
|
|
<A HREF="https://github.com/solardiz/ProgPOW">https://github.com/solardiz/ProgPOW</A>
|
|
|
|
Another change I included is "Index cache with byte offsets", which also
|
|
breaks compatibility with official ProgPoW, but I hope will be accepted
|
|
upstream (for a new spec revision) as it provides a 1% speedup on new
|
|
GPUs (and further 2% speedup on Maxwell) with no ill effects, as far as
|
|
I can tell. I propose it upstream here:
|
|
|
|
<A HREF="https://github.com/ifdefelse/ProgPOW/issues/40">https://github.com/ifdefelse/ProgPOW/issues/40</A>
|
|
|
|
Yet another topic I arrived at an opinion on and brought up for
|
|
discussion with upstream is "Make cache content vary per-hash":
|
|
|
|
<A HREF="https://github.com/ifdefelse/ProgPOW/issues/41">https://github.com/ifdefelse/ProgPOW/issues/41</A>
|
|
|
|
Both of these are described in detail on the issues above, with
|
|
rationale and pros and cons (well, there are no cons for #40).
|
|
|
|
In related news, I heard of a planned ProgPoW audit by Least Authority:
|
|
|
|
<A HREF="https://github.com/ethereum-cat-herders/progpow-audit">https://github.com/ethereum-cat-herders/progpow-audit</A>
|
|
<A HREF="https://medium.com/ethereum-cat-herders/progpow-audit-goals-expectations-75bb902a1f01">https://medium.com/ethereum-cat-herders/progpow-audit-goals-expectations-75bb902a1f01</A>
|
|
|
|
I'm in contact with Least Authority via e-mail, but as of this writing I
|
|
don't know what that project's status is - including not whether it got
|
|
funded to a sufficient extent or not.
|
|
|
|
Regardless, as I tweeted last month, this is similar to yet different
|
|
from my work. As I understand, theirs will focus on ProgPoW as-is,
|
|
whereas I focus on tweaking ProgPoW. I think the projects can co-exist.
|
|
|
|
Alexander
|
|
</PRE>
|
|
|
|
|
|
<!--endarticle-->
|
|
<HR>
|
|
<P><UL>
|
|
<!--threads-->
|
|
<LI>Previous message (by thread): <A HREF="000073.html">[ZcF-general] Grant project update - new PoW scheme
|
|
</A></li>
|
|
<LI>Next message (by thread): <A HREF="000089.html">[ZcF-general] Grant project update - new PoW scheme
|
|
</A></li>
|
|
<LI> <B>Messages sorted by:</B>
|
|
<a href="date.html#82">[ date ]</a>
|
|
<a href="thread.html#82">[ thread ]</a>
|
|
<a href="subject.html#82">[ subject ]</a>
|
|
<a href="author.html#82">[ author ]</a>
|
|
</LI>
|
|
</UL>
|
|
|
|
<hr>
|
|
<a href="/mailman/listinfo/general">More information about the general
|
|
mailing list</a><br>
|
|
</body></html>
|