Home
last modified time | relevance | path

Searched refs:shf (Results 1 – 25 of 29) sorted by relevance

12

/external/mksh/src/
Dshf.c40 static int shf_fillbuf(struct shf *);
41 static int shf_emptybuf(struct shf *, int);
48 struct shf *
51 struct shf *shf; in shf_open() local
58 shf = alloc(sizeof(struct shf) + bsize, ATEMP); in shf_open()
59 shf->areap = ATEMP; in shf_open()
60 shf->buf = (unsigned char *)&shf[1]; in shf_open()
61 shf->bsize = bsize; in shf_open()
62 shf->flags = SHF_ALLOCS; in shf_open()
68 afree(shf, shf->areap); in shf_open()
[all …]
Dtree.c30 static void ptree(struct op *, int, struct shf *);
31 static void pioact(struct shf *, struct ioword *);
32 static const char *wdvarput(struct shf *, const char *, int, int);
33 static void vfptreef(struct shf *, int, const char *, va_list);
46 ptree(struct op *t, int indent, struct shf *shf) in ptree() argument
73 fptreef(shf, indent, "%S", t->vars[0]); in ptree()
80 fptreef(shf, indent, "%S ", *w++); in ptree()
82 shf_puts("#no-vars# ", shf); in ptree()
86 fptreef(shf, indent, "%S ", *w++); in ptree()
88 shf_puts("#no-args# ", shf); in ptree()
[all …]
Dsh.h883 struct shf *shf; member
1097 #define shf_fileno(shf) ((shf)->fd) argument
1098 #define shf_setfileno(shf,nfd) ((shf)->fd = (nfd)) argument
1099 #define shf_getc_i(shf) ((shf)->rnleft > 0 ? \ argument
1100 (shf)->rnleft--, *(shf)->rp++ : \
1101 shf_getchar(shf))
1102 #define shf_putc_i(c, shf) ((shf)->wnleft == 0 ? \ argument
1103 shf_putchar((c), (shf)) : \
1104 ((shf)->wnleft--, *(shf)->wp++ = (c)))
1105 #define shf_eof(shf) ((shf)->flags & SHF_EOF) argument
[all …]
Deval.c45 struct shf *shf; member
426 struct shf shf; in expand() local
428 shf_sopen(NULL, 0, SHF_WR|SHF_DYNAMIC, &shf); in expand()
429 print_value_quoted(&shf, str_val(st->var)); in expand()
430 x.str = shf_sclose(&shf); in expand()
850 if (x.u.shf == NULL) { in expand()
860 while ((c = shf_getc(x.u.shf)) == 0 || c == '\n') in expand()
865 shf_ungetc(c, x.u.shf); in expand()
872 if (x.u.shf) in expand()
873 shf_close(x.u.shf); in expand()
[all …]
Dmain.c469 s->u.shf = shf_open(s->file, O_RDONLY, 0, in main_init()
471 if (s->u.shf == NULL) { in main_init()
483 s->u.shf = shf_fdopen(0, SHF_RD | can_seek(0), in main_init()
489 s->u.shf->flags |= SHF_INTERRUPT; in main_init()
665 struct shf *shf; in include() local
670 shf = shf_open(name, O_RDONLY, 0, SHF_MAPHI | SHF_CLEXEC); in include()
671 if (shf == NULL) in include()
683 quitenv(s ? s->u.shf : NULL); in include()
716 s->u.shf = shf; in include()
719 quitenv(s->u.shf); in include()
[all …]
Dmisc.c1111 print_value_quoted(struct shf *shf, const char *s) in print_value_quoted() argument
1126 shf_puts(s, shf); in print_value_quoted()
1139 shf_putc('\'', shf); in print_value_quoted()
1142 shf_putc('\\', shf); in print_value_quoted()
1144 shf_putc('\'', shf); in print_value_quoted()
1147 shf_putc(c, shf); in print_value_quoted()
1154 shf_putc('$', shf); in print_value_quoted()
1155 shf_putc('\'', shf); in print_value_quoted()
1161 shf_fprintf(shf, "\\u%04X", wc); in print_value_quoted()
1201 shf_putc('\\', shf); in print_value_quoted()
[all …]
Dlex.c1387 char *p = shf_getse(xp, Xnleft(s->xs, xp), s->u.shf); in getsc_line()
1389 if (!p && shf_error(s->u.shf) && in getsc_line()
1390 shf_errno(s->u.shf) == EINTR) { in getsc_line()
1391 shf_clearerr(s->u.shf); in getsc_line()
1413 shf_flush(s->u.shf); in getsc_line()
1432 shf_fdclose(s->u.shf); in getsc_line()
1472 struct shf *shf; in set_prompt() local
1478 shf = shf_sopen(NULL, strlen(ps1) * 2, in set_prompt()
1482 shf_putchar(*ps1++, shf); in set_prompt()
1484 shf_fprintf(shf, "%lu", s ? in set_prompt()
[all …]
Djobs.c133 static struct shf *shl_j;
143 static void j_print(Job *, int, struct shf *);
1525 j_print(Job *j, int how, struct shf *shf) in j_print() argument
1542 shf_fprintf(shf, "%d\n", (int)(j->pgrp ? j->pgrp : in j_print()
1603 shf_fprintf(shf, "[%d] %c ", j->job, jobchar); in j_print()
1605 shf_puts(filler, shf); in j_print()
1609 shf_fprintf(shf, "%5d ", (int)p->pid); in j_print()
1614 shf_fprintf(shf, "%s%s ", in j_print()
1619 shf_fprintf(shf, "%-20s %s%s%s", buf, p->command, in j_print()
1629 shf_fprintf(shf, "%s%5d %-20s %s%s", filler, in j_print()
[all …]
Dhistrap.c93 struct shf *shf; in c_fc() local
302 if (!(shf = tf->shf)) { in c_fc()
309 shf_fprintf(shf, "%s\n", *hp); in c_fc()
310 if (shf_close(shf) == -1) { in c_fc()
336 if (!(shf = shf_open(tf->tffn, O_RDONLY, 0, 0))) { in c_fc()
351 while ((n = shf_read(xp, Xnleft(xs, xp), shf)) > 0) { in c_fc()
358 "read", tf->tffn, cstrerror(shf_errno(shf))); in c_fc()
360 shf_close(shf); in c_fc()
363 shf_close(shf); in c_fc()
Dexec.c1541 hereinval(struct ioword *iop, int sub, char **resbuf, struct shf *shf) in hereinval() argument
1550 quitenv(shf); in hereinval()
1568 shf_puts(ccp, shf); in hereinval()
1580 struct shf *shf; in herein() local
1603 if (!(shf = h->shf) || (fd = binopen3(h->tffn, O_RDONLY, 0)) < 0) { in herein()
1606 !shf ? "create" : "open", h->tffn, cstrerror(i)); in herein()
1607 if (shf) in herein()
1608 shf_close(shf); in herein()
1613 if (hereinval(iop, i, NULL, shf) == -2) { in herein()
1619 if (shf_close(shf) == -1) { in herein()
Dfuncs.c232 static void p_time(struct shf *, bool, long, int, int,
2578 p_time(struct shf *shf, bool posix, long tv_sec, int tv_usec, int width, in p_time() argument
2583 shf_fprintf(shf, "%s%*ld.%02d%s", prefix, width, in p_time()
2586 shf_fprintf(shf, "%s%*ldm%02d.%02ds%s", prefix, width, in p_time()
/external/llvm/test/MC/Mips/msa/
Dtest_i8.s9 # CHECK: shf.b $w19, $w30, 105 # encoding: [0x78,0x69,0xf4,0xc2]
10 # CHECK: shf.h $w17, $w8, 76 # encoding: [0x79,0x4c,0x44,0x42]
11 # CHECK: shf.w $w14, $w3, 93 # encoding: [0x7a,0x5d,0x1b,0x82]
20 shf.b $w19, $w30, 105
21 shf.h $w17, $w8, 76
22 shf.w $w14, $w3, 93
Dinvalid.s38 shf.b $w19, $w30, -1 # CHECK: :[[@LINE]]:23: error: expected 8-bit unsigned immediate
39 shf.b $w19, $w30, 256 # CHECK: :[[@LINE]]:23: error: expected 8-bit unsigned immediate
40 shf.h $w17, $w8, -1 # CHECK: :[[@LINE]]:22: error: expected 8-bit unsigned immediate
41 shf.h $w17, $w8, 256 # CHECK: :[[@LINE]]:22: error: expected 8-bit unsigned immediate
42 shf.w $w14, $w3, -1 # CHECK: :[[@LINE]]:22: error: expected 8-bit unsigned immediate
43 shf.w $w14, $w3, 256 # CHECK: :[[@LINE]]:22: error: expected 8-bit unsigned immediate
Dinvalid-64.s40 shf.b $w19, $w30, -1 # CHECK: :[[@LINE]]:23: error: expected 8-bit unsigned immediate
41 shf.h $w17, $w8, -1 # CHECK: :[[@LINE]]:22: error: expected 8-bit unsigned immediate
42 shf.w $w14, $w3, -1 # CHECK: :[[@LINE]]:22: error: expected 8-bit unsigned immediate
/external/llvm/test/CodeGen/NVPTX/
Drotate.ll16 ; SM35: shf.l.wrap.b32
28 ; SM35: shf.l.wrap.b32
29 ; SM35: shf.l.wrap.b32
41 ; SM35: shf.r.wrap.b32
42 ; SM35: shf.r.wrap.b32
53 ; SM35: shf.l.wrap.b32
/external/llvm/test/MC/Disassembler/Mips/msa/
Dtest_i8.txt9 0x78 0x69 0xf4 0xc2 # CHECK: shf.b $w19, $w30, 105
10 0x79 0x4c 0x44 0x42 # CHECK: shf.h $w17, $w8, 76
11 0x7a 0x5d 0x1b 0x82 # CHECK: shf.w $w14, $w3, 93
/external/llvm/test/CodeGen/Mips/msa/
Di8.ll142 %1 = tail call <16 x i8> @llvm.mips.shf.b(<16 x i8> %0, i32 25)
147 declare <16 x i8> @llvm.mips.shf.b(<16 x i8>, i32) nounwind
151 ; CHECK: shf.b
161 %1 = tail call <8 x i16> @llvm.mips.shf.h(<8 x i16> %0, i32 25)
166 declare <8 x i16> @llvm.mips.shf.h(<8 x i16>, i32) nounwind
170 ; CHECK: shf.h
180 %1 = tail call <4 x i32> @llvm.mips.shf.w(<4 x i32> %0, i32 25)
185 declare <4 x i32> @llvm.mips.shf.w(<4 x i32>, i32) nounwind
189 ; CHECK: shf.w
Dbitcast.ll50 ; BIGENDIAN: shf.b [[R3:\$w[0-9]+]], [[R2]], 177
98 ; BIGENDIAN: shf.b [[R3:\$w[0-9]+]], [[R2]], 27
123 ; BIGENDIAN: shf.b [[R3:\$w[0-9]+]], [[R2]], 27
148 ; BIGENDIAN: shf.b [[R3:\$w[0-9]+]], [[R2]], 27
149 ; BIGENDIAN: shf.w [[R3:\$w[0-9]+]], [[R3]], 177
174 ; BIGENDIAN: shf.b [[R3:\$w[0-9]+]], [[R2]], 27
175 ; BIGENDIAN: shf.w [[R3:\$w[0-9]+]], [[R3]], 177
200 ; BIGENDIAN: shf.b [[R3:\$w[0-9]+]], [[R2]], 177
272 ; BIGENDIAN: shf.h [[R3:\$w[0-9]+]], [[R2]], 177
297 ; BIGENDIAN: shf.h [[R3:\$w[0-9]+]], [[R2]], 177
[all …]
Dshuffle.ll165 ; CHECK-DAG: shf.w [[R3:\$w[0-9]+]], [[R1]], 27
192 ; CHECK-DAG: shf.w [[R3:\$w[0-9]+]], [[R2]], 36
314 ; CHECK-DAG: shf.b [[R3:\$w[0-9]+]], [[R1]], 45
327 ; CHECK-DAG: shf.h [[R3:\$w[0-9]+]], [[R1]], 27
340 ; CHECK-DAG: shf.w [[R3:\$w[0-9]+]], [[R1]], 27
347 ; shf.d does not exist
/external/llvm/lib/Target/Mips/
DMSA.txt24 constant since shf.w covers exactly the same cases. shf.w is used
48 It is not possible to emit splati.w since shf.w covers the same cases.
49 shf.w will be emitted instead.
/external/mksh/
DMakefrag.inc5 SRCS= lalloc.c eval.c exec.c expr.c funcs.c histrap.c jobs.c lex.c main.c misc.c shf.c syn.c tree.…
6 …rc/histrap.c ../src/jobs.c ../src/lex.c ../src/main.c ../src/misc.c ../src/shf.c ../src/syn.c ../s…
7 OBJS_BP= lalloc.o eval.o exec.o expr.o funcs.o histrap.o jobs.o lex.o main.o misc.o shf.o syn.o tr…
DAndroid.mk30 src/lex.c src/main.c src/misc.c src/shf.c \
/external/apache-commons-math/src/main/java/org/apache/commons/math/dfp/
DDfp.java1981 int shf; in dfp2sci() local
1998 shf = p; in dfp2sci()
2027 e = exp * 4 - shf - 1; in dfp2sci()
/external/llvm/lib/Target/NVPTX/
DNVPTXInstrInfo.td1092 // Rotate: use ptx shf instruction if available.
1097 // r2 = shf.l r1, r1, n
1100 "shf.l.wrap.b32 \t$dst, $src, $src, $amt;",
1106 "shf.l.wrap.b32 \t$dst, $src, $src, $amt;",
1112 // r2 = shf.r r1, r1, n
1115 "shf.r.wrap.b32 \t$dst, $src, $src, $amt;",
1121 "shf.r.wrap.b32 \t$dst, $src, $src, $amt;",
1126 // Rotate: if ptx shf instruction is not available, then use shift+add
1373 "shf.l.clamp.b32 \t$dst, $lo, $hi, $amt;",
1380 "shf.r.clamp.b32 \t$dst, $lo, $hi, $amt;",
/external/valgrind/VEX/priv/
Dguest_arm64_toIR.c9191 IRTemp shf = newTempV128(); in dis_AdvSIMD_scalar_shift_by_imm() local
9194 assign(shf, mkV128(0x0000)); in dis_AdvSIMD_scalar_shift_by_imm()
9201 assign(shf, binop(op, src, mkU8(sh - nudge))); in dis_AdvSIMD_scalar_shift_by_imm()
9203 assign(res, isAcc ? binop(Iop_Add64x2, getQReg128(dd), mkexpr(shf)) in dis_AdvSIMD_scalar_shift_by_imm()
9204 : mkexpr(shf)); in dis_AdvSIMD_scalar_shift_by_imm()
9228 IRTemp shf = newTempV128(); in dis_AdvSIMD_scalar_shift_by_imm() local
9230 assign(shf, binop(op, src, amt)); in dis_AdvSIMD_scalar_shift_by_imm()
9231 assign(res, isAcc ? binop(Iop_Add64x2, getQReg128(dd), mkexpr(shf)) in dis_AdvSIMD_scalar_shift_by_imm()
9232 : mkexpr(shf)); in dis_AdvSIMD_scalar_shift_by_imm()
10387 IRTemp shf = newTempV128(); in dis_AdvSIMD_shift_by_immediate() local
[all …]

12