Skip to content

[SR-11744] Decrease Swift Runtime Size (for use on embedded devices) #3376

Open
@swift-ci

Description

@swift-ci
Previous ID SR-11744
Radar None
Original Reporter allright (JIRA User)
Type Improvement

Attachment: Download

Additional Detail from JIRA
Votes 3
Component/s Foundation, Standard Library
Labels Improvement, CodeSize, Performance
Assignee None
Priority Medium

md5: a854b179881f306ef61ed6d148fea3b9

Issue Description:

Too big size of:

libicudataswift.so (26.9 Mb)

libFoundation.so (13.2 Mb)

It is possible to use Swift on Android native level(under JNI) for cross-platform business-logic, and some middle-level UI code (ViewModels & etc) (MVVM pattern).

But it dramatically increase Android App Size.

But in comparison with C++, it is too big libraries size.

Is it possible to decrease, or to make special "embedded" version of swift RunTime?

Is it possible to compile for different ARM processors?

Is it possible to remove some unneeded parts while building library?

Is it possible to remove some safety code from Swift libraries, to decrease the size?

Also may be a good decision will be to use static libraries for embedded use.

Example project is Readdle:

https://blog.readdle.com/why-we-use-swift-for-android-db449feeacaf

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions