Skip to content

Deadbytes101/DEADWIRE-HTTPD

Repository files navigation

DEADWIRE HTTPD

DEADWIRE HTTPD

SMALL HTTP/1.0 STATIC SERVER. RAW BACKENDS. NO FRAMEWORK.

http asm keep alive framework

Current truth

DEADWIRE HTTPD is a small static HTTP/1.0 server with explicit platform backends.

Linux default is the V2.1 style-fast close-after-response server. The hot path is /style.css.

Windows default remains the stable close-after-response backend. V2 triple-thread remains an opt-in proof runtime.

Official comparison notes live under docs/benchmarks/ and docs/benchmarks/results/.

Speed proof

WSL close-mode /style.css, 4096 requests, 7 rounds
ASMHTTPD_UPSTREAM: DEADWIRE_STYLE_FAST won 3/3 ports, proof-run ratio 1.244x to 1.440x
MINSERV_UPSTREAM: DEADWIRE_STYLE_FAST won, proof-run ratio 2.727x

No broader performance claim is implied. Claims must name the exact build flavor and lane.

Architectural pipeline

flowchart LR
    Client["Client socket"]
    T0["Thread 0<br/>supervisor<br/>process truth"]
    T1["Thread 1<br/>acceptor<br/>owns listen socket"]
    Slot[("one-slot descriptor handoff")]
    T2["Thread 2<br/>HTTP engine<br/>receive parse route send close"]

    Read["read request"]
    Parse["parse method and path"]
    Route{"route decision"}
    Health["/health<br/>prebuilt full response"]
    StyleFast["/style.css<br/>V2.1 style-fast<br/>prebuilt header + embedded CSS body"]
    Static["generic static fallback<br/>build public path<br/>open lseek read close"]
    Error["error response<br/>400 / 403 / 404"]
    Close["close client"]

    T0 -->|starts and watches| T1
    T0 -->|starts and watches| T2
    Client -->|connect| T1
    T1 -->|accept fd| Slot
    Slot -->|single consumer| T2

    T2 --> Read --> Parse --> Route
    Route -->|/health| Health --> Close
    Route -->|/style.css| StyleFast --> Close
    Route -->|existing file path| Static --> Close
    Route -->|bad or missing path| Error --> Close
    Close -->|response bytes then FIN| Client
Loading
NO WORKER POOL
NO THREAD PER CONNECTION
ONE DESCRIPTOR OWNER AT A TIME

Architecture references:

TRIPLE_THREAD_RUNTIME.md
docs/architecture/architectural-pipeline.md
docs/architecture/v2-hot-static-plan.md
docs/architecture/v2-style-fast-contract.md

Build

make clean
make doctor
make verify
make run

Build Linux style-fast default

sh scripts/build-linux-style-fast.sh

This produces both:

build/deadwire                    Linux default executable
build/deadwire_linux_style_fast   named style-fast artifact

Verify V2

make verify-runtime-boundary
make verify-triple-thread

Prove V2.1 style-fast

sh scripts/prove-style-fast.sh

This checks /style.css correctness first, then runs the ASMHTTPD and Minserv score lanes.

Windows build flavors

build/deadwire.exe                 default close-after-response server
build/deadwire_accesslog_off.exe   quiet close-after-response bench server
build/deadwire_keepalive.exe       opt-in keep-alive server
build/deadwire_v2_runtime.exe      opt-in V2 triple-thread proof runtime

Benchmark docs

docs/benchmarks/upstream-asmttpd-score-lane.md
docs/benchmarks/upstream-minserv-score-lane.md
docs/benchmarks/external-assembly-targets.md
docs/benchmarks/results/2026-07-02-wsl-style-fast-proof.md
docs/benchmarks/results/README.md

Milestone status

V2.1 style-fast proof: promoted to Linux default artifact
ASMHTTPD proof lane: passed
Minserv proof lane: passed
web-server-assembly: sanity passed, not feature parity

Limits

REQUEST BUFFER       4096 BYTES
MAX SERVED FILE      65536 BYTES
NO CHUNKED ENCODING
NO PERCENT DECODING YET
NOT TLS
NOT CGI
NOT INTERNET FACING

Every platform boundary is explicit.