【24h】

Copy-on-write in the PHP language

机译:PHP语言中的复制写入

获取原文

摘要

PHP is a popular language for server-side applications. In PHP, assignment to variables copies the assigned values, according to its so-called copy-on-assignment semantics. In contrast, a typical PHP implementation uses a copy-on-write scheme to reduce the copy overhead by delaying copies as much as possible. This leads us to ask if the semantics and implementation of PHP coincide, and actually this is not the case in the presence of sharings within values. In this paper, we describe the copy-on-assignment semantics with three possible strategies to copy values containing sharings. The current PHP implementation has inconsistencies with these semantics, caused by its naive use of copy-on-write. We fix this problem by the novel mostly copy-on-write scheme, making the copy-on-write implementations faithful to the semantics. We prove that our copy-on-write implementations are correct, using bisimulation with the copy-on-assignment semantics.
机译:PHP是一种流行的服务器端应用程序。在PHP中,根据其所谓的副本 - 赋值语义,分配变量复制分配的值。相反,典型的PHP实现使用副本写入方案来通过尽可能延迟副本来减少复制开销。这导致我们询问PHP的语义和实施是否重合,实际上在价值中的共享情况下并非如此。在本文中,我们描述了具有三种可能的策略的副本 - 赋值语义,以复制包含共享的值。目前的PHP实现与这些语义不一致,由其幼稚的编写方式引起的。我们通过新颖的复制方案来解决这个问题,使编写的依赖于语义的编写型实现。我们证明我们的副本写入实现是正确的,使用与赋值语义进行分配语义的BISIMULATION。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号