jumper, turn off a few fancy features

This doesn't change any of the generated .S files, but it does cut a few
misc. sections from the intermediate .o files.  It's nice to get those
sections out of the way, and one day we might be able to find ways to
cut everything but .text... that'd allow us to switch the supicious
section sniffing code from a blacklist (no .const, no .literal, etc.) to
a more foolproof whitelist (.text or bust).

The remaining sections are only in ELF objects (aarch64.o, vfp4.o):
   .comment         (notes the version of Clang/LLVM that compiled it)
   .note.GNU-stack  (we manually add this back in build_stages.py)
and vfp4.o has two more sections that I don't understand yet:
   .ARM.exidx       (I'd have thought -fno-unwind-tables would cut this)
   .ARM.attributes

While doing this, I've tried to make the ARM flags a bit more compact.

Change-Id: I30ef6acb2a917ec938c5358c3f970fe04b6d7afa
Reviewed-on: https://skia-review.googlesource.com/11485
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
This commit is contained in:
Mike Klein 2017-04-06 13:44:03 -04:00 committed by Skia Commit-Bot
parent 42ce38f866
commit 3b80558bd2
2 changed files with 5 additions and 5 deletions

View File

@ -12,7 +12,7 @@
// and SkJumper_stages.cpp (compiled into Skia _and_ offline into SkJumper_generated.h).
// Keep it simple!
#if defined(JUMPER) && defined(__ANDROID__)
#if defined(JUMPER) && (defined(__aarch64__) || defined(__arm__))
// To reduce SkJumper's dependency on the Android NDK,
// we provide what we need from <string.h>, <stdint.h>, and <stddef.h> ourselves.
#define memcpy __builtin_memcpy

View File

@ -16,7 +16,8 @@ clang = ['ccache', clang, '-x', 'c++']
cflags = ['-std=c++11', '-Os', '-DJUMPER',
'-fomit-frame-pointer', '-ffp-contract=fast' ]
'-fomit-frame-pointer', '-ffp-contract=fast',
'-fno-exceptions', '-fno-rtti', '-fno-unwind-tables']
win = ['-DWIN', '-mno-red-zone']
sse2 = ['-msse2', '-mno-sse3', '-mno-ssse3', '-mno-sse4.1']
@ -51,15 +52,14 @@ subprocess.check_call(clang + cflags + hsw + win +
['-c', 'src/jumper/SkJumper_stages.cpp'] +
['-o', 'win_hsw.o'])
aarch64 = [ '--target=aarch64-linux-android' ]
aarch64 = [ '--target=aarch64' ]
subprocess.check_call(clang + cflags + aarch64 +
['-c', 'src/jumper/SkJumper_stages.cpp'] +
['-o', 'aarch64.o'])
vfp4 = [
'--target=armv7a-linux-android',
'--target=armv7a-linux-gnueabihf',
'-mfpu=neon-vfpv4',
'-mfloat-abi=hard',
]
subprocess.check_call(clang + cflags + vfp4 +
['-c', 'src/jumper/SkJumper_stages.cpp'] +