Skip to content

Instantly share code, notes, and snippets.

View richardkiss's full-sized avatar

Richard Kiss richardkiss

View GitHub Profile
@richardkiss
richardkiss / settlement_payments.md
Last active November 5, 2023 09:40
Ideas about Offers on Chia

We introduce a new puzzle, "settlement_payments", which pays out coins and make an announcement for each new coin created.

settlement_payments.cl:

(mod (coins_paid)
  ;; `coins_paid` is a list of notarized coin payments
  ;; a notarized coin payment is `(nonce puzzle_hash amount ...)`
  ;; Each notarized coin payment creates a `(CREATE_COIN puzzle_hash amount)` payment
@richardkiss
richardkiss / ffi.py
Last active December 17, 2023 08:02
Using ctypes in python to call a mojo function (mojo 0.6)
from ctypes import CFUNCTYPE, c_int
Ft = CFUNCTYPE(c_int, c_int, c_int)
def entry_point(ptr_to_function):
function_pointer = Ft(ptr_to_function)
result = function_pointer(5000, 2)
return result
@richardkiss
richardkiss / chia-db.md
Created December 21, 2023 21:06
Benchmarking `chia-blockchain` DB

This is a report on the chia-blockchain sqlite3 DB. The concern is that some operations are slow, and get slower over time. The symptom is the conversion from v1 of the DB to v2 never finishes and seems to get slower asymptotically as time goes on. This may affect performance during regular day-to-day operation, since DB conversion is not wholy different from DB operations performed on a day-to-day basis.

Summary

There are six tables and eight indices.

@richardkiss
richardkiss / nvidia-proxmox-kernel.md
Last active February 27, 2024 03:23
Minimal install of nvidia kernel drivers on proxmox host