There are many occasions where a function can be optimized under certain assumptions about the system. But since most aspects of Common Lisp can be redefined almost arbitrarily, there are few assumptions that a compiler can generally make. (A notable exception is the behavior of definitions in the CL package, and of built-in objects.)
This file contains hidden or 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
# This code is very hacky, please excuse the nonsensical variable/function naming | |
# See https://twitter.com/David3141593/status/1442883432925773829 for context | |
# Derived from this implementation of XXHASH64: https://github.com/Cyan4973/xxHash/blob/dev/xxhash.h | |
from xxhash import xxh64 | |
XXH_PRIME64_1 = 0x9E3779B185EBCA87 | |
XXH_PRIME64_2 = 0xC2B2AE3D27D4EB4F | |
XXH_PRIME64_3 = 0x165667B19E3779F9 | |
XXH_PRIME64_4 = 0x85EBCA77C2B2AE63 |
This file contains hidden or 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
(ps::defprinter ps-js::await (x) | |
(ps::psw (string-downcase "(await ")) | |
(ps::print-op-argument 'ps-js::await x) | |
(ps::psw ")")) | |
(ps::define-trivial-special-ops | |
await ps-js::await) | |
(ps::define-statement-operator async-defun (name lambda-list &rest body) | |
(multiple-value-bind (effective-args body-block docstring) |
This tutorial describes how to install TLS to a mail server consisting of Postfix and/or Dovecot by using Let's Encrypt certificates with automatic renewing and firewall management.
The system used for this tutorial was:
$ lsb_release -idrc
Distributor ID: Ubuntu
This file contains hidden or 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
;; -*- mode: lisp -*- | |
;; | |
;; A quick and dirty tree shaker for SBCL. Basically, it destroys the | |
;; package system and does a gc before saving the lisp image. Gives | |
;; about a 40% reduction in image size on a basic hello world test. | |
;; Would like to hear how it works on larger projects. | |
;; | |
;; Original idea from: https://groups.google.com/d/msg/comp.lang.lisp/6zpZsWFFW18/WMy4PyA9B4kJ | |
;; | |
;; Burton Samograd |
This file contains hidden or 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
|----------------------------------------------------------------------------------------|--------------------| | |
| Object Header (64 bits) | State | | |
|-------------------------------------------------------|--------------------------------|--------------------| | |
| Mark Word (32 bits) | Klass Word (32 bits) | | | |
|-------------------------------------------------------|--------------------------------|--------------------| | |
| identity_hashcode:25 | age:4 | biased_lock:1 | lock:2 | OOP to metadata object | Normal | | |
|-------------------------------------------------------|--------------------------------|--------------------| | |
| thread:23 | epoch:2 | age:4 | biased_lock:1 | lock:2 | OOP to metadata object | Biased | | |
|-------------------------------------------------------|--------------------------------|--------------------| | |
| |
This file contains hidden or 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
#lang racket | |
(require web-server/http | |
web-server/managers/none | |
web-server/servlet | |
web-server/servlet-env) | |
(provide interface-version manager star-polling-app) | |
(define interface-version 'v2) |