aboutsummaryrefslogtreecommitdiff
path: root/gcc/builtins.c
diff options
context:
space:
mode:
authorWilco Dijkstra <wdijkstr@arm.com>2019-03-05 15:04:01 +0000
committerWilco Dijkstra <wilco@gcc.gnu.org>2019-03-05 15:04:01 +0000
commitd7c50d679ffafaf5e7ba105cea765a307f60e2f3 (patch)
tree253d37b987d7417d008a27abf6398beaa5323df8 /gcc/builtins.c
parentdeeec83de4379e253af4f41eaaf8f45d4db17302 (diff)
downloadgcc-d7c50d679ffafaf5e7ba105cea765a307f60e2f3.zip
gcc-d7c50d679ffafaf5e7ba105cea765a307f60e2f3.tar.gz
gcc-d7c50d679ffafaf5e7ba105cea765a307f60e2f3.tar.bz2
[ARM] Fix PR89222
The GCC optimizer can generate symbols with non-zero offset from simple if-statements. Bit zero is used for the Arm/Thumb state bit, so relocations with offsets fail if it changes bit zero and the relocation forces bit zero to true. The fix is to disable offsets on function pointer symbols. gcc/ PR target/89222 * config/arm/arm.md (movsi): Use targetm.cannot_force_const_mem to decide when to split off a non-zero offset from a symbol. * config/arm/arm.c (arm_cannot_force_const_mem): Disallow offsets in function symbols. testsuite/ PR target/89222 * gcc.target/arm/pr89222.c: Add new test. From-SVN: r269390
Diffstat (limited to 'gcc/builtins.c')
0 files changed, 0 insertions, 0 deletions