From: Gurusamy Sarathy Date: Fri, 25 Feb 2000 01:50:04 +0000 (+0000) Subject: more Compiler tweaks for useithreads X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=9386585123187f184f4e811ad35f84c5d3ddd94c;p=p5sagit%2Fp5-mst-13.2.git more Compiler tweaks for useithreads p4raw-id: //depot/perl@5250 --- diff --git a/ext/B/B.xs b/ext/B/B.xs index d0ee8e4..9e29855 100644 --- a/ext/B/B.xs +++ b/ext/B/B.xs @@ -163,8 +163,11 @@ cc_opclass(pTHX_ OP *o) * an SVOP (and op_sv is the GV for the filehandle argument). */ return ((o->op_flags & OPf_KIDS) ? OPc_UNOP : +#ifdef USE_ITHREADS + (o->op_flags & OPf_REF) ? OPc_PADOP : OPc_BASEOP); +#else (o->op_flags & OPf_REF) ? OPc_SVOP : OPc_BASEOP); - +#endif case OA_LOOPEXOP: /* * next, last, redo, dump and goto use OPf_SPECIAL to indicate that a diff --git a/ext/B/B/C.pm b/ext/B/B/C.pm index c8fd96b..dafef33 100644 --- a/ext/B/B/C.pm +++ b/ext/B/B/C.pm @@ -298,7 +298,7 @@ sub B::PADOP::save { my ($op, $level) = @_; my $sym = objsym($op); return $sym if defined $sym; - $padopsect->add(sprintf("s\\_%x, s\\_%x, NULL, %u, %u, %u, 0x%x, 0x%x, Nullgv", + $padopsect->add(sprintf("s\\_%x, s\\_%x, NULL, %u, %u, %u, 0x%x, 0x%x, 0", ${$op->next}, ${$op->sibling}, $op->targ, $op->type, $op_seq, $op->flags, $op->private)); @@ -314,7 +314,7 @@ sub B::COP::save { return $sym if defined $sym; warn sprintf("COP: line %d file %s\n", $op->line, $op->file) if $debug_cops; - $copsect->add(sprintf("s\\_%x, s\\_%x, NULL, %u, %u, %u, 0x%x, 0x%x, %s, Nullhv, Nullgv, %u, %d, %u", + $copsect->add(sprintf("s\\_%x, s\\_%x, NULL, %u, %u, %u, 0x%x, 0x%x, %s, NULL, NULL, %u, %d, %u", ${$op->next}, ${$op->sibling}, $op->targ, $op->type, $op_seq, $op->flags, $op->private, cstring($op->label), $op->cop_seq, @@ -1090,6 +1090,7 @@ sub output_boilerplate { print <<'EOT'; #include "EXTERN.h" #include "perl.h" +#include "XSUB.h" /* Workaround for mapstart: the only op which needs a different ppaddr */ #undef Perl_pp_mapstart