[ARC] Add 'uncached' attribute.
authorClaudiu Zissulescu <claziss@synopsys.com>
Wed, 31 Jan 2018 10:01:34 +0000 (11:01 +0100)
committerClaudiu Zissulescu <claziss@gcc.gnu.org>
Wed, 31 Jan 2018 10:01:34 +0000 (11:01 +0100)
commit8180c03ff035fd70c4b8b1b4276dfce460d1e2bd
tree0b0908881e939c28f55e4d767bf88e4033f57b1b
parent2f857e1b0750d79172031951ed22e538df7299f8
[ARC] Add 'uncached' attribute.

The _Uncached type qualifier can be used to bypass the cache without
resorting to declaring variables as volatile.

gcc/
2018-01-31  Claudiu Zissulescu  <claziss@synopsys.com>

* config/arc/arc-protos.h (arc_is_uncached_mem_p): Function proto.
* config/arc/arc.c (arc_handle_uncached_attribute): New function.
(arc_attribute_table): Add 'uncached' attribute.
(arc_print_operand): Print '.di' flag for uncached memory
accesses.
(arc_in_small_data_p): Do not consider for small data the uncached
types.
(arc_is_uncached_mem_p): New function.
* config/arc/predicates.md (compact_store_memory_operand): Check
for uncached memory accesses.
(nonvol_nonimm_operand): Likewise.
* gcc/doc/extend.texi (ARC Type Attribute): New subsection.

gcc/testsuite
2018-01-31  Claudiu Zissulescu  <claziss@synopsys.com>

* gcc.target/arc/uncached.c: New test.

From-SVN: r257222
gcc/ChangeLog
gcc/config/arc/arc-protos.h
gcc/config/arc/arc.c
gcc/config/arc/predicates.md
gcc/doc/extend.texi
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/arc/uncached.c [new file with mode: 0644]