Skip to content

Instantly share code, notes, and snippets.

View marianposaceanu's full-sized avatar

Posăceanu Marian marianposaceanu

View GitHub Profile
device cpu single core score multi core score
iPhone 16 Pro Max Apple A18 Pro 3428 8531
iPhone 16 Pro Apple A18 Pro 3445 8624
MacBook Air (15-inch, 2025) Apple M4 @ 4.4 GHz (10 CPU cores, 10 GPU cores) 3708 14698
MacBook Air (13-inch, 2025) Apple M4 @ 4.4 GHz (10 CPU cores, 8 GPU cores) 3696 14729
MacBook Air (13-inch, 2025) Apple M4 @ 4.4 GHz (10 CPU cores, 10 GPU cores) 3696 14729
MacBook Pro (14-inch, 2025) Apple M5 @ 4.6 GHz (10 CPU cores, 10
Feature Samsung 990 Pro SSD PS5 Custom SSD
Interface PCIe 4.0 NVMe Custom PCIe 4.0-based
Raw Sequential Read Speed Up to 7.4 GB/s 5.5 GB/s
Effective Throughput Depends on workload (3-5 GB/s typical in gaming) 8-9 GB/s (with Kraken compression)
Decompression Method Software-based (CPU) Hardware-based (Kraken compression)
I/O Hardware Standard NVMe controller Custom I/O controller with DMA and decompression units
Purpose General-purpose consumer SSD Gaming-specific design
Operating System Windows/Linux
,---,
,--. ,----.. ,`--.' |
,--.'| / / \ | : :
,--,: : | / . : ' ' ;
,`--.'`| ' : . / ;. \ | | |
| : : | |. ; / ` ; ' : ;
: | \ | :; | ; \ ; | | | '
| : ' '; || : | ; | ' ' : |
' ' ;. ;. | ' ' ' : ; | ;
| | | \ |' ; \; / | `---'. |

Compare kitty and iterm2

Comparison

How to use top_history.sh

Overview

top_history.sh is a script that displays the top 10 most used commands from the zsh history. It generates a bar chart using Gnuplot to visualize the command frequencies.

Requirements

Before using top_history.sh, make sure you have the following requirements installed on your system:

  1. Zsh Shell: This script is designed for use with the Zsh shell. Ensure you have Zsh installed as your default shell.

Comparison of setting a key to Redis

note: Redis is running locally with a maximum of 10K connections

 set LZ4 + MessagePack:    401.7 i/s
           set Marshal:    232.3 i/s - 1.73x  slower
     set LZ4 + Marshal:    176.4 i/s - 2.28x  slower
              set to_s:    141.5 i/s - 2.84x  slower
 set Snappy + Marshal: 92.6 i/s - 4.34x slower
# A simple way to measure start-up time from inside Java application
# credits:
# - https://stackoverflow.com/questions/39321345/how-do-i-measure-jvm-startup-time
#
# How to run:
#
# 0. install JRuby (brew, rvm, etc.) e.g. `rvm install jruby-9.2.11.1`
# 1. download this script
# 2. in the shell run `for i in {1..10}; do ruby jruby_start_up.rb; done | awk '{ total += $1; count++ } END { print total/count }'`
# => 1673.9
@marianposaceanu
marianposaceanu / disable.sh
Created December 31, 2019 00:04
Disable bunch of #$!@ in Catalina
#!/bin/bash
# IMPORTANT: Don't forget to logout from your Apple ID in the settings before running it!
# IMPORTANT: You will need to run this script from Recovery. In fact, macOS Catalina brings read-only filesystem which prevent this script from working from the main OS.
# This script needs to be run from the volume you wish to use.
# E.g. run it like this: cd /Volumes/Macintosh\ HD && sh /Volumes/Macintosh\ HD/Users/sabri/Desktop/disable.sh
# WARNING: It might disable things that you may not like. Please double check the services in the TODISABLE vars.
# Get active services: launchctl list | grep -v "\-\t0"
# Find a service: grep -lR [service] /System/Library/Launch* /Library/Launch* ~/Library/LaunchAgents

Keybase proof

I hereby claim:

  • I am marianposaceanu on github.
  • I am dakull (https://keybase.io/dakull) on keybase.
  • I have a public key ASAh1wAzfMC9-2TW-ZwfKJU7fwtpkS-Yh17tNzAjpAWtHgo

To claim this, I am signing this object:

require 'benchmark'
timings = {}
measure_feature = -> feature_path {
time = Benchmark.measure {
puts "Benchmarking feature #{feature_path}."
cmd = `cucumber --format json -r features '#{feature_path}'`
}