Bug: http://b/116873221
Bug: http://b/124451159
This is to get them building with O0 (needed for coverage builds). At
O0, without the always_inline, the compiler is not able to reconcile the
constraints in the inline assembly.
In file included from system/core/libpixelflinger/trap.cpp:27:
In file included from system/core/libpixelflinger/trap.h:22:
In file included from
system/core/libpixelflinger/include/private/pixelflinger/ggl_context.h:27:
system/core/libpixelflinger/include/private/pixelflinger/ggl_fixed.h:113:9:
error: invalid operand for inline asm constraint 'I'
asm("smull %[lo], %[hi], %[x], %[y] \n"
^
system/core/libpixelflinger/include/private/pixelflinger/ggl_fixed.h:136:9:
error: invalid operand for inline asm constraint 'I'
asm("smull %[lo], %[hi], %[x], %[y] \n"
^
2 errors generated.
Test: m NATIVE_COVERAGE=true COVERAGE_PATHS=system/core/libpixelflinger
Test: m
Change-Id: Ia4516b19b957687b5fa25d2d100679abcec29366
This patch adds support to make libcutils create and use memfd where
possible, instead of ashmem.
The libcutils library is made dynamic, since apps are still sending over
ashmem FDs to processes and we are working on moving those apps away
from ashmem. The best we can do for that is make the library work, and
force apps in the long run to move away from directly using ashmem.
Due to further complications mentioned in the 'NOTE' section of the
patch, memfd is kept disabled for now, so nothing changes yet. To enable
it, set the sys.use_memfd property (check user_debug build).
Bug: 113362644
Change-Id: I491cb7841b664db5b1c26b3e07a440a14810e182
Signed-off-by: Joel Fernandes <joelaf@google.com>
system/core/libpixelflinger/codeflinger/../../../../external/dlmalloc/malloc.c:4286:61: error: arithmetic on a null pointer treated as a cast from integer to pointer is a GNU extension [-Werror,-Wnull-pointer-arithmetic]
if (!is_inuse(p) && (char*)p + psize >= base + size - TOP_FOOT_SIZE) {
^~~~~~~~~~~~~
system/core/libpixelflinger/codeflinger/../../../../external/dlmalloc/malloc.c:2731:17: note: expanded from macro 'TOP_FOOT_SIZE'
(align_offset(chunk2mem(0))+pad_request(sizeof(struct malloc_segment))+MIN_CHUNK_SIZE)
~~~~~~~~~~~~~^~~~~~~~~~~~~
system/core/libpixelflinger/codeflinger/../../../../external/dlmalloc/malloc.c:2218:55: note: expanded from macro 'chunk2mem'
#define chunk2mem(p) ((void*)((char*)(p) + TWO_SIZE_T_SIZES))
^
system/core/libpixelflinger/codeflinger/../../../../external/dlmalloc/malloc.c:1622:14: note: expanded from macro 'align_offset'
((((size_t)(A) & CHUNK_ALIGN_MASK) == 0)? 0 :\
Test: m checkbuild
Bug: 72331524
Change-Id: Iefc3b4ae6b36ba9f6cb908c03301cbe429ade320
Add FALLTHROUGH_INTENDED for clang compiler.
Bug: 112564944
Test: build with global -Wimplicit-fallthrough.
Change-Id: I40f8bbf94e207c9dd90921e9b762ba51abab5777
Instead, use x15 which is one of the available temporary registers.
Bug: 112907825
Test: test-pixelflinger-arm64-t32cb16blend
Change-Id: Icfcaae1d8163880eddc2862af92e5636a03d8b52
Point to log/log.h where necessary, define LOG_TAG where necessary.
Accept that private/android_logger.h is suitable replacement for
log/logger.h and android/log.h.
Correct liblog/README
Effectively a cleanup and controlled select revert of
'system/core: drop or replace log/logger.h' and
'system/core: Replace log/log.h with android/log.h'.
Test: compile
Bug: 30465923
Change-Id: Ic2ad157bad6f5efe2c6af293a73bb753300b17a2
Should use android/log.h instead of cutils/log.h as a good example
to all others. Adjust header order to comply with Android Coding
standards.
Test: Compile
Bug: 26552300
Bug: 31289077
Change-Id: I2c9cbbbd64d8dccf2d44356361d9742e4a9b9031
Use correct memory ordering.
Start the reference count at zero instead of one, thus giving us a
chance to actually deallocate something.
Remove remaining (unused) inclusions of cutils/atomic.h from
libpixelflinger.
Bug: 30838047
Change-Id: I3c6fd4a4861b3635cf398ca2aa3e915118100b10
The feature is not implemented anymore (and has been for a very long time).
Moreover, this will allow us to cleanup hardware/ from any QEMU-specific
items.
BUG=25875346
Change-Id: I71488f4128c737dedf2b28433499fa6ffd29dcb5
GGLAssembler inherits a reset method from two parent classes, but it
provides a separate reset method with a different signature, thus hiding
the inherited reset methods.
The fix is to explicitly hide the inherited reset methods as private.
Bug: 27346663
Change-Id: Ic64b00acb6d77fb791cfdeade9ef7e20148817c1
* The literals are signed negative int and got warnings about
.... cannot be narrowed to type uint64_t [-Wc++11-narrowing]
Change-Id: I88c2fc328dfe5c7e2f9ade32bcba273e4a74a84c
* The literals are signed int type and got warnings about
.... cannot be narrowed to type int16_t [-Wc++11-narrowing]
Change-Id: I156d8e456c70840953aebb24739f94256248b810
This reverts commit ab5265ebe6.
This broke the mips64 build (which, stupidly, I hadn't tested):
system/core/libpixelflinger/codeflinger/MIPS64Assembler.h:24:35: fatal error: tinyutils/KeyedVector.h: No such file or directory
#include "tinyutils/KeyedVector.h"
Change-Id: I4fa1c04e196592fd1ef893a83c75261a55d32290
Added ARMtoMips64Assembler class that translates ARM instructions to MIPS64r6
instructions.
Added MIPS64r6 assembly implementations for col32cb16_blend and t32cb16_blend
functions.
Added MIPS32r2 assembly implementation for col32cb16_blend function.
Added tests for MIPS64r6 (assembler, disassembler and assembly implementation
functions).
Added MIPS32 tests for assembly implementation functions.
Minor bug fixes for MIPS32r2 branch.
Change-Id: I69e49622117be5b8167628e9702db6aafb1849d7
Use external/safe-iop to check for overflows on arithmetic
operations.
Also remove an unnecessary copy of Vector/SharedBuffer from
codeflinger and use the copy from libutils instead.
Note that some of the unit tests are somewhat useless due to
test-runner limitations : gtest's ability to filter on abort message
doesn't work when combined with messages formatted by android's logging
system.
bug: 22953624
Change-Id: I46b1ae8ca1f3a010be13aca36a091e76a97a7b70
* Explicitly specify default .align 0.
* Use standard ldmfdlo instruction.
* Before and after gas outputs are identical,
with align 0 sections.
* Objdump showed .text/.data/.bss section alignment
attributes are 2^0 from gas and 2^2 from llvm
assembler. These .S files might be working when
compiled by gas, but llvm assembler's output should
be more correct or conservative.
Change-Id: I4e578dbc8155c0d06d1bbc1c33ec4cc851a18479
pixelflinger should not be used for new projects and should be moved out
of system/core at some point. As the first step, move all its headers
under system/core/libpixelflinger/include and update its Android.mk
files so they're not referring to the absolute system/core path anymore.
Change-Id: Idead273ab2c0450409d770f5402c4dba916192a9
Signed-off-by: Greg Hackmann <ghackmann@google.com>
libagl is now the only remaining pixelflinger client in the Android
tree, and it links with pixelflinger dynamically.
Change-Id: Ic5f8af57a88ceaeb25bf890cd6be8bc5a893fc10
Signed-off-by: Greg Hackmann <ghackmann@google.com>
pixelflinger should not be used for new projects and should be moved out
of system/core at some point. As the first step, move all its headers
under system/core/libpixelflinger/include and update its Android.mk
files so they're not referring to the absolute system/core path anymore.
Change-Id: I7acc3ef5b2e21d8ba6fe939ea8d3ec4c41959591
Signed-off-by: Greg Hackmann <ghackmann@google.com>
Intel accidentally made this dead code in 2010 with commit
2bef93cc20, and no one's ever noticed.
Since no one noticing for so long implies that it doesn't matter,
let's just kill the supposedly optimized code.
Change-Id: Id5b37056cb8884c20bfe2db362e19b46f02e337d