• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

extphprs / ext-php-rs
66%
master: 66%

Build:
Build:
LAST BUILD BRANCH: dependabot/github_actions/nhedger/setup-mago-2
DEFAULT BRANCH: master
Repo Added 29 Oct 2025 05:59AM UTC
Files 96
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

LAST BUILD ON BRANCH perf/precompute-mangled-property-names
branch: perf/precompute-mangled-property-names
CHANGE BRANCH
x
Reset
  • perf/precompute-mangled-property-names
  • 102_refs
  • 138_inheritance
  • 173_simple_extends_and_implements
  • 176_getter_test
  • 182_objects_in_props
  • 184_missing_property_types_in_stubs
  • 186_stubs_constants
  • 191_zend_callable
  • 199_union_intersection_dnf
  • 237_zval_flags
  • 252_static_props_and_methods
  • 310_performance
  • 325_static_str
  • 369_better_stubs
  • 424_zval_heap_corruption
  • 492_lit_suffixes_in_defaults
  • 493_feat_sets_in_arguments
  • 499_document_superglobals
  • 502_returning_self
  • 508_php_write
  • 515_ref_mutability
  • 518_cargo_php_install
  • 522_indexmap
  • 523_custom_allocator_and_stubs
  • 525_zend_ht_entry
  • 536_identifiers
  • 537_zend_bailout
  • 538_nullable_param
  • 590_interfaces
  • 599-add-performance-test-infrastructure
  • abstract_methods
  • add-grpc-php-rs
  • add-sapi-send-headers
  • add-sapi-zts-test
  • cargo_watch
  • chore/add-coc
  • chore/bump-edition-2024
  • chore/cargo-php-stubs-tests
  • chore/context7
  • chore/mago-php-formatting
  • chore/php-8-5
  • chore/php-86-nightly
  • ci/musl
  • ci/zts-embed
  • codspeed-wizard-1776277848593
  • customize-guide-logo
  • dependabot/cargo/convert_case-0.10.0
  • dependabot/cargo/convert_case-0.11.0
  • dependabot/cargo/convert_case-0.9.0
  • dependabot/cargo/darling-0.23
  • dependabot/cargo/libloading-0.9
  • dependabot/cargo/zip-7.0
  • dependabot/cargo/zip-8.0
  • dependabot/github_actions/JamesIves/github-pages-deploy-action-4.7.4
  • dependabot/github_actions/JamesIves/github-pages-deploy-action-4.7.6
  • dependabot/github_actions/JamesIves/github-pages-deploy-action-4.8.0
  • dependabot/github_actions/actions/cache-5
  • dependabot/github_actions/actions/checkout-6
  • dependabot/github_actions/actions/github-script-8
  • dependabot/github_actions/actions/github-script-9
  • dependabot/github_actions/actions/upload-artifact-7
  • dependabot/github_actions/dawidd6/action-download-artifact-19
  • dependabot/github_actions/dawidd6/action-download-artifact-20
  • dependabot/github_actions/dawidd6/action-download-artifact-21
  • dependabot/github_actions/docker/build-push-action-7
  • dependabot/github_actions/docker/setup-buildx-action-4
  • dependabot/github_actions/nhedger/setup-mago-2
  • docs/move-showcase-to-awesome
  • embed-zts
  • feat/cache-slot-property-lookup
  • feat/cargo-llvm-cov
  • feat/embed-php-code
  • feat/error-observer
  • feat/interface_impl
  • feat/issue-199-primitive-union-types
  • feat/module-globals
  • feat/observer-api
  • feat/sapi-trait-and-zts
  • feat/separated-phpref-types
  • feat/static-property-descriptors
  • feat/zend-extension
  • feat/zend-string-hashtable-keys
  • feat/zero-alloc-fast-path
  • feat/zval-ref-deref-inline
  • feat_immutable_empty_array
  • feat_zval_coercion
  • fix-valid-method-name
  • fix-windows-symbols
  • fix/184-property-type-stubs
  • fix/729-binary-interned-heap-corruption
  • fix/740-drop-clang-sys-fork
  • fix/bencher-host
  • fix/binary-return-memory-leak
  • fix/cargo-php-install-musl
  • fix/ci-badge-workflow-reference
  • fix/clang-arm64-preserve-none
  • fix/class-object-refcount-leak
  • fix/clippy--
  • fix/clippy-1-93-0
  • fix/clippy-1-95-0
  • fix/clippy-hasher
  • fix/clippy-rust-1-91
  • fix/cloning-class
  • fix/deploy-doc
  • fix/disable-zts-embed
  • fix/github-templates
  • fix/mock-unint
  • fix/module-entry-memory-leak
  • fix/musl-8-5-build
  • fix/null-pointer-sapi-trampolines
  • fix/parking-lot-min-version
  • fix/releaze-plz-workflow
  • fix/releaze-plz-workflow-permission
  • fix/segfault-empy-array
  • fix/string-prop-getter-zend-string-leak
  • fix/use-fork-bindgen
  • fix/windows-bindgen-nommx
  • fix/windows-dev-pack
  • fix/windows-link-attr-without-rustfmt
  • fix_prop_visibility
  • fix_stub_gen
  • hotload
  • json_serializable
  • lazy
  • master
  • named_arguments
  • patch-1
  • perf/zend-string-init-fast
  • raw-dylib-fix
  • readonly_class
  • release-plz-2025-10-29T06-23-17Z
  • release-plz-2025-10-29T13-44-17Z
  • release-plz-trigger
  • release-plz-trigger-v2
  • release-plz-trigger-v3
  • remove-php80-testing
  • showcase
  • smartstring
  • trusted-publishing

14 Apr 2026 08:29PM UTC coverage: 66.211% (-0.09%) from 66.299%
24421347301

Pull #724

github

ptondereau
perf: pre-compute mangled property names in get_properties

The get_properties handler (called by var_dump, print_r, json_encode,
serialization) was calling format!() per property per invocation to
build PHP-convention mangled names. This allocated on every call.

PHP itself computes mangled names once at class registration time
(zend_mangle_property_name in zend_compile.c) and reuses them forever.

This commit brings the same approach:
- Field properties: the proc macro emits the mangled name as a
  compile-time string literal in PropertyDescriptor. Zero runtime cost.
- Method properties: mangled names are computed once on first access
  and cached in ClassMetadata via OnceCell. One allocation per class
  for the entire process lifetime.
- get_properties handler reads pre-computed names instead of format!().

Benchmark results (callgrind, 100k iterations):
  property_dump: -21.4% instructions, -20.0% estimated cycles
  property_read: +1.4% (struct size overhead, acceptable)
  property_write: +1.6% (struct size overhead, acceptable)
Pull Request #724: perf: pre-compute mangled property names in get_properties

6 of 34 new or added lines in 3 files covered. (17.65%)

8426 of 12726 relevant lines covered (66.21%)

33.36 hits per line

Relevant lines Covered
Build:
Build:
12726 RELEVANT LINES 8426 COVERED LINES
33.36 HITS PER LINE
Source Files on perf/precompute-mangled-property-names
  • Tree
  • List 95
  • Changed 4
  • Source Changed 4
  • Coverage Changed 4
Coverage ∆ File Lines Relevant Covered Missed Hits/Line

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
24421347301 perf/precompute-mangled-property-names perf: pre-compute mangled property names in get_properties The get_properties handler (called by var_dump, print_r, json_encode, serialization) was calling format!() per property per invocation to build PHP-convention mangled names. This allocate... Pull #724 14 Apr 2026 08:32PM UTC ptondereau github
66.21
24421322317 perf/precompute-mangled-property-names fix: resolve rustdoc broken intra-doc link for ClassMetadata push 14 Apr 2026 08:32PM UTC ptondereau github
66.21
24421185838 perf/precompute-mangled-property-names perf: pre-compute mangled property names in get_properties The get_properties handler (called by var_dump, print_r, json_encode, serialization) was calling format!() per property per invocation to build PHP-convention mangled names. This allocate... push 14 Apr 2026 08:29PM UTC ptondereau github
66.21
24421201405 perf/precompute-mangled-property-names Merge eccf8c6c4 into 13625029f Pull #724 14 Apr 2026 08:29PM UTC web-flow github
66.21
24420229769 perf/precompute-mangled-property-names Merge pull request #721 from extphprs/release-plz-2026-04-14T11-48-12Z chore: release push 14 Apr 2026 08:06PM UTC web-flow github
66.3
See All Builds (987)
  • Repo on GitHub
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc