Commit Graph

12 Commits

Author SHA1 Message Date
Dario Rexin
a0272e163e [IRGen] Remove unnecessary default params (#63968)
Also adds type layout strings to analyze_code_size.py
2023-02-28 14:52:14 -08:00
Josh Soref
aec1cab8a2 spelling: uncategorized
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2022-09-15 19:43:37 -04:00
Erik Eckstein
c470c54fe7 Fix the analyze_code_size script after python3 upgrade 2022-05-31 13:00:01 +02:00
Daniel Duan
3dfc40898c [NFC] Remove Python 2 imports from __future__ (#42086)
The `__future__` we relied on is now,  where the 3 specific things are
all included [since Python 3.0](https://docs.python.org/3/library/__future__.html):

* absolute_import
* print_function
* unicode_literals
* division

These import statements are no-ops and are no longer necessary.
2022-04-13 14:01:30 -07:00
Arnold Schwaighofer
acc860a44d analyze_code_size.py: Improve recognition of nested class types and
sort listing by size
2020-06-19 07:39:28 -07:00
Arnold Schwaighofer
674c689626 analyze_code_size.py: provide option to further categorize specialized functions
The categorization can be viewed by using the `-group-specializations` command
line argument.

```
% utils/analyze_code_size.py -arch arm64e -group-specializations -categorize exe
```

Add `-list-group-specializations` to see the individual functions listed
under each group.

Current groups:

Swift.stdlib                class
Standard library specialization with one class type.

Swift.stdlib          class(dict)
Standard library specialization of a dictionary type with a single class type.

Swift.stdlib           foundation
Standard library specialization involving one foundation type (and possibly a
standard library type) or two foundation types.

Swift.stdlib    foundation, class
Standard library specialization where the the first type is from the
Foundation library and the second is a class.

Swift.stdlib                other
Standard library specialization with types other than the ones listed
here.

Swift.stdlib               stdlib
Standard library specialization involving standard library types only.

Swift.stdlib        stdlib, class
Standard library specialization where the the first type is from the
standard library and the second is a class.
2020-06-17 11:05:49 -07:00
Suyash Srijan
61f4731369 Fix python linting 2020-01-23 20:29:35 +00:00
Erik Eckstein
b5e2e021bc utils: change handling of generic specializations in analyze_code_size.py
Two changes:

* If a function is a function signature (or any other) specialization of a generic specialization, count it is generic specialization.
  Function signature speializations are just small modifications of the original function, whereas generic specializations are real copies. So it makes more sense to "prioritize" generic specializations.

* Create a separate category of generic specializations of stdlib functions.
2020-01-23 17:15:42 +01:00
Arnold Schwaighofer
d300684b04 anlysize_code_size.py: Add option to print csv 2019-06-24 08:50:50 -07:00
Arnold Schwaighofer
9364c471cd analyze_code_size.py sort the categories by size 2019-06-21 09:24:56 -07:00
Arnold Schwaighofer
9a968e9a45 analyze_code_size.py: Handle object files and dylibs 2019-02-12 09:59:46 -08:00
Arnold Schwaighofer
bcd3410ce8 Add script to categorize and list functions and data in all sections of an object 2019-02-07 11:20:42 -08:00