remove logs

This commit is contained in:
PhilReact 2024-11-18 20:56:11 +02:00
parent 86ed01cd1d
commit 0c986b9433
2 changed files with 0 additions and 7 deletions

View File

@ -2827,8 +2827,6 @@ async function getChatHeadsDirect() {
chrome?.runtime?.onMessage.addListener((request, sender, sendResponse) => { chrome?.runtime?.onMessage.addListener((request, sender, sendResponse) => {
if (request) { if (request) {
console.log('REQUEST MESSAGE', request)
switch (request.action) { switch (request.action) {
case "version": case "version":
// Example: respond with the version // Example: respond with the version

View File

@ -24,9 +24,7 @@ async function loadWasm() {
const wasmModule = await wasmInit(importObject); const wasmModule = await wasmInit(importObject);
compute = wasmModule.exports.compute2; compute = wasmModule.exports.compute2;
console.log('Wasm loaded successfully:', compute);
} catch (error) { } catch (error) {
console.error('Error loading Wasm:', error);
throw error; throw error;
} }
} }
@ -45,7 +43,6 @@ function sbrk(size) {
// Grow memory if needed // Grow memory if needed
if (brk > memory.buffer.byteLength) { if (brk > memory.buffer.byteLength) {
const pagesNeeded = Math.ceil((brk - memory.buffer.byteLength) / (64 * 1024)); // 64 KiB per page const pagesNeeded = Math.ceil((brk - memory.buffer.byteLength) / (64 * 1024)); // 64 KiB per page
console.log(`Growing memory by ${pagesNeeded} pages`);
try { try {
memory.grow(pagesNeeded); memory.grow(pagesNeeded);
heap = new Uint8Array(memory.buffer); // Update heap view heap = new Uint8Array(memory.buffer); // Update heap view
@ -78,9 +75,7 @@ async function computePow(chatBytes, difficulty) {
workBufferPtr = sbrk(workBufferLength); workBufferPtr = sbrk(workBufferLength);
} }
console.log('Starting POW computation...');
const nonce = compute(hashPtr, workBufferPtr, workBufferLength, difficulty); const nonce = compute(hashPtr, workBufferPtr, workBufferLength, difficulty);
console.log('POW computation finished.');
return { nonce, chatBytesArray }; return { nonce, chatBytesArray };
} }