arm.c (neon_immediate_valid_for_shift): New function.
authorDmitry Plotnikov <dplotnikov@ispras.ru>
Wed, 22 Jun 2011 11:57:52 +0000 (11:57 +0000)
committerAlexander Monakov <amonakov@gcc.gnu.org>
Wed, 22 Jun 2011 11:57:52 +0000 (15:57 +0400)
commit31a0c8251b9fb551d9979988e5e63df8bcc1d65f
tree377aee52f4ebe050c91bd7309e7509eaf305f3ab
parent1da9434b4ba81839aa43dfb53344a6dbfb0e314f
arm.c (neon_immediate_valid_for_shift): New function.

2011-06-22  Dmitry Plotnikov  <dplotnikov@ispras.ru>
Dmitry Melnik  <dm@ispras.ru>

* config/arm/arm.c (neon_immediate_valid_for_shift): New function.
(neon_output_shift_immediate): Ditto.
* config/arm/arm-protos.h (neon_immediate_valid_for_shift): New
prototype.
(neon_output_shift_immediate): Ditto.
* config/arm/neon.md (vashl<mode>3): Modified constraint.
(vashr<mode>3_imm): New insn pattern.
(vlshr<mode>3_imm): Ditto.
(vashr<mode>3): Modified constraint.
(vlshr<mode>3): Ditto.
* config/arm/predicates.md (imm_for_neon_lshift_operand): New
predicate.
(imm_for_neon_rshift_operand): Ditto.
(imm_lshift_or_reg_neon): Ditto.
(imm_rshift_or_reg_neon): Ditto.

* optabs.c (init_optabs): Init optab codes for vashl, vashr, vlshr.

testsuite:

* gcc.target/arm/neon-vshr-imm-1.c: New testcase.
* gcc.target/arm/neon-vshl-imm-1.c: New testcase.
* gcc.target/arm/neon-vlshr-imm-1.c: New testcase.

Co-Authored-By: Dmitry Melnik <dm@ispras.ru>
From-SVN: r175293
gcc/ChangeLog
gcc/config/arm/arm-protos.h
gcc/config/arm/arm.c
gcc/config/arm/neon.md
gcc/config/arm/predicates.md
gcc/optabs.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/arm/neon-vlshr-imm-1.c [new file with mode: 0644]
gcc/testsuite/gcc.target/arm/neon-vshl-imm-1.c [new file with mode: 0644]
gcc/testsuite/gcc.target/arm/neon-vshr-imm-1.c [new file with mode: 0644]