31
31
<p>This document describes the changes made to HiPE.</p>
33
<section><title>Hipe 3.7.9</title>
35
<section><title>Fixed Bugs and Malfunctions</title>
39
Fix erroneous fail info of a hipe_bs_primop</p>
45
The change fixes a bug in the translation of 'bs_add'
46
BEAM instruction to HiPE's Icode representation. When
47
these instructions appeared in a guard context the
48
previous translation was obviously buggy.</p>
54
Sanitize the specs of the code module</p>
56
After the addition of unicode_binary() to the
57
file:filename() type, dialyzer started complaining about
58
erroneous or incomplete specs in some functions of the
59
'code' module. The culprit was hard-coded information in
60
erl_bif_types for functions of this module, which were
61
not updated. Since these functions have proper specs
62
these days and code duplication (pun intended) is never a
63
good idea, their type information was removed from
66
While doing this, some erroneous comments were fixed in
67
the code module and also made sure that the code now runs
68
without dialyzer warnings even when the
69
-Wunmatched_returns option is used.</p>
71
Some cleanups were applied to erl_bif_types too.</p>
77
Fix bug in the simplification of inexact comparisons</p>
79
On 31/1/2011 Paul Guyot reported a bug in the native code
80
compilation of inexact equality/inequality tests between
81
floats and integers. The relevant test was:</p>
83
f(X) -> Y = X / 2, Y == 0.</p>
85
and hipe erroneously evaluated the calls f(0) and f(0.0)
88
The culprit was in the simplification code of the Icode
89
range analysis which used an erroneous test (lists:any/1
90
instead of lists:all/1).</p>
96
Document exiting and garbage_collecting process statuses</p>
102
Remove hipe constants pool</p>
104
Hipe constants used to be allocated within a single,
105
fixed-size pool for interaction with the garbage
106
collector. However, the garbage collector no longer
107
depends on constants being allocated within a single
108
pool, and the fixed size of the pool both meant
109
unnecessary allocations on most deployments and crashes
110
on deployments requiring more constants.</p>
112
The code was simplified to directly invoke erts_alloc.
113
Debugging and undocumented function
114
hipe_bifs:show_literals/0 was removed (it returned true
115
and output text to the console), and debugging and
116
undocumented function hipe_bifs:constants_size/0 was
117
rewritten with a global to count the size of allocated
127
<section><title>Hipe 3.7.8.1</title>
129
<section><title>Fixed Bugs and Malfunctions</title>
133
Several type specifications for standard libraries were
134
wrong in the R14B01 release. This is now corrected. The
135
corrections concern types in re,io,filename and the
136
module erlang itself.</p>
145
<section><title>Hipe 3.7.8</title>
147
<section><title>Improvements and New Features</title>
151
Compiler warnings were eliminated.</p>
160
<section><title>Hipe 3.7.7</title>
162
<section><title>Fixed Bugs and Malfunctions</title>
165
<p>The HiPE compiler could crash when compiling certain
166
modules (the bug has been latent, and been exposed by new
167
optimizations introduced in the BEAM compiler in R14A).
168
(Thanks to Mikael Pettersson.)</p>
174
hipe:load/1 was broken. (Thanks to Paul Guyot.)</p>
183
<section><title>Hipe 3.7.6</title>
185
<section><title>Improvements and New Features</title>
188
<p><c>receive</c> statements that can only read out a
189
newly created reference are now specially optimized so
190
that it will execute in constant time regardless of the
191
number of messages in the receive queue for the process.
192
That optimization will benefit calls to
193
<c>gen_server:call()</c>. (See <c>gen:do_call/4</c> for
194
an example of a receive statement that will be
201
Various changes to dialyzer-related files for R14.</p>
203
- Dialyzer properly supports the new attribute
204
-export_type and checks that remote types only refer to
205
exported types. A warning is produced if some
206
files/applications refer to types defined in modules
207
which are neither in the PLT nor in the analyzed
210
- Support for detecting data races involving whereis/1
211
and unregister/1.</p>
213
- More precise identification of the reason(s) why a
214
record construction violates the types declared for its
217
- Fixed bug in the handling of the 'or' guard.</p>
219
- Better handling of the erlang:element/2 BIF.</p>
221
- Complete handling of Erlang BIFs.</p>
226
<p><c>eprof</c> has been reimplemented with support in
227
the Erlang virtual machine and is now both faster (i.e.
228
slows down the code being measured less) and scales much
229
better. In measurements we saw speed-ups compared to the
230
old eprof ranging from 6 times (for sequential code that
231
only uses one scheduler/core) up to 84 times (for
232
parallel code that uses 8 cores).</p>
233
<p>Note: The API for the <c>eprof</c> has been cleaned up
234
and extended. See the documentation.</p>
236
*** POTENTIAL INCOMPATIBILITY ***</p>
245
<section><title>Hipe 3.7.5</title>
247
<section><title>Improvements and New Features</title>
250
<p>The documentation is now possible to build in an open
251
source environment after a number of bugs are fixed and
252
some features are added in the documentation build
254
<p>- The arity calculation is updated.</p>
255
<p>- The module prefix used in the function names for
256
bif's are removed in the generated links so the links
258
"http://www.erlang.org/doc/man/erlang.html#append_element-2"
260
"http://www.erlang.org/doc/man/erlang.html#erlang:append_element-2".</p>
261
<p>- Enhanced the menu positioning in the html
262
documentation when a new page is loaded.</p>
263
<p>- A number of corrections in the generation of man
264
pages (thanks to Sergei Golovan)</p>
265
<p>- The legal notice is taken from the xml book file so
266
OTP's build process can be used for non OTP
33
276
<section><title>Hipe 3.7.4</title>
35
278
<section><title>Improvements and New Features</title>