Improve cost of container commit #1216
All Vouch review confidence checks passed
Residual risk 0.21 = Change Risk (0.39) × (1 − Review Confidence (0.47)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.39 · 248 lines diff across 3 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Shallow Review Depth
shallow_review_depth
0.344
Diff Size
diff_size
0.330
Real PR Conversation Timeline
1 comments
"Review active on #1216"
general
weight: 0.35
mtrmac
The recent security fixes, in addition to the core write escapes, also switched to use
os.Rootfor creating tar archives. Becauseos.Rootresolves deeply nested paths one directory at a time, that is more costly, particularly with FUSE. Improve some of that performance again.statand xattr abstractions frompkg/systemtointernal/…. We just added publicstat.RootL…and they are now unused, so let’s not make that mistake again.root.Lstatcalls when the data is already provided by fs.WalkDir(), instead using a single root at the top level (paying the cost of the directory walk on each operation), create also a per-directoryparentRootand do all operations only on base names. The current plan in Go is to replace the directory walk with a singleopenat2syscall, but they would still do a separate syscall for the actual operation; so, using aparentRoot, we can eliminate (currently) the directory walk and (in the future) theopenat2., so that consecutive operations on files in the same directory don’t need to open the directory repeatedly.operation, where we are doing the directory walk manually, also use the cache and use basename-only operations.or similar handle of the individual file. Instead of creating that for each syscall, manage the lifetime explicitly as anxattr.Handle.This is not ideal, but to do better we’d need to wholly replace fs.WalkDir
, with something more complex (e.g. keeping the last 10 or so parent handles). That can still be done in the future; and if it eliminates the need ofrootlookupcache`, we can just drop it again.Mostly mitigates https://github.com/podman-container-tools/podman/issues/29833 , see there for some numbers.