JavaScript中的快捷方式融合优化 [英] Shortcut fusion optimization in javascript
问题描述
我听说lodash和其他javascript库使用一种称为快捷键融合"的技术进行优化,但是找不到任何对该技术的详细说明.
I have heard that lodash and other javascript libraries use a technique called 'shortcut fusion' for optimization but couldn't find a detailed explanation of the technique anywhere.
任何人都可以提供链接或以示例方式解释捷径融合"的含义吗?
Can anyone provide a link or explain with an example what 'shortcut fusion' means?
推荐答案
一个简短而不清楚的解释- https: //wiki.haskell.org/Short_cut_fusion
For a very short and unclear explanation - https://wiki.haskell.org/Short_cut_fusion
即使对于Haskell,我仍然找不到详细的解释.我能找到的最接近详细的解释是在书的一章中- http://link.springer.com/chapter/10.1007%2F978-3-642-32037-8_12#page-1
I still couldn't find a detailed explanation, even for Haskell. The closest to detailed explanation i could find was in a chapter in a book - http://link.springer.com/chapter/10.1007%2F978-3-642-32037-8_12#page-1
本章以pdf格式免费提供- http://www .fing.edu.uy/〜pardo/papers/tfp2011.pdf
The chapter is available for free as a pdf - http://www.fing.edu.uy/~pardo/papers/tfp2011.pdf
更多论文-
- 用于累积参数&的捷径融合类似于zip的函数- http://www.cse.chalmers.se/~ josefs/publications/fusion.pdf
- 具有计算效果的递归程序的捷径融合- https://personal.cis.strath.ac.uk/neil.ghani/papers/ghani-tfp08.pdf
- Shortcut fusion for accumulation parameters & zip-like functions - http://www.cse.chalmers.se/~josefs/publications/fusion.pdf
- Short Cut Fusion of Recursive Programs with Computational Effects - https://personal.cis.strath.ac.uk/neil.ghani/papers/ghani-tfp08.pdf
这看起来像是学术论文的兔子洞. 捷径融合"上最有用的链接是有关超级怪异/数学学术论文的.比我在这里可以咀嚼的要多得多.
This looks like a rabbit hole of academic papers. Most useful links on 'shortcut fusion' are for super geeky/mathematical academic papers. Bit much more than i can chew here.
P.S. -当我找到它们时,将继续用更多详细信息更新此答案.
P.S. - Will keep updating this answer with more details as i find them.
这篇关于JavaScript中的快捷方式融合优化的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!