<feed xmlns='http://www.w3.org/2005/Atom'>
<title>otp.git/lib/compiler/src, branch OTP-21.0</title>
<subtitle>Mirror of Erlang/OTP repository.
</subtitle>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/'/>
<entry>
<title>Update copyright year</title>
<updated>2018-06-18T12:51:18+00:00</updated>
<author>
<name>Henrik Nord</name>
<email>henrik@erlang.org</email>
</author>
<published>2018-06-18T12:51:18+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=5ca92e2eac1e84fd22f60e7abc3aa2b0ff1cb42b'/>
<id>5ca92e2eac1e84fd22f60e7abc3aa2b0ff1cb42b</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 #1832 from josevalim/jv-revert-beam-jump</title>
<updated>2018-06-07T11:29:47+00:00</updated>
<author>
<name>Björn Gustavsson</name>
<email>bgustavsson@gmail.com</email>
</author>
<published>2018-06-07T11:29:47+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=890936f03991e7b57d7801497a2de5a572b701de'/>
<id>890936f03991e7b57d7801497a2de5a572b701de</id>
<content type='text'>
Revert "Run the sharing optimisation in beam_jump until fixpoint"</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Revert "Run the sharing optimisation in beam_jump until fixpoint"</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #1831 from bjorng/bjorn/compiler/fix-name-capture</title>
<updated>2018-06-07T11:24:03+00:00</updated>
<author>
<name>Björn Gustavsson</name>
<email>bgustavsson@gmail.com</email>
</author>
<published>2018-06-07T11:24:03+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=463c8e7fa08388f138fd9f07995d7c7a7580507e'/>
<id>463c8e7fa08388f138fd9f07995d7c7a7580507e</id>
<content type='text'>
Fix name capture problem in sys_core_fold

OTP-15115
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix name capture problem in sys_core_fold

OTP-15115
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "Run the sharing optimisation in beam_jump until fixpoint"</title>
<updated>2018-06-04T19:01:35+00:00</updated>
<author>
<name>José Valim</name>
<email>jose.valim@plataformatec.com.br</email>
</author>
<published>2018-06-04T19:01:35+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=84d0923cc193e0fb06c21ecdfd08d5b204015628'/>
<id>84d0923cc193e0fb06c21ecdfd08d5b204015628</id>
<content type='text'>
We have found cases where compilation drastically slows down
due to this commit. We are working on a minimal cases and plan
to bring this patch back once we can work our the performance
issues.

This reverts commit f7c9383f4c3d4b6819b5ba4d54c7093df806fe4a.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We have found cases where compilation drastically slows down
due to this commit. We are working on a minimal cases and plan
to bring this patch back once we can work our the performance
issues.

This reverts commit f7c9383f4c3d4b6819b5ba4d54c7093df806fe4a.
</pre>
</div>
</content>
</entry>
<entry>
<title>sys_core_fold: Fix name capture problem</title>
<updated>2018-06-04T08:41:21+00:00</updated>
<author>
<name>Björn Gustavsson</name>
<email>bjorn@erlang.org</email>
</author>
<published>2018-06-04T04:14:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=7eb06ed5ac1687d38245db2e0aef2756cb43b1ae'/>
<id>7eb06ed5ac1687d38245db2e0aef2756cb43b1ae</id>
<content type='text'>
sys_core_fold could do unsafe transformations on the
code from the old inliner (invoked using the compiler
option `{inline,[{F/A}]}` to request inlining of specific
functions).

To explain the bug, let's first look at an example that
sys_core_fold handles correctly. Consider this code:

    'foo'/2 =
        fun (Arg1,Arg2) -&gt;
          let &lt;B&gt; = Arg2
          in let &lt;A,B&gt; = &lt;B,Arg1&gt;
             in {A,B}

In this example, the lets can be completely eliminated,
since the arguments for the lets are variables (as opposed
to expressions). Since the variable B is rebound in the
inner let, `sys_core_fold` must take special care when
doing the substitutions.

Here is the correct result:

    'foo'/2 =
        fun (Arg1, Arg2) -&gt;
          {Arg2,Arg1}

Consider a slight modifictation of the example:

    'bar'/2 =
        fun (Arg1,Arg2) -&gt;
            let &lt;B&gt; = [Arg2]
            in let &lt;A,B&gt; = &lt;B,[Arg1]&gt;
               in {A,B}

Here some of the arguments for the lets are expressions, so
the lets must be kept. sys_core_fold does not handle this
example correctly:

    'bar'/2 =
        fun (Arg1,Arg2) -&gt;
          let &lt;B&gt; = [Arg2]
    	  in let &lt;B&gt; = [Arg1]
    	     in {B,B}

In the inner let, the variable A has been eliminated and
replaced with the variable B in the body (the first B in
the tuple). Since the B in the outer let is never used,
the outer let will be eliminated, giving:

    'bar'/2 =
        fun (Arg1,Arg2) -&gt;
    	  let &lt;B&gt; = [Arg1]
    	  in {B,B}

To handle this example correctly, sys_core_fold must
rename the variable B in the inner let like this to
avoid capturing B:

    'bar'/2 =
       fun (Arg1,Arg2) -&gt;
         let &lt;B&gt; = [Arg2]
         in let &lt;NewName&gt; = [Arg1]
            in {B,NewName}

(Note: The `v3_kernel` pass alreday handles those examples correctly
in case `sys_core_fold` has been disabled.)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
sys_core_fold could do unsafe transformations on the
code from the old inliner (invoked using the compiler
option `{inline,[{F/A}]}` to request inlining of specific
functions).

To explain the bug, let's first look at an example that
sys_core_fold handles correctly. Consider this code:

    'foo'/2 =
        fun (Arg1,Arg2) -&gt;
          let &lt;B&gt; = Arg2
          in let &lt;A,B&gt; = &lt;B,Arg1&gt;
             in {A,B}

In this example, the lets can be completely eliminated,
since the arguments for the lets are variables (as opposed
to expressions). Since the variable B is rebound in the
inner let, `sys_core_fold` must take special care when
doing the substitutions.

Here is the correct result:

    'foo'/2 =
        fun (Arg1, Arg2) -&gt;
          {Arg2,Arg1}

Consider a slight modifictation of the example:

    'bar'/2 =
        fun (Arg1,Arg2) -&gt;
            let &lt;B&gt; = [Arg2]
            in let &lt;A,B&gt; = &lt;B,[Arg1]&gt;
               in {A,B}

Here some of the arguments for the lets are expressions, so
the lets must be kept. sys_core_fold does not handle this
example correctly:

    'bar'/2 =
        fun (Arg1,Arg2) -&gt;
          let &lt;B&gt; = [Arg2]
    	  in let &lt;B&gt; = [Arg1]
    	     in {B,B}

In the inner let, the variable A has been eliminated and
replaced with the variable B in the body (the first B in
the tuple). Since the B in the outer let is never used,
the outer let will be eliminated, giving:

    'bar'/2 =
        fun (Arg1,Arg2) -&gt;
    	  let &lt;B&gt; = [Arg1]
    	  in {B,B}

To handle this example correctly, sys_core_fold must
rename the variable B in the inner let like this to
avoid capturing B:

    'bar'/2 =
       fun (Arg1,Arg2) -&gt;
         let &lt;B&gt; = [Arg2]
         in let &lt;NewName&gt; = [Arg1]
            in {B,NewName}

(Note: The `v3_kernel` pass alreday handles those examples correctly
in case `sys_core_fold` has been disabled.)
</pre>
</div>
</content>
</entry>
<entry>
<title>sys_core_inline: Avoid spurious warnings</title>
<updated>2018-06-04T08:34:50+00:00</updated>
<author>
<name>Björn Gustavsson</name>
<email>bjorn@erlang.org</email>
</author>
<published>2018-06-04T05:19:44+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=7f3a501cada228c2fedbe34d0d30080e98560665'/>
<id>7f3a501cada228c2fedbe34d0d30080e98560665</id>
<content type='text'>
Add more `compiler_generated` attributes to avoid spurious compiler
warnings triggered by the bug fix in the next commit.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add more `compiler_generated` attributes to avoid spurious compiler
warnings triggered by the bug fix in the next commit.
</pre>
</div>
</content>
</entry>
<entry>
<title>compiler: Improve a contract</title>
<updated>2018-05-28T13:26:29+00:00</updated>
<author>
<name>Hans Bolinder</name>
<email>hasse@erlang.org</email>
</author>
<published>2018-05-28T10:14:26+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=186d8be66dd3d8eef24935c69c05723e15d00047'/>
<id>186d8be66dd3d8eef24935c69c05723e15d00047</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 'richcarl/eliminate_lib_module/PR-1786/OTP-15072'</title>
<updated>2018-05-16T13:13:25+00:00</updated>
<author>
<name>Hans Bolinder</name>
<email>hasse@erlang.org</email>
</author>
<published>2018-05-16T13:13:25+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=455fde56f533bd80d1a9d37058c3381521e201ba'/>
<id>455fde56f533bd80d1a9d37058c3381521e201ba</id>
<content type='text'>
* richcarl/eliminate_lib_module/PR-1786/OTP-15072:
  Fix minor issues
  Eliminate call to ct:get_progname() in ts_erl_config
  Use \n escape instead of integer 10
  Move error formatting to erl_error.erl and delete lib.erl
  Move extended parse functions in lib.erl to erl_eval.erl
  Move lib:eval_str/1 into mod_esi.erl
  Remove lib:progname/0
  Eliminate call to lib:progname/1 in slave.erl
  Add ct:get_progname/0
  Remove lib:error_message/2
  Remove lib:flush_receive/0
  Remove lib:send/2 and lib:sendw/2
  Move lib:nonl/1 into yecc.erl
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* richcarl/eliminate_lib_module/PR-1786/OTP-15072:
  Fix minor issues
  Eliminate call to ct:get_progname() in ts_erl_config
  Use \n escape instead of integer 10
  Move error formatting to erl_error.erl and delete lib.erl
  Move extended parse functions in lib.erl to erl_eval.erl
  Move lib:eval_str/1 into mod_esi.erl
  Remove lib:progname/0
  Eliminate call to lib:progname/1 in slave.erl
  Add ct:get_progname/0
  Remove lib:error_message/2
  Remove lib:flush_receive/0
  Remove lib:send/2 and lib:sendw/2
  Move lib:nonl/1 into yecc.erl
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #1800 from erszcz/master</title>
<updated>2018-05-07T13:08:27+00:00</updated>
<author>
<name>Hans Bolinder</name>
<email>hasse@erlang.org</email>
</author>
<published>2018-05-07T13:08:27+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=e781967c7902b98e90a05a23a7e6888014709a96'/>
<id>e781967c7902b98e90a05a23a7e6888014709a96</id>
<content type='text'>
Fix syntactic issues in EDoc comments across some libs</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix syntactic issues in EDoc comments across some libs</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #1802 from michalmuskala/map-is-key-bif</title>
<updated>2018-05-07T08:30:22+00:00</updated>
<author>
<name>Björn Gustavsson</name>
<email>bgustavsson@gmail.com</email>
</author>
<published>2018-05-07T08:30:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=7a19de1bf0eb863e0d0febf7e7e5e555c8628575'/>
<id>7a19de1bf0eb863e0d0febf7e7e5e555c8628575</id>
<content type='text'>
Introduce is_map_key/2 guard BIF

OTP-15037
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Introduce is_map_key/2 guard BIF

OTP-15037
</pre>
</div>
</content>
</entry>
</feed>
