Skip to content

Instantly share code, notes, and snippets.

This file has been truncated, but you can view the full file.
ticks:0x1234eb0c5 rip:0x70000002
ticks:0x1234eb0c5 rip:0x70000002
ticks:0x1234eb0c5 rip:0x7fd8c08f250c
ticks:0x1234eb0c5 rip:0x7fd8c08f250e
ticks:0x1234eb0c5 rip:0x7fd8c08f2515
ticks:0x1234eb0c5 rip:0x7fd8c08f2519
ticks:0x1234eb0c5 rip:0x7fd8c08ed71e
ticks:0x1234eb0c5 rip:0x7fd8c08ed722
ticks:0x1234eb0c5 rip:0x7fd8c08efaf9
ticks:0x1234eb0c5 rip:0x7fd8c08efafc
julia> foreach(println, equations(sys))
0 ~ var"0"(t) - v1₊n₊v(t)
0 ~ var"0"(t) - r1₊n₊v(t)
0 ~ var"0"(t) - c1₊n₊v(t)
0 ~ var"0"(t)
0 ~ d1₊p₊i(t) + v1₊p₊i(t)
0 ~ net1(t) - v1₊p₊v(t)
0 ~ net1(t) - d1₊p₊v(t)
0 ~ c1₊p₊i(t) + d1₊n₊i(t) + r1₊p₊i(t)
0 ~ net2(t) - d1₊n₊v(t)
struct effects {
// Meaning of concepts:
//
// idempotent - The function will always return the same value when given
// identical argument, irrespective of the heap state. In
// particular, this means that the return value (or any other
// side effect) does not depend on non-constant globals, loads
// from memory, or mutable structs.
//
// effect_free - The function has no side effects at all. In particular,
# ∂⃖rrule has a 4-recurrence - we model this as 4 separate structs that we
# cycle between. N.B.: These names match the names that these variables
# have in Snippet 19 of the terminology guide. They are probably not ideal,
# but if you rename them here, please update the terminology guide also.
struct ∂⃖rruleA{N, O}; ∂; ȳ; ȳ̄ ; end
struct ∂⃖rruleB{N, O}; ᾱ; ȳ̄ ; end
struct ∂⃖rruleC{N, O}; ȳ̄ ; Δ′′′; β̄ ; end
struct ∂⃖rruleD{N, O}; γ̄; β̄ ; end
@Keno
Keno / extract-loh.ll
Created February 25, 2021 23:15
llc -O3 -fast-isel -mcpu apple-a12 extract-loh.ll
; ModuleID = 'text.bc'
source_filename = "text"
target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128"
target triple = "arm64-apple-macosx-macho"
@jl_undefref_exception = external constant {}*
@_MergedGlobals = external hidden global <{ void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void
@Keno
Keno / gist:99c49ee7f3e4f262e5ae8551dbc585fa
Created February 25, 2021 17:23
~/llvm-project-build/bin/llc -mtriple arm64-apple-darwin20.0.0 -mcpu apple-a12 -code-model=small -O0 -fast-isel -o - x.ll
; ModuleID = 'f'
source_filename = "f"
target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128"
target triple = "arm64-apple-darwin20.0.0"
@llvm.compiler.used = appending global [3 x i8*] [i8* bitcast (void ({}*)* @jl_gc_queue_root to i8*), i8* bitcast ({}* (i8*, i32, i32)* @jl_gc_pool_alloc to i8*), i8* bitcast ({}* (i8*, i64)* @jl_gc_big_alloc to i8*)], section "llvm.metadata"
; @ REPL[15]:1 within `f'
; Function Attrs: sspstrong
define nonnull {}* @julia_f_1854(i32 signext %0) #0 !dbg !5 {
@Keno
Keno / gist:a2bb9385fa9b0426df057b9b37652980
Last active February 25, 2021 00:57
./bin/llc -mtriple arm64-apple-darwin20.0.0 -mcpu apple-a12 -code-model=small -O3 -fast-isel
; ModuleID = 'bugpoint-reduced-simplified.bc'
source_filename = "text"
target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128"
target triple = "arm64-apple-macosx-macho"
@jl_undefref_exception = external constant {}*
@jl_emptytuple = external constant {}*
@_j_str3 = external hidden unnamed_addr constant [11 x i8]
@_MergedGlobals = external hidden global <{ void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void ()*, void
@Keno
Keno / tcpstate.c
Last active December 11, 2020 23:45
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <unistd.h>
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <poll.h>
#include <signal.h>
reMarkable: ~/julia-bc94c501b6/ strace ./bin/julia -e 'using ICU_jll'
execve("./bin/julia", ["./bin/julia", "-e", "using ICU_jll"], 0x7ed979e8 /* 27 vars */) = 0
brk(NULL) = 0xf15000
uname({sysname="Linux", nodename="reMarkable", ...}) = 0
mmap2(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x76f7f000
readlink("/proc/self/exe", "/home/root/julia-bc94c501b6/bin/"..., 4096) = 37
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/home/root/julia-bc94c501b6/bin/../lib/tls/v7l/neon/vfp/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat64("/home/root/julia-bc94c501b6/bin/../lib/tls/v7l/neon/vfp", 0x7eb26220) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/home/root/julia-bc94c501b6/bin/../lib/tls/v7l/neon/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
No. Time Source Destination Protocol Length Info
282276 535.497236 127.0.0.1 127.0.0.1 TCP 68 57818 → 9362 [SYN] Seq=0 Win=65535 Len=0 MSS=16344 WS=64 TSval=1995819806 TSecr=0 SACK_PERM=1
282277 535.497361 127.0.0.1 127.0.0.1 TCP 68 9362 → 57818 [SYN, ACK] Seq=0 Ack=1 Win=65535 Len=0 MSS=16344 WS=64 TSval=1995819806 TSecr=1995819806 SACK_PERM=1
282278 535.497369 127.0.0.1 127.0.0.1 TCP 56 57818 → 9362 [ACK] Seq=1 Ack=1 Win=408256 Len=0 TSval=1995819806 TSecr=1995819806
282279 535.497374 127.0.0.1 127.0.0.1 TCP 56 [TCP Window Update] 9362 → 57818 [ACK] Seq=1 Ack=1 Win=408256 Len=0 TSval=1995819806 TSecr=1995819806
282280 535.497516 127.0.0.1 127.0.0.1 TCP 210 57818 → 9362 [PSH, ACK] Seq=1 Ack=1 Win=408256 Len=154 TSval=1995819806 TSecr=1995819806
282281 535.497528 127.0.0.1 127.0.0.1 TCP 56 9362 → 57818 [ACK] Seq=1 Ack=155 Win=408128 Len=0 TSval=1995819806 TSecr=1995819806
282288 537.014532 127.0.0.1 127.0.0.1 TCP 121 9362 → 57818 [PSH, ACK] Seq=1 Ack=155 Win=408128 Len=65 TSval=1995821311 TSecr=1995819806
282