<feed xmlns='http://www.w3.org/2005/Atom'>
<title>otp.git/lib/compiler, branch OTP-20.3.5</title>
<subtitle>Mirror of Erlang/OTP repository.
</subtitle>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/'/>
<entry>
<title>Update release notes</title>
<updated>2018-03-09T10:01:07+00:00</updated>
<author>
<name>Erlang/OTP</name>
<email>otp@erlang.org</email>
</author>
<published>2018-03-09T10:01:07+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=7c7ba7191a3932e737fa81fd0166df1c637d4b31'/>
<id>7c7ba7191a3932e737fa81fd0166df1c637d4b31</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Update version numbers</title>
<updated>2018-03-09T09:59:22+00:00</updated>
<author>
<name>Erlang/OTP</name>
<email>otp@erlang.org</email>
</author>
<published>2018-03-09T09:59:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=db5a9ef5e49f55338369f088bbef1d492f8c3c0c'/>
<id>db5a9ef5e49f55338369f088bbef1d492f8c3c0c</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Check that the stack is initialized when an exception may occur</title>
<updated>2018-02-09T10:54:18+00:00</updated>
<author>
<name>Björn Gustavsson</name>
<email>bjorn@erlang.org</email>
</author>
<published>2018-02-09T09:27:38+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=73ff9fa2126d96e5b30d01abd6c4560407f295e4'/>
<id>73ff9fa2126d96e5b30d01abd6c4560407f295e4</id>
<content type='text'>
Strengthen beam_validator to check that the stack is initialized
when an instruction with an {f,0} operand is executed.
For example, the following code sequence:

    {allocate,0,1}.
    {bif,element,{f,0},[{integer,1},{x,0}],{x,0}}.

should not be accepted because the stack may be scanned if
element/2 fails. That could cause a crash or other undefined
behavior if garbage on the stack looks like a catch tag.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Strengthen beam_validator to check that the stack is initialized
when an instruction with an {f,0} operand is executed.
For example, the following code sequence:

    {allocate,0,1}.
    {bif,element,{f,0},[{integer,1},{x,0}],{x,0}}.

should not be accepted because the stack may be scanned if
element/2 fails. That could cause a crash or other undefined
behavior if garbage on the stack looks like a catch tag.
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix incorrect type interference of integer ranges</title>
<updated>2018-01-29T14:29:06+00:00</updated>
<author>
<name>Björn Gustavsson</name>
<email>bjorn@erlang.org</email>
</author>
<published>2018-01-29T12:00:18+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=c455dc2ca108e8ffbf5431068223fcff8aeb5361'/>
<id>c455dc2ca108e8ffbf5431068223fcff8aeb5361</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #1674 from bjorng/bjorn/compiler/beam_validator</title>
<updated>2018-01-10T10:34:13+00:00</updated>
<author>
<name>Björn Gustavsson</name>
<email>bgustavsson@gmail.com</email>
</author>
<published>2018-01-10T10:34:13+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=df8499995b4994d3f85f4b80fc3c2cf941a99cdc'/>
<id>df8499995b4994d3f85f4b80fc3c2cf941a99cdc</id>
<content type='text'>
beam_validator: Strengthen validation of GC instructions

OTP-14863
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
beam_validator: Strengthen validation of GC instructions

OTP-14863
</pre>
</div>
</content>
</entry>
<entry>
<title>beam_validator: Strengthen validation of GC instructions</title>
<updated>2018-01-08T07:06:43+00:00</updated>
<author>
<name>Björn Gustavsson</name>
<email>bjorn@erlang.org</email>
</author>
<published>2018-01-04T12:28:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=1ee21858db7e55b15c2f947ddfa00ae5af5c009d'/>
<id>1ee21858db7e55b15c2f947ddfa00ae5af5c009d</id>
<content type='text'>
beam_validator did not verify that the Y registers were initialized
before executing the following instructions that could cause a GC:

    bs_append/8
    bs_init2/6
    bs_init_bits/6
    gc_bif1/5
    gc_bif2/6
    gc_bif3/7
    test_heap/2

That means that, for example, an incorrect optimization that replaced
an 'allocate_zero' instruction with an 'allocate' instruction when it
was not safe, would not be rejected by beam_validtor, but would
instead cause a crash or other undefined behavior at runtime.

Also fix a minor bug in beam_type exposed by the stronger checking.
When compiling from .S files, beam_type did not handle the
init/1 instruction and could produce unsafe code.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
beam_validator did not verify that the Y registers were initialized
before executing the following instructions that could cause a GC:

    bs_append/8
    bs_init2/6
    bs_init_bits/6
    gc_bif1/5
    gc_bif2/6
    gc_bif3/7
    test_heap/2

That means that, for example, an incorrect optimization that replaced
an 'allocate_zero' instruction with an 'allocate' instruction when it
was not safe, would not be rejected by beam_validtor, but would
instead cause a crash or other undefined behavior at runtime.

Also fix a minor bug in beam_type exposed by the stronger checking.
When compiling from .S files, beam_type did not handle the
init/1 instruction and could produce unsafe code.
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove unsafe is_record/test_arity optimizations</title>
<updated>2018-01-04T19:17:53+00:00</updated>
<author>
<name>John Högberg</name>
<email>john@erlang.org</email>
</author>
<published>2018-01-04T17:08:42+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=19b7ccfe076d88a96b62f3222f38be31bb087df2'/>
<id>19b7ccfe076d88a96b62f3222f38be31bb087df2</id>
<content type='text'>
The type optimizations for is_record and test_arity checked whether
the arity was equal to the size stored in the type information,
which is incorrect since said size is the *minimum* size of the
tuple (as determined by previous instructions) and not its exact
size.

A future patch to the 'master' branch will restore these
optimizations in a safe manner.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The type optimizations for is_record and test_arity checked whether
the arity was equal to the size stored in the type information,
which is incorrect since said size is the *minimum* size of the
tuple (as determined by previous instructions) and not its exact
size.

A future patch to the 'master' branch will restore these
optimizations in a safe manner.
</pre>
</div>
</content>
</entry>
<entry>
<title>Update release notes</title>
<updated>2017-12-08T09:57:50+00:00</updated>
<author>
<name>Erlang/OTP</name>
<email>otp@erlang.org</email>
</author>
<published>2017-12-08T09:57:50+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=47198f179ab14cf8cfcdab0d976650cd1519b236'/>
<id>47198f179ab14cf8cfcdab0d976650cd1519b236</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Update version numbers</title>
<updated>2017-12-08T09:53:22+00:00</updated>
<author>
<name>Erlang/OTP</name>
<email>otp@erlang.org</email>
</author>
<published>2017-12-08T09:53:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=f3a74a7dfb633b21b7d06e48bf430071cdc0f779'/>
<id>f3a74a7dfb633b21b7d06e48bf430071cdc0f779</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'lukas/compiler/add_to_dis/OTP-14784' into maint</title>
<updated>2017-11-20T09:32:25+00:00</updated>
<author>
<name>Lukas Larsson</name>
<email>lukas@erlang.org</email>
</author>
<published>2017-11-20T09:32:25+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=3b5fced77873fa6ee87a81a6162acf9d9f43c6de'/>
<id>3b5fced77873fa6ee87a81a6162acf9d9f43c6de</id>
<content type='text'>
* lukas/compiler/add_to_dis/OTP-14784:
  compiler: Add +to_dis option that dumps loaded asm
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* lukas/compiler/add_to_dis/OTP-14784:
  compiler: Add +to_dis option that dumps loaded asm
</pre>
</div>
</content>
</entry>
</feed>
