From 40a24151ca7f5735ff90a7b2d05cb35a9e501ce2 Mon Sep 17 00:00:00 2001 From: Chris Duncan Date: Wed, 20 Nov 2024 22:04:28 -0800 Subject: [PATCH] Worker threads do not seem to improve BLAKE2b ckd much, but BIP-44 ckd is 5x faster. This commit saves the work, and the next commit will clean up the logging and old functions. --- src/lib/wallet.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/lib/wallet.ts b/src/lib/wallet.ts index 2581de7..b2be001 100644 --- a/src/lib/wallet.ts +++ b/src/lib/wallet.ts @@ -415,7 +415,7 @@ export class Bip44Wallet extends Wallet { * @param {number} index - Index of the account * @returns {Promise} */ - async ckd (index: number | number[]): Promise { + async ckd_old (index: number | number[]): Promise { if (!Array.isArray(index)) index = [index] const keys = [] let now = performance.now() @@ -443,7 +443,7 @@ export class Bip44Wallet extends Wallet { * @param {number} index - Index of the account * @returns {Promise} */ - async ckd_new (index: number | number[]): Promise { + async ckd (index: number | number[]): Promise { if (!Array.isArray(index)) index = [index] const data: any = [] let now = performance.now() @@ -603,7 +603,7 @@ export class Blake2bWallet extends Wallet { * @param {number} index - Index of the account * @returns {Promise} */ - async ckd (index: number | number[]): Promise { + async ckd_old (index: number | number[]): Promise { if (!Array.isArray(index)) index = [index] const keys = [] let now = performance.now() @@ -632,7 +632,7 @@ export class Blake2bWallet extends Wallet { * @param {number} index - Index of the account * @returns {Promise} */ - async ckd_new (index: number | number[]): Promise { + async ckd (index: number | number[]): Promise { if (!Array.isArray(index)) index = [index] const data: any = [] let now = performance.now() -- 2.34.1