[nvptx] Rewrite nvptx_goacc_validate_dims to use predicate vars
authorTom de Vries <tdevries@suse.de>
Mon, 17 Dec 2018 21:26:39 +0000 (21:26 +0000)
committerTom de Vries <vries@gcc.gnu.org>
Mon, 17 Dec 2018 21:26:39 +0000 (21:26 +0000)
commitec6c865c6dc342dd6e99842377da5c18706a74ee
tree983e41c328af15f8c6280942d254b9a94f4c8ead
parentc764b12ccaaa84226682b9c19a448d51501ca56b
[nvptx] Rewrite nvptx_goacc_validate_dims to use predicate vars

The function nvptx_goacc_validate_dims has arguments decl and fn_level which
together describe different situations.

Introduce a predicate var for each situation, and use them, allowing to
understand what the function does in each situation without having to know the
way the situations are encoded in the args.

Build and reg-tested on x86_64 with nvptx accelerator.

2018-12-17  Tom de Vries  <tdevries@suse.de>

* config/nvptx/nvptx.c (nvptx_goacc_validate_dims): Rewrite using
predicate vars.

From-SVN: r267212
gcc/ChangeLog
gcc/config/nvptx/nvptx.c