Home
last modified time | relevance | path

Searched refs:b (Results 1 – 25 of 262) sorted by relevance

1234567891011

/picolibc-3.7.0-3.6.0/test/libc-testsuite/
Dstring.c57 char b[32]; in test_string() local
62 b[16]='a'; b[17]='b'; b[18]='c'; b[19]=0; in test_string()
63 TEST(s, strcpy(b, b+16), b, "wrong return %p != %p"); in test_string()
65 TEST(s, strcpy(b+1, b+16), b+1, "wrong return %p != %p"); in test_string()
67 TEST(s, strcpy(b+2, b+16), b+2, "wrong return %p != %p"); in test_string()
69 TEST(s, strcpy(b+3, b+16), b+3, "wrong return %p != %p"); in test_string()
72 TEST(s, strcpy(b+1, b+17), b+1, "wrong return %p != %p"); in test_string()
74 TEST(s, strcpy(b+2, b+18), b+2, "wrong return %p != %p"); in test_string()
76 TEST(s, strcpy(b+3, b+19), b+3, "wrong return %p != %p"); in test_string()
79 TEST(s, memset(b, 'x', sizeof b), b, "wrong return %p != %p"); in test_string()
[all …]
Dsnprintf.c171 char b[2000]; in test_snprintf() local
175 TEST(i, snprintf(b, 0, "%.0s", "goodbye"), 0, "length returned %d != %d"); in test_snprintf()
177 strcpy(b, "xxxxxxxx"); in test_snprintf()
178 TEST(i, snprintf(b, 4, "%ld", 123456l), 6, "length returned %d != %d"); in test_snprintf()
179 TEST_S(b, "123", "incorrect output"); in test_snprintf()
180 TEST(i, b[5], 'x', "buffer overrun"); in test_snprintf()
185 TEST(i, snprintf(b, sizeof b, "%.1022f", 0x1p-1021), 1024, "%d != %d"); in test_snprintf()
186 b[1] = '0'; in test_snprintf()
189 if (b[j]<'5') b[j]+=b[j]-'0'+k, k=0; in test_snprintf()
190 else b[j]+=b[j]-'0'-10+k, k=1; in test_snprintf()
[all …]
/picolibc-3.7.0-3.6.0/newlib/libc/machine/aarch64/
Dstrchr.S85 dup vrepchr.16b, chrin
90 b.eq L(loop)
96 ld1 {vdata1.16b, vdata2.16b}, [src], #32
98 cmeq vhas_nul1.16b, vdata1.16b, #0
99 cmeq vhas_chr1.16b, vdata1.16b, vrepchr.16b
100 cmeq vhas_nul2.16b, vdata2.16b, #0
101 cmeq vhas_chr2.16b, vdata2.16b, vrepchr.16b
102 bif vhas_nul1.16b, vhas_chr1.16b, vrepmask_0.16b
103 bif vhas_nul2.16b, vhas_chr2.16b, vrepmask_0.16b
104 and vend1.16b, vhas_nul1.16b, vrepmask_c.16b
[all …]
Dstrchrnul.S80 dup vrepchr.16b, chrin
84 b.eq L(loop)
90 ld1 {vdata1.16b, vdata2.16b}, [src], #32
92 cmeq vhas_chr1.16b, vdata1.16b, vrepchr.16b
93 cmeq vhas_chr2.16b, vdata2.16b, vrepchr.16b
94 cmhs vhas_nul1.16b, vhas_chr1.16b, vdata1.16b
95 cmhs vhas_nul2.16b, vhas_chr2.16b, vdata2.16b
96 and vhas_chr1.16b, vhas_nul1.16b, vrepmask.16b
97 and vhas_chr2.16b, vhas_nul2.16b, vrepmask.16b
99 addp vend1.16b, vhas_chr1.16b, vhas_chr2.16b // 256->128
[all …]
Dstrrchr.S90 dup vrepchr.16b, chrin
96 b.eq L(aligned)
102 ld1 {vdata1.16b, vdata2.16b}, [src], #32
104 cmeq vhas_nul1.16b, vdata1.16b, #0
105 cmeq vhas_chr1.16b, vdata1.16b, vrepchr.16b
106 cmeq vhas_nul2.16b, vdata2.16b, #0
107 cmeq vhas_chr2.16b, vdata2.16b, vrepchr.16b
108 and vhas_nul1.16b, vhas_nul1.16b, vrepmask_0.16b
109 and vhas_chr1.16b, vhas_chr1.16b, vrepmask_c.16b
110 and vhas_nul2.16b, vhas_nul2.16b, vrepmask_0.16b
[all …]
Dmemchr.S63 dup vrepchr.16b, chrin
69 b.eq L(loop)
77 ld1 {vdata1.16b, vdata2.16b}, [src], #32
80 cmeq vhas_chr1.16b, vdata1.16b, vrepchr.16b
81 cmeq vhas_chr2.16b, vdata2.16b, vrepchr.16b
82 and vhas_chr1.16b, vhas_chr1.16b, vrepmask.16b
83 and vhas_chr2.16b, vhas_chr2.16b, vrepmask.16b
84 addp vend.16b, vhas_chr1.16b, vhas_chr2.16b /* 256->128 */
85 addp vend.16b, vend.16b, vend.16b /* 128->64 */
92 b.ls L(masklast)
[all …]
Dstrlen.S103 b.hi L(page_cross)
124 b.eq L(bytes16_31)
150 b.eq L(loop_entry)
170 uminp maskv.16b, datav1.16b, datav2.16b
171 uminp maskv.16b, maskv.16b, maskv.16b
172 cmeq maskv.8b, maskv.8b, 0
177 cmeq maskv.16b, datav1.16b, 0
180 cmeq maskv.16b, datav2.16b, 0
184 shrn maskv.8b, maskv.8h, 4
197 ld1 {datav1.16b, datav2.16b}, [src]
[all …]
Dmemcmp.S42 b.lo L(less16)
47 b.ne L(return2)
52 b.ls L(last_bytes)
54 b.hs L(loop_align)
63 b.ne L(return2)
65 b.ls L(last_bytes)
71 b.ne L(return2)
76 b.hi L(loop32)
107 b L(return2)
116 b L(return2)
[all …]
Dmemrchr.S53 ld1 {vdata.16b}, [src]
54 dup vrepchr.16b, chrin
55 cmeq vhas_chr.16b, vdata.16b, vrepchr.16b
57 shrn vend.8b, vhas_chr.8h, 4 /* 128->64 */
71 b.ls L(nomatch)
81 cmeq vhas_chr.16b, vdata.16b, vrepchr.16b
82 umaxp vend.16b, vhas_chr.16b, vhas_chr.16b /* 128->64 */
89 cmeq vhas_chr.16b, vdata.16b, vrepchr.16b
90 b.lo L(end_2)
91 umaxp vend.16b, vhas_chr.16b, vhas_chr.16b /* 128->64 */
[all …]
/picolibc-3.7.0-3.6.0/newlib/libm/complex/
Dcsqrtl.c52 long double a, b; in csqrtl() local
57 b = cimagl(z); in csqrtl()
61 return (cpackl((long double) 0.0L, b)); in csqrtl()
62 if (isinf(b)) in csqrtl()
63 return (cpackl((long double) INFINITY, b)); in csqrtl()
65 t = (b - b) / (b - b); /* raise invalid if b is not a NaN */ in csqrtl()
76 return (cpackl(fabsl(b - b), copysignl(a, b))); in csqrtl()
78 return (cpackl(a, copysignl(b - b, b))); in csqrtl()
86 if (fabsl(a) >= THRESH || fabsl(b) >= THRESH) { in csqrtl()
88 b *= 0.25L; in csqrtl()
[all …]
/picolibc-3.7.0-3.6.0/newlib/libc/machine/h8500/
Dshifts.c19 int __ashrhi3(int a,int b) in __ashrhi3() argument
21 return a>>b; in __ashrhi3()
24 int __ashlhi3(int a,int b) in __ashlhi3() argument
26 return a<<b; in __ashlhi3()
29 unsigned __lshlhi3(unsigned int a,int b) in __lshlhi3() argument
31 return a<<b; in __lshlhi3()
34 unsigned __lshrhi3(unsigned int a,int b) in __lshrhi3() argument
36 return a>>b; in __lshrhi3()
42 long __ashrsi3(long a, int b) in __ashrsi3() argument
44 return a>>b; in __ashrsi3()
[all …]
Dmulsi3.c26 long __mulsi3(u a, u b) in __mulsi3() argument
34 b.s.msw == 0) in __mulsi3()
36 return (long)a.s.lsw * b.s.lsw; in __mulsi3()
45 if (b.v < 0) in __mulsi3()
48 b.v = - b.v; in __mulsi3()
51 pp1 = (long)a.s.lsw * b.s.lsw ; in __mulsi3()
52 pp2 = (long)a.s.lsw * b.s.msw + (long)a.s.msw * b.s.lsw; in __mulsi3()
62 long __mulpsi3(long a, long b) in __mulpsi3() argument
64 return a*b; in __mulpsi3()
69 __mulhi3(short a, short b) in __mulhi3() argument
[all …]
/picolibc-3.7.0-3.6.0/newlib/libm/math/
Dsf_jn.c27 float a, b, temp, di; in jnf() local
50 b = zero; in jnf()
54 b = j1f(x); in jnf()
56 temp = b; in jnf()
57 b = b * ((float)(i + i) / x) - a; /* avoid underflow */ in jnf()
66 b = zero; in jnf()
69 b = temp; in jnf()
72 b *= temp; /* b = (x/2)^n */ in jnf()
74 b = b / a; in jnf()
126 b = one; in jnf()
[all …]
Ds_jn.c54 __float64 a, b, temp, di; in jn64() local
81 b = zero; in jn64()
113 b = invsqrtpi * temp / sqrt64(x); in jn64()
116 b = j164(x); in jn64()
118 temp = b; in jn64()
119 b = b * ((__float64)(i + i) / x) - a; /* avoid underflow */ in jn64()
129 b = zero; in jn64()
132 b = temp; in jn64()
135 b *= temp; /* b = (x/2)^n */ in jn64()
137 b = b / a; in jn64()
[all …]
Ds_hypot.c53 __float64 a = x, b = y, t1, t2, y1, y2, w; in hypot64() local
62 b = x; in hypot64()
68 b = y; in hypot64()
71 SET_HIGH_WORD(b, hb); /* b <- |b| */ in hypot64()
73 return a + b; in hypot64()
79 w = a + b; /* for sNaN */ in hypot64()
81 if (((ha & 0xfffff) | low) == 0 && !issignaling(b)) in hypot64()
83 GET_LOW_WORD(low, b); in hypot64()
85 w = b; in hypot64()
93 SET_HIGH_WORD(b, hb); in hypot64()
[all …]
Dsf_hypot.c21 float a = x, b = y, t1, t2, y1, y2, w; in hypotf() local
34 SET_FLOAT_WORD(b, hb); /* b <- |b| */ in hypotf()
36 return a + b; in hypotf()
41 w = a + b; /* for sNaN */ in hypotf()
42 if (FLT_UWORD_IS_INFINITE(ha) && !issignaling(b)) in hypotf()
45 w = b; in hypotf()
53 SET_FLOAT_WORD(b, hb); in hypotf()
60 b *= t1; in hypotf()
68 SET_FLOAT_WORD(b, hb); in hypotf()
72 w = a - b; in hypotf()
[all …]
/picolibc-3.7.0-3.6.0/test/
Drounding-mode-sub.c41 div(double a, double b) in div() argument
43 return a/b; in div()
47 mul(double a, double b) in mul() argument
49 return a * b; in mul()
53 sub(double a, double b) in sub() argument
55 return a - b; in sub()
59 div_f(float a, float b) { in div_f() argument
60 return a/b; in div_f()
64 mul_f(float a, float b) { in mul_f() argument
65 return a * b; in mul_f()
[all …]
/picolibc-3.7.0-3.6.0/newlib/libc/stdlib/
Dgdtoa-gethex.c71 rshift (_Bigint *b, in rshift() argument
77 x = x1 = b->_x; in rshift()
79 if (n < b->_wds) { in rshift()
80 xe = x + b->_wds; in rshift()
96 if ((b->_wds = x1 - b->_x) == 0) in rshift()
97 b->_x[0] = 0; in rshift()
102 _Bigint *b) in increment() argument
110 if (!b) in increment()
113 x = b->_x; in increment()
114 xe = x + b->_wds; in increment()
[all …]
Dmprec.c166 _Bigint * b, in multadd() argument
177 if (!b) in multadd()
180 wds = b->_wds; in multadd()
181 x = b->_x; in multadd()
200 if (wds >= b->_maxwds) in multadd()
202 b1 = Balloc (b->_k + 1); in multadd()
204 Bfree(b); in multadd()
207 Bcopy (b1, b); in multadd()
208 Bfree (b); in multadd()
209 b = b1; in multadd()
[all …]
/picolibc-3.7.0-3.6.0/newlib/libc/tinystdio/
Dstdio_private.h200 #define _u128_plus_64(a,b) ((a) + (b)) argument
201 #define _u128_plus(a,b) ((a) + (b)) argument
202 #define _u128_minus(a,b) ((a) - (b)) argument
203 #define _u128_minus_64(a,b) ((a) - (b)) argument
205 #define _u128_times_base(a,b) ((a) * (b)) argument
209 #define _u128_lshift(a,b) ((_u128) (a) << (b)) argument
210 #define _u128_lshift_64(a,b) ((_u128) (a) << (b)) argument
211 #define _u128_rshift(a,b) ((a) >> (b)) argument
212 #define _i128_rshift(a,b) ((_i128) (a) >> (b)) argument
213 #define _u128_or_64(a,b) ((a) | (_u128) (b)) argument
[all …]
/picolibc-3.7.0-3.6.0/newlib/libm/ld/ld128/
De_hypotl.c50 long double a,b,t1,t2,yy1,y2,w; in hypotl() local
57 if(hb > ha) {a=y;b=x;j=ha; ha=hb;hb=j;} else {a=x;b=y;} in hypotl()
59 SET_LDOUBLE_MSW64(b,hb); /* b <- |b| */ in hypotl()
60 if((ha-hb)>0x78000000000000LL) {return a+b;} /* x/y > 2**120 */ in hypotl()
65 w = a+b; /* for sNaN */ in hypotl()
67 if(((ha&0xffffffffffffLL)|low)==0 && !issignalingl_inline(b)) in hypotl()
69 GET_LDOUBLE_LSW64(low,b); in hypotl()
71 w = b; in hypotl()
78 SET_LDOUBLE_MSW64(b,hb); in hypotl()
83 GET_LDOUBLE_LSW64(low,b); in hypotl()
[all …]
/picolibc-3.7.0-3.6.0/newlib/libm/ld/ld80/
De_hypotl.c50 long double a,b,t1,t2,yy1,y2,w; in hypotl() local
57 if(eb > ea) {a=y;b=x;j=ea; ea=eb;eb=j;} else {a=x;b=y;} in hypotl()
59 SET_LDOUBLE_EXP(b,eb); /* b <- |b| */ in hypotl()
60 if((ea-eb)>0x46) {return a+b;} /* x/y > 2**70 */ in hypotl()
65 w = a+b; /* for sNaN */ in hypotl()
68 if(((high&0x7fffffff)|low)==0 && !issignalingl_inline(b)) in hypotl()
70 GET_LDOUBLE_WORDS(es,high,low,b); in hypotl()
72 w = b; in hypotl()
78 SET_LDOUBLE_EXP(b,eb); in hypotl()
83 GET_LDOUBLE_WORDS(es,high,low,b); in hypotl()
[all …]
/picolibc-3.7.0-3.6.0/newlib/libc/machine/hppa/
Dstrcpy.S53 b case_analysis
65 b,n nullfound
69 b,n nullfound
73 b,n nullfound
84 b,n nullfound
88 b loop
122 b neg_aligned_copy /* 00 01 */
124 b neg_aligned_copy /* 00 10 */
126 b neg_aligned_copy /* 00 11 */
128 b pos_aligned_copy0 /* 01 00 */
[all …]
Dstrncpy.S54 b skip_mask /* don't reload tmp1*/
62 b,n null1
64 stbys,b,m tmp1,4(0,d_addr) /* store word (delay slot)*/
76 b,n null2
96 b skip_mask2
105 b,n null3
106 stbys,b,m tmp3,4(0,d_addr) /* store ! */
111 b,n null4
114 stbys,b,m tmp3,4(0,d_addr) /* store !*/
132 b,n null4
[all …]
/picolibc-3.7.0-3.6.0/newlib/libm/test/
Dtest.c149 __ieee_double_shape_type *b) in bigger() argument
152 if (a->parts.msw > b->parts.msw) in bigger()
157 else if (a->parts.msw == b->parts.msw) in bigger()
159 if (a->parts.lsw > b->parts.lsw) in bigger()
169 __ieee_float_shape_type *b) in fbigger() argument
172 if (a->p1 > b->p1) in fbigger()
186 __ieee_double_shape_type a,b; in mag_of_error() local
194 b.value = shouldbe; in mag_of_error()
196 if (a.parts.msw == b.parts.msw in mag_of_error()
197 && a.parts.lsw== b.parts.lsw) return 64; in mag_of_error()
[all …]

1234567891011