Skip to content

Instantly share code, notes, and snippets.

@AttilaFueloep
AttilaFueloep / icp-duration-by-size.bt
Created December 19, 2019 16:40
Bpftrace scripts capturing ICP AES-GCM performance.
// Display time taken by various crypto funcs in nsec., grouped by
// payload length.
struct common_ctx {
void *cc_keysched;
size_t cc_keysched_len;
uint64_t cc_iv[2];
uint64_t cc_remainder[2];
size_t cc_remainder_len;
uint8_t *cc_lastp;
@AttilaFueloep
AttilaFueloep / ghash-x86_64.S.diff
Last active December 19, 2019 15:54
Diff against openssl openssl/crypto/modes/ghash-x86_64.s.
--- ../openssl/crypto/modes/ghash-x86_64.s 2019-10-19 20:15:29.166647251 +0200
+++ module/icp/asm-x86_64/modes/ghash-x86_64.S 2019-12-09 21:15:50.320635370 +0100
@@ -1,864 +1,103 @@
-.text
-
-
-.globl gcm_gmult_4bit
-.type gcm_gmult_4bit,@function
-.align 16
-gcm_gmult_4bit:
@AttilaFueloep
AttilaFueloep / aesni-gcm-x86_64.S.diff
Last active December 16, 2019 21:53
Diff against openssl openssl/crypto/modes/aesni-gcm-x86_64.s.
--- ../openssl/crypto/modes/aesni-gcm-x86_64.s 2019-10-19 20:15:28.989989780 +0200
+++ module/icp/asm-x86_64/modes/aesni-gcm-x86_64.S 2019-12-16 19:32:16.699285141 +0100
@@ -1,3 +1,51 @@
+# Copyright 2013-2016 The OpenSSL Project Authors. All Rights Reserved.
+#
+# Licensed under the Apache License 2.0 (the "License"). You may not use
+# this file except in compliance with the License. You can obtain a copy
+# in the file LICENSE in the source distribution or at
+# https://www.openssl.org/source/license.html
+
@AttilaFueloep
AttilaFueloep / gist:958a746ee623a9e58a9fd2c95bbe370f
Last active April 21, 2018 17:05
Make history_event-zfs-list-cacher.s h manually callable
--- history_event-zfs-list-cacher.sh.orig 2018-04-19 22:44:25.000000000 +0200
+++ history_event-zfs-list-cacher.sh 2018-04-21 13:49:50.033360793 +0200
@@ -10,11 +10,20 @@
# If the pool specific cache file is not writeable, abort
[ -w "${FSLIST}" ] || exit 0
-[ -f "${ZED_ZEDLET_DIR}/zed.rc" ] && . "${ZED_ZEDLET_DIR}/zed.rc"
-. "${ZED_ZEDLET_DIR}/zed-functions.sh"
-
-zed_exit_if_ignoring_this_event