- Parallel Computing Course - Stanford CS149, Fall 2023
- Performance-Aware Programming Series by Casey Muratori
- Algorithms for Modern Hardware
- Computer Systems: A Programmer's Perspective, 3/E - by Randal E. Bryant and David R. O'Hallaron, Carnegie Mellon University
- Performance Engineering Of Software Systems - am MITOCW course
- Parallel Programming 2020 by NHR@FAU
- Cpu Caches and Why You Care
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Needs Bun | |
import biome from './biome.json'; | |
// Extracted from https://biomejs.dev/linter/rules/#recommended-rules | |
const recommended = (await Bun.file('./recommended.txt').text()) | |
.split('\n') | |
.map((x: string) => x.trim()) | |
.filter(Boolean); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Per https://code.google.com/p/v8/codesearch#v8/trunk/src/runtime.cc | |
%CreateSymbol | |
%CreatePrivateSymbol | |
%CreateGlobalPrivateSymbol | |
%NewSymbolWrapper | |
%SymbolDescription | |
%SymbolRegistry | |
%SymbolIsPrivate |
%GetOptimizationStatus
return a set of bitwise flags instead of a single value,
to access the value, you need to take the binary representation of the returned value.
Now, for example, if 65
is returned, the binary representation is the following:
(65).toString(2).padStart(12, '0');
// 000001000001
Each binary digit acts as a boolean with the following meaning:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://medium.com/google-cloud/node-to-google-cloud-compute-engine-in-25-minutes-7188830d884e | |
curl -sL https://deb.nodesource.com/setup_10.x | sudo bash - | |
sudo apt install nodejs | |
#install dependencies | |
#https://github.com/GoogleChrome/puppeteer/issues/290#issuecomment-322838700 | |
sudo apt-get install gconf-service libasound2 libatk1.0-0 libc6 libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 libgcc1 libgconf-2-4 libgdk-pixbuf2.0-0 libglib2.0-0 libgtk-3-0 libnspr4 libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxrandr2 libxrender1 libxss1 libxtst6 ca-certificates fonts-liberation libappindicator1 libnss3 lsb-release xdg-utils wget |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Source: | |
# https://www.cloudflare.com/ips | |
# https://support.cloudflare.com/hc/en-us/articles/200169166-How-do-I-whitelist-CloudFlare-s-IP-addresses-in-iptables- | |
for i in `curl https://www.cloudflare.com/ips-v4`; do iptables -I INPUT -p tcp -m multiport --dports http,https -s $i -j ACCEPT; done | |
for i in `curl https://www.cloudflare.com/ips-v6`; do ip6tables -I INPUT -p tcp -m multiport --dports http,https -s $i -j ACCEPT; done | |
# Avoid racking up billing/attacks | |
# WARNING: If you get attacked and CloudFlare drops you, your site(s) will be unreachable. | |
iptables -A INPUT -p tcp -m multiport --dports http,https -j DROP |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* WordPress opcache preloading. | |
* Requires PHP >= 7.4. | |
* | |
* @author Konrad Fedorczyk <contact@realhe.ro> | |
* @link https://stitcher.io/blog/preloading-in-php-74 | |
* | |
* @version 1.0.0 | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// pnpm -r -c exec 'node /path/to/machette.js' | |
const util = require('util'); | |
const exec = util.promisify(require('child_process').exec); | |
const process = require('process'); | |
const path = require('path'); | |
async function main() { | |
const cwd = process.cwd(); |
The following is adapted from original instructions at https://www.expressvpn.com/support/vpn-setup/app-for-linux/#install
- Log in from browser: https://www.expressvpn.com/sign-in
- Copy activation code to clipboard
- Download the
.deb
installation file - Go to terminal
cd ~/Downloads
sudo dpkg -i [installer file]
expressvpn activate
- Paste activation code from clipboard when asked. There is no visual feedback, so be careful to paste only once asked and press enter if need be.
NewerOlder