Skip to content

Instantly share code, notes, and snippets.

View SomeoneSerge's full-sized avatar
💭
Completely swamped again

Someone SomeoneSerge

💭
Completely swamped again
View GitHub Profile
@PedroHLC
PedroHLC / pkgsx86_64_v3.benchmarking.md
Last active November 23, 2023 13:45
Some benchmarks for chaotic#pkgsx86_64_v3

Ran on /tmp (with useTmpfs), where the files are, and directly from TTY1 (without any DE running).


  • Shell A: nix shell nixpkgs#hyperfine nixpkgs#ffmpeg-headless

  • Shell B: nix shell nixpkgs#hyperfine chaotic#pkgsx86_64_v3.ffmpeg-headless

  • Benchmark parameter: hyperfine -w 3 -M 10

  • Benchmark command: ffmpeg -threads 1 -y -i 01._Radio_Ga_Ga.flac -f ogg /dev/null

@FCLC
FCLC / Understanding how modern processors got fast: SIMD, multiple pipes and Out of Order execution.md
Last active November 13, 2023 06:07
An approachable introduction to how modern CPUs got fast, beyond throwing more GHz at the problem

Context

I was helping a few computer science students and enthusiasts understand “how” modern processors got to be “so fast” outside of clock speed increases.  

Here is the main ;p exert  

Acronyms:  

SIMD: Single Instruction, Multiple Data  

echo ""
echo "************ Github Dork Links (must be logged in) *******************"
echo ""
echo " password"
echo "https://github.com/search?q="hackertarget.site"+password&type=Code"
echo "https://github.com/search?q=""hackertarget""+password&type=Code"
echo ""
echo " npmrc _auth"
@jdarcy
jdarcy / activitypub.md
Created November 9, 2022 16:10
Some thoughts about ActivityPub

I've commented a few times about some issues I see with the scalability of ActivityPub - the protocol behind the Fediverse and its best-known implementation Mastodon. A couple of folks have asked for more elaboration, so ... here it is.

First, let me add some disclaimers and warnings. I haven't devoted a lot of time to looking at ActivityPub, so there might be some things I've misunderstood about it. On the other hand, I've brought bigger systems - similar node counts and orders of magnitude more activity per node - from broken to working well based on less study of the protocols involved. So if you want to correct particular misconceptions, that's great. Thank you in advance. If you want to turn this into an appeal to authority and say that I'm wrong only because I haven't developed a full ActivityPub implementation or worked on it for X years ... GTFO.

What

What is ActivityPub? It's an HTTP- and JSON-based protocol for exchanging information about "activities". An activity could be many things.

@roberth
roberth / minimod.nix
Last active March 11, 2025 00:52
Simple and quick module system alternative + thoughts and tasks
/*
minimod: A stripped down module system
TODO Comparison:
- [ ] Come up with a benchmark "logic" using plain old functions and let bindings
- [ ] Write the benchmark for the module system
- [ ] Write the benchmark for POP?
- [ ] Qualitative comparison of extensibility in the context of composable
Nixpkgs packaging logic
TODO Fine-tuning:
@mkyt
mkyt / fix-pages-metadata-conflicts.py
Last active December 6, 2022 15:36
Fix merge conflicts for `pages-metadata.edn` of LogSeq data directory
#!/usr/bin/env python3
from pathlib import Path
from typing import Union, Tuple, List, NamedTuple, Dict
import sys
class Block(NamedTuple):
name: str
created: int
updated: int
@suhr
suhr / proofs.md
Last active December 8, 2022 13:05

Упражнения по формальным доказательствам

Нет времени объяснять, переходим сразу к делу.

Инструменты

Доказывать теоремы мы будем, используя интерактивные пруверы Isabelle или Lean 3. Примеры приводятся для каждого прувера, для решения задач же можно использовать любой из них.

@bitonic
bitonic / vectorized-atan2f.cpp
Last active August 9, 2024 12:54
Vectorized & branchless atan2f
// Copyright (c) 2021 Francesco Mazzoli <[email protected]>
//
// Permission to use, copy, modify, and distribute this software for any
// purpose with or without fee is hereby granted, provided that the above
// copyright notice and this permission notice appear in all copies.
//
// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
@kmicinski
kmicinski / church.rkt
Created April 6, 2021 04:17
Church numerals in Racket
#lang racket
;; numbers are represented as:
;; (lambda (f) (lambda (x) (f ... (f x))))
;; where there are n calls to f.
(define zero (lambda (f) (lambda (x) x)))
(define one (lambda (f) (lambda (x) (f x))))
(define two (lambda (f) (lambda (x) (f (f x)))))
;; do add1 n times, starting from 0