1 2015-01-15 Jakub Jelinek <jakub@redhat.com>
3 * cp-gimplify.c (cp_genericize_r): Call
4 cp_ubsan_maybe_instrument_member_call for member calls.
5 (cp_ubsan_check_member_access_r): New function.
6 (cp_genericize_tree): Call cp_ubsan_instrument_member_accesses.
7 * cp-tree.h (cp_ubsan_maybe_instrument_member_call,
8 cp_ubsan_instrument_member_accesses,
9 cp_ubsan_maybe_instrument_downcast,
10 cp_ubsan_maybe_instrument_cast_to_vbase): New prototypes.
11 * cp-ubsan.c: New file.
12 * Make-lang.in (CXX_AND_OBJCXX_OBJS): Add cp/cp-ubsan.o.
13 * constexpr.c (cxx_eval_call_expression): Return void_node
15 (potential_constant_expression_1): Return true for
16 UBSAN_NULL, UBSAN_BOUNDS and UBSAN_VPTR internal calls.
17 * typeck.c (build_class_member_access_expr): Provide locus
19 (build_static_cast_1): Instrument downcasts.
20 * class.c (build_base_path): For -fsanitize=vptr and !fixed_type_p
21 add ubsan instrumentation for virtual_access.
22 * call.c: Include internal-fn.h.
23 (set_flags_from_callee): Handle internal calls.
25 2015-01-15 Momchil Velikov <momchil.velikov@gmail.com>
28 * name-lookup.c (pushdecl_maybe_friend_1): Hide friend functions
29 and function templates, declared only in the class.
30 * decl.c (duplicate_decls): Reveal hidden friend functions or
31 function templates, if they are redeclared outside the class.
33 2015-01-15 Jason Merrill <jason@redhat.com>
36 * constexpr.c (cxx_eval_binary_expression): Fix pasto.
39 * constexpr.c (potential_constant_expression_1): Handle reference
42 2015-01-15 Thomas Schwinge <thomas@codesourcery.com>
43 James Norris <jnorris@codesourcery.com>
44 Cesar Philippidis <cesar@codesourcery.com>
45 Ilmir Usmanov <i.usmanov@samsung.com>
46 Jakub Jelinek <jakub@redhat.com>
48 * parser.c: Include "gomp-constants.h".
49 (cp_parser_omp_clause_map): Use enum gomp_map_kind instead of enum
50 omp_clause_map_kind. Use GOMP_MAP_* instead of OMP_CLAUSE_MAP_*.
51 Use OMP_CLAUSE_SET_MAP_KIND.
52 (cp_parser_omp_construct, cp_parser_pragma): Handle
53 PRAGMA_OACC_CACHE, PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA,
54 PRAGMA_OACC_EXIT_DATA, PRAGMA_OACC_KERNELS, PRAGMA_OACC_PARALLEL,
55 PRAGMA_OACC_LOOP, PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
56 (cp_parser_omp_clause_name): Handle "async", "copy", "copyout",
57 "create", "delete", "deviceptr", "host", "num_gangs",
58 "num_workers", "present", "present_or_copy", "pcopy",
59 "present_or_copyin", "pcopyin", "present_or_copyout", "pcopyout",
60 "present_or_create", "pcreate", "vector_length", "wait".
61 (OACC_DATA_CLAUSE_MASK, OACC_ENTER_DATA_CLAUSE_MASK)
62 (OACC_EXIT_DATA_CLAUSE_MASK, OACC_KERNELS_CLAUSE_MASK)
63 (OACC_LOOP_CLAUSE_MASK, OACC_PARALLEL_CLAUSE_MASK)
64 (OACC_UPDATE_CLAUSE_MASK, OACC_WAIT_CLAUSE_MASK): New macros.
65 (cp_parser_omp_var_list_no_open): Handle OMP_CLAUSE__CACHE_.
66 (cp_parser_oacc_data_clause, cp_parser_oacc_data_clause_deviceptr)
67 (cp_parser_oacc_clause_vector_length, cp_parser_oacc_wait_list)
68 (cp_parser_oacc_clause_wait, cp_parser_omp_clause_num_gangs)
69 (cp_parser_omp_clause_num_workers, cp_parser_oacc_clause_async)
70 (cp_parser_oacc_all_clauses, cp_parser_oacc_cache)
71 (cp_parser_oacc_data, cp_parser_oacc_enter_exit_data)
72 (cp_parser_oacc_kernels, cp_parser_oacc_loop)
73 (cp_parser_oacc_parallel, cp_parser_oacc_update)
74 (cp_parser_oacc_wait): New functions.
75 * cp-tree.h (finish_oacc_data, finish_oacc_kernels)
76 (finish_oacc_parallel): New prototypes.
77 * semantics.c: Include "gomp-constants.h".
78 (handle_omp_array_sections): Handle GOMP_MAP_FORCE_DEVICEPTR. Use
79 GOMP_MAP_* instead of OMP_CLAUSE_MAP_*. Use
80 OMP_CLAUSE_SET_MAP_KIND.
81 (finish_omp_clauses): Handle OMP_CLAUSE_ASYNC,
82 OMP_CLAUSE_VECTOR_LENGTH, OMP_CLAUSE_WAIT, OMP_CLAUSE__CACHE_.
83 Use GOMP_MAP_* instead of OMP_CLAUSE_MAP_*.
84 (finish_oacc_data, finish_oacc_kernels, finish_oacc_parallel): New
87 2015-01-14 Paolo Carlini <paolo.carlini@oracle.com>
90 * decl2.c (var_defined_without_dynamic_init): Handle gracefully
93 2015-01-13 Jason Merrill <jason@redhat.com>
97 * constexpr.c (cxx_eval_binary_expression): Don't VERIFY_CONSTANT
99 (cxx_eval_increment_expression): Likewise.
102 * pt.c (coerce_template_parameter_pack): Return NULL for a
103 zero-length fixed parameter pack with a pack expansion arg.
106 * pt.c (unify): Don't try to deduce to std::initializer_list<T...>.
108 2015-01-12 Jason Merrill <jason@redhat.com>
111 * constexpr.c (cxx_eval_call_expression): A call to a void
112 function doesn't need to return a value.
114 2015-01-09 Michael Collison <michael.collison@linaro.org>
116 * call.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
117 input.h, alias.h, symtab.h, options.h, fold-const.h,
118 wide-int.h, and inchash.h due to flattening of tree.h.
120 * constexpr.c: Ditto.
121 * cp-array-notation.c: Ditto.
122 * cp-gimplify.c: Ditto.
124 * cp-objcp-common.c: Ditto.
137 * name-lookup.c: Ditto.
145 * semantics.c: Ditto.
150 2015-01-08 Jason Merrill <jason@redhat.com>
152 * cp-gimplify.c (cp_genericize): Use do_ubsan_in_current_function.
153 * decl.c (compute_array_index_type): Likewise.
154 * init.c (build_vec_init): Likewise.
155 * typeck.c (cp_build_binary_op): Likewise.
157 2015-01-08 Jason Merrill <jason@redhat.com>
159 * init.c (build_vec_init): Call ubsan_instrument_bounds to check
160 whether an initializer-list is too big for a VLA.
161 (throw_bad_array_length): Remove.
162 * cp-tree.h: Remove prototype.
164 2015-01-08 Paolo Carlini <paolo.carlini@oracle.com>
167 * decl.c (grokfndecl): Add bool parameter.
168 (grokdeclarator): Adjust calls.
169 (start_decl): Don't set DECL_DELETED_FN here.
171 2015-01-06 Jason Merrill <jason@redhat.com>
173 * parser.c (cp_parser_nested_name_specifier_opt): Diagnose invalid
177 * pt.c (type_dependent_expression_p): Handle variable templates.
178 * constexpr.c (potential_constant_expression_1): Use it.
181 * semantics.c (finish_offsetof): Handle templates here.
182 * parser.c (cp_parser_builtin_offsetof): Not here.
185 * semantics.c (process_outer_var_ref): Diagnose lambda in local
188 2015-01-06 Ville Voutilainen <ville.voutilainen@gmail.com>
191 * class.c (check_field_decls): Make copy assignment operators
192 complex only in c++98 mode.
194 2015-01-05 Trevor Saunders <tsaunders@mozilla.com>
197 * class.c (check_for_override): Warn when a virtual function is an
198 override not marked override.
200 2015-01-05 Trevor Saunders <tsaunders@mozilla.com>
202 * class.c (warn_hidden): Use auto_vec<tree> instead of tree_list to
204 (get_basefndecls): Adjust.
206 2015-01-05 Jakub Jelinek <jakub@redhat.com>
208 Update copyright years.
210 2015-01-05 Marek Polacek <polacek@redhat.com>
213 * typeck.c (cp_build_array_ref): Pass loc down to
214 warn_array_subscript_with_type_char.
217 Copyright (C) 2015 Free Software Foundation, Inc.
219 Copying and distribution of this file, with or without modification,
220 are permitted in any medium without royalty provided the copyright
221 notice and this notice are preserved.