Skip to content

mach0 refactoring #5317

@wargio

Description

@wargio

Mach0 is currently implemented with many quirks, where the buffer is parsed many times.

Probably the author tried to optimize the loading by consuming less memory in favor of slower loading; this leads to many weird parsing patterns scattered across the code where structures are not kept in memory, but instead parsed and freed multiple times, where some functions do the same job but with slightly different results.

Examples:
https://github.com/rizinorg/rizin/blob/dev/librz/bin/format/mach0/mach0.c#L353
https://github.com/rizinorg/rizin/blob/dev/librz/bin/format/mach0/mach0.c#L1423

Metadata

Metadata

Assignees

Labels

Mach-OperformanceA performance problem/enhancementrefactorRefactoring requests

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions