Jan 29, 2010
We are very happy to announce the website of Tidier, an automatic
refactoring tool for Erlang programs.
Tidier cleans up Erlang source code and suggests to its user a sequence
of transformations that improve the quality and performance of code.
More information about tidier can be found at its website (*):
http://tidier.softlab.ntua.gr/
We welcome feedback and suggestions!
Kostis Sagonas and Thanassis Avgerinos
俺很期待的东西.试验了下,可以上传erl文件或者整个项目的包上去, tidier果然很争气的找出有问题或者需要改进的地方
,效果相当的好. Erlang R13B04的代码都是经过tidier的. 唯一不好一点就是不开源,使用上有点受限,但是我们还是很感激的.
一起来吧从这里开始: http://tidier.softlab.ntua.gr:20000/tidier/getstarted
Erlang/OTP R13B04 has been released. R13B04 is a service release for R13B. There are mostly error corrections, but also some new functionality.
This is the first release after the introduction of the official Git repository at Github and it is amazing to notice that the number of contributions from the community has increased significantly. As many as 32 contributors have provided 1 or more patches each until now, resulting in 51 integrated patches from the open source community in this service release.
In addition to the contributions provided by the community we have the following examples of highlights in the release:
* The documentation can now be built from the source.
* The Native Implemented Functions (NIFs) are still in beta, but much enhanced.
* The garbage collection of binaries is further enhanced.
* Support for user defined prompt in the shell. A small but useful new function.
* Enhanced cross compilation support
*BUG fix版本,细细碎碎的改进了不少. 添加了个lcnt工具
OTP-8335 NIF improvements:
Driver API for multi-threading made available for NIFs.
Support for mempory managed (garbage collected) resource objects.
A way to pass “pointers” to native data structures between C and
Erlang in a safe way.
Various new functions, like enif_inspect_iolist_as_binary,
enif_make_sub_binary, enif_get_string, enif_get_atom,
enif_make_tuple_from_array, enif_make_list_from_array,
enif_make_existing_atom.
在调试版本下 这个工具可以直观的看出你的Erlang程序所用到的锁,对于诊断问题和提高性能非常有帮助.
OTP-8424 Add lock profiling tool.
The Lock profiling tool, lcnt, can make use of the internal lock
statistics when the runtime system is built with this feature
enabled.
This provides a mechanism to examine potential lock bottlenecks
within the runtime itself.
– Add erts_debug:lock_counters({copy_save, bool()}). This option
enables or disables statistics saving for destroyed processes and
ets-tables. Enabling this might consume a lot of memory.
– Add id-numbering for lock classes which is otherwise undefined.
R13B04后erlang的源码编译为了考虑移植性,就改变了编译方式,以下是官方wiki上的安装文档:
1. Cloning
Here are the basic steps to build Erlang/OTP in the Git repository.
Start by cloning:
git clone git://github.com/erlang/otp.git
2. Building
Next, set ERL_TOP the environment variable:
cd otp
export ERL_TOP=`pwd`
The repository does not contain a generated configure file, so it must be generated like this:
./otp_build autoconf
before configure can be run. When the configure files has been generated, you can build in the usual way as described in the README file. Shortly:
./configure
make
3. To run the system you have built without installing it first:
$ERL_TOP/bin/erl
从github otp的更新日志可以清楚的看到otp R13B04在binary heap的细化上做了很多工作:
1. 提供参数 限制binary的最小limit.
2. binary_to_term 加多参数来保证安全, 对于外来binary解码的安全性检查 比如说 避免atom的滥用.
3. 更高效率的处理binary fragment.
4. 加强GC对binary碎片的回收操作.
这个对于服务器性能很大帮助.
R13B03 binary vheap有助减少binary内存压力.
参看:http://www.erlang.org/download/otp_src_R13B03.readme
OTP-8202 A new garbage collecting strategy for binaries which is more
aggressive than the previous implementation. Binaries now has
a virtual binary heap tied to each process. When binaries are
created or received to a process it will check if the heap
limit has been reached and if a reclaim should be done. This
imitates the behavior of ordinary Erlang terms. The virtual
heaps are grown and shrunk like ordinary heaps. This will
lessen the memory footprint of binaries in a system.
原来的binary和其他类型的eterm是混在一起的,当进程的heap用完的时候,才进行GC,腾出空间。现在是把binary单独抽取出来,单独计数, 当binary用量过大的时候,马上就GC。
这个策略对于我们的服务器程序很有帮助,因为我们的服务器程序基本上包都是binary, 很容易出现binary无法及时回收,导致内存耗光的情况。
具体的改进效果待进一步的观察。
Recent Comments