3 $opcode_new = 'opcode.h-new';
4 $opname_new = 'opnames.h-new';
5 open(OC, ">$opcode_new") || die "Can't create $opcode_new: $!\n";
6 open(ON, ">$opname_new") || die "Can't create $opname_new: $!\n";
15 ($key, $desc, $check, $flags, $args) = split(/\t+/, $_, 5);
17 warn qq[Description "$desc" duplicates $seen{$desc}\n] if $seen{$desc};
18 die qq[Opcode "$key" duplicates $seen{$key}\n] if $seen{$key};
19 $seen{$desc} = qq[description of opcode "$key"];
20 $seen{$key} = qq[opcode "$key"];
24 $check{$key} = $check;
26 $flags{$key} = $flags;
37 * Copyright (c) 1997-2002, Larry Wall
39 * You may distribute under the terms of either the GNU General Public
40 * License or the Artistic License, as specified in the README file.
42 * !!!!!!! DO NOT EDIT THIS FILE !!!!!!!
43 * This file is built by opcode.pl from its data. Any changes made here
47 #define Perl_pp_i_preinc Perl_pp_preinc
48 #define Perl_pp_i_predec Perl_pp_predec
49 #define Perl_pp_i_postinc Perl_pp_postinc
50 #define Perl_pp_i_postdec Perl_pp_postdec
58 * Copyright (c) 1997-2002, Larry Wall
60 * You may distribute under the terms of either the GNU General Public
61 * License or the Artistic License, as specified in the README file.
64 * !!!!!!! DO NOT EDIT THIS FILE !!!!!!!
65 * This file is built by opcode.pl from its data. Any changes made here
73 print ON "\t", &tab(3,"OP_\U$_,"), "/* ", $i++, " */\n";
75 print ON "\t", &tab(3,"OP_max"), "\n";
76 print ON "} opcode;\n";
77 print ON "\n#define MAXO ", scalar @ops, "\n";
78 print ON "#define OP_phoney_INPUT_ONLY -1\n";
79 print ON "#define OP_phoney_OUTPUT_ONLY -2\n\n";
81 # Emit op names and descriptions.
88 #define OP_NAME(o) (o->op_type == OP_CUSTOM ? custom_op_name(o) : \\
89 PL_op_name[o->op_type])
90 #define OP_DESC(o) (o->op_type == OP_CUSTOM ? custom_op_desc(o) : \\
91 PL_op_desc[o->op_type])
94 EXT char *PL_op_name[];
96 EXT char *PL_op_name[] = {
111 EXT char *PL_op_desc[];
113 EXT char *PL_op_desc[] = {
117 my($safe_desc) = $desc{$_};
119 # Have to escape double quotes and escape characters.
120 $safe_desc =~ s/(^|[^\\])([\\"])/$1\\$2/g;
122 print qq(\t"$safe_desc",\n);
133 # Emit function declarations.
135 #for (sort keys %ckname) {
136 # print "OP *\t", &tab(3,$_),"(pTHX_ OP* o);\n";
142 # print "OP *\t", &tab(3, "pp_$_"), "(pTHX);\n";
145 # Emit ppcode switch array.
152 EXT OP * (CPERLscope(*PL_ppaddr)[])(pTHX);
154 EXT OP * (CPERLscope(*PL_ppaddr)[])(pTHX) = {
158 print "\tMEMBER_TO_FPTR(Perl_pp_$_),\n" unless $_ eq "custom";
167 # Emit check routines.
171 EXT OP * (CPERLscope(*PL_check)[]) (pTHX_ OP *op);
173 EXT OP * (CPERLscope(*PL_check)[]) (pTHX_ OP *op) = {
177 print "\t", &tab(3, "MEMBER_TO_FPTR(Perl_$check{$_}),"), "\t/* $_ */\n";
186 # Emit allowed argument types.
192 EXT U32 PL_opargs[] = {
202 R, 7, # scalar reference
212 '$', 6, # svop_or_padop
214 '"', 8, # pvop_or_svop
217 '%', 11, # baseop_or_unop
218 '-', 12, # filestatop
228 $argsum |= 1 if $flags =~ /m/; # needs stack mark
229 $argsum |= 2 if $flags =~ /f/; # fold constants
230 $argsum |= 4 if $flags =~ /s/; # always produces scalar
231 $argsum |= 8 if $flags =~ /t/; # needs target scalar
232 $argsum |= (8|256) if $flags =~ /T/; # ... which may be lexical
233 $argsum |= 16 if $flags =~ /i/; # always produces integer
234 $argsum |= 32 if $flags =~ /I/; # has corresponding int op
235 $argsum |= 64 if $flags =~ /d/; # danger, unknown side effects
236 $argsum |= 128 if $flags =~ /u/; # defaults to $_
237 $flags =~ /([\W\d_])/ or die qq[Opcode "$_" has no class indicator];
238 $argsum |= $opclass{$1} << 9;
239 $mul = 0x2000; # 2 ^ OASHIFT
240 for $arg (split(' ',$args{$_})) {
242 $OP_IS_SOCKET{$_} = 1 if $arg =~ s/s//;
243 $OP_IS_FILETEST{$_} = 1 if $arg =~ s/-//;
245 $argnum = ($arg =~ s/\?//) ? 8 : 0;
246 die "op = $_, arg = $arg\n" unless length($arg) == 1;
247 $argnum += $argnum{$arg};
248 warn "# Conflicting bit 32 for '$_'.\n"
249 if $argnum & 8 and $mul == 0x10000000;
250 $argsum += $argnum * $mul;
253 $argsum = sprintf("0x%08x", $argsum);
254 print "\t", &tab(3, "$argsum,"), "/* $_ */\n";
264 if (keys %OP_IS_SOCKET) {
265 print ON "\n#define OP_IS_SOCKET(op) \\\n\t(";
266 print ON join(" || \\\n\t ",
267 map { "(op) == OP_" . uc() } sort keys %OP_IS_SOCKET);
271 if (keys %OP_IS_FILETEST) {
272 print ON "\n#define OP_IS_FILETEST(op) \\\n\t(";
273 print ON join(" || \\\n\t ",
274 map { "(op) == OP_" . uc() } sort keys %OP_IS_FILETEST);
278 close OC or die "Error closing opcode.h: $!";
279 close ON or die "Error closing opnames.h: $!";
281 chmod 0600, 'opcode.h'; # required by dosish filesystems
282 chmod 0600, 'opnames.h'; # required by dosish filesystems
284 # Some dosish systems can't rename over an existing file:
285 unlink "$_-old" for qw(opcode.h opnames.h);
286 rename $_, "$_-old" for qw(opcode.h opnames.h);
288 rename $opcode_new, 'opcode.h' or die "renaming opcode.h: $!\n";
289 rename $opname_new, 'opnames.h' or die "renaming opnames.h: $!\n";
291 $pp_proto_new = 'pp_proto.h-new';
292 $pp_sym_new = 'pp.sym-new';
294 open PP, ">$pp_proto_new" or die "Error creating $pp_proto_new: $!";
295 open PPSYM, ">$pp_sym_new" or die "Error creating $pp_sym_new: $!";
298 /* !!!!!!! DO NOT EDIT THIS FILE !!!!!!!
299 This file is built by opcode.pl from its data. Any changes made here
307 # !!!!!!! DO NOT EDIT THIS FILE !!!!!!!
308 # This file is built by opcode.pl from its data. Any changes made here
315 for (sort keys %ckname) {
316 print PP "PERL_CKDEF(Perl_$_)\n";
317 print PPSYM "Perl_$_\n";
318 #OP *\t", &tab(3,$_),"(OP* o);\n";
324 next if /^i_(pre|post)(inc|dec)$/;
326 print PP "PERL_PPDEF(Perl_pp_$_)\n";
327 print PPSYM "Perl_pp_$_\n";
330 close PP or die "Error closing pp_proto.h: $!";
331 close PPSYM or die "Error closing pp.sym: $!";
333 chmod 0600, 'pp_proto.h'; # required by dosish filesystems
334 chmod 0600, 'pp.sym'; # required by dosish filesystems
336 # Some dosish systems can't rename over an existing file:
337 unlink "$_-old" for qw(pp_proto.h pp.sym);
338 rename $_, "$_-old" for qw(pp_proto.h pp.sym);
340 rename $pp_proto_new, 'pp_proto.h' or die "rename pp_proto.h: $!\n";
341 rename $pp_sym_new, 'pp.sym' or die "rename pp.sym: $!\n";
343 ###########################################################################
346 $t .= "\t" x ($l - (length($t) + 1) / 8);
349 ###########################################################################
351 # Some comments about 'T' opcode classifier:
353 # Safe to set if the ppcode uses:
354 # tryAMAGICbin, tryAMAGICun, SETn, SETi, SETu, PUSHn, PUSHTARG, SETTARG,
355 # SETs(TARG), XPUSHn, XPUSHu,
357 # Unsafe to set if the ppcode uses dTARG or [X]RETPUSH[YES|NO|UNDEF]
359 # lt and friends do SETs (including ncmp, but not scmp)
361 # Additional mode of failure: the opcode can modify TARG before it "used"
362 # all the arguments (or may call an external function which does the same).
363 # If the target coincides with one of the arguments ==> kaboom.
365 # pp.c pos substr each not OK (RETPUSHUNDEF)
366 # substr vec also not OK due to LV to target (are they???)
367 # ref not OK (RETPUSHNO)
368 # trans not OK (dTARG; TARG = sv_newmortal();)
369 # ucfirst etc not OK: TMP arg processed inplace
370 # quotemeta not OK (unsafe when TARG == arg)
371 # each repeat not OK too due to list context
372 # pack split - unknown whether they are safe
373 # sprintf: is calling do_sprintf(TARG,...) which can act on TARG
374 # before other args are processed.
376 # Suspicious wrt "additional mode of failure" (and only it):
377 # schop, chop, postinc/dec, bit_and etc, negate, complement.
379 # Also suspicious: 4-arg substr, sprintf, uc/lc (POK_only), reverse, pack.
381 # substr/vec: doing TAINT_off()???
384 # readline - unknown whether it is safe
385 # match subst not OK (dTARG)
386 # grepwhile not OK (not always setting)
387 # join not OK (unsafe when TARG == arg)
389 # Suspicious wrt "additional mode of failure": concat (dealt with
390 # in ck_sassign()), join (same).
393 # mapwhile flip caller not OK (not always setting)
396 # backtick glob warn die not OK (not always setting)
397 # warn not OK (RETPUSHYES)
398 # open fileno getc sysread syswrite ioctl accept shutdown
399 # ftsize(etc) readlink telldir fork alarm getlogin not OK (RETPUSHUNDEF)
400 # umask select not OK (XPUSHs(&PL_sv_undef);)
401 # fileno getc sysread syswrite tell not OK (meth("FILENO" "GETC"))
402 # sselect shm* sem* msg* syscall - unknown whether they are safe
403 # gmtime not OK (list context)
405 # Suspicious wrt "additional mode of failure": warn, die, select.
409 # New ops always go at the very end
411 # A recapitulation of the format of this file:
412 # The file consists of five columns: the name of the op, an English
413 # description, the name of the "check" routine used to optimize this
414 # operation, some flags, and a description of the operands.
416 # The flags consist of options followed by a mandatory op class signifier
419 # baseop - 0 unop - 1 binop - 2
420 # logop - | listop - @ pmop - /
421 # padop/svop - $ padop - # (unused) loop - {
422 # baseop/unop - % loopexop - } filestatop - -
426 # needs stack mark - m
427 # needs constant folding - f
428 # produces a scalar - s
429 # produces an integer - i
431 # target can be in a pad - T
432 # has a corresponding integer version - I
433 # has side effects - d
434 # uses $_ if no argument given - u
436 # Values for the operands are:
437 # scalar - S list - L array - A
438 # hash - H sub (CV) - C file - F
439 # socket - Fs filetest - F- reference - R
440 # "?" denotes an optional operand.
444 null null operation ck_null 0
446 scalar scalar ck_fun s% S
450 pushmark pushmark ck_null s0
451 wantarray wantarray ck_null is0
453 const constant item ck_svconst s$
455 gvsv scalar variable ck_null ds$
456 gv glob value ck_null ds$
457 gelem glob elem ck_null d2 S S
458 padsv private variable ck_null ds0
459 padav private array ck_null d0
460 padhv private hash ck_null d0
461 padany private value ck_null d0
463 pushre push regexp ck_null d/
465 # References and stuff.
467 rv2gv ref-to-glob cast ck_rvconst ds1
468 rv2sv scalar dereference ck_rvconst ds1
469 av2arylen array length ck_null is1
470 rv2cv subroutine dereference ck_rvconst d1
471 anoncode anonymous subroutine ck_anoncode $
472 prototype subroutine prototype ck_null s% S
473 refgen reference constructor ck_spair m1 L
474 srefgen single ref constructor ck_null fs1 S
475 ref reference-type operator ck_fun stu% S?
476 bless bless ck_fun s@ S S?
480 backtick quoted execution (``, qx) ck_open t%
481 # glob defaults its first arg to $_
482 glob glob ck_glob t@ S?
483 readline <HANDLE> ck_null t% F?
484 rcatline append I/O operator ck_null t$
486 # Bindable operators.
488 regcmaybe regexp internal guard ck_fun s1 S
489 regcreset regexp internal reset ck_fun s1 S
490 regcomp regexp compilation ck_null s| S
491 match pattern match (m//) ck_match d/
492 qr pattern quote (qr//) ck_match s/
493 subst substitution (s///) ck_null dis/ S
494 substcont substitution iterator ck_null dis|
495 trans transliteration (tr///) ck_null is" S
498 # sassign is special-cased for op class
500 sassign scalar assignment ck_sassign s0
501 aassign list assignment ck_null t2 L L
503 chop chop ck_spair mts% L
504 schop scalar chop ck_null stu% S?
505 chomp chomp ck_spair mTs% L
506 schomp scalar chomp ck_null sTu% S?
507 defined defined operator ck_defined isu% S?
508 undef undef operator ck_lfun s% S?
509 study study ck_fun su% S?
510 pos match position ck_lfun stu% S?
512 preinc preincrement (++) ck_lfun dIs1 S
513 i_preinc integer preincrement (++) ck_lfun dis1 S
514 predec predecrement (--) ck_lfun dIs1 S
515 i_predec integer predecrement (--) ck_lfun dis1 S
516 postinc postincrement (++) ck_lfun dIst1 S
517 i_postinc integer postincrement (++) ck_lfun disT1 S
518 postdec postdecrement (--) ck_lfun dIst1 S
519 i_postdec integer postdecrement (--) ck_lfun disT1 S
521 # Ordinary operators.
523 pow exponentiation (**) ck_null fsT2 S S
525 multiply multiplication (*) ck_null IfsT2 S S
526 i_multiply integer multiplication (*) ck_null ifsT2 S S
527 divide division (/) ck_null IfsT2 S S
528 i_divide integer division (/) ck_null ifsT2 S S
529 modulo modulus (%) ck_null IifsT2 S S
530 i_modulo integer modulus (%) ck_null ifsT2 S S
531 repeat repeat (x) ck_repeat mt2 L S
533 add addition (+) ck_null IfsT2 S S
534 i_add integer addition (+) ck_null ifsT2 S S
535 subtract subtraction (-) ck_null IfsT2 S S
536 i_subtract integer subtraction (-) ck_null ifsT2 S S
537 concat concatenation (.) or string ck_concat fsT2 S S
538 stringify string ck_fun fsT@ S
540 left_shift left bitshift (<<) ck_bitop fsT2 S S
541 right_shift right bitshift (>>) ck_bitop fsT2 S S
543 lt numeric lt (<) ck_null Iifs2 S S
544 i_lt integer lt (<) ck_null ifs2 S S
545 gt numeric gt (>) ck_null Iifs2 S S
546 i_gt integer gt (>) ck_null ifs2 S S
547 le numeric le (<=) ck_null Iifs2 S S
548 i_le integer le (<=) ck_null ifs2 S S
549 ge numeric ge (>=) ck_null Iifs2 S S
550 i_ge integer ge (>=) ck_null ifs2 S S
551 eq numeric eq (==) ck_null Iifs2 S S
552 i_eq integer eq (==) ck_null ifs2 S S
553 ne numeric ne (!=) ck_null Iifs2 S S
554 i_ne integer ne (!=) ck_null ifs2 S S
555 ncmp numeric comparison (<=>) ck_null Iifst2 S S
556 i_ncmp integer comparison (<=>) ck_null ifst2 S S
558 slt string lt ck_null ifs2 S S
559 sgt string gt ck_null ifs2 S S
560 sle string le ck_null ifs2 S S
561 sge string ge ck_null ifs2 S S
562 seq string eq ck_null ifs2 S S
563 sne string ne ck_null ifs2 S S
564 scmp string comparison (cmp) ck_null ifst2 S S
566 bit_and bitwise and (&) ck_bitop fst2 S S
567 bit_xor bitwise xor (^) ck_bitop fst2 S S
568 bit_or bitwise or (|) ck_bitop fst2 S S
570 negate negation (-) ck_null Ifst1 S
571 i_negate integer negation (-) ck_null ifsT1 S
572 not not ck_null ifs1 S
573 complement 1's complement (~) ck_bitop fst1 S
575 # High falutin' math.
577 atan2 atan2 ck_fun fsT@ S S
578 sin sin ck_fun fsTu% S?
579 cos cos ck_fun fsTu% S?
580 rand rand ck_fun sT% S?
581 srand srand ck_fun s% S?
582 exp exp ck_fun fsTu% S?
583 log log ck_fun fsTu% S?
584 sqrt sqrt ck_fun fsTu% S?
588 int int ck_fun fsTu% S?
589 hex hex ck_fun fsTu% S?
590 oct oct ck_fun fsTu% S?
591 abs abs ck_fun fsTu% S?
595 length length ck_lengthconst isTu% S?
596 substr substr ck_substr st@ S S S? S?
597 vec vec ck_fun ist@ S S S
599 index index ck_index isT@ S S S?
600 rindex rindex ck_index isT@ S S S?
602 sprintf sprintf ck_fun mfst@ S L
603 formline formline ck_fun ms@ S L
604 ord ord ck_fun ifsTu% S?
605 chr chr ck_fun fsTu% S?
606 crypt crypt ck_fun fsT@ S S
607 ucfirst ucfirst ck_fun fstu% S?
608 lcfirst lcfirst ck_fun fstu% S?
609 uc uc ck_fun fstu% S?
610 lc lc ck_fun fstu% S?
611 quotemeta quotemeta ck_fun fstu% S?
615 rv2av array dereference ck_rvconst dt1
616 aelemfast constant array element ck_null s$ A S
617 aelem array element ck_null s2 A S
618 aslice array slice ck_null m@ A L
623 values values ck_fun t% H
624 keys keys ck_fun t% H
625 delete delete ck_delete % S
626 exists exists ck_exists is% S
627 rv2hv hash dereference ck_rvconst dt1
628 helem hash element ck_null s2@ H S
629 hslice hash slice ck_null m@ H L
631 # Explosives and implosives.
633 unpack unpack ck_fun @ S S
634 pack pack ck_fun mst@ S L
635 split split ck_split t@ S S S
636 join join or string ck_join mst@ S L
640 list list ck_null m@ L
641 lslice list slice ck_null 2 H L L
642 anonlist anonymous list ([]) ck_fun ms@ L
643 anonhash anonymous hash ({}) ck_fun ms@ L
645 splice splice ck_fun m@ A S? S? L
646 push push ck_fun imsT@ A L
647 pop pop ck_shift s% A
648 shift shift ck_shift s% A
649 unshift unshift ck_fun imsT@ A L
650 sort sort ck_sort m@ C? L
651 reverse reverse ck_fun mt@ L
653 grepstart grep ck_grep dm@ C L
654 grepwhile grep iterator ck_null dt|
656 mapstart map ck_grep dm@ C L
657 mapwhile map iterator ck_null dt|
661 range flipflop ck_null | S S
662 flip range (or flip) ck_null 1 S S
663 flop range (or flop) ck_null 1
667 and logical and (&&) ck_null |
668 or logical or (||) ck_null |
669 xor logical xor ck_null fs2 S S
670 cond_expr conditional expression ck_null d|
671 andassign logical and assignment (&&=) ck_null s|
672 orassign logical or assignment (||=) ck_null s|
674 method method lookup ck_method d1
675 entersub subroutine entry ck_subr dmt1 L
676 leavesub subroutine exit ck_null 1
677 leavesublv lvalue subroutine return ck_null 1
678 caller caller ck_fun t% S?
679 warn warn ck_fun imst@ L
680 die die ck_die dimst@ L
681 reset symbol reset ck_fun is% S?
683 lineseq line sequence ck_null @
684 nextstate next statement ck_null s;
685 dbstate debug next statement ck_null s;
686 unstack iteration finalizer ck_null s0
687 enter block entry ck_null 0
688 leave block exit ck_null @
689 scope block ck_null @
690 enteriter foreach loop entry ck_null d{
691 iter foreach loop iterator ck_null 0
692 enterloop loop entry ck_null d{
693 leaveloop loop exit ck_null 2
694 return return ck_return dm@ L
695 last last ck_null ds}
696 next next ck_null ds}
697 redo redo ck_null ds}
698 dump dump ck_null ds}
699 goto goto ck_null ds}
700 exit exit ck_exit ds% S?
703 #nswitch numeric switch ck_null d
704 #cswitch character switch ck_null d
708 open open ck_open ismt@ F S? L
709 close close ck_fun is% F?
710 pipe_op pipe ck_fun is@ F F
712 fileno fileno ck_fun ist% F
713 umask umask ck_fun ist% S?
714 binmode binmode ck_fun s@ F S?
716 tie tie ck_fun idms@ R S L
717 untie untie ck_fun is% R
718 tied tied ck_fun s% R
719 dbmopen dbmopen ck_fun is@ H S S
720 dbmclose dbmclose ck_fun is% H
722 sselect select system call ck_select t@ S S S S
723 select select ck_select st@ F?
725 getc getc ck_eof st% F?
726 read read ck_fun imst@ F R S S?
727 enterwrite write ck_fun dis% F?
728 leavewrite write exit ck_null 1
730 prtf printf ck_listiob ims@ F? L
731 print print ck_listiob ims@ F? L
733 sysopen sysopen ck_fun s@ F S S S?
734 sysseek sysseek ck_fun s@ F S S
735 sysread sysread ck_fun imst@ F R S S?
736 syswrite syswrite ck_fun imst@ F S S? S?
738 send send ck_fun imst@ Fs S S S?
739 recv recv ck_fun imst@ Fs R S S
741 eof eof ck_eof is% F?
742 tell tell ck_fun st% F?
743 seek seek ck_fun s@ F S S
744 # truncate really behaves as if it had both "S S" and "F S"
745 truncate truncate ck_trunc is@ S S
747 fcntl fcntl ck_fun st@ F S S
748 ioctl ioctl ck_fun st@ F S S
749 flock flock ck_fun isT@ F S
753 socket socket ck_fun is@ Fs S S S
754 sockpair socketpair ck_fun is@ Fs Fs S S S
756 bind bind ck_fun is@ Fs S
757 connect connect ck_fun is@ Fs S
758 listen listen ck_fun is@ Fs S
759 accept accept ck_fun ist@ Fs Fs
760 shutdown shutdown ck_fun ist@ Fs S
762 gsockopt getsockopt ck_fun is@ Fs S S
763 ssockopt setsockopt ck_fun is@ Fs S S S
765 getsockname getsockname ck_fun is% Fs
766 getpeername getpeername ck_fun is% Fs
770 lstat lstat ck_ftst u- F
771 stat stat ck_ftst u- F
772 ftrread -R ck_ftst isu- F-
773 ftrwrite -W ck_ftst isu- F-
774 ftrexec -X ck_ftst isu- F-
775 fteread -r ck_ftst isu- F-
776 ftewrite -w ck_ftst isu- F-
777 fteexec -x ck_ftst isu- F-
778 ftis -e ck_ftst isu- F-
779 fteowned -O ck_ftst isu- F-
780 ftrowned -o ck_ftst isu- F-
781 ftzero -z ck_ftst isu- F-
782 ftsize -s ck_ftst istu- F-
783 ftmtime -M ck_ftst stu- F-
784 ftatime -A ck_ftst stu- F-
785 ftctime -C ck_ftst stu- F-
786 ftsock -S ck_ftst isu- F-
787 ftchr -c ck_ftst isu- F-
788 ftblk -b ck_ftst isu- F-
789 ftfile -f ck_ftst isu- F-
790 ftdir -d ck_ftst isu- F-
791 ftpipe -p ck_ftst isu- F-
792 ftlink -l ck_ftst isu- F-
793 ftsuid -u ck_ftst isu- F-
794 ftsgid -g ck_ftst isu- F-
795 ftsvtx -k ck_ftst isu- F-
796 fttty -t ck_ftst is- F-
797 fttext -T ck_ftst isu- F-
798 ftbinary -B ck_ftst isu- F-
802 chdir chdir ck_fun isT% S?
803 chown chown ck_fun imsT@ L
804 chroot chroot ck_fun isTu% S?
805 unlink unlink ck_fun imsTu@ L
806 chmod chmod ck_fun imsT@ L
807 utime utime ck_fun imsT@ L
808 rename rename ck_fun isT@ S S
809 link link ck_fun isT@ S S
810 symlink symlink ck_fun isT@ S S
811 readlink readlink ck_fun stu% S?
812 mkdir mkdir ck_fun isT@ S S?
813 rmdir rmdir ck_fun isTu% S?
817 open_dir opendir ck_fun is@ F S
818 readdir readdir ck_fun % F
819 telldir telldir ck_fun st% F
820 seekdir seekdir ck_fun s@ F S
821 rewinddir rewinddir ck_fun s% F
822 closedir closedir ck_fun is% F
826 fork fork ck_null ist0
827 wait wait ck_null isT0
828 waitpid waitpid ck_fun isT@ S S
829 system system ck_exec imsT@ S? L
830 exec exec ck_exec dimsT@ S? L
831 kill kill ck_fun dimsT@ L
832 getppid getppid ck_null isT0
833 getpgrp getpgrp ck_fun isT% S?
834 setpgrp setpgrp ck_fun isT@ S? S?
835 getpriority getpriority ck_fun isT@ S S
836 setpriority setpriority ck_fun isT@ S S S
840 # NOTE: MacOS patches the 'i' of time() away later when the interpreter
841 # is created because in MacOS time() is already returning times > 2**31-1,
842 # that is, non-integers.
844 time time ck_null isT0
846 localtime localtime ck_fun t% S?
847 gmtime gmtime ck_fun t% S?
848 alarm alarm ck_fun istu% S?
849 sleep sleep ck_fun isT% S?
853 shmget shmget ck_fun imst@ S S S
854 shmctl shmctl ck_fun imst@ S S S
855 shmread shmread ck_fun imst@ S S S S
856 shmwrite shmwrite ck_fun imst@ S S S S
860 msgget msgget ck_fun imst@ S S
861 msgctl msgctl ck_fun imst@ S S S
862 msgsnd msgsnd ck_fun imst@ S S S
863 msgrcv msgrcv ck_fun imst@ S S S S S
867 semget semget ck_fun imst@ S S S
868 semctl semctl ck_fun imst@ S S S S
869 semop semop ck_fun imst@ S S
873 require require ck_require du% S?
874 dofile do "file" ck_fun d1 S
875 entereval eval "string" ck_eval d% S
876 leaveeval eval "string" exit ck_null 1 S
877 #evalonce eval constant string ck_null d1 S
878 entertry eval {block} ck_null |
879 leavetry eval {block} exit ck_null @
883 ghbyname gethostbyname ck_fun % S
884 ghbyaddr gethostbyaddr ck_fun @ S S
885 ghostent gethostent ck_null 0
886 gnbyname getnetbyname ck_fun % S
887 gnbyaddr getnetbyaddr ck_fun @ S S
888 gnetent getnetent ck_null 0
889 gpbyname getprotobyname ck_fun % S
890 gpbynumber getprotobynumber ck_fun @ S
891 gprotoent getprotoent ck_null 0
892 gsbyname getservbyname ck_fun @ S S
893 gsbyport getservbyport ck_fun @ S S
894 gservent getservent ck_null 0
895 shostent sethostent ck_fun is% S
896 snetent setnetent ck_fun is% S
897 sprotoent setprotoent ck_fun is% S
898 sservent setservent ck_fun is% S
899 ehostent endhostent ck_null is0
900 enetent endnetent ck_null is0
901 eprotoent endprotoent ck_null is0
902 eservent endservent ck_null is0
903 gpwnam getpwnam ck_fun % S
904 gpwuid getpwuid ck_fun % S
905 gpwent getpwent ck_null 0
906 spwent setpwent ck_null is0
907 epwent endpwent ck_null is0
908 ggrnam getgrnam ck_fun % S
909 ggrgid getgrgid ck_fun % S
910 ggrent getgrent ck_null 0
911 sgrent setgrent ck_null is0
912 egrent endgrent ck_null is0
913 getlogin getlogin ck_null st0
917 syscall syscall ck_fun imst@ S L
919 # For multi-threading
920 lock lock ck_rfun s% S
921 threadsv per-thread value ck_null ds0
924 setstate set statement info ck_null s;
925 method_named method with known name ck_null d$
927 custom unknown custom operator ck_null 0