{"title":"HappyJIT:用于PHP的跟踪JIT编译器","authors":"Andrei Homescu, Alex Suhan","doi":"10.1145/2047849.2047854","DOIUrl":null,"url":null,"abstract":"Current websites are a combination of server-generated dynamic content with client-side interactive programs. Dynamically - typed languages have gained a lot of ground in both of these domains. The growth of Web 2.0 has introduced a myriad of websites which contain personalized content, which is specific to the user. PHP or Python programs generate the actual HTML page after querying a database and processing the results, which are then presented by the browser. It is becoming more and more vital to accelerate the execution of these programs, as this is a significant part of the total time needed to present the page to the user.\n This paper presents a novel interpreter for the PHP language written in RPython, which the PyPy translator then translates into C. The translator integrates into the interpreter a tracing just-in-time compiler which optimizes the hottest loops in the interpreted programs. We also describe a data model that supports all the data types in the PHP language, such as references and iterators. We evaluate the performance of this interpreter, showing that speedups up to a factor of 8 are observed using this approach.","PeriodicalId":344101,"journal":{"name":"Dynamic Languages Symposium","volume":"81 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2011-10-24","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"20","resultStr":"{\"title\":\"HappyJIT: a tracing JIT compiler for PHP\",\"authors\":\"Andrei Homescu, Alex Suhan\",\"doi\":\"10.1145/2047849.2047854\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"Current websites are a combination of server-generated dynamic content with client-side interactive programs. Dynamically - typed languages have gained a lot of ground in both of these domains. The growth of Web 2.0 has introduced a myriad of websites which contain personalized content, which is specific to the user. PHP or Python programs generate the actual HTML page after querying a database and processing the results, which are then presented by the browser. It is becoming more and more vital to accelerate the execution of these programs, as this is a significant part of the total time needed to present the page to the user.\\n This paper presents a novel interpreter for the PHP language written in RPython, which the PyPy translator then translates into C. The translator integrates into the interpreter a tracing just-in-time compiler which optimizes the hottest loops in the interpreted programs. We also describe a data model that supports all the data types in the PHP language, such as references and iterators. We evaluate the performance of this interpreter, showing that speedups up to a factor of 8 are observed using this approach.\",\"PeriodicalId\":344101,\"journal\":{\"name\":\"Dynamic Languages Symposium\",\"volume\":\"81 1\",\"pages\":\"0\"},\"PeriodicalIF\":0.0000,\"publicationDate\":\"2011-10-24\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"20\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"Dynamic Languages Symposium\",\"FirstCategoryId\":\"1085\",\"ListUrlMain\":\"https://doi.org/10.1145/2047849.2047854\",\"RegionNum\":0,\"RegionCategory\":null,\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"\",\"JCRName\":\"\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"Dynamic Languages Symposium","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/2047849.2047854","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
Current websites are a combination of server-generated dynamic content with client-side interactive programs. Dynamically - typed languages have gained a lot of ground in both of these domains. The growth of Web 2.0 has introduced a myriad of websites which contain personalized content, which is specific to the user. PHP or Python programs generate the actual HTML page after querying a database and processing the results, which are then presented by the browser. It is becoming more and more vital to accelerate the execution of these programs, as this is a significant part of the total time needed to present the page to the user.
This paper presents a novel interpreter for the PHP language written in RPython, which the PyPy translator then translates into C. The translator integrates into the interpreter a tracing just-in-time compiler which optimizes the hottest loops in the interpreted programs. We also describe a data model that supports all the data types in the PHP language, such as references and iterators. We evaluate the performance of this interpreter, showing that speedups up to a factor of 8 are observed using this approach.