microsoft / microsoft/SizeBench
Direct Analysis of Lib File Sizes
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 175
- Forks
- 20
- PR merge metrics
- No merged PRs in 30d
Description
Is your feature request related to a problem? Please describe.
Currently, the tool can only analyze the size of linked PE format files, and cannot directly analyze the size of lib files. This limits our understanding and optimization of the library files themselves.
Describe the solution you'd like
I would like the author to add a new feature that allows direct analysis of lib file sizes, without the need to link them into PE format first. This feature should be able to:
- Read and parse the lib file format
- Display the size of each object file (.obj) within the lib file
- List all symbols (functions and variables) in the lib and their sizes
- Provide overall size statistics for the lib file
- If possible, compare size changes between different versions of lib files
Describe alternatives you've considered
- Using other specialized lib analysis tools, but this requires switching between different tools, which is not convenient.
- Manually unpacking lib files and analyzing the .obj files within, but this process is tedious and prone to errors.
- Modifying the compilation process to generate intermediate files for analysis, but this might affect the normal build process.
Additional context
This feature would help developers better understand and optimize their library files, especially in scenarios where reducing the final executable size is necessary. It can help identify which parts of the code contribute most to the size, thus guiding optimization efforts. Additionally, for cross-platform development, being able to directly analyze lib files for different platforms would also be very helpful.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the tool's existing analysis of linked PE files and determine how lib files and their contained .obj files should be parsed. Define how object sizes, symbol sizes, overall statistics, and optional cross-version comparisons should be represented. Done means direct lib analysis provides the requested size information without linking first.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- devtools
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100