Repository navigation
Commit bf60aac
committed
build(runtime): keep building the armeabi-v7a runtime as A32
With the NDK defaults no longer overwritten, armeabi-v7a picks up the
toolchain's -mthumb and the runtime's own code turns into Thumb-2. That
shrank the stripped v7 library by 480 KB (-140 KB gzipped, runtime code
-33%), but on a Samsung SM-G780G (API 33, optimized release, 32-bit
process) it made the JNI bridge consistently slower than the A32 build
we have shipped so far:
static.noop() 175 -> 210 ns (+19.5%)
static.add(int,int) +14.4%
instance.getInt() +10.2%
instance.echo(String) +10.9%
field.get int +12.8%
geomean, 63 rows +4-11%
Pass -DANDROID_ARM_MODE=arm so the toolchain leaves -mthumb out (clang's
armv7 default is A32) while every other NDK default still applies. V8's
prebuilt archive is unaffected and stays Thumb-2.1 parent 4595c58 commit bf60aac
2 files changed
Lines changed: 5 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
23 | | - | |
24 | | - | |
| 23 | + | |
| 24 | + | |
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
121 | 121 | | |
122 | 122 | | |
123 | 123 | | |
124 | | - | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
125 | 127 | | |
126 | 128 | | |
127 | 129 | | |
| |||
0 commit comments