blob: 43f712e2de72710ec1c399af596101cb788884de (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
|
2015-12-09 Alexander Monakov <amonakov@ispras.ru>
* config/nvptx/nvptx.c (need_unisimt_decl): New variable. Set it...
(nvptx_init_unisimt_predicate): ...here (new function) and use it...
(nvptx_file_end): ...here to emit declaration of __nvptx_uni array.
(nvptx_declare_function_name): Call nvptx_init_unisimt_predicate.
(nvptx_get_unisimt_master): New helper function.
(nvptx_get_unisimt_predicate): Ditto.
(nvptx_call_insn_is_syscall_p): Ditto.
(nvptx_unisimt_handle_set): Ditto.
(nvptx_reorg_uniform_simt): New. Transform code for -muniform-simt.
(nvptx_get_axis_predicate): New helper function, factored out from...
(nvptx_single): ...here.
(nvptx_reorg): Call nvptx_reorg_uniform_simt.
* config/nvptx/nvptx.h (TARGET_CPU_CPP_BUILTINS): Define
__nvptx_unisimt__ when -muniform-simt option is active.
(struct machine_function): Add unisimt_master, unisimt_predicate
rtx fields.
* config/nvptx/nvptx.md (divergent): New attribute.
(atomic_compare_and_swap<mode>_1): Mark as divergent.
(atomic_exchange<mode>): Ditto.
(atomic_fetch_add<mode>): Ditto.
(atomic_fetch_addsf): Ditto.
(atomic_fetch_<logic><mode>): Ditto.
* config/nvptx/nvptx.opt (muniform-simt): New option.
* doc/invoke.texi (-muniform-simt): Document.
2015-12-09 Alexander Monakov <amonakov@ispras.ru>
* config/nvptx/nvptx.c (nvptx_output_call_insn): Handle COND_EXEC
patterns. Emit instruction predicate.
(nvptx_print_operand): Unbreak handling of instruction predicates.
* config/nvptx/nvptx.md (predicable): New attribute. Generate
predicated forms via define_cond_exec.
(br_true): Mark as not predicable.
(br_false): Ditto.
(br_true_uni): Ditto.
(br_false_uni): Ditto.
(return): Ditto.
(trap_if_true): Ditto.
(trap_if_false): Ditto.
(nvptx_fork): Ditto.
(nvptx_forked): Ditto.
(nvptx_joining): Ditto.
(nvptx_join): Ditto.
(nvptx_barsync): Ditto.
2015-12-09 Alexander Monakov <amonakov@ispras.ru>
* config/nvptx/nvptx.c: (need_softstack_decl): New variable.
(nvptx_declare_function_name): Handle TARGET_SOFT_STACK.
(nvptx_output_return): Emit stack restore if needed.
(nvptx_file_end): Handle need_softstack_decl.
* config/nvptx/nvptx.h: (TARGET_CPU_CPP_BUILTINS): Define
__nvptx_softstack__ when -msoft-stack is active.
(struct machine_function): New bool field using_softstack.
* config/nvptx/nvptx.opt: (msoft-stack): New option.
* doc/invoke.texi (msoft-stack): Document.
2015-12-08 Alexander Monakov <amonakov@ispras.ru>
* config/nvptx/nvptx.c: (write_omp_entry): New. Use it...
(nvptx_declare_function_name): ...here to emit pointers for libgomp.
2015-12-08 Alexander Monakov <amonakov@ispras.ru>
* omp-low.c (create_omp_child_function): Set "omp target entrypoint",
"omp acc target entrypoint" or "omp declare target" attribute based on
is_gimple_omp_offloaded and is_gimple_omp_oacc.
* config/nvptx/nvptx.c (write_as_kernel): Test OpenACC-specific
attribute "omp acc target entrypoint". Add a comment about the OpenMP
attribute handling.
2015-12-08 Alexander Monakov <amonakov@ispras.ru>
* config/nvptx/mkoffload.c (main): Allow -fopenmp.
|