forked from pnggroup/libpng
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update the support for target-specific code
The change removes the need for build configuration of target specific code such as SIMD enhancements. The extensible framework is based on checks in the new file named pngtarget.h and allows per target description of requirements and capabilities using macros with the prefix PNG_TARGET_. These macros are interpreted by the core libpng code in a target independent way. The PNG_TARGET_ prefixed macros describe the target specific implementation and document how to include it. The actual inclusion of the code is done, at present, by a single target independent core file named pngsimd.c. This approach ensures that no special configuration in the build system is required on any system. It is not required on a system which is compiling for the build host where we can reasonably assume that the compiler is correctly set up. Neither is it required for cross builds so long as the toolchain is correctly set up. In this case the toolchain means the cross build system and any ancilliary programs it requires. More details of the implementation are included in the source files named pngtarget.h and pngsimd.c. These files document in C comments how additional target specific code might be added. The changes consist primarily of movement of target specific code from the core libpng source files to the existing target specific subdirectories such as the ones named intel and arm. This isolates the code into the corresponding subdirectory and eliminates the requirement for changes across the libpng structure. As part of this the ARM processor NEON instruction set specific palette to RGB code has been generalised to allow implementation in other architectures. The resultant updated version of the original (ARM Ltd) implementation has been moved to the subdirectory named arm. In addition some selected changes have been included to allow testing with higher warning levels than the typical compiler defaults. Reviewed-by: Cosmin Truta <ctruta@gmail.com> Signed-off-by: John Bowler <jbowler@acm.org> Signed-off-by: Cosmin Truta <ctruta@gmail.com>
- Loading branch information
Showing
31 changed files
with
857 additions
and
1,241 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.