Home
last modified time | relevance | path

Searched refs:alloc (Results 1 – 25 of 28) sorted by relevance

12

/aosp14/system/core/libutils/
H A DSharedBuffer_test.cpp31 EXPECT_DEATH(android::SharedBuffer::alloc(SIZE_MAX), ""); in TEST()
32 EXPECT_DEATH(android::SharedBuffer::alloc(SIZE_MAX - sizeof(android::SharedBuffer)), ""); in TEST()
39 android::SharedBuffer::alloc(SIZE_MAX - sizeof(android::SharedBuffer) - 1); in TEST()
49 android::SharedBuffer* buf = android::SharedBuffer::alloc(SIZE_MAX / 2); in TEST()
57 android::SharedBuffer* buf = android::SharedBuffer::alloc(0); in TEST()
64 android::SharedBuffer* buf = android::SharedBuffer::alloc(10); in TEST()
66 buf = android::SharedBuffer::alloc(10); in TEST()
73 android::SharedBuffer* buf = android::SharedBuffer::alloc(10); in TEST()
84 android::SharedBuffer* buf = android::SharedBuffer::alloc(10); in TEST()
H A DSharedBuffer.cpp30 SharedBuffer* SharedBuffer::alloc(size_t size) in alloc() function in android::SharedBuffer
60 SharedBuffer* sb = alloc(mSize); in edit()
84 SharedBuffer* sb = alloc(newSize); in editResize()
104 SharedBuffer* sb = alloc(new_size); in reset()
H A DString16.cpp34 void* String16::alloc(size_t size) in alloc() function in android::String16
36 SharedBuffer* buf = SharedBuffer::alloc(size); in alloc()
52 SharedBuffer* buf = static_cast<SharedBuffer*>(alloc(sizeof(char16_t) * (u16len + 1))); in allocFromUTF8()
75 SharedBuffer* buf = static_cast<SharedBuffer*>(alloc((u16len + 1) * sizeof(char16_t))); in allocFromUTF16()
307 buf = static_cast<SharedBuffer*>(alloc((size() + 1) * sizeof(char16_t))); in edit()
325 buf = static_cast<SharedBuffer*>(alloc(newSize)); in editResize()
H A DString8.cpp48 SharedBuffer* buf = SharedBuffer::alloc(1); in getEmptyString()
66 SharedBuffer* buf = SharedBuffer::alloc(len+1); in allocFromUTF8()
90 SharedBuffer* buf = SharedBuffer::alloc(resultStrLen); in allocFromUTF16()
112 SharedBuffer* buf = SharedBuffer::alloc(resultStrLen); in allocFromUTF32()
H A DVectorImpl.cpp93 editable = SharedBuffer::alloc(sb->size()); in editArrayImpl()
342 SharedBuffer* sb = SharedBuffer::alloc(new_allocation_size); in setCapacity()
421 SharedBuffer* sb = SharedBuffer::alloc(new_alloc_size); in _grow()
488 SharedBuffer* sb = SharedBuffer::alloc(new_capacity * mItemSize); in _shrink()
H A DSharedBuffer.h44 static SharedBuffer* alloc(size_t size);
/aosp14/frameworks/base/rs/java/android/renderscript/
H A DRenderScript.java481 rsnAllocationCopyToBitmap(mContext, alloc, bmp); in nAllocationCopyToBitmap()
487 rsnAllocationSyncAll(mContext, alloc, src); in nAllocationSyncAll()
511 return rsnAllocationGetSurface(mContext, alloc); in nAllocationGetSurface()
516 rsnAllocationSetSurface(mContext, alloc, sur); in nAllocationSetSurface()
518 native void rsnAllocationIoSend(long con, long alloc); in rsnAllocationIoSend() argument
519 synchronized void nAllocationIoSend(long alloc) { in nAllocationIoSend() argument
521 rsnAllocationIoSend(mContext, alloc); in nAllocationIoSend()
524 synchronized long nAllocationIoReceive(long alloc) { in nAllocationIoReceive() argument
526 return rsnAllocationIoReceive(mContext, alloc); in nAllocationIoReceive()
532 rsnAllocationGenerateMipmaps(mContext, alloc); in nAllocationGenerateMipmaps()
[all …]
H A DMesh.java368 Allocation alloc = null; in create() local
371 alloc = Allocation.createTyped(mRS, entry.t, mUsage); in create()
373 alloc = Allocation.createSized(mRS, entry.e, entry.size, mUsage); in create()
378 vertexBuffers[ct] = alloc; in create()
379 vtx[ct] = alloc.getID(mRS); in create()
383 Allocation alloc = null; in create() local
386 alloc = Allocation.createTyped(mRS, entry.t, mUsage); in create()
388 alloc = Allocation.createSized(mRS, entry.e, entry.size, mUsage); in create()
393 long allocID = (alloc == null) ? 0 : alloc.getID(mRS); in create()
394 indexBuffers[ct] = alloc; in create()
H A DAllocationAdapter.java30 AllocationAdapter(long id, RenderScript rs, Allocation alloc, Type t) { in AllocationAdapter() argument
31 super(id, rs, alloc.mType, alloc.mUsage); in AllocationAdapter()
32 mAdaptedAllocation = alloc; in AllocationAdapter()
H A DAllocation.java2828 alloc.setBitmap(b); in createFromBitmap()
2829 return alloc; in createFromBitmap()
2933 if (alloc.getID(rs) == 0) { in createFromAllocation()
2937 Type type = alloc.getType(); in createFromAllocation()
2938 int usage = alloc.getUsage(); in createFromAllocation()
2946 outAlloc.shareBufferQueue(alloc); in createFromAllocation()
2970 void shareBufferQueue(Allocation alloc) { in shareBufferQueue() argument
2975 mGetSurfaceSurface = alloc.getSurface(); in shareBufferQueue()
3266 return alloc; in createFromBitmapResource()
3315 alloc.copyFrom(allocArray); in createFromString()
[all …]
/aosp14/frameworks/base/rs/jni/
H A Dandroid_renderscript_RenderScript.cpp1244 (RsAllocation)alloc, numAlloc); in nAllocationSetupBufferQueue()
1281 (RsAllocation)alloc, (Surface *)sur); in nAllocationSetSurface()
1390 RsAllocation *alloc = (RsAllocation *)_alloc; in nAllocationData1D() local
1429 RsAllocation *alloc = (RsAllocation *)_alloc; in nAllocationData2D() local
1474 RsAllocation *alloc = (RsAllocation *)_alloc; in nAllocationData3D() local
1517 RsAllocation *alloc = (RsAllocation *)_alloc; in nAllocationRead() local
1532 RsAllocation *alloc = (RsAllocation *)_alloc; in nAllocationRead1D() local
1570 RsAllocation *alloc = (RsAllocation *)_alloc; in nAllocationRead2D() local
1587 RsAllocation *alloc = (RsAllocation *)_alloc; in nAllocationRead3D() local
1612 (RsAllocation)alloc, dimX); in nAllocationResize1D()
[all …]
/aosp14/frameworks/base/libs/hwui/tests/unit/
H A DLinearAllocatorTests.cpp33 la.alloc<char>(64); in TEST()
53 la.alloc<char>(100); in TEST()
58 la.alloc<char>(100); in TEST()
72 auto addr = la.alloc<char>(100); in TEST()
/aosp14/frameworks/base/packages/FakeOemFeatures/src/com/android/fakeoemfeatures/
H A DFakeBackgroundService.java54 int[] alloc = new int[FakeApp.PAGE_SIZE/4];
55 mAllocs.add(alloc);
58 alloc[j] = VAL;
/aosp14/system/core/trusty/apploader/fuzz/
H A Dapp_fuzzer.cpp111 BufferAllocator alloc; in LLVMFuzzerTestOneInput() local
112 unique_fd dma_buf(alloc.Alloc(kDmabufSystemHeapName, shm_len)); in LLVMFuzzerTestOneInput()
/aosp14/frameworks/base/libs/hwui/
H A DVertexBuffer.h58 TYPE* alloc(int vertexCount) { in alloc() function
94 TYPE* dst = alloc<TYPE>(verticesToCopy); in copyInto()
/aosp14/frameworks/base/libs/hwui/utils/
H A DLinearAllocator.h60 void* alloc(size_t size) { in alloc() function
176 return (T*)(linearAllocator.alloc<void*>(num * sizeof(T)));
/aosp14/system/core/trusty/apploader/
H A Dapploader.cpp122 BufferAllocator alloc; in read_file() local
123 unique_fd dmabuf_fd(alloc.Alloc(kDmabufSystemHeapName, file_page_size)); in read_file()
/aosp14/system/core/trusty/utils/acvp/
H A Dtrusty_modulewrapper.cpp122 BufferAllocator alloc; in SendMessage() local
123 dmabuf_fd_.reset(alloc.Alloc(kDmabufSystemHeapName, shm_size_)); in SendMessage()
/aosp14/frameworks/base/libs/androidfw/include/androidfw/
H A DCursorWindow.h192 status_t alloc(size_t size, uint32_t* outOffset);
/aosp14/frameworks/base/libs/androidfw/
H A DCursorWindow.cpp321 status_t CursorWindow::alloc(size_t size, uint32_t* outOffset) { in alloc() function in android::CursorWindow
375 if (alloc(size, &offset)) { in putBlobOrString()
/aosp14/frameworks/base/libs/hwui/hwui/
H A DBitmap.cpp94 static sk_sp<Bitmap> allocateBitmap(SkBitmap* bitmap, AllocPixelRef alloc) { in allocateBitmap() argument
110 auto wrapper = alloc(size, info, rowBytes); in allocateBitmap()
/aosp14/system/core/libutils/include/utils/
H A DString16.h124 static void* alloc(size_t size);
/aosp14/system/core/debuggerd/
H A Ddebuggerd_test.cpp674 uintptr_t alloc = reinterpret_cast<uintptr_t>(malloc(16)); in TEST_F() local
675 auto it = allocs.insert(alloc).first; in TEST_F()
676 if (it != allocs.begin() && *std::prev(it) + 128 > alloc) { in TEST_F()
679 if (std::next(it) != allocs.end() && alloc + 128 > *std::next(it)) { in TEST_F()
680 *reinterpret_cast<int*>(alloc + 16) = 42; in TEST_F()
/aosp14/frameworks/base/core/jni/
H A Dandroid_util_AssetManager.cpp294 String8 alloc = Asset::getAssetAllocations(); in NativeGetAssetAllocations() local
295 if (alloc.length() <= 0) { in NativeGetAssetAllocations()
298 return env->NewStringUTF(alloc.string()); in NativeGetAssetAllocations()
/aosp14/frameworks/base/media/jni/
H A Dandroid_media_MediaCodec.cpp2684 std::shared_ptr<C2Allocator> alloc; in android_media_MediaCodec_native_queueHardwareBuffer() local
2686 C2PlatformAllocatorStore::GRALLOC, &alloc); in android_media_MediaCodec_native_queueHardwareBuffer()
2688 return alloc; in android_media_MediaCodec_native_queueHardwareBuffer()
2692 std::shared_ptr<C2GraphicAllocation> alloc; in android_media_MediaCodec_native_queueHardwareBuffer() local
2693 c2_status_t c2err = sGrallocAlloc->priorGraphicAllocation(handle, &alloc); in android_media_MediaCodec_native_queueHardwareBuffer()
2703 std::shared_ptr<C2GraphicBlock> block = _C2BlockFactory::CreateGraphicBlock(alloc); in android_media_MediaCodec_native_queueHardwareBuffer()

12