/[pcre]/code/trunk/sljit/sljitLir.h
ViewVC logotype

Diff of /code/trunk/sljit/sljitLir.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1181 by zherczeg, Sat Oct 20 21:33:38 2012 UTC revision 1182 by zherczeg, Sun Oct 28 05:22:32 2012 UTC
# Line 369  SLJIT_API_FUNC_ATTRIBUTE void sljit_set_ Line 369  SLJIT_API_FUNC_ATTRIBUTE void sljit_set_
369    
370  /* Return from machine code.  The op argument can be SLJIT_UNUSED which means the  /* Return from machine code.  The op argument can be SLJIT_UNUSED which means the
371     function does not return with anything or any opcode between SLJIT_MOV and     function does not return with anything or any opcode between SLJIT_MOV and
372     SLJIT_MOV_SI (see sljit_emit_op1). As for src and srcw they must be 0 if op     SLJIT_MOV_P (see sljit_emit_op1). As for src and srcw they must be 0 if op
373     is SLJIT_UNUSED, otherwise see below the description about source and     is SLJIT_UNUSED, otherwise see below the description about source and
374     destination arguments. */     destination arguments. */
375  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler, int op,  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler, int op,
# Line 377  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ Line 377  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_
377    
378  /* Really fast calling method for utility functions inside sljit (see SLJIT_FAST_CALL).  /* Really fast calling method for utility functions inside sljit (see SLJIT_FAST_CALL).
379     All registers and even the stack frame is passed to the callee. The return address is     All registers and even the stack frame is passed to the callee. The return address is
380     preserved in dst/dstw by sljit_emit_fast_enter, and sljit_emit_fast_return can     preserved in dst/dstw by sljit_emit_fast_enter (the type of the value stored by this
381     use this as a return value later. */     function is sljit_p), and sljit_emit_fast_return can use this as a return value later. */
382    
383  /* Note: only for sljit specific, non ABI compilant calls. Fast, since only a few machine instructions  /* Note: only for sljit specific, non ABI compilant calls. Fast, since only a few machine
384     are needed. Excellent for small uility functions, where saving registers and setting up     instructions are needed. Excellent for small uility functions, where saving registers
385     a new stack frame would cost too much performance. However, it is still possible to return     and setting up a new stack frame would cost too much performance. However, it is still
386     to the address of the caller (or anywhere else). */     possible to return to the address of the caller (or anywhere else). */
387    
388  /* Note: flags are not changed (unlike sljit_emit_enter / sljit_emit_return). */  /* Note: flags are not changed (unlike sljit_emit_enter / sljit_emit_return). */
389    
# Line 512  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ Line 512  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_
512         or SLJIT_MEM2(r1, r2), r1 is increased by the sum of r2 and the constant argument         or SLJIT_MEM2(r1, r2), r1 is increased by the sum of r2 and the constant argument
513     UB = unsigned byte (8 bit)     UB = unsigned byte (8 bit)
514     SB = signed byte (8 bit)     SB = signed byte (8 bit)
515     UH = unsgined half (16 bit)     UH = unsigned half (16 bit)
516     SH = unsgined half (16 bit) */     SH = signed half (16 bit)
517       UI = unsigned int (32 bit)
518       SI = signed int (32 bit)
519       P  = pointer (sljit_p) size */
520    
521  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
522  #define SLJIT_MOV                       6  #define SLJIT_MOV                       6
# Line 530  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ Line 533  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_
533  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
534  #define SLJIT_MOV_SI                    12  #define SLJIT_MOV_SI                    12
535  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
536  #define SLJIT_MOVU                      13  #define SLJIT_MOV_P                     13
537  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
538  #define SLJIT_MOVU_UB                   14  #define SLJIT_MOVU                      14
539  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
540  #define SLJIT_MOVU_SB                   15  #define SLJIT_MOVU_UB                   15
541  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
542  #define SLJIT_MOVU_UH                   16  #define SLJIT_MOVU_SB                   16
543  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
544  #define SLJIT_MOVU_SH                   17  #define SLJIT_MOVU_UH                   17
545  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
546  #define SLJIT_MOVU_UI                   18  #define SLJIT_MOVU_SH                   18
547  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
548  #define SLJIT_MOVU_SI                   19  #define SLJIT_MOVU_UI                   19
549    /* Flags: - (never set any flags) */
550    #define SLJIT_MOVU_SI                   20
551    /* Flags: - (never set any flags) */
552    #define SLJIT_MOVU_P                    21
553  /* Flags: I | E | K */  /* Flags: I | E | K */
554  #define SLJIT_NOT                       20  #define SLJIT_NOT                       22
555  /* Flags: I | E | O | K */  /* Flags: I | E | O | K */
556  #define SLJIT_NEG                       21  #define SLJIT_NEG                       23
557  /* Count leading zeroes  /* Count leading zeroes
558     Flags: I | E | K     Flags: I | E | K
559     Important note! Sparc 32 does not support K flag, since     Important note! Sparc 32 does not support K flag, since
560     the required popc instruction is introduced only in sparc 64. */     the required popc instruction is introduced only in sparc 64. */
561  #define SLJIT_CLZ                       22  #define SLJIT_CLZ                       24
562    
563  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int op,  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int op,
564          int dst, sljit_w dstw,          int dst, sljit_w dstw,
565          int src, sljit_w srcw);          int src, sljit_w srcw);
566    
567  /* Flags: I | E | O | C | K */  /* Flags: I | E | O | C | K */
568  #define SLJIT_ADD                       23  #define SLJIT_ADD                       25
569  /* Flags: I | C | K */  /* Flags: I | C | K */
570  #define SLJIT_ADDC                      24  #define SLJIT_ADDC                      26
571  /* Flags: I | E | S | U | O | C | K */  /* Flags: I | E | S | U | O | C | K */
572  #define SLJIT_SUB                       25  #define SLJIT_SUB                       27
573  /* Flags: I | C | K */  /* Flags: I | C | K */
574  #define SLJIT_SUBC                      26  #define SLJIT_SUBC                      28
575  /* Note: integer mul  /* Note: integer mul
576     Flags: I | O (see SLJIT_C_MUL_*) | K */     Flags: I | O (see SLJIT_C_MUL_*) | K */
577  #define SLJIT_MUL                       27  #define SLJIT_MUL                       29
578  /* Flags: I | E | K */  /* Flags: I | E | K */
579  #define SLJIT_AND                       28  #define SLJIT_AND                       30
580  /* Flags: I | E | K */  /* Flags: I | E | K */
581  #define SLJIT_OR                        29  #define SLJIT_OR                        31
582  /* Flags: I | E | K */  /* Flags: I | E | K */
583  #define SLJIT_XOR                       30  #define SLJIT_XOR                       32
584  /* Flags: I | E | K  /* Flags: I | E | K
585     Let bit_length be the length of the shift operation: 32 or 64.     Let bit_length be the length of the shift operation: 32 or 64.
586     If src2 is immediate, src2w is masked by (bit_length - 1).     If src2 is immediate, src2w is masked by (bit_length - 1).
587     Otherwise, if the content of src2 is outside the range from 0     Otherwise, if the content of src2 is outside the range from 0
588     to bit_length - 1, the operation is undefined. */     to bit_length - 1, the operation is undefined. */
589  #define SLJIT_SHL                       31  #define SLJIT_SHL                       33
590  /* Flags: I | E | K  /* Flags: I | E | K
591     Let bit_length be the length of the shift operation: 32 or 64.     Let bit_length be the length of the shift operation: 32 or 64.
592     If src2 is immediate, src2w is masked by (bit_length - 1).     If src2 is immediate, src2w is masked by (bit_length - 1).
593     Otherwise, if the content of src2 is outside the range from 0     Otherwise, if the content of src2 is outside the range from 0
594     to bit_length - 1, the operation is undefined. */     to bit_length - 1, the operation is undefined. */
595  #define SLJIT_LSHR                      32  #define SLJIT_LSHR                      34
596  /* Flags: I | E | K  /* Flags: I | E | K
597     Let bit_length be the length of the shift operation: 32 or 64.     Let bit_length be the length of the shift operation: 32 or 64.
598     If src2 is immediate, src2w is masked by (bit_length - 1).     If src2 is immediate, src2w is masked by (bit_length - 1).
599     Otherwise, if the content of src2 is outside the range from 0     Otherwise, if the content of src2 is outside the range from 0
600     to bit_length - 1, the operation is undefined. */     to bit_length - 1, the operation is undefined. */
601  #define SLJIT_ASHR                      33  #define SLJIT_ASHR                      35
602    
603  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int op,  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int op,
604          int dst, sljit_w dstw,          int dst, sljit_w dstw,
# Line 628  SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fp Line 635  SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fp
635     Note: NaN check is always performed. If SLJIT_C_FLOAT_UNORDERED is set,     Note: NaN check is always performed. If SLJIT_C_FLOAT_UNORDERED is set,
636           the comparison result is unpredictable.           the comparison result is unpredictable.
637     Flags: E | S (see SLJIT_C_FLOAT_*) */     Flags: E | S (see SLJIT_C_FLOAT_*) */
638  #define SLJIT_FCMP                      34  #define SLJIT_FCMP                      36
639  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
640  #define SLJIT_FMOV                      35  #define SLJIT_FMOV                      37
641  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
642  #define SLJIT_FNEG                      36  #define SLJIT_FNEG                      38
643  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
644  #define SLJIT_FABS                      37  #define SLJIT_FABS                      39
645    
646  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, int op,  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, int op,
647          int dst, sljit_w dstw,          int dst, sljit_w dstw,
648          int src, sljit_w srcw);          int src, sljit_w srcw);
649    
650  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
651  #define SLJIT_FADD                      38  #define SLJIT_FADD                      40
652  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
653  #define SLJIT_FSUB                      39  #define SLJIT_FSUB                      41
654  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
655  #define SLJIT_FMUL                      40  #define SLJIT_FMUL                      42
656  /* Flags: - (never set any flags) */  /* Flags: - (never set any flags) */
657  #define SLJIT_FDIV                      41  #define SLJIT_FDIV                      43
658    
659  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, int op,  SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, int op,
660          int dst, sljit_w dstw,          int dst, sljit_w dstw,

Legend:
Removed from v.1181  
changed lines
  Added in v.1182

  ViewVC Help
Powered by ViewVC 1.1.5