Change 33338 by [EMAIL PROTECTED] on 2008/02/20 22:39:56

        Eliminate ck_lengthconst.

Affected files ...

... //depot/perl/embed.fnc#588 edit
... //depot/perl/embed.h#749 edit
... //depot/perl/op.c#991 edit
... //depot/perl/opcode.h#150 edit
... //depot/perl/opcode.pl#173 edit
... //depot/perl/pod/perltodo.pod#213 edit
... //depot/perl/pp.sym#41 edit
... //depot/perl/pp_proto.h#49 edit
... //depot/perl/proto.h#923 edit

Differences ...

==== //depot/perl/embed.fnc#588 (text) ====
Index: perl/embed.fnc
--- perl/embed.fnc#587~33304~   2008-02-14 00:09:36.000000000 -0800
+++ perl/embed.fnc      2008-02-20 14:39:56.000000000 -0800
@@ -1209,7 +1209,6 @@
 pR     |OP*    |ck_grep        |NN OP *o
 pR     |OP*    |ck_index       |NN OP *o
 pR     |OP*    |ck_join        |NN OP *o
-pR     |OP*    |ck_lengthconst |NN OP *o
 pR     |OP*    |ck_lfun        |NN OP *o
 pR     |OP*    |ck_listiob     |NN OP *o
 pR     |OP*    |ck_match       |NN OP *o

==== //depot/perl/embed.h#749 (text+w) ====
Index: perl/embed.h
--- perl/embed.h#748~33284~     2008-02-11 12:07:50.000000000 -0800
+++ perl/embed.h        2008-02-20 14:39:56.000000000 -0800
@@ -1176,7 +1176,6 @@
 #define ck_grep                        Perl_ck_grep
 #define ck_index               Perl_ck_index
 #define ck_join                        Perl_ck_join
-#define ck_lengthconst         Perl_ck_lengthconst
 #define ck_lfun                        Perl_ck_lfun
 #define ck_listiob             Perl_ck_listiob
 #define ck_match               Perl_ck_match
@@ -3474,7 +3473,6 @@
 #define ck_grep(a)             Perl_ck_grep(aTHX_ a)
 #define ck_index(a)            Perl_ck_index(aTHX_ a)
 #define ck_join(a)             Perl_ck_join(aTHX_ a)
-#define ck_lengthconst(a)      Perl_ck_lengthconst(aTHX_ a)
 #define ck_lfun(a)             Perl_ck_lfun(aTHX_ a)
 #define ck_listiob(a)          Perl_ck_listiob(aTHX_ a)
 #define ck_match(a)            Perl_ck_match(aTHX_ a)

==== //depot/perl/op.c#991 (text) ====
Index: perl/op.c
--- perl/op.c#990~33323~        2008-02-15 23:06:40.000000000 -0800
+++ perl/op.c   2008-02-20 14:39:56.000000000 -0800
@@ -7124,15 +7124,6 @@
 }
 
 OP *
-Perl_ck_lengthconst(pTHX_ OP *o)
-{
-    PERL_ARGS_ASSERT_CK_LENGTHCONST;
-
-    /* XXX length optimization goes here */
-    return ck_fun(o);
-}
-
-OP *
 Perl_ck_lfun(pTHX_ OP *o)
 {
     const OPCODE type = o->op_type;

==== //depot/perl/opcode.h#150 (text+w) ====
Index: perl/opcode.h
--- perl/opcode.h#149~33337~    2008-02-20 01:21:53.000000000 -0800
+++ perl/opcode.h       2008-02-20 14:39:56.000000000 -0800
@@ -1282,7 +1282,7 @@
        MEMBER_TO_FPTR(Perl_ck_fun),    /* hex */
        MEMBER_TO_FPTR(Perl_ck_fun),    /* oct */
        MEMBER_TO_FPTR(Perl_ck_fun),    /* abs */
-       MEMBER_TO_FPTR(Perl_ck_lengthconst),    /* length */
+       MEMBER_TO_FPTR(Perl_ck_fun),    /* length */
        MEMBER_TO_FPTR(Perl_ck_substr), /* substr */
        MEMBER_TO_FPTR(Perl_ck_fun),    /* vec */
        MEMBER_TO_FPTR(Perl_ck_index),  /* index */

==== //depot/perl/opcode.pl#173 (xtext) ====
Index: perl/opcode.pl
--- perl/opcode.pl#172~33337~   2008-02-20 01:21:53.000000000 -0800
+++ perl/opcode.pl      2008-02-20 14:39:56.000000000 -0800
@@ -760,7 +760,7 @@
 
 # String stuff.
 
-length         length                  ck_lengthconst  ifsTu%  S?
+length         length                  ck_fun          ifsTu%  S?
 substr         substr                  ck_substr       st@     S S S? S?
 vec            vec                     ck_fun          ist@    S S S
 

==== //depot/perl/pod/perltodo.pod#213 (text) ====
Index: perl/pod/perltodo.pod
--- perl/pod/perltodo.pod#212~33277~    2008-02-11 02:43:35.000000000 -0800
+++ perl/pod/perltodo.pod       2008-02-20 14:39:56.000000000 -0800
@@ -386,14 +386,6 @@
 
 =back
 
-=head2
-
-C<Perl_ck_lengthconst> does nothing, but has the comment
-
-    /* XXX length optimization goes here */
-
-It predates 5.003. Investigate what it's about, and then implement it.
-
 =head2 Modernize the order of directories in @INC
 
 The way @INC is laid out by default, one cannot upgrade core (dual-life)

==== //depot/perl/pp.sym#41 (text+w) ====
Index: perl/pp.sym
--- perl/pp.sym#40~33267~       2008-02-09 23:35:45.000000000 -0800
+++ perl/pp.sym 2008-02-20 14:39:56.000000000 -0800
@@ -24,7 +24,6 @@
 Perl_ck_grep
 Perl_ck_index
 Perl_ck_join
-Perl_ck_lengthconst
 Perl_ck_lfun
 Perl_ck_listiob
 Perl_ck_match

==== //depot/perl/pp_proto.h#49 (text+w) ====
Index: perl/pp_proto.h
--- perl/pp_proto.h#48~33267~   2008-02-09 23:35:45.000000000 -0800
+++ perl/pp_proto.h     2008-02-20 14:39:56.000000000 -0800
@@ -23,7 +23,6 @@
 PERL_CKDEF(Perl_ck_grep)
 PERL_CKDEF(Perl_ck_index)
 PERL_CKDEF(Perl_ck_join)
-PERL_CKDEF(Perl_ck_lengthconst)
 PERL_CKDEF(Perl_ck_lfun)
 PERL_CKDEF(Perl_ck_listiob)
 PERL_CKDEF(Perl_ck_match)

==== //depot/perl/proto.h#923 (text+w) ====
Index: perl/proto.h
--- perl/proto.h#922~33304~     2008-02-14 00:09:36.000000000 -0800
+++ perl/proto.h        2008-02-20 14:39:56.000000000 -0800
@@ -4401,12 +4401,6 @@
 #define PERL_ARGS_ASSERT_CK_JOIN       \
        assert(o)
 
-PERL_CALLCONV OP*      Perl_ck_lengthconst(pTHX_ OP *o)
-                       __attribute__warn_unused_result__
-                       __attribute__nonnull__(pTHX_1);
-#define PERL_ARGS_ASSERT_CK_LENGTHCONST        \
-       assert(o)
-
 PERL_CALLCONV OP*      Perl_ck_lfun(pTHX_ OP *o)
                        __attribute__warn_unused_result__
                        __attribute__nonnull__(pTHX_1);
End of Patch.

Reply via email to