Major Features: - Debug counter infrastructure for Refill Stage tracking - Free Pipeline counters (ss_local, ss_remote, tls_sll) - Diagnostic counters for early return analysis - Unified larson.sh benchmark runner with profiles - Phase 6-3 regression analysis documentation Bug Fixes: - Fix SuperSlab disabled by default (HAKMEM_TINY_USE_SUPERSLAB) - Fix profile variable naming consistency - Add .gitignore patterns for large files Performance: - Phase 6-3: 4.79 M ops/s (has OOM risk) - With SuperSlab: 3.13 M ops/s (+19% improvement) This is a clean repository without large log files. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
29 lines
621 B
C
29 lines
621 B
C
// hakmem_tiny_rss.c
|
|
// Phase 2B-2: RSS Monitoring
|
|
// Extracted from hakmem_tiny.c (lines 1665-1682)
|
|
|
|
#include <stdio.h>
|
|
#include <stdlib.h>
|
|
#include <string.h>
|
|
|
|
#include "hakmem_tiny_rss_api.h"
|
|
|
|
int get_rss_kb_self(void) {
|
|
FILE* f = fopen("/proc/self/status", "r");
|
|
if (!f) return 0;
|
|
char buf[256];
|
|
int kb = 0;
|
|
while (fgets(buf, sizeof(buf), f)) {
|
|
if (strncmp(buf, "VmRSS:", 6) == 0) {
|
|
char* p = buf;
|
|
while (*p && (*p < '0' || *p > '9')) {
|
|
p++;
|
|
}
|
|
kb = atoi(p);
|
|
break;
|
|
}
|
|
}
|
|
fclose(f);
|
|
return kb;
|
|
}
|