YSRossi

@YSRossi

Joined on Oct 17, 2020

  • 任務簡述 依據 ktcp 的指示,我們可在 sysprog21/khttpd 的程式碼基礎之上,打造出高效且穩定的網頁伺服器,不過 Linux 核心模組建構和維護的成本極高,本任務嘗試以 eBPF 來建構 TCP 伺服器。需要確保在 Linux v5.15+ 運作。 相關資訊: ebpf-proxy-test: Compare a proxy-server using ebpf sockmap redirect with a normal proxy server using poll. ebpf-summit-2020: Steering connections to sockets with BPF socket lookup hook 每秒 1 百萬個封包傳輸 需要自行安裝 libbpf
     Like  Bookmark
  • contributed by < YSRossi > 開發環境 $ gcc --version gcc (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0 $ lscpu Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Address sizes: 48 bits physical, 48 bits virtual
     Like  Bookmark
  • contributed by < YSRossi > 開發環境 $ gcc --version gcc (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0 $ lscpu Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Address sizes: 48 bits physical, 48 bits virtual
     Like  Bookmark
  • contributed by < YSRossi > 開發環境 $ gcc --version gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0 $ lscpu Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Byte Order: Little Endian
     Like  Bookmark
  • contributed by < YSRossi > 測驗 4 int ceil_log2(uint32_t x) { uint32_t r, shift; x--; r = (x > 0xFFFF) << 4; x >>= r;
     Like  Bookmark
  • contributed by < YSRossi > 測驗 1 uint64_t next_pow2(uint64_t x) { x |= x >> 1; x |= x >> 1; x |= x >> 1; x |= x >> 1; x |= x >> 1;
     Like  Bookmark