Skip to content

Commit

Permalink
Update ramblings/revert-B-load-BEGIN patches RT#81332 for 5.14/5.16
Browse files Browse the repository at this point in the history
  • Loading branch information
Reini Urban committed Aug 22, 2013
1 parent f59ddc1 commit f31b51e
Show file tree
Hide file tree
Showing 4 changed files with 108 additions and 1 deletion.
3 changes: 2 additions & 1 deletion MANIFEST
Expand Up @@ -72,7 +72,8 @@ ramblings/flip-flop
ramblings/frozenperl_2010.pod
ramblings/magic
ramblings/reg.alloc
ramblings/revert-B-load-BEGIN.patch
ramblings/revert-B-load-BEGIN-514.patch
ramblings/revert-B-load-BEGIN-516.patch
ramblings/runtime.porting
ramblings/yapc_bratislava08.pod
ramblings/yapceu_2010.pod
Expand Down
File renamed without changes.
53 changes: 53 additions & 0 deletions ramblings/revert-B-load-BEGIN-516.patch
@@ -0,0 +1,53 @@
RT#81332 revert 744aaba0 bloats the B compilers
For 5.16.1 and 5.16.2

diff -u ext/B/B.pm.orig ext/B/B.pm
--- ext/B/B.pm.orig 2013-01-09 13:06:02.400814216 -0600
+++ ext/B/B.pm 2013-01-09 13:09:57.898447521 -0600
@@ -8,24 +8,15 @@
package B;
use strict;

+require XSLoader;
require Exporter;
@B::ISA = qw(Exporter);

# walkoptree_slow comes from B.pm (you are there),
# walkoptree comes from B.xs

-BEGIN {
- $B::VERSION = '1.35';
- @B::EXPORT_OK = ();
-
- # Our BOOT code needs $VERSION set, and will append to @EXPORT_OK.
- # Want our constants loaded before the compiler meets OPf_KIDS below, as
- # the combination of having the constant stay a Proxy Constant Subroutine
- # and its value being inlined saves a little over .5K
-
- require XSLoader;
- XSLoader::load();
-}
+$B::VERSION = '1.35_01';
+@B::EXPORT_OK = ();

push @B::EXPORT_OK, (qw(minus_c ppname save_BEGINs
class peekop cast_I32 cstring cchar hash threadsv_names
@@ -38,6 +29,9 @@
@specialsv_name
), $] > 5.009 && 'unitcheck_av');

+sub OPf_KIDS ();
+use strict;
+
@B::SV::ISA = 'B::OBJECT';
@B::NULL::ISA = 'B::SV';
@B::PV::ISA = 'B::SV';
@@ -332,6 +326,8 @@
}
}

+XSLoader::load();
+
1;

__END__
53 changes: 53 additions & 0 deletions ramblings/revert-B-load-BEGIN-5160.patch
@@ -0,0 +1,53 @@
RT#81332 revert 744aaba0 bloats the B compilers
For 5.16.0

diff -u ext/B/B.pm.orig ext/B/B.pm
--- ext/B/B.pm.orig 2012-05-23 17:40:02.167549196 -0500
+++ ext/B/B.pm 2013-01-09 13:15:10.391328942 -0600
@@ -8,24 +8,15 @@
package B;
use strict;

+require XSLoader;
require Exporter;
@B::ISA = qw(Exporter);

# walkoptree_slow comes from B.pm (you are there),
# walkoptree comes from B.xs

-BEGIN {
- $B::VERSION = '1.34';
- @B::EXPORT_OK = ();
-
- # Our BOOT code needs $VERSION set, and will append to @EXPORT_OK.
- # Want our constants loaded before the compiler meets OPf_KIDS below, as
- # the combination of having the constant stay a Proxy Constant Subroutine
- # and its value being inlined saves a little over .5K
-
- require XSLoader;
- XSLoader::load();
-}
+$B::VERSION = '1.34_01';
+@B::EXPORT_OK = ();

push @B::EXPORT_OK, (qw(minus_c ppname save_BEGINs
class peekop cast_I32 cstring cchar hash threadsv_names
@@ -38,6 +29,9 @@
@specialsv_name
), $] > 5.009 && 'unitcheck_av');

+sub OPf_KIDS ();
+use strict;
+
@B::SV::ISA = 'B::OBJECT';
@B::NULL::ISA = 'B::SV';
@B::PV::ISA = 'B::SV';
@@ -332,6 +326,8 @@
}
}

+XSLoader::load();
+
1;

__END__

0 comments on commit f31b51e

Please sign in to comment.