mirror of
https://github.com/slint-ui/slint.git
synced 2025-08-03 18:29:09 +00:00
![]() SmolStr has an Arc internally for large strings. This allows cheap copies of large strings, but we lose that ability when we convert the SmolStr to a &str and then reconstruct a SmolStr from that slice. I was hoping for some larger gains here, considering the impact of this code change, but it only removes ~50k allocations, while the impact on the runtime is not noticeable at all. Still, I believe this is the right thing to do. Before: ``` allocations: 2338981 Time (mean ± σ): 988.3 ms ± 17.9 ms [User: 690.2 ms, System: 206.4 ms] Range (min … max): 956.4 ms … 1016.3 ms 10 runs ``` After: ``` allocations: 2287723 Time (mean ± σ): 989.8 ms ± 23.2 ms [User: 699.2 ms, System: 197.6 ms] Range (min … max): 945.3 ms … 1021.4 ms 10 runs ``` |
||
---|---|---|
.. | ||
generator | ||
LICENSES | ||
llr | ||
lookup | ||
parser | ||
parser-test-macro | ||
passes | ||
tests | ||
widgets | ||
build.rs | ||
builtin_macros.rs | ||
builtins.slint | ||
Cargo.toml | ||
diagnostics.rs | ||
embedded_resources.rs | ||
expression_tree.rs | ||
fileaccess.rs | ||
generator.rs | ||
langtype.rs | ||
layout.rs | ||
lexer.rs | ||
lib.rs | ||
literals.rs | ||
llr.rs | ||
load_builtins.rs | ||
lookup.rs | ||
namedreference.rs | ||
object_tree.rs | ||
parser.rs | ||
passes.rs | ||
pathutils.rs | ||
README.md | ||
typeloader.rs | ||
typeregister.rs |
The Slint Compiler Library
NOTE: This library is an internal crate of the Slint project.
This crate should not be used directly by applications using Slint.
You should use the slint
crate instead.
WARNING: This crate does not follow the semver convention for versioning and can
only be used with version = "=x.y.z"
in Cargo.toml.