[ARM] Enable Purecode for ARMv8-M Baseline
commit7561225230ccd73fb07fa5773795a2bc0d48af7c
authorthopre01 <thopre01@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 4 May 2017 10:26:25 +0000 (4 10:26 +0000)
committerthopre01 <thopre01@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 4 May 2017 10:26:25 +0000 (4 10:26 +0000)
tree9495abb72c031085227a8e4025311a32dce1ec5b
parent1e5fee4e59eb8fa30ebce495ba7562846d44345a
[ARM] Enable Purecode for ARMv8-M Baseline

This patch adds support for purecode to ARMv8-M Baseline, in addition to
the existing support for ARMv7-M and ARMv8-M Mainline.

2017-05-04  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
            Andre Simoes Dias Vieira  <andre.simoesdiasvieira@arm.com>

    gcc/
    * config/arm/arm.md (movsi): Change TARGET_32BIT to TARGET_HAVE_MOVT.
    (movt splitter): Likewise.
    * config/arm/arm.c (arm_option_check_internal): Change arm_arch_thumb2
    to TARGET_HAVE_MOVT, and merge with -mslow-flash-data check.
    (const_ok_for_arm): Change else to else if (TARGET_THUMB2) and add else
    block for Thumb-1 with MOVT.
    (thumb2_legitimate_address_p): Move code block ...
    (can_avoid_literal_pool_for_label_p): ... into this new function.
    (thumb1_legitimate_address_p): Add check for TARGET_HAVE_MOVT and
    literal pool.
    (thumb_legitimate_constant_p): Add conditional on TARGET_HAVE_MOVT
    * doc/invoke.texi (-mpure-code): Change "ARMv7-M targets" for
    "M-profile targets with the MOVT instruction".

    gcc/testsuite/
    * gcc.target/arm/pure-code/pure-code.exp: Add conditional for
    check_effective_target_arm_thumb1_movt_ok.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@247585 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/config/arm/arm.c
gcc/config/arm/arm.md
gcc/doc/invoke.texi
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/arm/pure-code/pure-code.exp