Home
last modified time | relevance | path

Searched refs:rem (Results 1 – 25 of 33) sorted by relevance

12

/libcore/luni/src/main/java/java/math/
DDivision.java52 long rem = 0; in divideArrayByInt() local
56 long temp = (rem << 32) | (dividend[i] & 0xffffffffL); in divideArrayByInt()
60 rem = (temp % bLong); in divideArrayByInt()
69 rem = aPos % bPos; in divideArrayByInt()
71 rem = (rem << 1) + (temp & 1); in divideArrayByInt()
74 if (quot <= rem) { in divideArrayByInt()
75 rem -= quot; in divideArrayByInt()
77 if (quot - rem <= bLong) { in divideArrayByInt()
78 rem += bLong - quot; in divideArrayByInt()
81 rem += (bLong << 1) - quot; in divideArrayByInt()
[all …]
DNativeBN.java109 public static native void BN_div(long dv, long rem, long m, long d); in BN_div() argument
123 long add, long rem); in BN_generate_prime_ex() argument
DConversion.java396 long rem; in divideLongByBillion() local
401 rem = (a % bLong); in divideLongByBillion()
410 rem = aPos % bPos; in divideLongByBillion()
412 rem = (rem << 1) + (a & 1); in divideLongByBillion()
414 return ((rem << 32) | (quot & 0xFFFFFFFFL)); in divideLongByBillion()
DBigInt.java299 long quot, rem; in division() local
308 rem = remainder.bignum; in division()
310 rem = 0; in division()
312 NativeBN.BN_div(quot, rem, dividend.bignum, divisor.bignum); in division()
/libcore/ojluni/src/main/java/sun/misc/
DBASE64Decoder.java106 protected void decodeAtom(PushbackInputStream inStream, OutputStream outStream, int rem) in decodeAtom() argument
112 if (rem < 2) { in decodeAtom()
123 i = readFully(inStream, decode_buffer, 1, rem-1); in decodeAtom()
128 if (rem > 3 && decode_buffer[3] == '=') { in decodeAtom()
129 rem = 3; in decodeAtom()
131 if (rem > 2 && decode_buffer[2] == '=') { in decodeAtom()
132 rem = 2; in decodeAtom()
134 switch (rem) { in decodeAtom()
147 switch (rem) { in decodeAtom()
/libcore/ojluni/src/main/java/sun/nio/ch/
DIOUtil.java57 int rem = (pos <= lim ? lim - pos : 0); in write() local
58 ByteBuffer bb = Util.getTemporaryDirectBuffer(rem); in write()
83 int rem = (pos <= lim ? lim - pos : 0); in writeFromNativeBuffer() local
86 if (rem == 0) in writeFromNativeBuffer()
91 rem, position); in writeFromNativeBuffer()
93 written = nd.write(fd, ((DirectBuffer)bb).address() + pos, rem); in writeFromNativeBuffer()
124 int rem = (pos <= lim ? lim - pos : 0); in write() local
125 if (rem > 0) { in write()
126 vec.setBuffer(iov_len, buf, pos, rem); in write()
130 ByteBuffer shadow = Util.getTemporaryDirectBuffer(rem); in write()
[all …]
DChannelInputStream.java117 long rem = Math.max(0, sbc.size() - sbc.position()); in available() local
118 return (rem > Integer.MAX_VALUE) ? Integer.MAX_VALUE : (int)rem; in available()
DIOVecWrapper.java110 void setBuffer(int i, ByteBuffer buf, int pos, int rem) { in setBuffer() argument
113 this.remaining[i] = rem; in setBuffer()
DDatagramChannelImpl.java416 int rem = (pos <= lim ? lim - pos : 0); in receive() local
417 if (dst instanceof DirectBuffer && rem > 0) in receive()
418 return receiveIntoNativeBuffer(fd, dst, rem, pos); in receive()
423 int newSize = Math.max(rem, 1); in receive()
431 if (n > 0 && rem > 0) in receive()
440 int rem, int pos) in receiveIntoNativeBuffer() argument
443 int n = receive0(fd, ((DirectBuffer)bb).address() + pos, rem, in receiveIntoNativeBuffer()
521 int rem = (pos <= lim ? lim - pos : 0); in send() local
523 ByteBuffer bb = Util.getTemporaryDirectBuffer(rem); in send()
548 int rem = (pos <= lim ? lim - pos : 0); in sendFromNativeBuffer() local
[all …]
/libcore/ojluni/src/main/java/java/lang/
DProcess.java190 long rem = unit.toNanos(timeout); in waitFor() local
197 if (rem > 0) in waitFor()
199 Math.min(TimeUnit.NANOSECONDS.toMillis(rem) + 1, 100)); in waitFor()
201 rem = unit.toNanos(timeout) - (System.nanoTime() - startTime); in waitFor()
202 } while (rem > 0); in waitFor()
/libcore/ojluni/src/main/java/java/nio/
DByteBufferAsIntBuffer.java61 int rem = (pos <= lim ? lim - pos : 0); in slice() local
64 return new ByteBufferAsIntBuffer(bb, -1, 0, rem, rem, off, order); in slice()
137 int rem = (pos <= lim ? lim - pos : 0); in compact() local
139 System.arraycopy(bb.array(), ix(pos), bb.array(), ix(0), rem << 2); in compact()
141 Memory.memmove(this, ix(0), this, ix(pos), rem << 2); in compact()
143 position(rem); in compact()
DByteBufferAsShortBuffer.java61 int rem = (pos <= lim ? lim - pos : 0); in slice() local
64 return new ByteBufferAsShortBuffer(bb, -1, 0, rem, rem, off, order); in slice()
136 int rem = (pos <= lim ? lim - pos : 0); in compact() local
138 System.arraycopy(bb.array(), ix(pos), bb.array(), ix(0), rem << 1); in compact()
140 Memory.memmove(this, ix(0), this, ix(pos), rem << 1); in compact()
142 position(rem); in compact()
DByteBufferAsFloatBuffer.java61 int rem = (pos <= lim ? lim - pos : 0); in slice() local
64 return new ByteBufferAsFloatBuffer(bb, -1, 0, rem, rem, off, order); in slice()
137 int rem = (pos <= lim ? lim - pos : 0); in compact() local
139 System.arraycopy(bb.array(), ix(pos), bb.array(), ix(0), rem << 2); in compact()
141 Memory.memmove(this, ix(0), this, ix(pos), rem << 2); in compact()
143 position(rem); in compact()
DByteBufferAsLongBuffer.java61 int rem = (pos <= lim ? lim - pos : 0); in slice() local
64 return new ByteBufferAsLongBuffer(bb, -1, 0, rem, rem, off, order); in slice()
137 int rem = (pos <= lim ? lim - pos : 0); in compact() local
139 System.arraycopy(bb.array(), ix(pos), bb.array(), ix(0), rem << 3); in compact()
141 Memory.memmove(this, ix(0), this, ix(pos), rem << 3); in compact()
143 position(rem); in compact()
DByteBufferAsDoubleBuffer.java62 int rem = (pos <= lim ? lim - pos : 0); in slice() local
65 return new ByteBufferAsDoubleBuffer(bb, -1, 0, rem, rem, off, order); in slice()
138 int rem = (pos <= lim ? lim - pos : 0); in compact() local
140 System.arraycopy(bb.array(), ix(pos), bb.array(), ix(0), rem << 3); in compact()
142 Memory.memmove(this, ix(0), this, ix(pos), rem << 3); in compact()
144 position(rem); in compact()
DByteBufferAsCharBuffer.java61 int rem = (pos <= lim ? lim - pos : 0); in slice() local
64 return new ByteBufferAsCharBuffer(bb, -1, 0, rem, rem, off, order); in slice()
141 int rem = (pos <= lim ? lim - pos : 0); in compact() local
143 System.arraycopy(bb.array(), ix(pos), bb.array(), ix(0), rem << 1); in compact()
145 Memory.memmove(this, ix(0), this, ix(pos), rem << 1); in compact()
147 position(rem); in compact()
DDirectByteBuffer.java164 int rem = (pos <= lim ? lim - pos : 0); in slice() local
167 return new DirectByteBuffer(memoryRef, -1, 0, rem, rem, off, isReadOnly); in slice()
237 int rem = (pos <= lim ? lim - pos : 0); in get() local
238 if (length > rem) in get()
296 int rem = (pos <= lim ? lim - pos : 0); in put() local
297 if (length > rem) in put()
316 int rem = (pos <= lim ? lim - pos : 0); in compact() local
318 position(rem); in compact()
440 int rem = (off <= lim ? lim - off : 0); in asCharBuffer() local
441 int size = rem >> 1; in asCharBuffer()
[all …]
/libcore/ojluni/src/main/java/java/util/zip/
DAdler32.java108 int rem = limit - pos; in update() local
109 if (rem <= 0) in update()
112 adler = updateByteBuffer(adler, ((DirectBuffer)buffer).address(), pos, rem); in update()
114 adler = updateBytes(adler, buffer.array(), pos + buffer.arrayOffset(), rem); in update()
116 byte[] b = new byte[rem]; in update()
DCRC32.java105 int rem = limit - pos; in update() local
106 if (rem <= 0) in update()
109 crc = updateByteBuffer(crc, ((DirectBuffer)buffer).address(), pos, rem); in update()
111 crc = updateBytes(crc, buffer.array(), pos + buffer.arrayOffset(), rem); in update()
113 byte[] b = new byte[rem]; in update()
DZipFile.java775 protected long rem; // number of remaining bytes within entry field in ZipFile.ZipFileInputStream
780 rem = getEntryCSize(jzentry); in ZipFileInputStream()
795 long rem = this.rem; in read() local
797 if (rem == 0) { in read()
803 if (len > rem) { in read()
804 len = (int) rem; in read()
814 this.rem = (rem - len); in read()
817 if (rem == 0) { in read()
833 if (n > rem) in skip()
834 n = rem; in skip()
[all …]
/libcore/ojluni/src/main/java/sun/nio/fs/
DLinuxUserDefinedFileAttributeView.java163 int rem = (pos <= lim ? lim - pos : 0); in read() local
172 nb = NativeBuffers.getNativeBuffer(rem); in read()
179 int n = fgetxattr(fd, nameAsBytes(file,name), address, rem); in read()
182 if (rem == 0) { in read()
221 int rem = (pos <= lim ? lim - pos : 0); in write() local
230 nb = NativeBuffers.getNativeBuffer(rem); in write()
238 for (int i = 0; i < rem; i++) { in write()
243 byte[] tmp = new byte[rem]; in write()
249 for (int i = 0; i < rem; i++) { in write()
258 fsetxattr(fd, nameAsBytes(file,name), address, rem); in write()
[all …]
/libcore/ojluni/src/main/java/sun/nio/cs/
DStreamDecoder.java289 int rem = (pos <= lim ? lim - pos : 0); in readBytes() local
290 assert rem > 0; in readBytes() local
291 int n = in.read(bb.array(), bb.arrayOffset() + pos, rem); in readBytes()
296 assert (n <= rem) : "n = " + n + ", rem = " + rem; in readBytes() local
305 int rem = bb.remaining(); in readBytes() local
306 assert (rem != 0) : rem; in readBytes()
307 return rem; in readBytes()
DStreamEncoder.java214 int rem = (pos <= lim ? lim - pos : 0); in writeBytes() local
216 if (rem > 0) { in writeBytes()
218 if (ch.write(bb) != rem) in writeBytes()
219 assert false : rem; in writeBytes()
221 out.write(bb.array(), bb.arrayOffset() + pos, rem); in writeBytes() local
/libcore/ojluni/annotations/hiddenapi/sun/misc/
DBASE64Decoder.java45 java.io.PushbackInputStream inStream, java.io.OutputStream outStream, int rem) in decodeAtom() argument
/libcore/luni/src/main/native/
Djava_math_NativeBN.cpp475 static void NativeBN_BN_div(JNIEnv* env, jclass, jlong dv, jlong rem, jlong m, jlong d) { in NativeBN_BN_div() argument
476 if (!fourValidHandles(env, (rem ? rem : dv), (dv ? dv : rem), m, d)) return; in NativeBN_BN_div()
478 if (!BN_div(toBigNum(dv), toBigNum(rem), toBigNum(m), toBigNum(d), ctx.get())) { in NativeBN_BN_div()
508 jboolean safe, jlong add, jlong rem) { in NativeBN_BN_generate_prime_ex() argument
510 if (!BN_generate_prime_ex(toBigNum(ret), bits, safe, toBigNum(add), toBigNum(rem), in NativeBN_BN_generate_prime_ex()

12