From 7684c754696f68a8b610980a40a7ff11aafcc337 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sun, 2 Nov 2025 23:22:21 +0000 Subject: [PATCH] Improve code comments based on review feedback Co-authored-by: RubenCGomes <116815718+RubenCGomes@users.noreply.github.com> --- _codeql_detected_source_root | 1 + aad_coin_miner_simd.c | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) create mode 120000 _codeql_detected_source_root diff --git a/_codeql_detected_source_root b/_codeql_detected_source_root new file mode 120000 index 0000000..945c9b4 --- /dev/null +++ b/_codeql_detected_source_root @@ -0,0 +1 @@ +. \ No newline at end of file diff --git a/aad_coin_miner_simd.c b/aad_coin_miner_simd.c index c6aa707..28405bd 100644 --- a/aad_coin_miner_simd.c +++ b/aad_coin_miner_simd.c @@ -36,7 +36,7 @@ static int is_valid_coin(u32_t *hash) // static int increment_coin(u32_t coin[14]) { - // Update the variable part (simple counter-based approach) + // Increment the variable part using byte-by-byte logic with carry // Increment from the end to beginning (positions 53 down to 12) int pos = 53; while(pos >= 12) @@ -147,7 +147,7 @@ static void mine_coins_avx(u64_t max_attempts) ((u08_t *)base_coin)[0x36 ^ 3] = '\n'; ((u08_t *)base_coin)[0x37 ^ 3] = 0x80; - // Initialize variable part with the same pattern as CPU miner + // Initialize variable part with A-Z cycling pattern (same as CPU miner) for(int i = 12; i < 54; i++) ((u08_t *)base_coin)[i ^ 3] = 'A' + (i - 12) % 26; @@ -239,7 +239,7 @@ static void mine_coins_avx2(u64_t max_attempts) ((u08_t *)base_coin)[0x36 ^ 3] = '\n'; ((u08_t *)base_coin)[0x37 ^ 3] = 0x80; - // Initialize variable part with the same pattern as CPU miner + // Initialize variable part with A-Z cycling pattern (same as CPU miner) for(int i = 12; i < 54; i++) ((u08_t *)base_coin)[i ^ 3] = 'A' + (i - 12) % 26;