angr.analyses.decompiler.semantic_naming.size_naming

Semantic variable naming for size/length/count variables.

This module detects variables used as sizes, lengths, or counts and names them appropriately (e.g., size, len, count, n).

class angr.analyses.decompiler.semantic_naming.size_naming.SizeNaming

Bases: ClinicNamingBase

Detects variables used as sizes, lengths, or counts based on: 1. Being passed as size parameters to known functions 2. Being used in loop bounds (compared with loop counters) 3. Having names that suggest size semantics

PRIORITY: int = 70
__init__(*args, **kwargs)
analyze()

Analyze the graph for size/length variable patterns.

Return type:

dict[SimVariable, str]

Returns:

Dictionary mapping SimVariable to new name