]>
Commit | Line | Data |
---|---|---|
e6533e2e GA |
1 | 2022-03-07 Jakub Jelinek <jakub@redhat.com> |
2 | ||
3 | * libgccjit.h: Fix up duplicated word issue in a comment. | |
4 | ||
fc829782 GA |
5 | 2022-01-17 Martin Liska <mliska@suse.cz> |
6 | ||
7 | * config-lang.in: Rename .c names to .cc. | |
8 | * docs/_build/texinfo/libgccjit.texi: Likewise. | |
9 | * docs/internals/index.rst: Likewise. | |
10 | * jit-builtins.cc (builtins_manager::make_builtin_function): Likewise. | |
11 | * jit-playback.cc (fold_const_var): Likewise. | |
12 | (playback::context::~context): Likewise. | |
13 | (new_field): Likewise. | |
14 | (new_bitfield): Likewise. | |
15 | (new_compound_type): Likewise. | |
16 | (playback::compound_type::set_fields): Likewise. | |
17 | (global_set_init_rvalue): Likewise. | |
18 | (load_blob_in_ctor): Likewise. | |
19 | (new_global_initialized): Likewise. | |
20 | (double>): Likewise. | |
21 | (new_string_literal): Likewise. | |
22 | (as_truth_value): Likewise. | |
23 | (build_call): Likewise. | |
24 | (playback::context::build_cast): Likewise. | |
25 | (new_array_access): Likewise. | |
26 | (new_field_access): Likewise. | |
27 | (dereference): Likewise. | |
28 | (postprocess): Likewise. | |
29 | (add_jump): Likewise. | |
30 | (add_switch): Likewise. | |
31 | (build_goto_operands): Likewise. | |
32 | (playback::context::read_dump_file): Likewise. | |
33 | (init_types): Likewise. | |
34 | * jit-recording.cc (recording::context::get_int_type): Likewise. | |
35 | * jit-recording.h: Likewise. | |
36 | * libgccjit.cc (compatible_types): Likewise. | |
37 | (gcc_jit_context_acquire): Likewise. | |
38 | (gcc_jit_context_release): Likewise. | |
39 | (gcc_jit_context_new_child_context): Likewise. | |
40 | (gcc_jit_type_as_object): Likewise. | |
41 | (gcc_jit_context_get_type): Likewise. | |
42 | (gcc_jit_context_get_int_type): Likewise. | |
43 | (gcc_jit_type_get_pointer): Likewise. | |
44 | (gcc_jit_type_get_const): Likewise. | |
45 | (gcc_jit_type_get_volatile): Likewise. | |
46 | (gcc_jit_type_dyncast_array): Likewise. | |
47 | (gcc_jit_type_is_bool): Likewise. | |
48 | (gcc_jit_type_is_pointer): Likewise. | |
49 | (gcc_jit_type_is_integral): Likewise. | |
50 | (gcc_jit_type_dyncast_vector): Likewise. | |
51 | (gcc_jit_type_is_struct): Likewise. | |
52 | (gcc_jit_vector_type_get_num_units): Likewise. | |
53 | (gcc_jit_vector_type_get_element_type): Likewise. | |
54 | (gcc_jit_type_unqualified): Likewise. | |
55 | (gcc_jit_type_dyncast_function_ptr_type): Likewise. | |
56 | (gcc_jit_function_type_get_return_type): Likewise. | |
57 | (gcc_jit_function_type_get_param_count): Likewise. | |
58 | (gcc_jit_function_type_get_param_type): Likewise. | |
59 | (gcc_jit_context_new_array_type): Likewise. | |
60 | (gcc_jit_context_new_field): Likewise. | |
61 | (gcc_jit_field_as_object): Likewise. | |
62 | (gcc_jit_context_new_struct_type): Likewise. | |
63 | (gcc_jit_struct_as_type): Likewise. | |
64 | (gcc_jit_struct_set_fields): Likewise. | |
65 | (gcc_jit_struct_get_field_count): Likewise. | |
66 | (gcc_jit_context_new_union_type): Likewise. | |
67 | (gcc_jit_context_new_function_ptr_type): Likewise. | |
68 | (gcc_jit_param_as_rvalue): Likewise. | |
69 | (gcc_jit_context_new_function): Likewise. | |
70 | (gcc_jit_function_get_return_type): Likewise. | |
71 | (gcc_jit_function_dump_to_dot): Likewise. | |
72 | (gcc_jit_block_get_function): Likewise. | |
73 | (gcc_jit_global_set_initializer_rvalue): Likewise. | |
74 | (gcc_jit_rvalue_get_type): Likewise. | |
75 | (gcc_jit_context_new_rvalue_from_int): Likewise. | |
76 | (gcc_jit_context_one): Likewise. | |
77 | (gcc_jit_context_new_rvalue_from_double): Likewise. | |
78 | (gcc_jit_context_null): Likewise. | |
79 | (gcc_jit_context_new_string_literal): Likewise. | |
80 | (valid_binary_op_p): Likewise. | |
81 | (gcc_jit_context_new_binary_op): Likewise. | |
82 | (gcc_jit_context_new_comparison): Likewise. | |
83 | (gcc_jit_context_new_call): Likewise. | |
84 | (is_valid_cast): Likewise. | |
85 | (gcc_jit_context_new_cast): Likewise. | |
86 | (gcc_jit_object_get_context): Likewise. | |
87 | (gcc_jit_object_get_debug_string): Likewise. | |
88 | (gcc_jit_lvalue_access_field): Likewise. | |
89 | (gcc_jit_rvalue_access_field): Likewise. | |
90 | (gcc_jit_rvalue_dereference_field): Likewise. | |
91 | (gcc_jit_rvalue_dereference): Likewise. | |
92 | (gcc_jit_lvalue_get_address): Likewise. | |
93 | (gcc_jit_lvalue_set_tls_model): Likewise. | |
94 | (gcc_jit_lvalue_set_link_section): Likewise. | |
95 | (gcc_jit_function_new_local): Likewise. | |
96 | (gcc_jit_block_add_eval): Likewise. | |
97 | (gcc_jit_block_add_assignment): Likewise. | |
98 | (is_bool): Likewise. | |
99 | (gcc_jit_block_end_with_conditional): Likewise. | |
100 | (gcc_jit_block_add_comment): Likewise. | |
101 | (gcc_jit_block_end_with_jump): Likewise. | |
102 | (gcc_jit_block_end_with_return): Likewise. | |
103 | (gcc_jit_block_end_with_void_return): Likewise. | |
104 | (case_range_validator::case_range_validator): Likewise. | |
105 | (case_range_validator::validate): Likewise. | |
106 | (case_range_validator::get_wide_int): Likewise. | |
107 | (gcc_jit_block_end_with_switch): Likewise. | |
108 | (gcc_jit_context_set_str_option): Likewise. | |
109 | (gcc_jit_context_set_int_option): Likewise. | |
110 | (gcc_jit_context_set_bool_option): Likewise. | |
111 | (gcc_jit_context_set_bool_allow_unreachable_blocks): Likewise. | |
112 | (gcc_jit_context_set_bool_use_external_driver): Likewise. | |
113 | (gcc_jit_context_add_command_line_option): Likewise. | |
114 | (gcc_jit_context_add_driver_option): Likewise. | |
115 | (gcc_jit_context_enable_dump): Likewise. | |
116 | (gcc_jit_context_compile): Likewise. | |
117 | (gcc_jit_context_compile_to_file): Likewise. | |
118 | (gcc_jit_context_set_logfile): Likewise. | |
119 | (gcc_jit_context_dump_reproducer_to_file): Likewise. | |
120 | (gcc_jit_context_get_first_error): Likewise. | |
121 | (gcc_jit_context_get_last_error): Likewise. | |
122 | (gcc_jit_result_get_code): Likewise. | |
123 | (gcc_jit_result_get_global): Likewise. | |
124 | (gcc_jit_rvalue_set_bool_require_tail_call): Likewise. | |
125 | (gcc_jit_type_get_aligned): Likewise. | |
126 | (gcc_jit_type_get_vector): Likewise. | |
127 | (gcc_jit_function_get_address): Likewise. | |
128 | (gcc_jit_version_patchlevel): Likewise. | |
129 | (gcc_jit_block_add_extended_asm): Likewise. | |
130 | (gcc_jit_extended_asm_as_object): Likewise. | |
131 | (gcc_jit_extended_asm_set_volatile_flag): Likewise. | |
132 | (gcc_jit_extended_asm_set_inline_flag): Likewise. | |
133 | (gcc_jit_extended_asm_add_output_operand): Likewise. | |
134 | (gcc_jit_extended_asm_add_input_operand): Likewise. | |
135 | (gcc_jit_extended_asm_add_clobber): Likewise. | |
136 | * notes.txt: Likewise. | |
137 | ||
138 | 2022-01-17 Martin Liska <mliska@suse.cz> | |
139 | ||
140 | * dummy-frontend.c: Moved to... | |
141 | * dummy-frontend.cc: ...here. | |
142 | * jit-builtins.c: Moved to... | |
143 | * jit-builtins.cc: ...here. | |
144 | * jit-logging.c: Moved to... | |
145 | * jit-logging.cc: ...here. | |
146 | * jit-playback.c: Moved to... | |
147 | * jit-playback.cc: ...here. | |
148 | * jit-recording.c: Moved to... | |
149 | * jit-recording.cc: ...here. | |
150 | * jit-result.c: Moved to... | |
151 | * jit-result.cc: ...here. | |
152 | * jit-spec.c: Moved to... | |
153 | * jit-spec.cc: ...here. | |
154 | * jit-tempdir.c: Moved to... | |
155 | * jit-tempdir.cc: ...here. | |
156 | * jit-w32.c: Moved to... | |
157 | * jit-w32.cc: ...here. | |
158 | * libgccjit.c: Moved to... | |
159 | * libgccjit.cc: ...here. | |
160 | ||
054e57e4 GA |
161 | 2021-12-28 Martin Liska <mliska@suse.cz> |
162 | ||
163 | * docs/_build/texinfo/libgccjit.texi: Replace http:// with https. | |
164 | * docs/cp/index.rst: Likewise. | |
165 | * docs/cp/intro/index.rst: Likewise. | |
166 | * docs/cp/intro/tutorial01.rst: Likewise. | |
167 | * docs/cp/intro/tutorial02.rst: Likewise. | |
168 | * docs/cp/intro/tutorial03.rst: Likewise. | |
169 | * docs/cp/intro/tutorial04.rst: Likewise. | |
170 | * docs/cp/topics/asm.rst: Likewise. | |
171 | * docs/cp/topics/compilation.rst: Likewise. | |
172 | * docs/cp/topics/contexts.rst: Likewise. | |
173 | * docs/cp/topics/expressions.rst: Likewise. | |
174 | * docs/cp/topics/functions.rst: Likewise. | |
175 | * docs/cp/topics/index.rst: Likewise. | |
176 | * docs/cp/topics/locations.rst: Likewise. | |
177 | * docs/cp/topics/objects.rst: Likewise. | |
178 | * docs/cp/topics/types.rst: Likewise. | |
179 | * docs/index.rst: Likewise. | |
180 | * docs/internals/index.rst: Likewise. | |
181 | * docs/intro/index.rst: Likewise. | |
182 | * docs/intro/tutorial01.rst: Likewise. | |
183 | * docs/intro/tutorial02.rst: Likewise. | |
184 | * docs/intro/tutorial03.rst: Likewise. | |
185 | * docs/intro/tutorial04.rst: Likewise. | |
186 | * docs/intro/tutorial05.rst: Likewise. | |
187 | * docs/topics/asm.rst: Likewise. | |
188 | * docs/topics/compatibility.rst: Likewise. | |
189 | * docs/topics/compilation.rst: Likewise. | |
190 | * docs/topics/contexts.rst: Likewise. | |
191 | * docs/topics/expressions.rst: Likewise. | |
192 | * docs/topics/function-pointers.rst: Likewise. | |
193 | * docs/topics/functions.rst: Likewise. | |
194 | * docs/topics/index.rst: Likewise. | |
195 | * docs/topics/locations.rst: Likewise. | |
196 | * docs/topics/objects.rst: Likewise. | |
197 | * docs/topics/performance.rst: Likewise. | |
198 | * docs/topics/types.rst: Likewise. | |
199 | ||
7631a4d1 GA |
200 | 2021-12-20 Martin Liska <mliska@suse.cz> |
201 | ||
202 | * libgccjit.c (struct version_info): Rename to jit_version_info. | |
203 | (struct jit_version_info): Likewise. | |
204 | (gcc_jit_version_major): Likewise. | |
205 | (gcc_jit_version_minor): Likewise. | |
206 | (gcc_jit_version_patchlevel): Likewise. | |
207 | ||
9c6586bc GA |
208 | 2021-12-14 Petter Tomner <tomner@kth.se> |
209 | ||
210 | * jit-common.h: New enum | |
211 | * jit-playback.c : Folding an setting intitial | |
212 | (global_new_decl) : Handle const global generation | |
213 | (new_global) : New flag | |
214 | (global_set_init_rvalue) : New | |
215 | (new_ctor) : New | |
216 | (new_global_initialized) : Flag | |
217 | (as_truth_value) : Fold | |
218 | (new_unary_op) : Fold | |
219 | (new_binary_op) : Fold | |
220 | (new_comparison) : Fold | |
221 | (new_array_access) : Fold | |
222 | (new_dereference) : Fold | |
223 | (get_address) : Fold | |
224 | * jit-playback.h : | |
225 | (global_set_init_rvalue) : New | |
226 | (new_ctor) : New | |
227 | * jit-recording.c : | |
228 | * jit-recording.h : | |
229 | (new_global_init_rvalue) : New | |
230 | (new_ctor) : New | |
231 | (ctor) : New, inherits rvalue | |
232 | (global_init_rvalue) : New, inherits memento | |
233 | (type::is_union) : New | |
234 | * libgccjit++.h : New entrypoints, see C-header | |
235 | * libgccjit.c : See .h | |
236 | * libgccjit.h : New entrypoints | |
237 | (gcc_jit_context_new_array_constructor) : New | |
238 | (gcc_jit_context_new_struct_constructor) : New | |
239 | (gcc_jit_context_new_union_constructor) : New | |
240 | (gcc_jit_global_set_initializer_rvalue) : New | |
241 | (LIBGCCJIT_HAVE_CTORS) : New feuture macro | |
242 | * libgccjit.map : New entrypoints added to ABI 19 | |
243 | * docs/topics/expressions.rst : Updated docs | |
244 | ||
c8dcf64b GA |
245 | 2021-12-12 Antoni Boucher <bouanto@zoho.com> |
246 | ||
247 | PR target/100688 | |
248 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_18): New ABI | |
249 | tag. | |
250 | * docs/topics/expressions.rst: Add documentation for the | |
251 | function gcc_jit_lvalue_set_link_section. | |
252 | * jit-playback.h: New function (set_link_section). | |
253 | * jit-recording.c: New function (set_link_section) and | |
254 | support for setting the link section. | |
255 | * jit-recording.h: New function (set_link_section) and new | |
256 | field m_link_section. | |
257 | * libgccjit.c: New function (gcc_jit_lvalue_set_link_section). | |
258 | * libgccjit.h: New function (gcc_jit_lvalue_set_link_section). | |
259 | * libgccjit.map (LIBGCCJIT_ABI_18): New ABI tag. | |
260 | ||
e8decbe7 GA |
261 | 2021-12-12 Antoni Boucher <bouanto@zoho.com> |
262 | ||
263 | PR target/95415 | |
264 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_17): New ABI | |
265 | tag. | |
266 | * docs/topics/expressions.rst: Add document for the function | |
267 | gcc_jit_lvalue_set_tls_model. | |
268 | * jit-playback.h: New function (set_tls_model). | |
269 | * jit-recording.c: New function (set_tls_model), new | |
270 | variables (tls_models and tls_model_enum_strings) and support | |
271 | for setting the tls model. | |
272 | * jit-recording.h: New function (set_tls_model) and new | |
273 | field m_tls_model. | |
274 | * libgccjit.c: New function (gcc_jit_lvalue_set_tls_model). | |
275 | * libgccjit.h: New function (gcc_jit_lvalue_set_tls_model) | |
276 | and new enum (gcc_jit_tls_model). | |
277 | * libgccjit.map (LIBGCCJIT_ABI_17): New ABI tag. | |
278 | ||
279 | 2021-12-11 Antoni Boucher <bouanto@zoho.com> | |
280 | ||
281 | PR target/96066 | |
282 | PR target/96067 | |
283 | * jit-builtins.c: Implement missing types for builtins. | |
284 | * jit-recording.c:: Allow sending a volatile const void * as | |
285 | argument. | |
286 | * jit-recording.h: New functions (is_volatile, is_const) and | |
287 | allow comparing qualified types. | |
288 | ||
0bceef16 GA |
289 | 2021-12-10 David Malcolm <dmalcolm@redhat.com> |
290 | ||
291 | PR jit/103562 | |
292 | * jit-playback.c (gcc::jit::playback::context::new_function): Set | |
293 | DECL_CONTEXT of the result_decl. | |
294 | ||
d62c8c74 GA |
295 | 2021-11-27 Petter Tomner <tomner@kth.se> |
296 | ||
297 | * libgccjit.c: %ld -> %zu | |
298 | ||
d9ca4b45 GA |
299 | 2021-11-24 Martin Liska <mliska@suse.cz> |
300 | ||
301 | * jit-playback.c (function): Initialize m_blocks vector. | |
302 | ||
f658f1d7 GA |
303 | 2021-11-20 Antoni Boucher <bouanto@zoho.com> |
304 | ||
305 | PR target/96889 | |
306 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_16): New ABI tag. | |
307 | * docs/topics/functions.rst: Add documentation for the | |
308 | functions gcc_jit_function_get_return_type and | |
309 | gcc_jit_function_get_param_count | |
310 | * docs/topics/types.rst: Add documentation for the functions | |
311 | gcc_jit_function_type_get_return_type, | |
312 | gcc_jit_function_type_get_param_count, | |
313 | gcc_jit_function_type_get_param_type, | |
314 | gcc_jit_type_unqualified, gcc_jit_type_dyncast_array, | |
315 | gcc_jit_type_is_bool, | |
316 | gcc_jit_type_dyncast_function_ptr_type, | |
317 | gcc_jit_type_is_integral, gcc_jit_type_is_pointer, | |
318 | gcc_jit_type_dyncast_vector, | |
319 | gcc_jit_vector_type_get_element_type, | |
320 | gcc_jit_vector_type_get_num_units, | |
321 | gcc_jit_struct_get_field, gcc_jit_type_is_struct, | |
322 | and gcc_jit_struct_get_field_count | |
323 | * libgccjit.c: | |
324 | (gcc_jit_function_get_return_type, gcc_jit_function_get_param_count, | |
325 | gcc_jit_function_type_get_return_type, | |
326 | gcc_jit_function_type_get_param_count, | |
327 | gcc_jit_function_type_get_param_type, gcc_jit_type_unqualified, | |
328 | gcc_jit_type_dyncast_array, gcc_jit_type_is_bool, | |
329 | gcc_jit_type_dyncast_function_ptr_type, gcc_jit_type_is_integral, | |
330 | gcc_jit_type_is_pointer, gcc_jit_type_dyncast_vector, | |
331 | gcc_jit_vector_type_get_element_type, | |
332 | gcc_jit_vector_type_get_num_units, gcc_jit_struct_get_field, | |
333 | gcc_jit_type_is_struct, gcc_jit_struct_get_field_count): New | |
334 | functions. | |
335 | (struct gcc_jit_function_type, struct gcc_jit_vector_type): | |
336 | New types. | |
337 | * libgccjit.h: | |
338 | (gcc_jit_function_get_return_type, gcc_jit_function_get_param_count, | |
339 | gcc_jit_function_type_get_return_type, | |
340 | gcc_jit_function_type_get_param_count, | |
341 | gcc_jit_function_type_get_param_type, gcc_jit_type_unqualified, | |
342 | gcc_jit_type_dyncast_array, gcc_jit_type_is_bool, | |
343 | gcc_jit_type_dyncast_function_ptr_type, gcc_jit_type_is_integral, | |
344 | gcc_jit_type_is_pointer, gcc_jit_type_dyncast_vector, | |
345 | gcc_jit_vector_type_get_element_type, | |
346 | gcc_jit_vector_type_get_num_units, gcc_jit_struct_get_field, | |
347 | gcc_jit_type_is_struct, gcc_jit_struct_get_field_count): New | |
348 | function declarations. | |
349 | (struct gcc_jit_function_type, struct gcc_jit_vector_type): | |
350 | New types. | |
351 | * jit-recording.h: New functions (is_struct and is_vector) | |
352 | * libgccjit.map (LIBGCCJIT_ABI_16): New ABI tag. | |
353 | ||
af2852b9 GA |
354 | 2021-11-12 David Malcolm <dmalcolm@redhat.com> |
355 | ||
356 | PR jit/103199 | |
357 | * docs/examples/tut04-toyvm/toyvm.c (toyvm_function_compile): | |
358 | Increase size of buffer. | |
359 | * docs/examples/tut04-toyvm/toyvm.cc | |
360 | (compilation_state::create_function): Likewise. | |
361 | ||
a26206ec GA |
362 | 2021-09-10 Petter Tomner <tomner@kth.se> |
363 | ||
364 | * jit-playback.c: Moved global var processing to after loc handling. | |
365 | Setting TYPE_NAME for fundamental types. | |
366 | Using common functions for finalizing globals. | |
367 | * jit-playback.h: New method init_types(). | |
368 | Changed get_tree_node_for_type() to method. | |
369 | ||
b57fba5e GA |
370 | 2021-08-19 Iain Sandoe <iain@sandoe.co.uk> |
371 | ||
372 | * docs/examples/tut04-toyvm/toyvm.c: Include jit-dejagnu.h. | |
373 | * docs/examples/tut04-toyvm/toyvm.cc: Likewise. | |
374 | * jit-dejagnu.h: New file, imported from dejagnu-1.6.2 and | |
375 | patched for this application. | |
376 | ||
6e529985 GA |
377 | 2021-08-18 Iain Sandoe <iain@sandoe.co.uk> |
378 | ||
379 | PR jit/100613 | |
380 | * Make-lang.in: Provide clauses for Darwin hosts. | |
381 | ||
bdea84c4 GA |
382 | 2021-07-18 Antoni Boucher <bouanto@zoho.com> |
383 | ||
384 | PR target/95498 | |
385 | * jit-playback.c (convert): Add support to handle truncation and | |
386 | extension in the convert function. | |
387 | ||
65f32e5d GA |
388 | 2021-05-19 Martin Liska <mliska@suse.cz> |
389 | ||
390 | PR testsuite/100658 | |
391 | * libgccjit.c (gcc_jit_context_new_function): Fix typos. | |
392 | ||
8bf52ffa GA |
393 | 2021-03-24 Matthias Klose <doko@ubuntu.com> |
394 | ||
395 | * Make-lang.in (jit.sphinx.html, jit.sphinx.pdf): Use $(mkinstalldirs), | |
396 | (jit.install-headers): Depend on installdirs. | |
397 | ||
50352c6c GA |
398 | 2021-02-19 David Malcolm <dmalcolm@redhat.com> |
399 | ||
400 | PR jit/99126 | |
401 | * jit-builtins.c | |
402 | (gcc::jit::builtins_manager::get_builtin_function_by_id): | |
403 | Update assertion to reject BUILT_IN_NONE. | |
404 | (gcc::jit::builtins_manager::ensure_optimization_builtins_exist): | |
405 | New. | |
406 | * jit-builtins.h | |
407 | (gcc::jit::builtins_manager::ensure_optimization_builtins_exist): | |
408 | New decl. | |
409 | * jit-playback.c (gcc::jit::playback::context::replay): Call it. | |
410 | Remove redundant conditional on bm. | |
411 | ||
5fff80fd GA |
412 | 2021-01-14 David Malcolm <dmalcolm@redhat.com> |
413 | ||
414 | * docs/cp/index.rst: Remove "Alpha" warning. | |
415 | * docs/index.rst: Likewise. | |
416 | * docs/_build/texinfo/libgccjit.texi: Regenerate | |
417 | ||
360258da GA |
418 | 2020-11-25 Martin Sebor <msebor@redhat.com> |
419 | ||
420 | PR bootstrap/94982 | |
421 | * jit-recording.c (recording::function::dump_to_dot): Avoid | |
422 | -Wformat-diag. | |
423 | (recording::block::dump_to_dot): Same. | |
424 | ||
82e5048e GA |
425 | 2020-11-20 Jakub Jelinek <jakub@redhat.com> |
426 | ||
427 | PR other/97911 | |
428 | * Make-lang.in (jit.serial): Change from goal to a | |
429 | variable. | |
430 | (.PHONY): Drop jit.serial and jit.prev. | |
431 | ($(LIBGCCJIT_FILENAME)): Depend on $(jit.serial) rather than | |
432 | jit.serial. | |
433 | ||
25bb75f8 GA |
434 | 2020-11-18 Jakub Jelinek <jakub@redhat.com> |
435 | ||
436 | * Make-lang.in (jit.serial): New goal. | |
437 | (.PHONY): Add jit.serial jit.prev. | |
438 | ($(LIBGCCJIT_FILENAME)): Depend on jit.prev. Call LINK_PROGRESS. | |
439 | ||
a5a11525 GA |
440 | 2020-11-12 David Malcolm <dmalcolm@redhat.com> |
441 | ||
442 | PR jit/87291 | |
443 | * docs/cp/topics/asm.rst: New file. | |
444 | * docs/cp/topics/index.rst (Topic Reference): Add it. | |
445 | * docs/topics/asm.rst: New file. | |
446 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_15): New. | |
447 | * docs/topics/functions.rst (Statements): Add link to extended | |
448 | asm. | |
449 | * docs/topics/index.rst (Topic Reference): Add asm.rst. | |
450 | * docs/topics/objects.rst: Add gcc_jit_extended_asm to ASCII art. | |
451 | * docs/_build/texinfo/Makefile: Regenerate. | |
452 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
453 | * jit-common.h (gcc::jit::recording::extended_asm): New forward | |
454 | decl. | |
455 | (gcc::jit::recording::top_level_asm): Likewise. | |
456 | * jit-playback.c: Include "stmt.h". | |
457 | (build_string): New. | |
458 | (gcc::jit::playback::context::new_string_literal): Disambiguate | |
459 | build_string call. | |
460 | (gcc::jit::playback::context::add_top_level_asm): New. | |
461 | (build_operand_chain): New. | |
462 | (build_clobbers): New. | |
463 | (build_goto_operands): New. | |
464 | (gcc::jit::playback::block::add_extended_asm): New. | |
465 | * jit-playback.h (gcc::jit::playback::context::add_top_level_asm): | |
466 | New decl. | |
467 | (struct gcc::jit::playback::asm_operand): New struct. | |
468 | (gcc::jit::playback::block::add_extended_asm): New decl. | |
469 | * jit-recording.c (gcc::jit::recording::context::dump_to_file): | |
470 | Dump top-level asms. | |
471 | (gcc::jit::recording::context::add_top_level_asm): New. | |
472 | (gcc::jit::recording::block::add_extended_asm): New. | |
473 | (gcc::jit::recording::block::end_with_extended_asm_goto): New. | |
474 | (gcc::jit::recording::asm_operand::asm_operand): New. | |
475 | (gcc::jit::recording::asm_operand::print): New. | |
476 | (gcc::jit::recording::asm_operand::make_debug_string): New. | |
477 | (gcc::jit::recording::output_asm_operand::write_reproducer): New. | |
478 | (gcc::jit::recording::output_asm_operand::print): New. | |
479 | (gcc::jit::recording::input_asm_operand::write_reproducer): New. | |
480 | (gcc::jit::recording::input_asm_operand::print): New. | |
481 | (gcc::jit::recording::extended_asm::add_output_operand): New. | |
482 | (gcc::jit::recording::extended_asm::add_input_operand): New. | |
483 | (gcc::jit::recording::extended_asm::add_clobber): New. | |
484 | (gcc::jit::recording::extended_asm::replay_into): New. | |
485 | (gcc::jit::recording::extended_asm::make_debug_string): New. | |
486 | (gcc::jit::recording::extended_asm::write_flags): New. | |
487 | (gcc::jit::recording::extended_asm::write_clobbers): New. | |
488 | (gcc::jit::recording::extended_asm_simple::write_reproducer): New. | |
489 | (gcc::jit::recording::extended_asm::maybe_populate_playback_blocks): | |
490 | New. | |
491 | (gcc::jit::recording::extended_asm_goto::extended_asm_goto): New. | |
492 | (gcc::jit::recording::extended_asm_goto::replay_into): New. | |
493 | (gcc::jit::recording::extended_asm_goto::write_reproducer): New. | |
494 | (gcc::jit::recording::extended_asm_goto::get_successor_blocks): | |
495 | New. | |
496 | (gcc::jit::recording::extended_asm_goto::maybe_print_gotos): New. | |
497 | (gcc::jit::recording::extended_asm_goto::maybe_populate_playback_blocks): | |
498 | New. | |
499 | (gcc::jit::recording::top_level_asm::top_level_asm): New. | |
500 | (gcc::jit::recording::top_level_asm::replay_into): New. | |
501 | (gcc::jit::recording::top_level_asm::make_debug_string): New. | |
502 | (gcc::jit::recording::top_level_asm::write_to_dump): New. | |
503 | (gcc::jit::recording::top_level_asm::write_reproducer): New. | |
504 | * jit-recording.h | |
505 | (gcc::jit::recording::context::add_top_level_asm): New decl. | |
506 | (gcc::jit::recording::context::m_top_level_asms): New field. | |
507 | (gcc::jit::recording::block::add_extended_asm): New decl. | |
508 | (gcc::jit::recording::block::end_with_extended_asm_goto): New | |
509 | decl. | |
510 | (gcc::jit::recording::asm_operand): New class. | |
511 | (gcc::jit::recording::output_asm_operand): New class. | |
512 | (gcc::jit::recording::input_asm_operand): New class. | |
513 | (gcc::jit::recording::extended_asm): New class. | |
514 | (gcc::jit::recording::extended_asm_simple): New class. | |
515 | (gcc::jit::recording::extended_asm_goto): New class. | |
516 | (gcc::jit::recording::top_level_asm): New class. | |
517 | * libgccjit++.h (gccjit::extended_asm): New forward decl. | |
518 | (gccjit::context::add_top_level_asm): New. | |
519 | (gccjit::block::add_extended_asm): New. | |
520 | (gccjit::block::end_with_extended_asm_goto): New. | |
521 | (gccjit::extended_asm): New class. | |
522 | (gccjit::extended_asm::extended_asm): New ctors. | |
523 | (gccjit::extended_asm::set_volatile_flag): New. | |
524 | (gccjit::extended_asm::set_inline_flag): New. | |
525 | (gccjit::extended_asm::add_output_operand): New. | |
526 | (gccjit::extended_asm::add_input_operand): New. | |
527 | (gccjit::extended_asm::add_clobber): New. | |
528 | (gccjit::extended_asm::get_inner_extended_asm): New. | |
529 | * libgccjit.c (struct gcc_jit_extended_asm): New. | |
530 | (jit_error): Make "loc" param take a gcc::jit::recording::location * | |
531 | rather than a gcc_jit_location *. | |
532 | (gcc_jit_block_add_extended_asm): New entrypoint. | |
533 | (gcc_jit_block_end_with_extended_asm_goto): New entrypoint. | |
534 | (gcc_jit_extended_asm_as_object): New entrypoint. | |
535 | (gcc_jit_extended_asm_set_volatile_flag): New entrypoint. | |
536 | (gcc_jit_extended_asm_set_inline_flag): New entrypoint. | |
537 | (gcc_jit_extended_asm_add_output_operand): New entrypoint. | |
538 | (gcc_jit_extended_asm_add_clobber): New entrypoint. | |
539 | (gcc_jit_context_add_top_level_asm): New entrypoint. | |
540 | * libgccjit.h: Add gcc_jit_extended_asm to ASCII art. | |
541 | (gcc_jit_extended_asm): New typedef. | |
542 | (LIBGCCJIT_HAVE_ASM_STATEMENTS): New define. | |
543 | (gcc_jit_block_add_extended_asm): New entrypoint. | |
544 | (gcc_jit_block_end_with_extended_asm_goto): New entrypoint. | |
545 | (gcc_jit_extended_asm_as_object): New entrypoint. | |
546 | (gcc_jit_extended_asm_set_volatile_flag): New entrypoint. | |
547 | (gcc_jit_extended_asm_set_inline_flag): New entrypoint. | |
548 | (gcc_jit_extended_asm_add_output_operand): New entrypoint. | |
549 | (gcc_jit_extended_asm_add_input_operand): New entrypoint. | |
550 | (gcc_jit_extended_asm_add_clobber): New entrypoint. | |
551 | (gcc_jit_context_add_top_level_asm): New entrypoint. | |
552 | * libgccjit.map (LIBGCCJIT_ABI_15): New. | |
553 | ||
554 | 2020-11-12 David Malcolm <dmalcolm@redhat.com> | |
555 | ||
556 | * jit-recording.c (recording::context::new_string): Add "escaped" | |
557 | param and use it when creating the new recording::string instance. | |
558 | (recording::string::string): Add "escaped" param and use it to | |
559 | initialize m_escaped. | |
560 | (recording::string::make_debug_string): Replace check that first | |
561 | char is double-quote with use of m_escaped. Fix escaping of | |
562 | '\t' and '\n'. Set "escaped" on the result. | |
563 | * jit-recording.h (recording::context::new_string): Add "escaped" | |
564 | param. | |
565 | (recording::string::string): Add "escaped" param. | |
566 | (recording::string::m_escaped): New field. | |
567 | ||
568 | 2020-11-12 David Malcolm <dmalcolm@redhat.com> | |
569 | ||
570 | * libgccjit.h: Fix typo in comment. | |
571 | ||
50a71cd0 GA |
572 | 2020-09-14 Andrea Corallo <andrea.corallo@arm.com> |
573 | ||
574 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
575 | ||
ac35c090 GA |
576 | 2020-09-11 Andrea Corallo <andrea.corallo@arm.com> |
577 | ||
578 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_14): New ABI tag. | |
579 | * docs/topics/expressions.rst (gcc_jit_global_set_initializer): | |
580 | Document new entry point in section 'Global variables'. | |
581 | * jit-playback.c (global_new_decl, global_finalize_lvalue): New | |
582 | method. | |
583 | (playback::context::new_global): Make use of global_new_decl, | |
584 | global_finalize_lvalue. | |
585 | (load_blob_in_ctor): New template function in use by the | |
586 | following. | |
587 | (playback::context::new_global_initialized): New method. | |
588 | * jit-playback.h (class context): Decl 'new_global_initialized', | |
589 | 'global_new_decl', 'global_finalize_lvalue'. | |
590 | (lvalue::set_initializer): Add implementation. | |
591 | * jit-recording.c (recording::memento_of_get_pointer::get_size) | |
592 | (recording::memento_of_get_type::get_size): Add implementation. | |
593 | (recording::global::write_initializer_reproducer): New function in | |
594 | use by 'recording::global::write_reproducer'. | |
595 | (recording::global::replay_into) | |
596 | (recording::global::write_to_dump) | |
597 | (recording::global::write_reproducer): Handle | |
598 | initialized case. | |
599 | * jit-recording.h (class type): Decl 'get_size' and | |
600 | 'num_elements'. | |
601 | * libgccjit++.h (class lvalue): Declare new 'set_initializer' | |
602 | method. | |
603 | (class lvalue): Decl 'is_global' and 'set_initializer'. | |
604 | (class global) Decl 'write_initializer_reproducer'. Add | |
605 | 'm_initializer', 'm_initializer_num_bytes' fields. Implement | |
606 | 'set_initializer'. Add a destructor to free 'm_initializer'. | |
607 | * libgccjit.c (gcc_jit_global_set_initializer): New function. | |
608 | * libgccjit.h (gcc_jit_global_set_initializer): New function | |
609 | declaration. | |
610 | * libgccjit.map (LIBGCCJIT_ABI_14): New ABI tag. | |
611 | ||
8f7ea26a GA |
612 | 2020-08-28 Martin Sebor <msebor@redhat.com> |
613 | ||
614 | * jit-recording.c (recording::switch_::make_debug_string): Add argument | |
615 | to a call. | |
616 | ||
e769f970 GA |
617 | 2020-08-22 Andrea Corallo <andrea.corallo@arm.com> |
618 | ||
619 | * libgccjit.c: | |
620 | (gcc_jit_context_new_rvalue_from_int) | |
621 | (gcc_jit_context_new_rvalue_from_long) | |
622 | (gcc_jit_context_new_rvalue_from_double) | |
623 | (gcc_jit_context_new_rvalue_from_ptr): Update function heading | |
624 | comments. | |
625 | ||
6fb94d67 GA |
626 | 2020-06-16 Nicolas Bértolo <nicolasbertolo@gmail.com> |
627 | ||
628 | * Make-lang.in: Always define version, minor and release | |
629 | numbers. Create the Windows shared library as | |
630 | libgccjit-$(LIBGCCJIT_VERSION_NUM).dll. | |
631 | ||
9a5b7438 GA |
632 | 2020-06-03 David Malcolm <dmalcolm@redhat.com> |
633 | ||
634 | PR jit/95306 | |
635 | * jit-builtins.c (builtins_manager::make_primitive_type): | |
636 | Implement BT_CONST_VOLATILE_PTR. | |
637 | ||
a9312a79 GA |
638 | 2020-06-02 David Malcolm <dmalcolm@redhat.com> |
639 | ||
640 | PR jit/95426 | |
641 | * dummy-frontend.c: Include "options.h", "stringpool.h", and | |
642 | "attribs.h". | |
643 | (ATTR_EXCL): New, copied from lto/lto-lang.c. | |
644 | (attr_noreturn_exclusions): Likewise. | |
645 | (attr_returns_twice_exclusions): Likewise. | |
646 | (attr_const_pure_exclusions): Likewise. | |
647 | (jit_attribute_table): Likewise, copied from lto_attribute_table. | |
648 | (jit_format_attribute_table): Likewise, copied from | |
649 | lto_format_attribute_table. | |
650 | (handle_noreturn_attribute): New, copied from lto/lto-lang.c. | |
651 | (handle_leaf_attribute): Likewise. | |
652 | (handle_const_attribute): Likewise. | |
653 | (handle_malloc_attribute): Likewise. | |
654 | (handle_pure_attribute): Likewise. | |
655 | (handle_novops_attribute): Likewise. | |
656 | (get_nonnull_operand): Likewise. | |
657 | (handle_nonnull_attribute): Likewise. | |
658 | (handle_nothrow_attribute): Likewise. | |
659 | (handle_sentinel_attribute): Likewise. | |
660 | (handle_type_generic_attribute): Likewise. | |
661 | (handle_transaction_pure_attribute): Likewise. | |
662 | (handle_returns_twice_attribute): Likewise. | |
663 | (handle_patchable_function_entry_attribute): Likewise. | |
664 | (ignore_attribute): Likewise. | |
665 | (handle_format_attribute): Likewise. | |
666 | (handle_format_arg_attribute): Likewise. | |
667 | (handle_fnspec_attribute): Likewise. | |
668 | (LANG_HOOKS_COMMON_ATTRIBUTE_TABLE): Define. | |
669 | (LANG_HOOKS_FORMAT_ATTRIBUTE_TABLE): Define. | |
670 | ||
53ffb43a GA |
671 | 2020-05-28 Nicolas Bértolo <nicolasbertolo@gmail.com> |
672 | ||
673 | * Make-lang.in: Remove extra slash. Build libgccjit.dll and its | |
674 | import library in Windows. | |
675 | * config-lang.in: Update comment about --enable-host-shared. | |
676 | * jit-w32.h: New file. | |
677 | * jit-w32.c: New file. | |
678 | (print_last_error): New function that prints the error | |
679 | string corresponding to GetLastError(). | |
680 | (get_TOKEN_USER_current_user): Helper function used for getting | |
681 | the SID belonging to the current user. | |
682 | (create_directory_for_current_user): Helper function to create | |
683 | a directory with permissions such that only the current user can | |
684 | access it. | |
685 | (win_mkdtemp): Create a temporary directory using Windows APIs. | |
686 | * jit-playback.c: Do not chmod files in Windows. Use LoadLibrary, | |
687 | FreeLibrary and GetProcAddress instead of libdl. | |
688 | * jit-result.h, jit-result.c: Introduce result::handle_t to | |
689 | abstract over the types used for dynamic library handles. | |
690 | * jit-tempdir.c: Do not use mkdtemp() in Windows, use | |
691 | win_mkdtemp(). | |
692 | ||
61f3b605 GA |
693 | 2020-05-27 David Malcolm <dmalcolm@redhat.com> |
694 | ||
695 | PR jit/95314 | |
696 | * dummy-frontend.c (LANG_HOOKS_DEEP_UNSHARING): Define to be true. | |
697 | * jit-playback.h (gcc::jit::playback::rvalue): Mark tree node with | |
698 | TREE_VISITED. | |
699 | ||
700 | 2020-05-27 Tom Tromey <tromey@gcc.gnu.org> | |
701 | ||
702 | PR jit/91330 | |
703 | * docs/conf.py (texinfo_documents): Set description. | |
704 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
705 | ||
c3a4169b GA |
706 | 2020-05-26 David Malcolm <dmalcolm@redhat.com> |
707 | ||
708 | PR jit/95306 | |
709 | * docs/topics/functions.rst | |
710 | (gcc_jit_context_get_builtin_function): Document. | |
711 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
712 | * dummy-frontend.c (jit_langhook_global_bindings_p): Remove | |
713 | gcc_unreachable. | |
714 | * jit-builtins.c (type_names): New array. | |
715 | (get_string_for_type_id): New function. | |
716 | (gcc::jit::builtins_manager::make_primitive_type): Show name of | |
717 | type in error messages. Update cases to reflect the order in | |
718 | builtin-types.def. Implement cases for BT_INT8, BT_INT16, | |
719 | BT_UINT8, BT_CONST_PTR, BT_VOLATILE_PTR, BT_INT_PTR, BT_FLOAT_PTR, | |
720 | BT_CONST_DOUBLE_PTR, BT_SIZE, BT_CONST_SIZE. | |
721 | ||
722 | 2020-05-26 David Malcolm <dmalcolm@redhat.com> | |
723 | ||
724 | * docs/topics/compatibility.rst: Fix underline. | |
725 | Fix missing labels. | |
726 | * docs/topics/types.rst: Fix missing blank line. | |
727 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
728 | ||
729 | 2020-05-26 David Malcolm <dmalcolm@redhat.com> | |
730 | ||
731 | PR jit/95296 | |
732 | * docs/topics/expressions.rst (Unary Operations): Document that | |
733 | result_type of gcc_jit_context_new_unary_op must be a numeric type. | |
734 | (Binary Operations): Likewise for gcc_jit_context_new_binary_op. | |
735 | (Global variables): Document that "type" of | |
736 | gcc_jit_context_new_global must be non-`void`. | |
737 | * docs/topics/function-pointers.rst | |
738 | (gcc_jit_context_new_function_ptr_type): Document that the | |
739 | param_types must be non-void, but that return_type may be. | |
740 | * docs/topics/functions.rst (Params): Document that | |
741 | gcc_jit_context_new_param's type must be non-void. | |
742 | (Functions): Likewise for gcc_jit_function_new_local. | |
743 | * docs/topics/types.rst (gcc_jit_context_new_array_type): Document | |
744 | that the type must be non-void. | |
745 | (gcc_jit_context_new_field): Likewise. | |
746 | * docs/_build/texinfo/Makefile: Regenerate. | |
747 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
748 | * libgccjit.c (gcc_jit_context_new_array_type): Fail if | |
749 | element_type is void. | |
750 | (gcc_jit_context_new_field): Likewise for "type". | |
751 | (gcc_jit_context_new_function_ptr_type): Likewise for each | |
752 | element of param_types. | |
753 | (gcc_jit_context_new_param): Likewise for "type". | |
754 | (gcc_jit_context_new_global): Likewise. | |
755 | (gcc_jit_function_new_local): Likewise. | |
756 | (gcc_jit_type_get_aligned): Likewise. | |
757 | ||
63b2923d A |
758 | 2020-03-31 Andrea Corallo <andrea.corallo@arm.com> |
759 | David Malcolm <dmalcolm@redhat.com> | |
760 | ||
761 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_13): New ABI tag | |
762 | plus add version paragraph. | |
763 | * libgccjit++.h (namespace gccjit::version): Add new namespace. | |
764 | * libgccjit.c (gcc_jit_version_major, gcc_jit_version_minor) | |
765 | (gcc_jit_version_patchlevel): New functions. | |
766 | * libgccjit.h (LIBGCCJIT_HAVE_gcc_jit_version): New macro. | |
767 | (gcc_jit_version_major, gcc_jit_version_minor) | |
768 | (gcc_jit_version_patchlevel): New functions. | |
769 | * libgccjit.map (LIBGCCJIT_ABI_13) New ABI tag. | |
770 | ||
0cd55f9d A |
771 | 2020-03-23 Andrea Corallo <andrea.corallo@arm.com> |
772 | ||
773 | * jit-playback.h | |
774 | (gcc::jit::playback::context m_recording_ctxt): Remove | |
775 | m_char_array_type_node field. | |
776 | * jit-playback.c | |
777 | (playback::context::context) Remove m_char_array_type_node from member | |
778 | initializer list. | |
779 | (playback::context::new_string_literal) Fix logic to handle string | |
780 | length > 200. | |
781 | ||
8d9254fc JJ |
782 | 2020-01-01 Jakub Jelinek <jakub@redhat.com> |
783 | ||
784 | Update copyright years. | |
785 | ||
70ce1ab9 JB |
786 | 2019-11-29 Julian Brown <julian@codesourcery.com> |
787 | ||
788 | * jit-builtins.c (BT_DFLOAT32_PTR, BT_DFLOAT64_PTR, BT_DFLOAT128_PTR): | |
789 | Remove commented-out cases. | |
790 | ||
56e04525 DM |
791 | 2019-11-20 David Malcolm <dmalcolm@redhat.com> |
792 | ||
793 | PR jit/92483 | |
794 | * jit-playback.c (gcc::jit::playback::context::make_fake_args): | |
795 | Update GCC_JIT_BOOL_OPTION_SELFCHECK_GC for new --param syntax. | |
796 | ||
4d732405 RS |
797 | 2019-08-13 Richard Sandiford <richard.sandiford@arm.com> |
798 | ||
799 | PR middle-end/91421 | |
800 | * jit-playback.c (new_function): Use set_decl_built_in_function. | |
801 | ||
ab20d992 | 802 | 2019-07-22 Andrea Corallo <andrea.corallo@arm.com> |
9afb91b2 AC |
803 | |
804 | * jit-recording.c (unary_op_reproducer_strings): Make it extern. | |
805 | (binary_op_reproducer_strings): Likewise. | |
806 | * jit-recording.h (unary_op_reproducer_strings): Likewise. | |
807 | (binary_op_reproducer_strings): Likewise. | |
808 | * libgccjit.c (gcc_jit_context_new_unary_op): Check result_type to be a | |
809 | numeric type. | |
810 | * libgccjit.c (gcc_jit_context_new_binary_op): Improve error message. | |
811 | ||
ab20d992 | 812 | 2019-07-04 Andrea Corallo <andrea.corallo@arm.com> |
2b442504 AC |
813 | |
814 | * libgccjit.c (gcc_jit_context_new_binary_op): Check result_type to be a | |
815 | numeric type. | |
816 | ||
ab20d992 | 817 | 2019-07-04 Andrea Corallo <andrea.corallo@arm.com> |
ee118c14 AC |
818 | |
819 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_12): New ABI tag. | |
820 | * docs/topics/types.rst: Add gcc_jit_context_new_bitfield. | |
821 | * jit-common.h (namespace recording): Add class bitfield. | |
822 | * jit-playback.c: | |
823 | (DECL_C_BIT_FIELD, SET_DECL_C_BIT_FIELD): Add macros. | |
824 | (playback::context::new_bitfield): New method. | |
825 | (playback::compound_type::set_fields): Add bitfield support. | |
826 | (playback::lvalue::mark_addressable): Was jit_mark_addressable make this | |
827 | a method of lvalue plus return a bool to communicate success. | |
828 | (playback::lvalue::get_address): Check for jit_mark_addressable return | |
829 | value. | |
830 | * jit-playback.h (new_bitfield): New method. | |
831 | (class bitfield): New class. | |
832 | (class lvalue): Add jit_mark_addressable method. | |
833 | * jit-recording.c (recording::context::new_bitfield): New method. | |
834 | (recording::bitfield::replay_into): New method. | |
835 | (recording::bitfield::write_to_dump): Likewise. | |
836 | (recording::bitfield::make_debug_string): Likewise. | |
837 | (recording::bitfield::write_reproducer): Likewise. | |
838 | * jit-recording.h (class context): Add new_bitfield method. | |
839 | (class field): Make it derivable by class bitfield. | |
840 | (class bitfield): Add new class. | |
841 | * libgccjit++.h (class context): Add new_bitfield method. | |
842 | * libgccjit.c (struct gcc_jit_bitfield): New structure. | |
843 | (gcc_jit_context_new_bitfield): New function. | |
844 | * libgccjit.h | |
845 | (LIBGCCJIT_HAVE_gcc_jit_context_new_bitfield) New macro. | |
846 | (gcc_jit_context_new_bitfield): New function. | |
847 | * libgccjit.map (LIBGCCJIT_ABI_12) New ABI tag. | |
848 | ||
36a3a7a3 JJ |
849 | 2019-03-21 Jakub Jelinek <jakub@redhat.com> |
850 | ||
851 | * jit-recording.c (reproducer::m_set_identifiers): Use false as Lazy | |
852 | in hash_set template param. | |
853 | ||
ab20d992 | 854 | 2019-02-05 Andrea Corallo <andrea.corallo@arm.com> |
216090cc AC |
855 | |
856 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_11): New ABI tag. | |
857 | * docs/topics/contexts.rst (Additional driver options): New | |
858 | section. | |
859 | * jit-playback.c (invoke_driver): Add call to append_driver_options. | |
860 | * jit-recording.c: Within namespace gcc::jit... | |
861 | (recording::context::~context): Free the optnames within | |
862 | m_driver_options. | |
863 | (recording::context::add_driver_option): New method. | |
864 | (recording::context::append_driver_options): New method. | |
865 | (recording::context::dump_reproducer_to_file): Add driver | |
866 | options. | |
867 | * jit-recording.h: Within namespace gcc::jit... | |
868 | (recording::context::add_driver_option): New method. | |
869 | (recording::context::append_driver_options): New method. | |
870 | (recording::context::m_driver_options): New field. | |
871 | * libgccjit++.h (gccjit::context::add_driver_option): New | |
872 | method. | |
873 | * libgccjit.c (gcc_jit_context_add_driver_option): New API | |
874 | entrypoint. | |
875 | * libgccjit.h (gcc_jit_context_add_driver_option): New API | |
876 | entrypoint. | |
877 | (LIBGCCJIT_HAVE_gcc_jit_context_add_driver_option): New | |
878 | macro. | |
879 | * libgccjit.map (LIBGCCJIT_ABI_11): New ABI tag. | |
880 | ||
a5544970 JJ |
881 | 2019-01-01 Jakub Jelinek <jakub@redhat.com> |
882 | ||
883 | Update copyright years. | |
884 | ||
478dd60d DM |
885 | 2018-11-15 David Malcolm <dmalcolm@redhat.com> |
886 | ||
887 | PR other/19165 | |
888 | * dummy-frontend.c (jit_begin_diagnostic): Add diagnostic_t param. | |
889 | ||
620e594b DM |
890 | 2018-11-13 David Malcolm <dmalcolm@redhat.com> |
891 | ||
892 | * jit-playback.c: Replace "source_location" with "location_t". | |
893 | ||
033eb567 DM |
894 | 2018-10-17 David Malcolm <dmalcolm@redhat.com> |
895 | ||
896 | * Make-lang.in (selftest-jit): New. | |
897 | ||
98086b2b ML |
898 | 2018-06-28 Martin Liska <mliska@suse.cz> |
899 | ||
900 | * jit-playback.c: Include opt-suggestions.h. | |
901 | ||
3de37a5d ML |
902 | 2018-06-28 Martin Liska <mliska@suse.cz> |
903 | ||
904 | * jit-playback.c (class auto_argvec): Moved to vec.h. | |
905 | (auto_argvec::~auto_argvec): Likewise. | |
906 | (compile): Use the renamed name. | |
907 | (invoke_driver): Likewise. | |
908 | ||
ea143da7 RO |
909 | 2018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> |
910 | ||
911 | PR jit/84288 | |
912 | * Make-lang.in ($(LIBGCCJIT_FILENAME)): Add $(EXTRA_GCC_LIBS). | |
913 | ||
deb3da39 DM |
914 | 2018-03-09 David Malcolm <dmalcolm@redhat.com> |
915 | Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> | |
916 | ||
917 | PR jit/64089 | |
918 | PR jit/84288 | |
919 | * Make-lang.in (COMMA): New. | |
920 | (LIBGCCJIT_VERSION_SCRIPT_OPTION): New. | |
921 | (LIBGCCJIT_SONAME_OPTION): New. | |
922 | (jit): Move --version-script and -soname linker options to the | |
923 | above. | |
924 | ||
9aba6f77 DM |
925 | 2018-01-25 David Malcolm <dmalcolm@redhat.com> |
926 | ||
927 | PR jit/81672 | |
928 | * jit-recording.h (gcc::jit::recording::union_): Remove fields | |
929 | "m_loc" and "m_name". | |
930 | ||
85ec4feb JJ |
931 | 2018-01-03 Jakub Jelinek <jakub@redhat.com> |
932 | ||
933 | Update copyright years. | |
934 | ||
01512446 JJ |
935 | 2017-12-19 Jakub Jelinek <jakub@redhat.com> |
936 | ||
937 | * jit-playback.c (get_type, playback::compile_to_file::copy_file, | |
938 | playback::context::acquire_mutex): Replace Yoda conditions with | |
939 | typical order conditions. | |
940 | * libgccjit.c (gcc_jit_context_new_struct_type, | |
941 | gcc_jit_struct_set_fields, gcc_jit_context_new_union_type, | |
942 | gcc_jit_context_new_function, gcc_jit_timer_pop): Likewise. | |
943 | * jit-builtins.c (matches_builtin): Likewise. | |
944 | * jit-recording.c (recording::compound_type::set_fields, | |
945 | recording::fields::write_reproducer, recording::rvalue::set_scope, | |
946 | recording::function::validate): Likewise. | |
947 | * jit-logging.c (logger::decref): Likewise. | |
948 | ||
5de73c05 JJ |
949 | 2017-11-30 Jakub Jelinek <jakub@redhat.com> |
950 | ||
951 | * jit-recording.c | |
952 | (recording::memento_of_new_rvalue_from_const <long>::write_reproducer): | |
953 | Use ; instead of ;;. | |
954 | ||
9e851845 JJ |
955 | 2017-11-28 Jakub Jelinek <jakub@redhat.com> |
956 | ||
957 | * jit-playback.c (add_switch): Build SWITCH_EXPR using build2 instead | |
958 | of build3. Formatting fixes. Adjust funciton comment. | |
959 | ||
120e92fc TV |
960 | 2017-11-23 Tom de Vries <tom@codesourcery.com> |
961 | ||
962 | * libgccjit.c (RETURN_NULL_IF_FAIL_NONNULL_NUMERIC_TYPE): Wrap in | |
963 | JIT_{BEGIN,END}_STMT. | |
964 | ||
77f4ead7 DM |
965 | 2017-10-31 David Malcolm <dmalcolm@redhat.com> |
966 | ||
967 | * docs/internals/index.rst (Running the test suite): Document | |
968 | PRESERVE_EXECUTABLES. | |
969 | (Running under valgrind): Add markup to RUN_UNDER_VALGRIND. | |
970 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
971 | ||
6069fe72 DM |
972 | 2017-10-04 David Malcolm <dmalcolm@redhat.com> |
973 | ||
974 | * docs/cp/topics/expressions.rst (Vector expressions): New | |
975 | section. | |
976 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_10): New ABI tag. | |
977 | * docs/topics/expressions.rst (Vector expressions): New section. | |
978 | * docs/topics/types.rst (gcc_jit_type_get_vector): Add link to | |
979 | gcc_jit_context_new_rvalue_from_vector. | |
980 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
981 | * jit-common.h (gcc::jit:recording::vector_type): New forward | |
982 | decl. | |
983 | * jit-playback.c | |
984 | (gcc::jit::playback::context::new_rvalue_from_vector): New method. | |
985 | * jit-playback.h | |
986 | (gcc::jit::playback::context::new_rvalue_from_vector): New method. | |
987 | * jit-recording.c: In namespace gcc::jit:: | |
988 | (class comma_separated_string): New class. | |
989 | (comma_separated_string::comma_separated_string): New ctor, | |
990 | adapted from recording::call::make_debug_string. | |
991 | (comma_separated_string::~comma_separated_string): New dtor. | |
992 | In namespace gcc::jit::recording:: | |
993 | (context::new_rvalue_from_vector): New method. | |
994 | (type::get_vector): Update for renaming of memento_of_get_vector. | |
995 | (class memento_of_get_vector): Rename to... | |
996 | (class vector_type): ..this. | |
997 | (memento_of_new_rvalue_from_vector::memento_of_new_rvalue_from_vector): | |
998 | New ctor. | |
999 | (memento_of_new_rvalue_from_vector::replay_into): New method. | |
1000 | (memento_of_new_rvalue_from_vector::visit_children): New method. | |
1001 | (memento_of_new_rvalue_from_vector::make_debug_string): New | |
1002 | method. | |
1003 | (memento_of_new_rvalue_from_vector::write_reproducer): New method. | |
1004 | (call::make_debug_string): Split out arg-printing code into ctor | |
1005 | for comma_separated_string. | |
1006 | * jit-recording.h: In namespace gcc::jit::recording:: | |
1007 | (context::new_rvalue_from_vector): New method. | |
1008 | (type::dyn_cast_vector_type): New virtual function. | |
1009 | (class memento_of_get_vector): Rename to... | |
1010 | (class vector_type): ...this. | |
1011 | (vector_type::unqualified): Remove this vfunc override in favor | |
1012 | of... | |
1013 | (vector_type::get_element_type): ...this new method. | |
1014 | (vector_type::get_num_units): New method. | |
1015 | (vector_type::dyn_cast_vector_type): New vfunc override. | |
1016 | (class memento_of_new_rvalue_from_vector): New class. | |
1017 | * libgccjit++.h (gccjit::context::new_rvalue): Add overload for | |
1018 | vector of rvalue. | |
1019 | * libgccjit.c (gcc_jit_context_new_binary_op): Strip off type | |
1020 | qualifications when checking that both operands have same type. | |
1021 | (gcc_jit_context_new_rvalue_from_vector): New API entrypoint. | |
1022 | * libgccjit.h | |
1023 | (LIBGCCJIT_HAVE_gcc_jit_context_new_rvalue_from_vector): New | |
1024 | macro. | |
1025 | (gcc_jit_context_new_rvalue_from_vector): New API entrypoint. | |
1026 | * libgccjit.map (LIBGCCJIT_ABI_10): New ABI tag. | |
1027 | ||
ecd5156d DM |
1028 | 2017-09-28 David Malcolm <dmalcolm@redhat.com> |
1029 | ||
1030 | * docs/topics/expressions.rst (Function calls): Add link to | |
1031 | gcc_jit_context_new_function_ptr_type. | |
1032 | (Function pointers): Convert to cross-references to | |
1033 | function-pointers.rst, moving material there. | |
1034 | * docs/topics/function-pointers.rst: New page. | |
1035 | * docs/topics/index.rst: Add function-pointers.rst. | |
1036 | * docs/topics/types.rst (Function pointer types): New section. | |
1037 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1038 | ||
5a47aa2c DM |
1039 | 2017-09-28 David Malcolm <dmalcolm@redhat.com> |
1040 | ||
1041 | * jit-recording.c | |
1042 | (gcc::jit::recording::function_type::is_same_type_as): New function. | |
1043 | * jit-recording.h: In namespace gcc::jit::recording:: | |
1044 | (type::accepts_writes_from): Use is_same_type_as rather than pointer | |
1045 | equality. | |
1046 | (type::is_same_type_as): New virtual function. | |
1047 | (function_type::is_same_type_as): New override. | |
1048 | ||
15a65e63 DM |
1049 | 2017-09-27 David Malcolm <dmalcolm@redhat.com> |
1050 | ||
1051 | * docs/cp/topics/expressions.rst (Function pointers): New section. | |
1052 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_9): New tag. | |
1053 | * docs/topics/expressions.rst (Function pointers): New section. | |
1054 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1055 | * jit-common.h (class gcc::jit::recording::function_pointer): New | |
1056 | forward decl. | |
1057 | * jit-playback.c (gcc::jit::playback::function::get_address): New | |
1058 | method. | |
1059 | * jit-playback.h (gcc::jit::playback::function::get_address): New | |
1060 | method decl. | |
1061 | * jit-recording.c: Within namespace gcc::jit::recording... | |
1062 | (function::function): Initialize new field "m_fn_ptr_type". | |
1063 | (function::get_address): New method. | |
1064 | (function_pointer::replay_into): New method. | |
1065 | (function_pointer::visit_children): New method. | |
1066 | (function_pointer::make_debug_string): New method. | |
1067 | (function_pointer::write_reproducer): New method. | |
1068 | * jit-recording.h: Within namespace gcc::jit::recording... | |
1069 | (function::get_address): New method. | |
1070 | (function): Add field "m_fn_ptr_type". | |
1071 | (class function_pointer): New subclass of rvalue. | |
1072 | * libgccjit++.h (gccjit::function::get_address): New method. | |
1073 | * libgccjit.c (gcc_jit_function_get_address): New function. | |
1074 | * libgccjit.h (LIBGCCJIT_HAVE_gcc_jit_function_get_address): New | |
1075 | macro. | |
1076 | (gcc_jit_function_get_address): New API entrypoint. | |
1077 | * libgccjit.map (LIBGCCJIT_ABI_9): New tag. | |
1078 | ||
595ced60 DM |
1079 | 2017-09-14 David Malcolm <dmalcolm@redhat.com> |
1080 | ||
1081 | PR jit/82174 | |
1082 | * jit-builtins.c (matches_builtin): Ignore entries with a NULL | |
1083 | name. | |
1084 | ||
953e520d DM |
1085 | 2017-08-18 David Malcolm <dmalcolm@redhat.com> |
1086 | ||
1087 | PR tree-optimization/46805 | |
1088 | * dummy-frontend.c (jit_langhook_parse_file): Handle vector types. | |
1089 | ||
519d0798 DM |
1090 | 2017-08-18 David Malcolm <dmalcolm@redhat.com> |
1091 | ||
1092 | * jit-recording.c (class gcc::jit::reproducer): Rename field | |
1093 | "m_identifiers" to "m_map_memento_to_identifier". Add field | |
1094 | "m_set_identifiers" and struct hash_traits for it. | |
1095 | (gcc::jit::reproducer::reproducer): Update for above. | |
1096 | (convert_to_identifier): New function. | |
1097 | (gcc::jit::reproducer::ensure_identifier_is_unique): New method. | |
1098 | (gcc::jit::reproducer::make_identifier): Avoid appending the %p | |
1099 | unless necessary for uniqueness. Update for field renaming. | |
1100 | (gcc::jit::reproducer::get_identifier): Update for field renaming. | |
1101 | ||
47ee1b7c DM |
1102 | 2017-08-09 David Malcolm <dmalcolm@redhat.com> |
1103 | ||
1104 | * docs/cp/topics/types.rst (Vector types): New section. | |
1105 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_8): New tag. | |
1106 | * docs/topics/types.rst (gcc_jit_context_get_type): Fix typo in | |
1107 | example. | |
1108 | (Vector types): New section. | |
1109 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1110 | * jit-playback.c (gcc::jit::playback::type::get_vector): New | |
1111 | method. | |
1112 | * jit-playback.h (gcc::jit::playback::type::get_vector): New | |
1113 | method. | |
1114 | * jit-recording.c: In namespace gcc::jit::recording:: | |
1115 | (type::get_vector): New method. | |
1116 | (memento_of_get_aligned::write_reproducer): Fix typo | |
1117 | in leading comment. | |
1118 | (memento_of_get_vector::replay_into): New method. | |
1119 | (memento_of_get_vector::make_debug_string): New method. | |
1120 | (memento_of_get_vector::write_reproducer): New method. | |
1121 | * jit-recording.h: In namespace gcc::jit::recording:: | |
1122 | (type::get_vector): New | |
1123 | method. | |
1124 | (class memento_of_get_vector): New class. | |
1125 | * libgccjit++.h (gccjit::type::get_vector): New method. | |
1126 | * libgccjit.c (gcc_jit_type_get_vector): New public entrypoint. | |
1127 | * libgccjit.h (LIBGCCJIT_HAVE_gcc_jit_type_get_vector): New | |
1128 | define. | |
1129 | (gcc_jit_type_get_vector): New decl. | |
1130 | * libgccjit.map (LIBGCCJIT_ABI_8): New ABI tag. | |
1131 | ||
b8506a8a RS |
1132 | 2017-07-05 Richard Sandiford <richard.sandiford@linaro.org> |
1133 | Alan Hayward <alan.hayward@arm.com> | |
1134 | David Sherwood <david.sherwood@arm.com> | |
1135 | ||
1136 | * dummy-frontend.c (jit_langhook_type_for_mode): Remove "enum" before | |
1137 | "machine_mode". | |
1138 | ||
0ebd1f00 DM |
1139 | 2017-04-24 David Malcolm <dmalcolm@redhat.com> |
1140 | ||
1141 | * docs/cp/topics/types.rst (gccjit::type::get_const): Remove | |
1142 | comment. | |
1143 | (gccjit::type::get_aligned): Add. | |
1144 | * docs/topics/compatibility.rst: Add LIBGCCJIT_ABI_7. | |
1145 | * docs/topics/types.rst: Add gcc_jit_type_get_aligned. | |
1146 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1147 | * jit-playback.c (gcc::jit::playback::type::get_aligned): New | |
1148 | method. | |
1149 | * jit-playback.h (gcc::jit::playback::type::get_aligned): New | |
1150 | method. | |
1151 | * jit-recording.c: Within namespace gcc::jit::recording... | |
1152 | (type::get_aligned): New method. | |
1153 | (memento_of_get_aligned::replay_into): New method. | |
1154 | (memento_of_get_aligned::make_debug_string): New method. | |
1155 | (memento_of_get_aligned::write_reproducer): New method. | |
1156 | * jit-recording.h: Within namespace gcc::jit::recording... | |
1157 | (type::get_aligned): New method. | |
1158 | (type::accepts_writes_from): Strip off qualifications from | |
1159 | this when comparing pointer equality. | |
1160 | (decorated_type): New subclass of type, subsuming the | |
1161 | commonality between memento_of_get_const and | |
1162 | memento_of_get_volatile. | |
1163 | (memento_of_get_const): Make a subclass of decorated_type, | |
1164 | rather than type. | |
1165 | (memento_of_get_volatile): Likewise. | |
1166 | (memento_of_get_aligned): Likewise. | |
1167 | * libgccjit++.h: Within namespace gccjit... | |
1168 | (type::get_const): New method. | |
1169 | (type::get_aligned): New method. | |
1170 | * libgccjit.c (gcc_jit_type_get_aligned): New function. | |
1171 | * libgccjit.h (gcc_jit_type_get_aligned): New decl. | |
1172 | * libgccjit.map (LIBGCCJIT_ABI_7): New | |
1173 | (gcc_jit_type_get_aligned): Add. | |
1174 | ||
8a3a6ab4 DM |
1175 | 2017-01-19 David Malcolm <dmalcolm@redhat.com> |
1176 | ||
1177 | * dummy-frontend.c (jit_langhook_type_for_size): Delete. | |
1178 | (LANG_HOOKS_TYPE_FOR_SIZE): Don't redefine. | |
1179 | ||
b37589b0 DM |
1180 | 2017-01-18 David Malcolm <dmalcolm@redhat.com> |
1181 | ||
1182 | * dummy-frontend.c (jit_langhook_type_for_size): Implement, using | |
1183 | lto's lto_type_for_size. | |
1184 | ||
cbe34bb5 JJ |
1185 | 2017-01-01 Jakub Jelinek <jakub@redhat.com> |
1186 | ||
1187 | Update copyright years. | |
1188 | ||
15c671a7 DM |
1189 | 2016-05-20 David Malcolm <dmalcolm@redhat.com> |
1190 | ||
1191 | * docs/topics/compatibility.rst: Add LIBGCCJIT_ABI_6. | |
1192 | * docs/topics/expressions.rst (Function calls): Add documentation | |
1193 | of gcc_jit_rvalue_set_bool_require_tail_call. | |
1194 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1195 | * jit-common.h (gcc::jit::recording::base_call): Add forward decl. | |
1196 | * jit-playback.c: Within namespace gcc::jit::playback... | |
1197 | (context::build_call) Add "require_tail_call" param and use it | |
1198 | to set CALL_EXPR_MUST_TAIL_CALL. | |
1199 | (context::new_call): Add "require_tail_call" param. | |
1200 | (context::new_call_through_ptr): Likewise. | |
1201 | * jit-playback.h: Within namespace gcc::jit::playback... | |
1202 | (context::new_call: Add "require_tail_call" param. | |
1203 | (context::new_call_through_ptr): Likewise. | |
1204 | (context::build_call): Likewise. | |
1205 | * jit-recording.c: Within namespace gcc::jit::recording... | |
1206 | (base_call::base_call): New constructor. | |
1207 | (base_call::write_reproducer_tail_call): New method. | |
1208 | (call::call): Update for inheritance from base_call. | |
1209 | (call::replay_into): Provide m_require_tail_call to call | |
1210 | to new_call. | |
1211 | (call::write_reproducer): Call write_reproducer_tail_call. | |
1212 | (call_through_ptr::call_through_ptr): Update for inheritance from | |
1213 | base_call. | |
1214 | (call_through_ptr::replay_into): Provide m_require_tail_call to call | |
1215 | to new_call_through_ptr. | |
1216 | (recording::call_through_ptr::write_reproducer): Call | |
1217 | write_reproducer_tail_call. | |
1218 | * jit-recording.h: Within namespace gcc::jit::recording... | |
1219 | (rvalue::dyn_cast_base_call): New virtual function. | |
1220 | (class base_call): New subclass of class rvalue. | |
1221 | (class call): Inherit from base_call rather than directly from | |
1222 | rvalue, moving get_precedence and m_args to base_call. | |
1223 | (class call_through_ptr): Likewise. | |
1224 | * libgccjit.c (gcc_jit_rvalue_set_bool_require_tail_call): New | |
1225 | function. | |
1226 | * libgccjit.h | |
1227 | (LIBGCCJIT_HAVE_gcc_jit_rvalue_set_bool_require_tail_call): New | |
1228 | macro. | |
1229 | (gcc_jit_rvalue_set_bool_require_tail_call): New function. | |
1230 | * libgccjit.map (LIBGCCJIT_ABI_6): New. | |
1231 | (gcc_jit_rvalue_set_bool_require_tail_call): Add. | |
1232 | ||
6b5423a5 DM |
1233 | 2016-05-17 David Malcolm <dmalcolm@redhat.com> |
1234 | ||
1235 | * dummy-frontend.c: Include diagnostic.h. | |
1236 | (jit_begin_diagnostic): New function. | |
1237 | (jit_end_diagnostic): New function. | |
1238 | (jit_langhook_init): Register jit_begin_diagnostic | |
1239 | and jit_end_diagnostic with the global_dc. | |
1240 | * jit-playback.c: Include diagnostic.h. | |
1241 | (gcc::jit::playback::context::add_diagnostic): New method. | |
1242 | * jit-playback.h (struct diagnostic_context): Add forward | |
1243 | declaration. | |
1244 | (gcc::jit::playback::context::add_diagnostic): New method. | |
1245 | ||
f51703a8 DM |
1246 | 2016-05-17 David Malcolm <dmalcolm@redhat.com> |
1247 | ||
1248 | * docs/topics/expressions.rst (Function calls): Document | |
1249 | gcc_jit_context_new_call_through_ptr. | |
1250 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1251 | ||
54ece5e2 DM |
1252 | 2016-05-13 David Malcolm <dmalcolm@redhat.com> |
1253 | ||
1254 | * jit-playback.h: Within namespace gcc:jit::playback... | |
1255 | (compile_to_memory::postprocess): Mark with FINAL OVERRIDE. | |
1256 | (compile_to_file::postprocess): Likewise. | |
1257 | (function::finalizer): Likewise. | |
1258 | (block::finalizer): Likewise. | |
1259 | (source_file::finalizer): Likewise. | |
1260 | (source_line::finalizer): Likewise. | |
1261 | * jit-recording.c (gcc::jit::rvalue_usage_validator):: Likewise. | |
1262 | * jit-recording.h: Within namespace gcc::jit::recording... | |
1263 | (string::replay_into): Mark with FINAL OVERRIDE. | |
1264 | (string::make_debug_string): Likewise. | |
1265 | (string::write_reproducer): Likewise. | |
1266 | (location::replay_into): Likewise. | |
1267 | (location::dyn_cast_location): Likewise. | |
1268 | (location::make_debug_string): Likewise. | |
1269 | (location::write_reproducer): Likewise. | |
1270 | (memento_of_get_type::dereference): Likewise. | |
1271 | (memento_of_get_type::accepts_writes_from): Likewise. | |
1272 | (memento_of_get_type::is_int): Likewise. | |
1273 | (memento_of_get_type::is_float): Likewise. | |
1274 | (memento_of_get_type::is_bool): Likewise. | |
1275 | (memento_of_get_type::is_pointer): Likewise. | |
1276 | (memento_of_get_type::is_array): Likewise. | |
1277 | (memento_of_get_type::is_void): Likewise. | |
1278 | (memento_of_get_type::replay_into): Likewise. | |
1279 | (memento_of_get_type::make_debug_string): Likewise. | |
1280 | (memento_of_get_type::write_reproducer): Likewise. | |
1281 | (memento_of_get_pointer::dereference): Likewise. | |
1282 | (memento_of_get_pointer::accepts_writes_from): Likewise. | |
1283 | (memento_of_get_pointer::replay_into): Likewise. | |
1284 | (memento_of_get_pointer::is_int): Likewise. | |
1285 | (memento_of_get_pointer::is_float): Likewise. | |
1286 | (memento_of_get_pointer::is_bool): Likewise. | |
1287 | (memento_of_get_pointer::is_pointer): Likewise. | |
1288 | (memento_of_get_pointer::is_array): Likewise. | |
1289 | (memento_of_get_pointer::make_debug_string): Likewise. | |
1290 | (memento_of_get_pointer::write_reproducer): Likewise. | |
1291 | (memento_of_get_const::dereference): Likewise. | |
1292 | (memento_of_get_const::accepts_writes_from): Likewise. | |
1293 | (memento_of_get_const::unqualified): Likewise. | |
1294 | (memento_of_get_const::is_int): Likewise. | |
1295 | (memento_of_get_const::is_float): Likewise. | |
1296 | (memento_of_get_const::is_bool): Likewise. | |
1297 | (memento_of_get_const::is_pointer): Likewise. | |
1298 | (memento_of_get_const::is_array): Likewise. | |
1299 | (memento_of_get_const::void replay_into): Likewise; | |
1300 | (memento_of_get_const::make_debug_string): Likewise. | |
1301 | (memento_of_get_const::write_reproducer): Likewise. | |
1302 | (memento_of_get_volatile::dereference): Likewise. | |
1303 | (memento_of_get_volatile::unqualified): Likewise. | |
1304 | (memento_of_get_volatile::is_int): Likewise. | |
1305 | (memento_of_get_volatile::is_float): Likewise. | |
1306 | (memento_of_get_volatile::is_bool): Likewise. | |
1307 | (memento_of_get_volatile::is_pointer): Likewise. | |
1308 | (memento_of_get_volatile::is_array): Likewise. | |
1309 | (memento_of_get_volatile::replay_into): Likewise; | |
1310 | (memento_of_get_volatile::make_debug_string): Likewise. | |
1311 | (memento_of_get_volatile::write_reproducer): Likewise. | |
1312 | (array_type::dereference): Likewise. | |
1313 | (array_type::is_int): Likewise. | |
1314 | (array_type::is_float): Likewise. | |
1315 | (array_type::is_bool): Likewise. | |
1316 | (array_type::is_pointer): Likewise. | |
1317 | (array_type::is_array): Likewise. | |
1318 | (array_type::replay_into): Likewise; | |
1319 | (array_type::make_debug_string): Likewise. | |
1320 | (array_type::write_reproducer): Likewise. | |
1321 | (function_type::dereference): Likewise. | |
1322 | (function_type::function_dyn_cast_function_type): Likewise. | |
1323 | (function_type::function_as_a_function_type): Likewise. | |
1324 | (function_type::is_int): Likewise. | |
1325 | (function_type::is_float): Likewise. | |
1326 | (function_type::is_bool): Likewise. | |
1327 | (function_type::is_pointer): Likewise. | |
1328 | (function_type::is_array): Likewise. | |
1329 | (function_type::replay_into): Likewise; | |
1330 | (function_type::make_debug_string): Likewise. | |
1331 | (function_type::write_reproducer): Likewise. | |
1332 | (field::replay_into): Likewise; | |
1333 | (field::write_to_dump): Likewise. | |
1334 | (field::make_debug_string): Likewise. | |
1335 | (field::write_reproducer): Likewise. | |
1336 | (compound_type::dereference): Likewise. | |
1337 | (compound_type::is_int): Likewise. | |
1338 | (compound_type::is_float): Likewise. | |
1339 | (compound_type::is_bool): Likewise. | |
1340 | (compound_type::is_pointer): Likewise. | |
1341 | (compound_type::is_array): Likewise. | |
1342 | (compound_type::has_known_size): Likewise. | |
1343 | (struct_::dyn_cast_struct): Likewise. | |
1344 | (struct_::replay_into): Likewise. | |
1345 | (struct_::access_as_type): Likewise. | |
1346 | (struct_::make_debug_string): Likewise. | |
1347 | (struct_::write_reproducer): Likewise. | |
1348 | (fields::replay_into): Likewise. | |
1349 | (fields::write_to_dump): Likewise. | |
1350 | (fields::make_debug_string): Likewise. | |
1351 | (fields::write_reproducer): Likewise. | |
1352 | (union_::replay_into): Likewise. | |
1353 | (union_::make_debug_string): Likewise. | |
1354 | (union_::write_reproducer): Likewise. | |
1355 | (lvalue::access_as_rvalue): Mark with OVERRIDE. | |
1356 | (param::replay_into): Mark with FINAL OVERRIDE. | |
1357 | (param::visit_children): Likewise. | |
1358 | (param::dyn_cast_param): Likewise. | |
1359 | (param::access_as_rvalue): Likewise. | |
1360 | (param::access_as_lvalue): Likewise. | |
1361 | (param::make_debug_string): Likewise. | |
1362 | (param::write_reproducer): Likewise. | |
1363 | (param::get_precedence): Likewise. | |
1364 | (function::replay_into): Likewise. | |
1365 | (function::write_to_dump): Likewise. | |
1366 | (function::make_debug_string): Likewise. | |
1367 | (function::write_reproducer): Likewise. | |
1368 | (block::write_to_dump): Likewise. | |
1369 | (block::make_debug_string): Likewise. | |
1370 | (block::write_reproducer): Likewise. | |
1371 | (block::replay_into): Likewise. | |
1372 | (global::replay_into): Likewise; | |
1373 | (global::visit_children): Likewise. | |
1374 | (global::write_to_dump): Likewise. | |
1375 | (global::make_debug_string): Likewise. | |
1376 | (global::write_reproducer): Likewise. | |
1377 | (global::get_precedence): Likewise. | |
1378 | (memento_of_new_rvalue_from_const::replay_into): Likewise. | |
1379 | (memento_of_new_rvalue_from_const::visit_children): Likewise. | |
1380 | (memento_of_new_rvalue_from_const::is_constant): Likewise. | |
1381 | (memento_of_new_rvalue_from_const::get_wide_int): Likewise. | |
1382 | (memento_of_new_rvalue_from_const::make_debug_string): Likewise. | |
1383 | (memento_of_new_rvalue_from_const::write_reproducer): Likewise. | |
1384 | (memento_of_new_rvalue_from_const::get_precedence): Likewise. | |
1385 | (memento_of_new_string_literal::replay_into): Likewise. | |
1386 | (memento_of_new_string_literal::visit_children): Likewise. | |
1387 | (memento_of_new_string_literal::make_debug_string): Likewise. | |
1388 | (memento_of_new_string_literal::write_reproducer): Likewise. | |
1389 | (memento_of_new_string_literal::get_precedence): Likewise. | |
1390 | (unary_op::replay_into): Likewise. | |
1391 | (unary_op::visit_children): Likewise. | |
1392 | (unary_op::make_debug_string): Likewise. | |
1393 | (unary_op::write_reproducer): Likewise. | |
1394 | (unary_op::get_precedence): Likewise. | |
1395 | (binary_op::replay_into): Likewise. | |
1396 | (binary_op::visit_children): Likewise. | |
1397 | (binary_op::make_debug_string): Likewise. | |
1398 | (binary_op::write_reproducer): Likewise. | |
1399 | (binary_op::get_precedence): Likewise. | |
1400 | (comparison::replay_into): Likewise. | |
1401 | (comparison::visit_children): Likewise. | |
1402 | (comparison::make_debug_string): Likewise. | |
1403 | (comparison::write_reproducer): Likewise. | |
1404 | (comparison::get_precedence): Likewise. | |
1405 | (cast::replay_into): Likewise. | |
1406 | (cast::visit_children): Likewise. | |
1407 | (cast::make_debug_string): Likewise. | |
1408 | (cast::write_reproducer): Likewise. | |
1409 | (cast::get_precedence): Likewise. | |
1410 | (call::replay_into): Likewise. | |
1411 | (call::visit_children): Likewise. | |
1412 | (call::make_debug_string): Likewise. | |
1413 | (call::write_reproducer): Likewise. | |
1414 | (call::get_precedence): Likewise. | |
1415 | (call_through_ptr::replay_into): Likewise. | |
1416 | (call_through_ptr::visit_children): Likewise. | |
1417 | (call_through_ptr::make_debug_string): Likewise. | |
1418 | (call_through_ptr::write_reproducer): Likewise. | |
1419 | (call_through_ptr::get_precedence): Likewise. | |
1420 | (array_access::replay_into): Likewise. | |
1421 | (array_access::visit_children): Likewise. | |
1422 | (array_access::make_debug_string): Likewise. | |
1423 | (array_access::write_reproducer): Likewise. | |
1424 | (array_access::get_precedence): Likewise. | |
1425 | (access_field_of_lvalue::replay_into): Likewise. | |
1426 | (access_field_of_lvalue::visit_children): Likewise. | |
1427 | (access_field_of_lvalue::make_debug_string): Likewise. | |
1428 | (access_field_of_lvalue::write_reproducer): Likewise. | |
1429 | (access_field_of_lvalue::get_precedence): Likewise. | |
1430 | (access_field_rvalue::replay_into): Likewise. | |
1431 | (access_field_rvalue::visit_children): Likewise. | |
1432 | (access_field_rvalue::make_debug_string): Likewise. | |
1433 | (access_field_rvalue::write_reproducer): Likewise. | |
1434 | (access_field_rvalue::get_precedence): Likewise. | |
1435 | (dereference_field_rvalue::replay_into): Likewise. | |
1436 | (dereference_field_rvalue::visit_children): Likewise. | |
1437 | (dereference_field_rvalue::make_debug_string): Likewise. | |
1438 | (dereference_field_rvalue::write_reproducer): Likewise. | |
1439 | (dereference_field_rvalue::get_precedence): Likewise. | |
1440 | (dereference_rvalue::replay_into): Likewise. | |
1441 | (dereference_rvalue::visit_children): Likewise. | |
1442 | (dereference_rvalue::make_debug_string): Likewise. | |
1443 | (dereference_rvalue::write_reproducer): Likewise. | |
1444 | (dereference_rvalue::get_precedence): Likewise. | |
1445 | (get_address_of_lvalue::replay_into): Likewise. | |
1446 | (get_address_of_lvalue::visit_children): Likewise. | |
1447 | (get_address_of_lvalue::make_debug_string): Likewise. | |
1448 | (get_address_of_lvalue::write_reproducer): Likewise. | |
1449 | (get_address_of_lvalue::get_precedence): Likewise. | |
1450 | (local::replay_into): Likewise. | |
1451 | (local::visit_children): Likewise. | |
1452 | (local::write_to_dump): Likewise. | |
1453 | (local::make_debug_string): Likewise. | |
1454 | (local::write_reproducer): Likewise. | |
1455 | (local::get_precedence): Likewise. | |
1456 | (statement::write_to_dump): Likewise. | |
1457 | (eval::replay_into): Likewise. | |
1458 | (eval::make_debug_string): Likewise. | |
1459 | (eval::write_reproducer): Likewise. | |
1460 | (assignment::replay_into): Likewise. | |
1461 | (assignment::make_debug_string): Likewise. | |
1462 | (assignment::write_reproducer): Likewise. | |
1463 | (assignment_op::replay_into): Likewise. | |
1464 | (assignment_op::make_debug_string): Likewise. | |
1465 | (assignment_op::write_reproducer): Likewise. | |
1466 | (comment::replay_into): Likewise. | |
1467 | (comment::make_debug_string): Likewise. | |
1468 | (comment::write_reproducer): Likewise. | |
1469 | (conditional::replay_into): Likewise. | |
1470 | (conditional::get_successor_blocks): Likewise. | |
1471 | (conditional::make_debug_string): Likewise. | |
1472 | (conditional::write_reproducer): Likewise. | |
1473 | (jump::replay_into): Likewise. | |
1474 | (jump::get_successor_blocks): Likewise. | |
1475 | (jump::make_debug_string): Likewise. | |
1476 | (jump::write_reproducer): Likewise. | |
1477 | (return_::replay_into): Likewise. | |
1478 | (return_::get_successor_blocks): Likewise. | |
1479 | (return_::make_debug_string): Likewise. | |
1480 | (return_::write_reproducer): Likewise. | |
1481 | (case_::replay_into): Likewise. | |
1482 | (case_::write_reproducer): Likewise. | |
1483 | (case_::make_debug_string): Likewise. | |
1484 | (switch_::replay_into): Likewise. | |
1485 | (switch_::get_successor_blocks): Likewise. | |
1486 | (switch_::make_debug_string): Likewise. | |
1487 | (switch_::write_reproducer): Likewise. | |
1488 | ||
f258ad62 DM |
1489 | 2016-02-08 David Malcolm <dmalcolm@redhat.com> |
1490 | ||
1491 | * dummy-frontend.c (jit_langhook_init): Remove | |
1492 | second argument to build_common_tree_nodes to | |
1493 | track r233218. | |
1494 | ||
1c652ccb IB |
1495 | 2016-01-23 Iain Buclaw <ibuclaw@gdcproject.org> |
1496 | ||
1497 | * jit-playback.c: Include pthread.h. | |
1498 | ||
199501ea DM |
1499 | 2016-01-19 David Malcolm <dmalcolm@redhat.com> |
1500 | ||
1501 | PR jit/69144 | |
1502 | * jit-playback.c (gcc::jit::playback::compile_to_file::postprocess): | |
1503 | Potentially add the temporary artifact to the tempdir's list of | |
1504 | tempfiles needing additional cleanup. | |
1505 | (gcc::jit::playback::context::extract_any_requested_dumps): Likewise | |
1506 | for the dumpfile. | |
1507 | * jit-tempdir.c (gcc::jit::tempdir::~tempdir): Clean up additional | |
1508 | tempfiles. | |
1509 | * jit-tempdir.h (gcc::jit::tempdir::add_temp_file): New method. | |
1510 | (gcc::jit::tempdir::m_tempfiles): New field. | |
1511 | * docs/cp/intro/tutorial04.rst: Update for changes to toyvm.cc. | |
1512 | * docs/examples/tut04-toyvm/toyvm.cc (class compilation_result): | |
1513 | New. | |
1514 | (toyvm_function::compile): Change return type from function ptr | |
1515 | to a compilation_result. | |
1516 | (toyvm_function::get_function_name): New accessor. | |
1517 | (toyvm_function::m_funcname): New field. | |
1518 | (get_function_name): Convert to... | |
1519 | (toyvm_function::make_function_name): ...this new method. | |
1520 | (toyvm_function::parse): Call make_function_name. | |
1521 | (toyvm_function::compile): Convert return type from function ptr | |
1522 | to a compilation_result. Use get_function_name. | |
1523 | (compilation_state::compile): Convert return type from | |
1524 | gcc_jit_result * to a compilation_result. | |
1525 | (test_script): Update for above changes, extracting the code from | |
1526 | the compilation_result. | |
1527 | (main): Likewise. | |
1528 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1529 | ||
818ab71a JJ |
1530 | 2016-01-04 Jakub Jelinek <jakub@redhat.com> |
1531 | ||
1532 | Update copyright years. | |
1533 | ||
69f293c9 AM |
1534 | 2015-11-11 Andrew MacLeod <amacleod@redhat.com> |
1535 | ||
1536 | * dummy-frontend.c: Remove unused header files. | |
1537 | * jit-builtins.c: Likewise. | |
1538 | * jit-playback.c: Likewise. | |
1539 | * jit-recording.c: Likewise. | |
1540 | * jit-spec.c: Likewise. | |
1541 | * libgccjit.c: Likewise. | |
1542 | ||
0aad0198 RS |
1543 | 2015-11-07 Richard Sandiford <richard.sandiford@arm.com> |
1544 | ||
1545 | * jit-builtins.c: Don't undef DEF_BUILTIN. | |
1546 | ||
2adfab87 AM |
1547 | 2015-10-29 Andrew MacLeod <amacleod@redhat.com> |
1548 | ||
1549 | * dummy-frontend.c: Reorder #include's and remove duplicates. | |
1550 | * jit-builtins.c: Likewise. | |
1551 | * jit-playback.c: Likewise. | |
1552 | * jit-recording.c: Likewise. | |
1553 | * libgccjit.c: Likewise. | |
1554 | ||
d9a6bd32 JJ |
1555 | 2015-10-13 Jakub Jelinek <jakub@redhat.com> |
1556 | ||
1557 | * jit-builtins.c (DEF_FUNCTION_TYPE_9, DEF_FUNCTION_TYPE_10, | |
1558 | DEF_FUNCTION_TYPE_11): Define. | |
1559 | * jit-builtins.h (DEF_FUNCTION_TYPE_9, DEF_FUNCTION_TYPE_10, | |
1560 | DEF_FUNCTION_TYPE_11): Define. | |
1561 | ||
fa83660d TS |
1562 | 2015-09-30 Thomas Schwinge <thomas@codesourcery.com> |
1563 | Ulrich Drepper <drepper@gmail.com> | |
1564 | ||
1565 | * jit-builtins.h: Undefine DEF_FUNCTION_TYPE_VAR_6 after use. | |
1566 | ||
20a44562 MK |
1567 | 2015-09-30 Matthias Klose <doko@ubuntu.com> |
1568 | ||
1569 | * jit-builtins.h Define DEF_FUNCTION_TYPE_VAR_6, | |
1570 | remove DEF_FUNCTION_TYPE_VAR_11. | |
1571 | * jit-builtins.c (builtins_manager::make_type): Define and handle | |
1572 | DEF_FUNCTION_TYPE_VAR_6, remove DEF_FUNCTION_TYPE_VAR_11. | |
1573 | ||
9376dd63 DM |
1574 | 2015-08-25 David Malcolm <dmalcolm@redhat.com> |
1575 | ||
1576 | * docs/cp/topics/contexts.rst | |
1577 | (gccjit::context::set_bool_use_external_driver): New. | |
1578 | * docs/internals/test-hello-world.exe.log.txt: Update. | |
1579 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_5): New. | |
1580 | * docs/topics/contexts.rst | |
1581 | (gcc_jit_context_set_bool_use_external_driver): New. | |
1582 | * jit-common.h (enum inner_bool_option): Add | |
1583 | INNER_BOOL_OPTION_USE_EXTERNAL_DRIVER. | |
1584 | * jit-playback.c (gcc_driver_name): New global. | |
1585 | (gcc:jit::playback::context::invoke_driver): Split out second | |
1586 | half into... | |
1587 | (gcc::jit::playback::context::invoke_embedded_driver): ...this new | |
1588 | function, and... | |
1589 | (gcc::jit::playback::context::invoke_external_driver): ...this new | |
1590 | function. | |
1591 | * jit-playback.h | |
1592 | (gcc::jit::playback::context::get_inner_bool_option): New. | |
1593 | (gcc::jit::playback::context::invoke_embedded_driver): New. | |
1594 | (gcc::jit::playback::context::invoke_external_driver): New. | |
1595 | * jit-recording.c (inner_bool_option_reproducer_strings): | |
1596 | Add entry for INNER_BOOL_OPTION_USE_EXTERNAL_DRIVER. | |
1597 | * libgccjit++.h | |
1598 | (gccjit::context::set_bool_use_external_driver): New. | |
1599 | * libgccjit.c (gcc_jit_context_set_bool_use_external_driver): New. | |
1600 | * libgccjit.h (gcc_jit_context_set_bool_use_external_driver): New. | |
1601 | (LIBGCCJIT_HAVE_gcc_jit_context_set_bool_use_external_driver): | |
1602 | New. | |
1603 | * libgccjit.map (LIBGCCJIT_ABI_5): New. | |
1604 | * notes.txt: Show invocation of embedded copy of driver. | |
1605 | * docs/internals/test-hello-world.exe.log.txt: Update | |
1606 | ||
baf3fbad DM |
1607 | 2015-08-13 David Malcolm <dmalcolm@redhat.com> |
1608 | ||
1609 | * jit-playback.c (invoke_driver): On OS X, add | |
1610 | "-Wl,-undefined,dynamic_lookup" to the driver arguments. | |
1611 | ||
afed3459 DM |
1612 | 2015-08-03 David Malcolm <dmalcolm@redhat.com> |
1613 | ||
1614 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_4): New. | |
1615 | * docs/topics/contexts.rst (GCC_JIT_BOOL_OPTION_DUMP_SUMMARY): | |
1616 | We no longer show a profile. | |
1617 | * docs/topics/index.rst (Topic Reference): Add performance.rst. | |
1618 | * docs/topics/performance.rst: New file. | |
1619 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1620 | * jit-playback.c (gcc::jit::playback::context::compile): Add timer | |
1621 | param when constructing the "toplev" instance. | |
1622 | (gcc::jit::playback::context::acquire_mutex): Add timer param when | |
1623 | constructing auto_timevar instance. | |
1624 | (gcc::jit::playback::context::make_fake_args): If we have a timer, | |
1625 | add "-ftime-report". | |
1626 | (gcc::jit::playback::context::invoke_driver): Add timer param when | |
1627 | constructing auto_timevar instance. | |
1628 | (gcc::jit::playback::context::dlopen_built_dso): Likewise. | |
1629 | * jit-playback.h (gcc::jit::playback::context::get_timer): New accessor. | |
1630 | * jit-recording.c: Include timevar.h. | |
1631 | (gcc::jit::recording::context::context): Initialize field "m_timer". | |
1632 | * jit-recording.h: Add forward declaration of class timer. | |
1633 | (gcc::jit::recording::context::set_timer): New method. | |
1634 | (gcc::jit::recording::context::get_timer): New method. | |
1635 | (gcc::jit::recording::context::m_timer): New field. | |
1636 | * libgccjit++.h (gccjit::timer): New class. | |
1637 | (gccjit::auto_time): New class. | |
1638 | (gccjit::context::set_timer): New method. | |
1639 | (gccjit::context::get_timer): New. | |
1640 | (gccjit::timer::timer): New. | |
1641 | (gccjit::timer::push): New. | |
1642 | (gccjit::timer::pop): New. | |
1643 | (timer::print): New. | |
1644 | (timer::get_inner_timer): New. | |
1645 | (timer::release): New. | |
1646 | (auto_time::auto_time): New. | |
1647 | (auto_time::~auto_time): New. | |
1648 | * libgccjit.c: Include timevar.h. | |
1649 | (struct gcc_jit_timer): New. | |
1650 | (gcc_jit_timer_new): New function. | |
1651 | (gcc_jit_timer_release): New function. | |
1652 | (gcc_jit_context_set_timer): New function. | |
1653 | (gcc_jit_context_get_timer): New function. | |
1654 | (gcc_jit_timer_push): New function. | |
1655 | (gcc_jit_timer_pop): New function. | |
1656 | (gcc_jit_timer_print): New function. | |
1657 | * libgccjit.h (LIBGCCJIT_HAVE_TIMING_API): New macro. | |
1658 | (gcc_jit_timer): New typedef. | |
1659 | (gcc_jit_timer_new): New function. | |
1660 | (gcc_jit_timer_release): New function. | |
1661 | (gcc_jit_context_set_timer): New function. | |
1662 | (gcc_jit_context_get_timer): New function. | |
1663 | (gcc_jit_timer_push): New function. | |
1664 | (gcc_jit_timer_pop): New function. | |
1665 | (gcc_jit_timer_print): New function. | |
1666 | * libgccjit.map (LIBGCCJIT_ABI_4): New. | |
1667 | (gcc_jit_timer_new): New function. | |
1668 | (gcc_jit_timer_release): New function. | |
1669 | (gcc_jit_context_set_timer): New function. | |
1670 | (gcc_jit_context_get_timer): New function. | |
1671 | (gcc_jit_timer_push): New function. | |
1672 | (gcc_jit_timer_pop): New function. | |
1673 | (gcc_jit_timer_print): New function. | |
1674 | ||
eb3982c1 DM |
1675 | 2015-07-23 David Malcolm <dmalcolm@redhat.com> |
1676 | ||
1677 | * jit-playback.c (invoke_driver): Convert local "argvec" | |
1678 | to an auto_argvec, so that it owns copies of the strings, | |
1679 | rather than borrows them, updating ADD_ARG to use xstrdup | |
1680 | and special-casing the NULL terminator to avoid | |
1681 | xstrdup (NULL). Call add_multilib_driver_arguments at the front | |
1682 | of the arguments. | |
1683 | (MULTILIB_DEFAULTS): Provide a default definition. | |
1684 | (multilib_defaults_raw): New constant array. | |
1685 | (gcc::jit::playback::context::add_multilib_driver_arguments): New | |
1686 | method. | |
1687 | * jit-playback.h | |
1688 | (gcc::jit::playback::context::add_multilib_driver_arguments): New | |
1689 | method. | |
1690 | * docs/internals/test-hello-world.exe.log.txt: Update. | |
1691 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1692 | ||
1470e75f DM |
1693 | 2015-07-16 David Malcolm <dmalcolm@redhat.com> |
1694 | ||
1695 | * docs/internals/index.rst (Overview of code structure): Add note | |
1696 | that the implementation is in C++, despite the .c extension. | |
1697 | (Submitting patches): New subsection. | |
1698 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1699 | ||
1916bcb5 AM |
1700 | 2015-07-09 Andrew MacLeod <amacleod@redhat.com> |
1701 | ||
1702 | * dummy-frontend.c: Adjust includes for flags.h changes. | |
1703 | * jit-common.h: Likewise. | |
1704 | * jit-playback.c: Likewise. | |
1705 | ||
58c5ad40 DM |
1706 | 2015-07-08 David Malcolm <dmalcolm@redhat.com> |
1707 | ||
1708 | PR jit/66783 | |
1709 | * libgccjit.c (gcc_jit_context_new_field): Show name of field in | |
1710 | "unknown size" error message. | |
1711 | (gcc_jit_struct_set_fields): Show name of struct in error message. | |
1712 | (gcc_jit_context_new_global): Show name of global in | |
1713 | "unknown size" error message. | |
1714 | (gcc_jit_function_new_local): Likewise for local. | |
1715 | ||
c7131fb2 AM |
1716 | 2015-07-07 Andrew MacLeod <amacleod@redhat.com> |
1717 | ||
1718 | * dummy-frontend.c: Adjust includes. | |
1719 | * jit-common.h: Likewise. | |
1720 | * jit-playback.c: Likewise. | |
1721 | ||
3457d39e DM |
1722 | 2015-07-07 David Malcolm <dmalcolm@redhat.com> |
1723 | ||
1724 | PR jit/66783 | |
1725 | * jit-recording.h: Within namespace gcc:jit::recording... | |
1726 | (type::has_known_size): New virtual function. | |
1727 | (struct_has_known_size): New function. | |
1728 | * libgccjit.c (gcc_jit_context_new_field): Verify that the type | |
1729 | has a known size. | |
1730 | (gcc_jit_context_new_global): Likewise. | |
1731 | (gcc_jit_function_new_local): Likewise. | |
1732 | ||
bada4bed DM |
1733 | 2015-07-07 David Malcolm <dmalcolm@redhat.com> |
1734 | ||
1735 | PR jit/66779 | |
1736 | * dummy-frontend.c (jit_langhook_type_for_mode): Ensure that we | |
1737 | handle modes QI, HI, SI, DI, TI. | |
1738 | ||
e09abfa4 DM |
1739 | 2015-07-01 David Malcolm <dmalcolm@redhat.com> |
1740 | ||
1741 | PR jit/66700 | |
1742 | * jit-playback.c (jit_mark_addressable): New function. | |
1743 | (gcc::jit::playback::lvalue::get_address): Call | |
1744 | jit_mark_addressable on the underlying tree. | |
1745 | ||
e807aeaa DM |
1746 | 2015-07-01 David Malcolm <dmalcolm@redhat.com> |
1747 | ||
1748 | * docs/topics/types.rst (gcc_jit_context_new_union_type): Add | |
1749 | documentation. | |
1750 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1751 | ||
c575221a DM |
1752 | 2015-07-01 David Malcolm <dmalcolm@redhat.com> |
1753 | ||
1754 | * docs/topics/contexts.rst (gcc_jit_context_set_bool_option): | |
1755 | Clarify lack of lifetime requirements on (const char *) parameter. | |
1756 | * docs/topics/expressions.rst | |
1757 | (gcc_jit_context_new_string_literal): Likewise. | |
1758 | (gcc_jit_context_new_global): Likewise. | |
1759 | * docs/topics/functions.rst (gcc_jit_context_new_param): Likewise. | |
1760 | (gcc_jit_context_new_function): Likewise. | |
1761 | (gcc_jit_function_new_block): Likewise. | |
1762 | (gcc_jit_block_add_comment): Likewise. | |
1763 | * docs/topics/locations.rst (gcc_jit_context_new_location): | |
1764 | Likewise. | |
1765 | * docs/topics/types.rst (gcc_jit_context_new_field): Likewise. | |
1766 | (gcc_jit_context_new_struct_type): Likewise. | |
1767 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1768 | ||
ec5d0088 DM |
1769 | 2015-06-30 David Malcolm <dmalcolm@redhat.com> |
1770 | ||
1771 | * docs/cp/topics/functions.rst (Blocks): Add switch statements to | |
1772 | list of ways to terminate a block. | |
1773 | (gccjit::block::end_with_switch): Add function description. | |
1774 | (gccjit::case_): Add class. | |
1775 | (gccjit::context::new_case): Add function description. | |
1776 | * docs/cp/topics/objects.rst: Add "case_" to class hierarchy. | |
1777 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_3): New. | |
1778 | * docs/topics/functions.rst (Blocks): Add switch statements to | |
1779 | list of ways to terminate a block. | |
1780 | (gcc_jit_block_end_with_switch): Add function description. | |
1781 | (gcc_jit_case): Add type. | |
1782 | (gcc_jit_context_new_case): Add function description. | |
1783 | (gcc_jit_case_as_object): Add function description. | |
1784 | * docs/topics/objects.rst: Add gcc_jit_case to class hierarchy. | |
1785 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1786 | * jit-common.h (gcc::jit::recording::case_): Add forward decl. | |
1787 | (gcc::jit::playback::case_): Add forward decl. | |
1788 | * jit-playback.c (add_case): New function. | |
1789 | (gcc::jit::playback::block::add_switch): New function. | |
1790 | * jit-playback.h (gcc::jit::playback::case_): New struct. | |
1791 | (gcc::jit::playback::block::get_function): New method. | |
1792 | (gcc::jit::playback::block::add_switch): New method. | |
1793 | * jit-recording.c: Within namespace gcc::jit... | |
1794 | (recording::context::new_case): New method. | |
1795 | (recording::function::validate): Update for change to | |
1796 | get_successor_blocks. | |
1797 | (recording::block::end_with_switch): New method. | |
1798 | (recording::block::get_successor_blocks): Update to support an | |
1799 | arbitrary number of successor blocks. | |
1800 | (recording::block::dump_edges_to_dot): Likewise. | |
1801 | (memento_of_new_rvalue_from_const <int>::get_wide_int): New. | |
1802 | (memento_of_new_rvalue_from_const <long>::get_wide_int): New. | |
1803 | (memento_of_new_rvalue_from_const <double>::get_wide_int): New. | |
1804 | (memento_of_new_rvalue_from_const <void *>::get_wide_int): New. | |
1805 | (recording::statement::get_successor_blocks): Update to support an | |
1806 | arbitrary number of successor blocks. | |
1807 | (recording::conditional::get_successor_blocks): Likewise. | |
1808 | (recording::jump::get_successor_blocks): Likewise. | |
1809 | (recording::return_::get_successor_blocks): Likewise. | |
1810 | (recording::case_::write_reproducer): New. | |
1811 | (recording::case_::make_debug_string): New. | |
1812 | (recording::switch_::switch_): New. | |
1813 | (recording::switch_::replay_into): New. | |
1814 | (recording::switch_::get_successor_blocks): New. | |
1815 | (recording::switch_::make_debug_string): New. | |
1816 | (recording::switch_::write_reproducer): New. | |
1817 | * jit-recording.h: Within namespace gcc::jit::recording... | |
1818 | (context::new_case): New. | |
1819 | (rvalue::is_constant): New. | |
1820 | (rvalue::get_wide_int): New. | |
1821 | (block::end_with_switch): New. | |
1822 | (block::get_successor_blocks): Update to support an arbitrary | |
1823 | number of successor blocks. | |
1824 | (memento_of_new_rvalue_from_const::is_constant): New. | |
1825 | (memento_of_new_rvalue_from_const::get_wide_int): New. | |
1826 | (statement::get_successor_blocks): Update to support an arbitrary | |
1827 | number of successor blocks. | |
1828 | (conditional::get_successor_blocks): Likewise. | |
1829 | (jump::get_successor_blocks): Likewise. | |
1830 | (return_::get_successor_blocks): Likewise. | |
1831 | (case_): New subclass of memento. | |
1832 | (switch_): New subclass of statement. | |
1833 | * libgccjit++.h (gccjit::case_): New subclass of gccjit::object. | |
1834 | (gccjit::context::new_case): New method. | |
1835 | (gccjit::block::end_with_switch): New method. | |
1836 | (gccjit::case_::case): New ctors. | |
1837 | (gccjit::case_::get_inner_case): New method. | |
1838 | * libgccjit.c: Include "typed-splay-tree.h" | |
1839 | (struct gcc_jit_case): New. | |
1840 | (gcc_jit_context_new_case): New function. | |
1841 | (gcc_jit_case_as_object): New function. | |
1842 | (valid_dest_for_switch): New function. | |
1843 | (valid_case_for_switch): New function. | |
1844 | (class api_call_validator): New class. | |
1845 | (class case_range_validator): New class. | |
1846 | (case_range_validator::case_range_validator): New. | |
1847 | (case_range_validator::validate): New. | |
1848 | (case_range_validator::case_compare): New. | |
1849 | (case_range_validator::get_wide_int): new. | |
1850 | (gcc_jit_block_end_with_switch): New. | |
1851 | * libgccjit.h: Add gcc_jit_case to class hierarchy comment. | |
1852 | (gcc_jit_case): New typedef. | |
1853 | (gcc_jit_context_new_case): New function. | |
1854 | (gcc_jit_case_as_object): New function. | |
1855 | (gcc_jit_block_end_with_switch): New function. | |
1856 | (LIBGCCJIT_HAVE_SWITCH_STATEMENTS): New. | |
1857 | * libgccjit.map: Add gcc_jit_block_end_with_switch, | |
1858 | gcc_jit_case_as_object and gcc_jit_context_new_case. | |
1859 | ||
6a3603e3 DM |
1860 | 2015-06-30 David Malcolm <dmalcolm@redhat.com> |
1861 | ||
1862 | PR jit/66546 | |
1863 | * docs/cp/topics/contexts.rst | |
1864 | (gccjit::context::set_bool_allow_unreachable_blocks): New. | |
1865 | * docs/topics/compatibility.rst (LIBGCCJIT_ABI_2): New. | |
1866 | * docs/topics/contexts.rst (Options): Add notes discussing the | |
1867 | transition from enums to entrypoints for new options. | |
1868 | (gcc_jit_context_set_bool_allow_unreachable_blocks): New. | |
1869 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1870 | * jit-common.h (gcc::jit::inner_bool_option): New enum. | |
1871 | * jit-recording.c: Within namespace gcc::jit... | |
1872 | (recording::context::context): Handle m_inner_bool_options. | |
1873 | (recording::context::set_inner_bool_option): New. | |
1874 | (inner_bool_option_reproducer_strings): New. | |
1875 | (recording::context::log_all_options): Log the "inner" bool | |
1876 | options. | |
1877 | (recording::context::log_inner_bool_option): New. | |
1878 | (recording::context::dump_reproducer_to_file): Write initializers | |
1879 | for "inner" bool options. | |
1880 | (recording::function::validate): Don't check for block | |
1881 | reachability if INNER_BOOL_OPTION_ALLOW_UNREACHABLE_BLOCKS is set. | |
1882 | * jit-recording.h: Within namespace gcc::jit... | |
1883 | (recording::context::set_inner_bool_option): New. | |
1884 | (recording::context::get_inner_bool_option): New. | |
1885 | (recording::context::log_inner_bool_option): New. | |
1886 | (recording::context::m_inner_bool_options): New. | |
1887 | * libgccjit++.h | |
1888 | (gccjit::context::set_bool_allow_unreachable_blocks): New. | |
1889 | * libgccjit.c | |
1890 | (gcc_jit_context_set_bool_allow_unreachable_blocks): New. | |
1891 | * libgccjit.h: Add note about options present in the | |
1892 | initial release of libgccjit. | |
1893 | (gcc_jit_context_set_bool_allow_unreachable_blocks): New API | |
1894 | entrypoint. | |
1895 | (LIBGCCJIT_HAVE_gcc_jit_context_set_bool_allow_unreachable_blocks): | |
1896 | New macro. | |
1897 | * libgccjit.map (LIBGCCJIT_ABI_2): New, containing... | |
1898 | (gcc_jit_context_set_bool_allow_unreachable_blocks): ...this new | |
1899 | entrypoint. | |
1900 | ||
fa22c20d DM |
1901 | 2015-06-30 David Malcolm <dmalcolm@redhat.com> |
1902 | ||
1903 | PR jit/66628 | |
1904 | * docs/cp/topics/contexts.rst (Additional command-line options): | |
1905 | New section. | |
1906 | * docs/topics/compatibility.rst: New file. | |
1907 | * docs/topics/contexts.rst (Additional command-line options): New | |
1908 | section. | |
1909 | * docs/topics/index.rst: Add compatibility.rst. | |
1910 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1911 | * jit-playback.c (make_fake_args): Add call to | |
1912 | append_command_line_options. | |
1913 | * jit-recording.c: Within namespace gcc::jit... | |
1914 | (recording::context::~context): Free the optnames within | |
1915 | m_command_line_options. | |
1916 | (recording::context::set_bool_option): Likewise. | |
1917 | (recording::context::add_command_line_option): New method. | |
1918 | (recording::context::append_command_line_options): New method. | |
1919 | (recording::context::dump_reproducer_to_file): Add command-line | |
1920 | options. | |
1921 | * jit-recording.h: Within namespace gcc::jit... | |
1922 | (recording::context::add_command_line_option): New method. | |
1923 | (recording::context::append_command_line_options): New method. | |
1924 | (recording::context::m_command_line_options): New field. | |
1925 | * libgccjit++.h (gccjit::context::add_command_line_option): New | |
1926 | method. | |
1927 | * libgccjit.c (gcc_jit_context_add_command_line_option): New API | |
1928 | entrypoint. | |
1929 | * libgccjit.h (gcc_jit_context_add_command_line_option): New API | |
1930 | entrypoint. | |
1931 | (LIBGCCJIT_HAVE_gcc_jit_context_add_command_line_option): New | |
1932 | macro. | |
1933 | * libgccjit.map: Put existing symbols within LIBGCCJIT_ABI_0; add | |
1934 | LIBGCCJIT_ABI_1 and gcc_jit_context_add_command_line_option. | |
1935 | ||
a6314e15 DM |
1936 | 2015-06-30 David Malcolm <dmalcolm@redhat.com> |
1937 | ||
1938 | * jit-recording.c | |
1939 | (gcc::jit::recording::context::dump_reproducer_to_file): | |
1940 | Add pragma to generated reproducers to disable -Wunused-variable. | |
1941 | Fix handling of NULL string options. | |
1942 | ||
adb6d84b DM |
1943 | 2015-06-30 David Malcolm <dmalcolm@redhat.com> |
1944 | ||
1945 | * docs/cp/topics/expressions.rst: Remove stray semicolon. | |
1946 | * docs/cp/topics/functions.rst: Remove stray backslash. | |
1947 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
1948 | ||
f0889939 AM |
1949 | 2015-06-25 Andrew MacLeod <amacleod@redhat.com> |
1950 | ||
1951 | * dummy-frontend.c: Remove ipa-ref.h and plugin-api.h from include list. | |
1952 | * jit-playback.c: Likewise. | |
1953 | ||
9cad7a76 AM |
1954 | 2015-06-25 Andrew Macleod <amacleod@redhat.com> |
1955 | ||
1956 | * jit-common.h: Don't include alias.h. | |
1957 | ||
41571b55 DM |
1958 | 2015-06-17 David Malcolm <dmalcolm@redhat.com> |
1959 | ||
1960 | * libgccjit.c (gcc_jit_lvalue_access_field): Verify that the field | |
1961 | is for the correct struct. | |
1962 | (gcc_jit_rvalue_access_field): Likewise. | |
1963 | ||
abb226c9 AM |
1964 | 2015-06-17 Andrew MacLeod <amacleod@redhat.com> |
1965 | ||
1966 | * dummy-frontend.c: Do not include input.h, line-map.h or is-a.h. | |
1967 | * jit-common.h: Likewise. | |
1968 | * jit-playback.c: Likewise. | |
1969 | ||
bd93aa1a DM |
1970 | 2015-06-16 David Malcolm <dmalcolm@redhat.com> |
1971 | ||
1972 | PR jit/66539 | |
1973 | * jit-recording.c: Within namespace gcc::jit::recording:: | |
1974 | (rvalue::get_debug_string_parens): New function. | |
1975 | (binary_op::make_debug_string): Update to mimic C precedence | |
1976 | rules. | |
1977 | (binary_op_precedence): New array. | |
1978 | (binary_op::get_precedence): New function. | |
1979 | (comparison::make_debug_string): Update to mimic C precedence | |
1980 | rules. | |
1981 | (comparison_precedence): New array. | |
1982 | (comparison::get_precedence): New function. | |
1983 | (cast::make_debug_string): Update to mimic C precedence rules. | |
1984 | (call::make_debug_string): Likewise. | |
1985 | (call_through_ptr::make_debug_string): Likewise. | |
1986 | (array_access::make_debug_string): Likewise. | |
1987 | (access_field_of_lvalue::make_debug_string): Likewise. | |
1988 | (access_field_rvalue::make_debug_string): Likewise. | |
1989 | (dereference_field_rvalue::make_debug_string): Likewise. | |
1990 | (dereference_rvalue::make_debug_string): Likewise. | |
1991 | (get_address_of_lvalue::make_debug_string): Likewise. | |
1992 | * jit-recording.h: Within namespace gcc::jit::recording:: | |
1993 | (precedence): New enum. | |
1994 | (rvalue::rvalue): Initialize field "m_parenthesized_string". | |
1995 | (rvalue::get_debug_string_parens): New method. | |
1996 | (rvalue::get_precedence): New pure virtual function. | |
1997 | (rvalue::m_parenthesized_string): New field. | |
1998 | (param::get_precedence): New function. | |
1999 | (global::get_precedence): New function. | |
2000 | (memento_of_new_rvalue_from_const::get_precedence): New function. | |
2001 | (memento_of_new_string_literal::get_precedence): New function. | |
2002 | (unary_op::get_precedence): New function. | |
2003 | (binary_op::get_precedence): New function. | |
2004 | (comparison::get_precedence): New function. | |
2005 | (cast::get_precedence): New function. | |
2006 | (call::get_precedence): New function. | |
2007 | (call_through_ptr::get_precedence): New function. | |
2008 | (array_access::get_precedence): New function. | |
2009 | (access_field_of_lvalue::get_precedence): New function. | |
2010 | (access_field_rvalue::get_precedence): New function. | |
2011 | (dereference_field_rvalue::get_precedence): New function. | |
2012 | (dereference_rvalue::get_precedence): New function. | |
2013 | (get_address_of_lvalue::get_precedence): New function. | |
2014 | (local::get_precedence): New function. | |
2015 | ||
83c1b80e MK |
2016 | 2015-06-09 Matthias Klose <doko@ubuntu.com> |
2017 | ||
2018 | * Make-lang.in (jit.install-common): Install headers using INSTALL_DATA. | |
2019 | ||
13fdf2e2 AM |
2020 | 2015-06-08 Andrew MacLeod <amacleod@redhat.com> |
2021 | ||
2022 | * dummy-frontend.c : Adjust include files. | |
2023 | * jit-common.h : Likewise. | |
2024 | * jit-playback.c : Likewise. | |
2025 | ||
e4753451 DM |
2026 | 2015-06-05 David Malcolm <dmalcolm@redhat.com> |
2027 | ||
2028 | * dummy-frontend.c | |
2029 | (jit_langhook_post_compilation_parsing_cleanups): Remove. | |
2030 | (LANG_HOOKS_POST_COMPILATION_PARSING_CLEANUPS): Remove | |
2031 | * jit-playback.c (gcc::jit::playback::context::new_global): Add | |
2032 | call to varpool_node::finalize_decl. | |
2033 | (gcc::jit::playback::context::finalize_global_decls): Remove. | |
2034 | * jit-playback.h | |
2035 | (gcc::jit::playback::context::finalize_global_decls): Remove. | |
2036 | ||
e7547bc6 DM |
2037 | 2015-06-05 David Malcolm <dmalcolm@redhat.com> |
2038 | ||
2039 | * dummy-frontend.c (jit_langhook_write_globals): Rename to... | |
2040 | (jit_langhook_post_compilation_parsing_cleanups): ...this, and | |
2041 | eliminate calls to finalize_compilation_unit and | |
2042 | write_global_decls_2. | |
2043 | (LANG_HOOKS_WRITE_GLOBALS): Rename to... | |
2044 | (LANG_HOOKS_POST_COMPILATION_PARSING_CLEANUPS): ...this and | |
2045 | redirect from jit_langhook_write_globals to | |
2046 | jit_langhook_post_compilation_parsing_cleanups. | |
2047 | * jit-playback.c | |
2048 | (gcc::jit::playback::context::write_global_decls_1): Rename to... | |
2049 | (gcc::jit::playback::context::finalize_global_decls): ...this. | |
2050 | (gcc::jit::playback::context::write_global_decls_1): Delete. | |
2051 | * jit-playback.h | |
2052 | (gcc::jit::playback::context::write_global_decls_1): Rename to... | |
2053 | (gcc::jit::playback::context::finalize_global_decls): ...this. | |
2054 | (gcc::jit::playback::context::write_global_decls_1): Delete. | |
2055 | ||
ecb9f223 AM |
2056 | 2015-06-04 Andrew MacLeod <amacleod@redhat.com> |
2057 | ||
2058 | * dummy-frontend.c: Adjust includes for restructured coretypes.h. | |
2059 | * jit-common.h: Likewise. | |
2060 | * jit-playback.c: Likewise. | |
2061 | ||
2637afb7 DM |
2062 | 2015-05-12 David Malcolm <dmalcolm@redhat.com> |
2063 | ||
2064 | * jit-builtins.c: Include vec.h before target.h. | |
2065 | ||
46bf0b0a JW |
2066 | 2015-04-27 Jim Wilson <jim.wilson@linaro.org> |
2067 | ||
2068 | * Make-lang.in (jit.mostlyclean): Remove shared libraries and object | |
2069 | files. | |
2070 | ||
51c5c6b5 DM |
2071 | 2015-04-09 David Malcolm <dmalcolm@redhat.com> |
2072 | ||
2073 | PR jit/65691 | |
2074 | * docs/cp/topics/expressions.rst (Simple expressions): Fix copy | |
2075 | and paste error in description of gccjit::context::one. | |
2076 | * docs/topics/expressions.rst (Simple expressions): Likewise in | |
2077 | description of gcc_jit_context_one. | |
2078 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2079 | ||
f40fd895 UB |
2080 | 2015-03-13 Uros Bizjak <ubizjak@gmail.com> |
2081 | ||
2082 | * jit-recording.c (dump::write): Also check vasprintf return value. | |
2083 | (recording::context::add_error_va): Ditto. | |
2084 | (recording::string::from_printf): Ditto. | |
2085 | ||
18eb0d13 DM |
2086 | 2015-03-13 David Malcolm <dmalcolm@redhat.com> |
2087 | ||
2088 | * docs/internals/index.rst (Packaging notes): New section. | |
2089 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2090 | ||
7ef96183 DM |
2091 | 2015-03-05 David Malcolm <dmalcolm@redhat.com> |
2092 | ||
2093 | * docs/cp/intro/tutorial03.rst: Add missing arguments to | |
2094 | gccjit::block::end_with_conditional call. Add on_true/on_false | |
2095 | comments. Tweak the wording. | |
2096 | * docs/intro/tutorial03.rst: Add missing arguments to | |
2097 | gcc_jit_block_end_with_conditional call. Add some clarifying | |
2098 | comments. | |
2099 | * docs/topics/compilation.rst: Tweak the wording to avoid an | |
2100 | ambiguous use of "this". | |
2101 | * docs/topics/contexts.rst: Fix a typo. | |
2102 | * docs/topics/expressions.rst (GCC_JIT_BINARY_OP_MINUS): Remove | |
2103 | a stray backtick. | |
2104 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2105 | ||
56a9f6bc TS |
2106 | 2015-02-24 Thomas Schwinge <thomas@codesourcery.com> |
2107 | ||
2108 | PR libgomp/64625 | |
2109 | * jit-builtins.c (DEF_FUNCTION_TYPE_VAR_8) | |
2110 | (DEF_FUNCTION_TYPE_VAR_12): Remove macros. | |
2111 | (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros. | |
2112 | * jit-builtins.h (DEF_FUNCTION_TYPE_VAR_8) | |
2113 | (DEF_FUNCTION_TYPE_VAR_12): Remove macros. | |
2114 | (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros. | |
2115 | ||
a4be4e91 DM |
2116 | 2015-02-04 David Malcolm <dmalcolm@redhat.com> |
2117 | ||
2118 | PR jit/64257 | |
2119 | * docs/conf.py (html_theme): Change from 'pyramid' | |
2120 | to 'sphinxdoc'. | |
2121 | ||
f435bff3 DM |
2122 | 2015-02-04 David Malcolm <dmalcolm@redhat.com> |
2123 | ||
2124 | * docs/topics/contexts.rst (gcc_jit_context_acquire): Fix | |
2125 | typo. | |
2126 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2127 | ||
0ed4f017 DM |
2128 | 2015-02-03 David Malcolm <dmalcolm@redhat.com> |
2129 | ||
2130 | * jit-logging.h (gcc::jit::log_user::log): Make const. | |
2131 | * jit-recording.c (gcc::jit::recording::context::set_str_option): | |
2132 | Log the new value of the option. | |
2133 | (gcc::jit::recording::context::set_int_option): Likewise. | |
2134 | (gcc::jit::recording::context::set_bool_option): Likewise. | |
2135 | (gcc::jit::recording::context::compile): Log the value of all | |
2136 | options. | |
2137 | (gcc::jit::recording::context::compile_to_file): Likewise. | |
2138 | (gcc::jit::recording::context::log_all_options): New function. | |
2139 | (gcc::jit::recording::context::log_str_option): New function. | |
2140 | (gcc::jit::recording::context::log_int_option): New function. | |
2141 | (gcc::jit::recording::context::log_bool_option): New function. | |
2142 | * jit-recording.h (gcc::jit::recording::context::log_all_options): | |
2143 | New function. | |
2144 | (gcc::jit::recording::context::log_str_option): New function. | |
2145 | (gcc::jit::recording::context::log_int_option): New function. | |
2146 | (gcc::jit::recording::context::log_bool_option): New function. | |
2147 | * docs/internals/test-hello-world.exe.log.txt: Update for above | |
2148 | changes. | |
2149 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2150 | ||
2cb844ce DM |
2151 | 2015-02-03 David Malcolm <dmalcolm@redhat.com> |
2152 | ||
2153 | PR jit/64810 | |
2154 | * Make-lang.in (jit_OBJS): Add jit/jit-spec.o and gcc.o. | |
2155 | (LIBGCCJIT_FILENAME): Add EXTRA_GCC_OBJS. | |
2156 | * jit-playback.c: Include gcc.h. | |
2157 | (gcc::jit::playback::context::compile): Move mutex acquisition | |
2158 | to before the call to make_fake_args. | |
2159 | (append_arg_from_driver): New function. | |
2160 | (gcc::jit::playback::context::make_fake_args): On the first call, | |
2161 | call into driver_get_configure_time_options to get configure-time | |
2162 | default options and cache them. Add them to the args for | |
2163 | toplev::main. | |
2164 | * jit-spec.c: New source file. | |
2165 | * docs/internals/test-hello-world.exe.log.txt: Update to reflect | |
2166 | above changes. | |
2167 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2168 | ||
16a71c50 DM |
2169 | 2015-02-02 David Malcolm <dmalcolm@redhat.com> |
2170 | ||
2171 | PR jit/64810 | |
2172 | * dummy-frontend.c (jit_langhook_type_for_mode): Support | |
2173 | TYPE_MODE (long_long_integer_type_node). | |
2174 | ||
53c04ec9 DM |
2175 | 2015-01-27 David Malcolm <dmalcolm@redhat.com> |
2176 | ||
2177 | * docs/internals/test-hello-world.exe.log.txt: Add example version | |
2178 | lines. | |
2179 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2180 | * jit-common.h (gcc::jit::dump::get_file): New accessor. | |
2181 | * jit-logging.c: Include toplev.h. | |
2182 | (gcc::jit::logger::logger): Log the GCC version. | |
2183 | * jit-recording.c: Include toplev.h. | |
2184 | (gcc:jit::recording::context::dump_reproducer_to_file): Log the | |
2185 | GCC version. | |
2186 | ||
dc44ee3a DM |
2187 | 2015-01-26 David Malcolm <dmalcolm@redhat.com> |
2188 | ||
2189 | * docs/topics/compilation.rst (gcc_jit_result_get_code): Fix typo. | |
2190 | * docs/topics/contexts.rst (gcc_jit_context_get_last_error): The | |
2191 | error buffer is only valid until the next call to the context. | |
2192 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2193 | * libgccjit.h (gcc_jit_context_get_first_error): Reword the | |
2194 | comment to omit mention of compiling. | |
2195 | (gcc_jit_context_get_last_error): The error buffer is only valid | |
2196 | until the next call to the context. | |
2197 | ||
3349605d DM |
2198 | 2015-01-26 David Malcolm <dmalcolm@redhat.com> |
2199 | ||
2200 | PR jit/64708 | |
2201 | * config-lang.in (compilers): Drop "libgccjit.so". | |
2202 | ||
6fc2d0f3 DM |
2203 | 2015-01-23 David Malcolm <dmalcolm@redhat.com> |
2204 | ||
2205 | PR jit/64721 | |
2206 | * jit-playback.c (gcc::jit::playback::context::compile): Construct | |
2207 | toplev instances with init_signals=false. | |
2208 | ||
fdce7209 DM |
2209 | 2015-01-19 David Malcolm <dmalcolm@redhat.com> |
2210 | ||
2211 | * docs/cp/topics/results.rst: Rename to... | |
2212 | * docs/cp/topics/compilation.rst: ...this, and add section on | |
2213 | ahead-of-time compilation. | |
2214 | * docs/cp/topics/index.rst: Update for renaming of results.rst | |
2215 | to compilation.rst. | |
2216 | * docs/examples/emit-alphabet.bf: New file, a sample "brainf" | |
2217 | script. | |
2218 | * docs/examples/tut05-bf.c: New file, implementing a compiler | |
2219 | for "brainf". | |
2220 | * docs/internals/test-hello-world.exe.log.txt: Update to reflect | |
2221 | changes to logger output. | |
2222 | * docs/intro/index.rst: Add tutorial05.rst | |
2223 | * docs/intro/tutorial05.rst: New file. | |
2224 | * docs/topics/results.rst: Rename to... | |
2225 | * docs/topics/compilation.rst: ...this, and add section on | |
2226 | ahead-of-time compilation. | |
2227 | * docs/topics/index.rst: Update for renaming of results.rst to | |
2228 | compilation.rst. | |
2229 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2230 | * jit-playback.c (gcc::jit::playback::context::compile): Convert | |
2231 | return type from result * to void. Move the code to convert to | |
2232 | dso and dlopen the result to a new pure virtual "postprocess" | |
2233 | method. | |
2234 | (gcc::jit::playback::compile_to_memory::compile_to_memory): New | |
2235 | function. | |
2236 | (gcc::jit::playback::compile_to_memory::postprocess): New | |
2237 | function, based on playback::context::compile. | |
2238 | (gcc::jit::playback::compile_to_file::compile_to_file): New | |
2239 | function. | |
2240 | (gcc::jit::playback::compile_to_file::postprocess): New function. | |
2241 | (gcc::jit::playback::compile_to_file::copy_file): New function. | |
2242 | (gcc::jit::playback::context::convert_to_dso): Move internals | |
2243 | to... | |
2244 | (gcc::jit::playback::context::invoke_driver): New method. Add | |
2245 | "-shared" and "-c" options to driver's argv as needed. | |
2246 | * jit-playback.h: Include "timevar.h". | |
2247 | (gcc::jit::playback::context::compile): Convert return type from | |
2248 | result * to void. | |
2249 | (gcc::jit::playback::context::postprocess): New pure virtual | |
2250 | function, making this an abstract base class. | |
2251 | (gcc::jit::playback::context::get_tempdir): New accessor. | |
2252 | (gcc::jit::playback::context::invoke_driver): New function. | |
2253 | (class gcc::jit::playback::compile_to_memory): New subclass of | |
2254 | playback::context. | |
2255 | (class gcc::jit::playback::compile_to_file): Likewise. | |
2256 | * jit-recording.c (gcc::jit::recording::context::compile): Use a | |
2257 | playback::compile_to_memory, and extract its result. | |
2258 | (gcc::jit::recording::context::compile_to_file): New function. | |
2259 | * jit-recording.h (gcc::jit::recording::context::compile_to_file): | |
2260 | New function. | |
2261 | * libgccjit++.h (gccjit::context::compile_to_file): New method. | |
2262 | * libgccjit.c (gcc_jit_context_compile): Update log message to | |
2263 | clarify that this is an in-memory compile. | |
2264 | (gcc_jit_context_compile_to_file): New function. | |
2265 | * libgccjit.h (gcc_jit_context): Clarify that you can compile | |
2266 | a context more than once, and that you can compile to a file | |
2267 | as well as to memory. | |
2268 | (gcc_jit_result): Clarify that this is the result of an | |
2269 | in-memory compilation. | |
2270 | (gcc_jit_context_compile): Clarify that you can compile, and that | |
2271 | this is an in-memory compilation. | |
2272 | (enum gcc_jit_output_kind): New enum. | |
2273 | (gcc_jit_context_compile_to_file): New function. | |
2274 | (gcc_jit_context_enable_dump): Clarify comment to cover both forms | |
2275 | of compilation. | |
2276 | * libgccjit.map (gcc_jit_context_compile_to_file): New API | |
2277 | entrypoint. | |
2278 | * notes.txt: Update to show the playback::context::postprocess | |
2279 | virtual function. | |
2280 | ||
450e225b DM |
2281 | 2015-01-19 David Malcolm <dmalcolm@redhat.com> |
2282 | ||
2283 | * jit-recording.c | |
2284 | (gcc::jit::recording::memento_of_new_string_literal::make_debug_string): | |
2285 | Add missing format string. | |
2286 | ||
499de348 DM |
2287 | 2015-01-16 David Malcolm <dmalcolm@redhat.com> |
2288 | ||
2289 | * Make-lang.in (lang_checks_parallelized): Add "check-jit". | |
2290 | (check_jit_parallelize): Set this to an arbitrary value (10). | |
2291 | ||
e989e68d JJ |
2292 | 2015-01-16 Jakub Jelinek <jakub@redhat.com> |
2293 | ||
2294 | * jit-builtins.h (DEF_FUNCTION_TYPE_VAR_5): Fix spelling of | |
2295 | last argument. | |
2296 | (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12): Define and | |
2297 | undef afterwards. | |
2298 | * jit-builtins.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12): | |
2299 | Likewise. | |
2300 | ||
179ed8f5 RS |
2301 | 2015-01-15 Richard Sandiford <richard.sandiford@arm.com> |
2302 | ||
2303 | Update copyright years in docs/. | |
2304 | ||
96a87981 DM |
2305 | 2015-01-15 David Malcolm <dmalcolm@redhat.com> |
2306 | ||
2307 | * libgccjit.c (gcc_jit_block_add_assignment_op): Check that the | |
2308 | lvalue and the rvalue are of compatible type. | |
2309 | ||
86d0ac88 DM |
2310 | 2015-01-13 David Malcolm <dmalcolm@redhat.com> |
2311 | ||
2312 | * docs/cp/topics/contexts.rst (Debugging): Add | |
2313 | gccjit::context::dump_reproducer_to_file. | |
2314 | * docs/internals/index.rst (Design notes): New section, | |
2315 | discussing input validation and | |
2316 | gcc_jit_context_dump_reproducer_to_file. | |
2317 | * docs/topics/contexts.rst (Debugging): Add | |
2318 | gcc_jit_context_dump_reproducer_to_file. | |
2319 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2320 | * jit-common.h (gcc::jit::dump::get_context): New accessor. | |
2321 | * jit-recording.c: Include "hash-map.h". | |
2322 | Within namespace ::gcc::jit... | |
2323 | (dump::write): Flush each line. | |
2324 | (dump::make_location): Pass false for new param "created_by_user". | |
2325 | (class allocator): New class. | |
2326 | (allocator::~allocator): New function. | |
2327 | (allocator::xstrdup_printf): New function. | |
2328 | (allocator::xstrdup_printf_va): New function. | |
2329 | (class reproducer): New subclass of dump. | |
2330 | (reproducer::reproducer): New function. | |
2331 | (reproducer::write_params): New function. | |
2332 | (reproducer::write_args): New function. | |
2333 | (reproducer::make_identifier): New function. | |
2334 | (reproducer::make_tmp_identifier): New function. | |
2335 | (reproducer::get_identifier): New pair of functions. | |
2336 | (reproducer::get_identifier_as_rvalue): New function. | |
2337 | (reproducer::get_identifier_as_lvalue): New function. | |
2338 | (reproducer::get_identifier_as_type): New function. | |
2339 | (reproducer::xstrdup_printf): New function. | |
2340 | (recording::context::context): Initialize m_toplevel_ctxt. | |
2341 | (recording::context::new_location): Add param created_by_user. | |
2342 | (str_option_reproducer_strings): New table of strings. | |
2343 | (int_option_reproducer_strings): Likewise. | |
2344 | (bool_option_reproducer_strings): Likewise. | |
2345 | (get_type_enum_strings): Likewise. | |
2346 | (names_of_function_kinds): Likewise. | |
2347 | (global_kind_reproducer_strings): Likewise. | |
2348 | (unary_op_reproducer_strings): Likewise. | |
2349 | (binary_op_reproducer_strings): Likewise. | |
2350 | (comparison_reproducer_strings): Likewise. | |
2351 | Within namespace ::gcc::jit::recording::... | |
2352 | (context::dump_reproducer_to_file): New function. | |
2353 | (string::write_reproducer): Likewise. | |
2354 | (location::write_reproducer): Likewise. | |
2355 | (type::access_as_type): Likewise. | |
2356 | (memento_of_get_type::write_reproducer): Likewise. | |
2357 | (memento_of_get_pointer::write_reproducer): Likewise. | |
2358 | (memento_of_get_const::write_reproducer): Likewise. | |
2359 | (memento_of_get_volatile::write_reproducer): Likewise. | |
2360 | (array_type::write_reproducer): Likewise. | |
2361 | (function_type::write_reproducer): Likewise. | |
2362 | (function_type::write_deferred_reproducer): Likewise. | |
2363 | (field::write_reproducer): Likewise. | |
2364 | (struct_::access_as_type): Likewise. | |
2365 | (struct_::write_reproducer): Likewise. | |
2366 | (union_::write_reproducer): Likewise. | |
2367 | (fields::write_reproducer): Likewise. | |
2368 | (rvalue::access_as_rvalue): Likewise. | |
2369 | (lvalue::access_as_rvalue): Likewise. | |
2370 | (lvalue::access_as_lvalue): Likewise. | |
2371 | (param::access_as_rvalue): Likewise. | |
2372 | (param::access_as_lvalue): Likewise. | |
2373 | (param::write_reproducer): Likewise. | |
2374 | (function::write_reproducer): Likewise. | |
2375 | (block::write_reproducer): Likewise. | |
2376 | (global::write_reproducer): Likewise. | |
2377 | (memento_of_new_rvalue_from_const <int>::write_reproducer): | |
2378 | Likewise. | |
2379 | (memento_of_new_rvalue_from_const <long>::write_reproducer): | |
2380 | Likewise. | |
2381 | (memento_of_new_rvalue_from_const <double>::write_reproducer): | |
2382 | Likewise. | |
2383 | (memento_of_new_rvalue_from_const <void *>::write_reproducer): | |
2384 | Likewise. | |
2385 | (memento_of_new_string_literal::write_reproducer): Likewise. | |
2386 | (unary_op::write_reproducer): Likewise. | |
2387 | (binary_op::write_reproducer): Likewise. | |
2388 | (comparison::write_reproducer): Likewise. | |
2389 | (cast::write_reproducer): Likewise. | |
2390 | (call::write_reproducer): Likewise. | |
2391 | (call_through_ptr::write_reproducer): Likewise. | |
2392 | (array_access::write_reproducer): Likewise. | |
2393 | (access_field_of_lvalue::write_reproducer): Likewise. | |
2394 | (access_field_rvalue::write_reproducer): Likewise. | |
2395 | (dereference_field_rvalue::write_reproducer): Likewise. | |
2396 | (dereference_rvalue::write_reproducer): Likewise. | |
2397 | (get_address_of_lvalue::write_reproducer): Likewise. | |
2398 | (local::write_reproducer): Likewise. | |
2399 | (eval::write_reproducer): Likewise. | |
2400 | (assignment::write_reproducer): Likewise. | |
2401 | (assignment_op::write_reproducer): Likewise. | |
2402 | (comment::write_reproducer): Likewise. | |
2403 | (conditional::write_reproducer): Likewise. | |
2404 | (jump::write_reproducer): Likewise. | |
2405 | (return_::write_reproducer): Likewise. | |
2406 | * jit-recording.h (gcc::jit::reproducer): New forward declararion. | |
2407 | Within namespace ::gcc::jit::recording::... | |
2408 | (context::new_location): Add "created_by_user" param. | |
2409 | (context::dump_reproducer_to_file): New method. | |
2410 | (context::m_toplevel_ctxt): New field. | |
2411 | (memento::write_reproducer): New pure virtual function. | |
2412 | (memento::dyn_cast_location): New virtual function. | |
2413 | (string::write_reproducer): | |
2414 | (location::location): Add "created_by_user" param. | |
2415 | (location::dyn_cast_location): New function. | |
2416 | (location::created_by_user): New accessor. | |
2417 | (location::write_reproducer): New function. | |
2418 | (location::m_created_by_user): New field. | |
2419 | (type::access_as_type): New virtual function. | |
2420 | (location::write_reproducer): Likewise. | |
2421 | (type::access_as_type): Likewise. | |
2422 | (memento_of_get_type::write_reproducer): Likewise. | |
2423 | (memento_of_get_pointer::write_reproducer): Likewise. | |
2424 | (memento_of_get_const::write_reproducer): Likewise. | |
2425 | (memento_of_get_volatile::write_reproducer): Likewise. | |
2426 | (array_type::write_reproducer): Likewise. | |
2427 | (function_type::write_reproducer): Likewise. | |
2428 | (function_type::write_deferred_reproducer): Likewise. | |
2429 | (field::write_reproducer): Likewise. | |
2430 | (struct_::access_as_type): Likewise. | |
2431 | (struct_::write_reproducer): Likewise. | |
2432 | (union_::write_reproducer): Likewise. | |
2433 | (union_::m_fields): Remove stray unused field. | |
2434 | (fields::length): New accessor. | |
2435 | (fields::get_field): New accessor. | |
2436 | (fields::write_reproducer): New function. | |
2437 | (rvalue::access_as_rvalue): Likewise. | |
2438 | (lvalue::access_as_rvalue): Likewise. | |
2439 | (lvalue::access_as_lvalue): Likewise. | |
2440 | (param::access_as_rvalue): Likewise. | |
2441 | (param::access_as_lvalue): Likewise. | |
2442 | (param::write_reproducer): Likewise. | |
2443 | (function::write_reproducer): Likewise. | |
2444 | (block::write_reproducer): Likewise. | |
2445 | (global::write_reproducer): Likewise. | |
2446 | (memento_of_new_rvalue_from_const <HOST_TYPE>::write_reproducer): | |
2447 | Likewise. | |
2448 | (memento_of_new_string_literal::write_reproducer): Likewise. | |
2449 | (unary_op::write_reproducer): Likewise. | |
2450 | (binary_op::write_reproducer): Likewise. | |
2451 | (comparison::write_reproducer): Likewise. | |
2452 | (cast::write_reproducer): Likewise. | |
2453 | (call::write_reproducer): Likewise. | |
2454 | (call_through_ptr::write_reproducer): Likewise. | |
2455 | (array_access::write_reproducer): Likewise. | |
2456 | (access_field_of_lvalue::write_reproducer): Likewise. | |
2457 | (access_field_rvalue::write_reproducer): Likewise. | |
2458 | (dereference_field_rvalue::write_reproducer): Likewise. | |
2459 | (dereference_rvalue::write_reproducer): Likewise. | |
2460 | (get_address_of_lvalue::write_reproducer): Likewise. | |
2461 | (local::write_reproducer): Likewise. | |
2462 | (eval::write_reproducer): Likewise. | |
2463 | (assignment::write_reproducer): Likewise. | |
2464 | (assignment_op::write_reproducer): Likewise. | |
2465 | (comment::write_reproducer): Likewise. | |
2466 | (conditional::write_reproducer): Likewise. | |
2467 | (jump::write_reproducer): Likewise. | |
2468 | (return_::write_reproducer): Likewise. | |
2469 | * libgccjit++.h (gccjit::context::dump_reproducer_to_file): New. | |
2470 | * libgccjit.c (gcc_jit_context_new_location): Pass "true" as | |
2471 | param "created_by_user". | |
2472 | (gcc_jit_context_dump_reproducer_to_file): New API entrypoint. | |
2473 | * libgccjit.h (gcc_jit_context_dump_reproducer_to_file): New API | |
2474 | entrypoint. | |
2475 | * libgccjit.map (gcc_jit_context_dump_reproducer_to_file): New API | |
2476 | entrypoint. | |
2477 | ||
f6f2b019 DM |
2478 | 2015-01-12 David Malcolm <dmalcolm@redhat.com> |
2479 | ||
2480 | * jit-recording.c (class gcc::jit::rvalue_usage_validator): New. | |
2481 | (gcc::jit::rvalue_usage_validator::rvalue_usage_validator): New | |
2482 | ctor. | |
2483 | (gcc::jit::rvalue_usage_validator::visit): New function. | |
2484 | (gcc::jit::recording::rvalue::verify_valid_within_stmt): New | |
2485 | function. | |
2486 | (gcc::jit::recording::rvalue::set_scope): New function. | |
2487 | (gcc::jit::recording::function::function): Call set_scope on each | |
2488 | param, issuing errors for any params that already have a function. | |
2489 | (gcc::jit::recording::block::add_eval): Return the new statement; | |
2490 | update the comment given that some error-checking now happens after | |
2491 | this returns. | |
2492 | (gcc::jit::recording::block::add_assignment): Likewise. | |
2493 | (gcc::jit::recording::block::add_assignment_op): Likewise. | |
2494 | (gcc::jit::recording::block::add_comment): Likewise. | |
2495 | (gcc::jit::recording::block::end_with_conditional): Likewise. | |
2496 | (gcc::jit::recording::block::end_with_jump): Likewise. | |
2497 | (gcc::jit::recording::block::end_with_return): Likewise. | |
2498 | (gcc::jit::recording::block::validate): Add a comment. | |
2499 | (gcc::jit::recording::unary_op::visit_children): New function. | |
2500 | (gcc::jit::recording::binary_op::visit_children): New function. | |
2501 | (gcc::jit::recording::comparison::visit_children): New function. | |
2502 | (gcc::jit::recording::cast::visit_children): New function. | |
2503 | (gcc::jit::recording::call::visit_children): New function. | |
2504 | (gcc::jit::recording::call_through_ptr::visit_children): New function. | |
2505 | (gcc::jit::recording::array_access::visit_children): New function. | |
2506 | (gcc::jit::recording::access_field_of_lvalue::visit_children): New | |
2507 | function. | |
2508 | (gcc::jit::recording::access_field_rvalue::visit_children): New | |
2509 | function. | |
2510 | (gcc::jit::recording::dereference_field_rvalue::visit_children): | |
2511 | New function. | |
2512 | (gcc::jit::recording::dereference_rvalue::visit_children): New | |
2513 | function. | |
2514 | (gcc::jit::recording::get_address_of_lvalue::visit_children): New | |
2515 | function. | |
2516 | * jit-recording.h: Within namespace gcc::jit::recording... | |
2517 | (class rvalue_visitor): New. | |
2518 | (rvalue::rvalue): Initialize m_scope. | |
2519 | (rvalue::get_loc): New accessor. | |
2520 | (rvalue::verify_valid_within_stmt): New function. | |
2521 | (rvalue::visit_children): New pure virtual function. | |
2522 | (rvalue::set_scope): New function. | |
2523 | (rvalue::get_scope): New function. | |
2524 | (rvalue::dyn_cast_param): New function. | |
2525 | (rvalue::m_scope): New field. | |
2526 | (param::visit_children): New empty function. | |
2527 | (param::dyn_cast_param): New function. | |
2528 | (function::get_loc): New function. | |
2529 | (block::add_eval): Return the new statement. | |
2530 | (block::add_assignment): Likewise. | |
2531 | (block::add_assignment_op): Likewise. | |
2532 | (block::add_comment): Likewise. | |
2533 | (block::end_with_conditional): Likewise. | |
2534 | (block::end_with_jump): Likewise. | |
2535 | (block::end_with_return): Likewise. | |
2536 | (global::visit_children): New function. | |
2537 | (memento_of_new_rvalue_from_const<HOST_TYPE>::visit_children): | |
2538 | New function. | |
2539 | (memento_of_new_string_literal::visit_children): New function. | |
2540 | (unary_op::visit_children): New function. | |
2541 | (binary_op::visit_children): New function. | |
2542 | (comparison::visit_children): New function. | |
2543 | (cast::visit_children): New function. | |
2544 | (call::visit_children): New function. | |
2545 | (call_through_ptr::visit_children): New function. | |
2546 | (array_access::visit_children): New function. | |
2547 | (access_field_of_lvalue::visit_children): New function. | |
2548 | (access_field_rvalue::visit_children): New function. | |
2549 | (dereference_field_rvalue::visit_children): New function. | |
2550 | (dereference_rvalue::visit_children): New function. | |
2551 | (get_address_of_lvalue::visit_children): New function. | |
2552 | (local::local): Call set_scope. | |
2553 | (local::visit_children): New function. | |
2554 | (statement::get_block): Make public. | |
2555 | * libgccjit.c (RETURN_VAL_IF_FAIL_PRINTF5): New macro. | |
2556 | (RETURN_NULL_IF_FAIL_PRINTF5): New macro. | |
2557 | (gcc_jit_context_new_function): Verify that each param has | |
2558 | not yet been used for creating another function. | |
2559 | (gcc_jit_block_add_eval): After creating the stmt, verify | |
2560 | that the rvalue expression tree is valid to use within it. | |
2561 | (gcc_jit_block_add_assignment): Likewise for the lvalue and | |
2562 | rvalue expression trees. | |
2563 | (gcc_jit_block_add_assignment_op): Likewise. | |
2564 | (gcc_jit_block_end_with_conditional): Likewise for the boolval | |
2565 | expression tree. | |
2566 | (gcc_jit_block_end_with_return): Likewise for the rvalue | |
2567 | expression tree. | |
2568 | (gcc_jit_block_end_with_void_return): Remove return of "void", | |
2569 | now that block::end_with_return is now non-void. | |
2570 | ||
1c35cc2c DM |
2571 | 2015-01-12 David Malcolm <dmalcolm@redhat.com> |
2572 | ||
2573 | * jit-playback.c (gcc::jit::playback::context::read_dump_file): | |
2574 | Add missing fclose on error-handling path. | |
2575 | ||
791cfef8 DM |
2576 | 2015-01-12 David Malcolm <dmalcolm@redhat.com> |
2577 | ||
2578 | * docs/cp/topics/expressions.rst (Global variables): Add | |
2579 | enum gcc_jit_global_kind param to gccjit::context::new_global. | |
2580 | * docs/topics/expressions.rst (Global variables): Likewise. | |
2581 | Document the new enum. | |
2582 | * docs/topics/results.rst (Compilation results): Document | |
2583 | globals-handling. | |
2584 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2585 | * dummy-frontend.c (jit_langhook_write_globals): Call into the | |
2586 | playback context's write_global_decls_1 and write_global_decls_2 | |
2587 | before and after calling symtab->finalize_compilation_unit (). | |
2588 | * jit-playback.c: Include "debug.h". | |
2589 | (gcc::jit::playback::context::new_global): Add "kind" param and | |
2590 | use it to set TREE_PUBLIC, TREE_STATIC and DECL_EXTERNAL on the | |
2591 | underlying VAR_DECL. Call varpool_node::get_create on the | |
2592 | VAR_DECL, and add it to m_globals. | |
2593 | (gcc::jit::playback::context::write_global_decls_1): New function. | |
2594 | (gcc::jit::playback::context::write_global_decls_2): New function. | |
2595 | * jit-playback.h (gcc::jit::playback::context::context): Call | |
2596 | create on m_globals. | |
2597 | (gcc::jit::playback::context::new_global): Add "kind" param. | |
2598 | (gcc::jit::playback::context::write_global_decls_1): New function. | |
2599 | (gcc::jit::playback::context::write_global_decls_2): New function. | |
2600 | (gcc::jit::playback::context::m_globals): New field. | |
2601 | * jit-recording.c (gcc::jit::recording::context::context): | |
2602 | Initialize m_globals. | |
2603 | (gcc::jit::recording::context::new_global): Add param "kind". | |
2604 | Add the new global to m_globals. | |
2605 | (gcc::jit::recording::context::dump_to_file): Dump the globals. | |
2606 | (gcc::jit::recording::global::replay_into): Add field m_kind. | |
2607 | (gcc::jit::recording::global::write_to_dump): New override. | |
2608 | * jit-recording.h (gcc::jit::recording::context::new_global): Add | |
2609 | param "kind". | |
2610 | (gcc::jit::recording::context::m_globals): New field. | |
2611 | (gcc::jit::recording::global::global): Add param kind. | |
2612 | (gcc::jit::recording::global::write_to_dump): New override. | |
2613 | (gcc::jit::recording::global::m_kind): New field. | |
2614 | * jit-result.c (gcc::jit::result::get_global): New function. | |
2615 | * jit-result.h (gcc::jit::result::get_global): New function. | |
2616 | * libgccjit++.h (gccjit::context::new_global): Add "kind" param. | |
2617 | * libgccjit.c (gcc_jit_context_new_global): Likewise. | |
2618 | (gcc_jit_result_get_global): New API entrypoint. | |
2619 | * libgccjit.h (gcc_jit_result_get_global): New API entrypoint. | |
2620 | (enum gcc_jit_global_kind): New enum. | |
2621 | (gcc_jit_context_new_global): API change: add "kind" param. | |
2622 | * libgccjit.map (gcc_jit_result_get_global): New symbol. | |
2623 | ||
860e981c DM |
2624 | 2015-01-09 David Malcolm <dmalcolm@redhat.com> |
2625 | ||
2626 | * dummy-frontend.c: Include "fixed-value.h", "alias.h", "flags.h", | |
2627 | "symtab.h", "inchash.h". Move include of "hash-set.h" much | |
2628 | earlier. | |
2629 | * jit-builtins.c: Remove redundant includes of "opts.h" and | |
2630 | "tree.h". | |
2631 | * jit-common.h: Include "hash-set.h", "input.h", "vec.h", | |
2632 | "double-int.h", "alias.h", "flags.h", "symtab.h", "inchash.h". | |
2633 | * jit-playback.c: Include "hashtab.h", "machmode.h", "input.h", | |
2634 | "statistics.h", "vec.h", "double-int.h", "real.h", | |
2635 | "fixed-value.h", "alias.h", "flags.h", "symtab.h", "tree-core.h", | |
2636 | "inchash.h", "fold-const.h". Move include of "hash-set.h" to | |
2637 | earlier. | |
2638 | * jit-recording.c: Remove redundant includes of "opts.h" and | |
2639 | "tree.h". | |
2640 | ||
ccce3b2a DM |
2641 | 2015-01-09 David Malcolm <dmalcolm@redhat.com> |
2642 | ||
2643 | * docs/cp/topics/expressions.rst (Simple expressions): Use | |
2644 | ":c:type:" for C types. Document new overload of | |
2645 | gcc::jit::context::new_rvalue. | |
2646 | * docs/topics/expressions.rst (Simple expressions): Use | |
2647 | ":c:type:" for C types. Document new entrypoint | |
2648 | gcc_jit_context_new_rvalue_from_long. | |
2649 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2650 | * jit-playback.c: Within namespace gcc::jit::playback... | |
2651 | (context::new_rvalue_from_int): Eliminate in favor of... | |
2652 | (context::new_rvalue_from_const <int>): ...this. | |
2653 | (context::new_rvalue_from_double): Eliminate in favor of... | |
2654 | (context::new_rvalue_from_const <double>): ...this. | |
2655 | (context::new_rvalue_from_const <long>): New. | |
2656 | (context::new_rvalue_from_ptr): Eliminate in favor of... | |
2657 | (context::new_rvalue_from_const <void *>): ...this. | |
2658 | * jit-playback.h: Within namespace gcc::jit::playback... | |
2659 | (context::new_rvalue_from_int): Eliminate in favor of... | |
2660 | (context::new_rvalue_from_const <HOST_TYPE>): ...this. | |
2661 | (context::new_rvalue_from_double): Likewise. | |
2662 | (context::new_rvalue_from_ptr): Likewise. | |
2663 | * jit-recording.c: Within namespace gcc::jit::recording... | |
2664 | (context::new_rvalue_from_int): Eliminate. | |
2665 | (context::new_rvalue_from_double): Likewise. | |
2666 | (context::new_rvalue_from_ptr): Likewise. | |
2667 | (class memento_of_new_rvalue_from_const <int>): | |
2668 | Add explicit specialization. | |
2669 | (class memento_of_new_rvalue_from_const <long>): | |
2670 | Likewise. | |
2671 | (class memento_of_new_rvalue_from_const <double>): | |
2672 | Likewise. | |
2673 | (class memento_of_new_rvalue_from_const <void *>): | |
2674 | Likewise. | |
2675 | (memento_of_new_rvalue_from_int::replay_into): | |
2676 | Generalize into... | |
2677 | (memento_of_new_rvalue_from_const <HOST_TYPE>::replay_into): | |
2678 | ...this... | |
2679 | (memento_of_new_rvalue_from_double::replay_into): | |
2680 | ...allowing this... | |
2681 | (memento_of_new_rvalue_from_ptr::replay_into): | |
2682 | ...and this to be deleted. | |
2683 | (memento_of_new_rvalue_from_int::make_debug_string): | |
2684 | Convert to... | |
2685 | (memento_of_new_rvalue_from_const <int>::make_debug_string): | |
2686 | ...this. | |
2687 | (memento_of_new_rvalue_from_double::make_debug_string): | |
2688 | Convert to... | |
2689 | (memento_of_new_rvalue_from_const <double>::make_debug_string): | |
2690 | ...this. | |
2691 | (memento_of_new_rvalue_from_ptr::make_debug_string) | |
2692 | Convert to... | |
2693 | (memento_of_new_rvalue_from_const <void *>::make_debug_string): | |
2694 | ...this. | |
2695 | (memento_of_new_rvalue_from_const <long>::make_debug_string): | |
2696 | New function. | |
2697 | * jit-recording.h: Within namespace gcc::jit::recording... | |
2698 | (context::new_rvalue_from_int): Eliminate. | |
2699 | (context::new_rvalue_from_double): Likewise. | |
2700 | (context::new_rvalue_from_ptr): Likewise, all in favor of... | |
2701 | (context::new_rvalue_from_const <HOST_TYPE>): New family of | |
2702 | methods. | |
2703 | (class memento_of_new_rvalue_from_int): Eliminate. | |
2704 | (class memento_of_new_rvalue_from_double): Likewise. | |
2705 | (class memento_of_new_rvalue_from_ptr): Likewise. | |
2706 | (class memento_of_new_rvalue_from_const <HOST_TYPE>): New family | |
2707 | of rvalue subclasses. | |
2708 | * libgccjit++.h (gccjit::context::new_rvalue): New overload, for | |
2709 | "long". | |
2710 | * libgccjit.c (gcc_jit_context_new_rvalue_from_int): Update for | |
2711 | rewriting of recording::context::new_rvalue_from_int to | |
2712 | recording::context::new_rvalue_from_const <int>. | |
2713 | (gcc_jit_context_new_rvalue_from_long): New API entrypoint. | |
2714 | (gcc_jit_context_new_rvalue_from_double): Update for | |
2715 | rewriting of recording::context::new_rvalue_from_double to | |
2716 | recording::context::new_rvalue_from_const <double>. | |
2717 | (gcc_jit_context_new_rvalue_from_ptr): Update for | |
2718 | rewriting of recording::context::new_rvalue_from_ptr to | |
2719 | recording::context::new_rvalue_from_const <void *>. | |
2720 | * libgccjit.h (gcc_jit_context_new_rvalue_from_long): New API | |
2721 | entrypoint. | |
2722 | * libgccjit.map (gcc_jit_context_new_rvalue_from_long): Likewise. | |
2723 | ||
d2286af3 DM |
2724 | 2015-01-09 David Malcolm <dmalcolm@redhat.com> |
2725 | ||
2726 | PR jit/64206 | |
2727 | * docs/internals/test-hello-world.exe.log.txt: Update, the log now | |
2728 | shows tempdir creation/cleanup. | |
2729 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2730 | * jit-logging.h (class gcc::jit::log_user): Add gcc::jit::tempdir | |
2731 | to the list of subclasses in the comment. | |
2732 | * jit-playback.c (gcc::jit::playback::context::context): Add a | |
2733 | comment clarifying when the tempdir gets cleaned up. | |
2734 | (gcc::jit::playback::context::compile): Pass the context's logger, | |
2735 | if any, to the tempdir. | |
2736 | (gcc::jit::playback::context::dlopen_built_dso): When creating the | |
2737 | gcc::jit::result, if GCC_JIT_BOOL_OPTION_DEBUGINFO is set, hand | |
2738 | over ownership of the tempdir to it. | |
2739 | * jit-result.c: Include "jit-tempdir.h". | |
2740 | (gcc::jit::result::result): Add tempdir param, saving it as | |
2741 | m_tempdir. | |
2742 | (gcc::jit::result::~result): Delete m_tempdir. | |
2743 | * jit-result.h (gcc::jit::result::result): Add tempdir param. | |
2744 | (gcc::jit::result::m_tempdir): New field. | |
2745 | * jit-tempdir.c (gcc::jit::tempdir::tempdir): Add logger param; | |
2746 | add JIT_LOG_SCOPE. | |
2747 | (gcc::jit::tempdir::create): Add JIT_LOG_SCOPE to log entry/exit, | |
2748 | and log m_path_template and m_path_tempdir. | |
2749 | (gcc::jit::tempdir::~tempdir): Add JIT_LOG_SCOPE to log | |
2750 | entry/exit, and log the unlink and rmdir calls. | |
2751 | * jit-tempdir.h: Include "jit-logging.h". | |
2752 | (class gcc::jit::tempdir): Make this be a subclass of log_user. | |
2753 | (gcc::jit::tempdir::tempdir): Add logger param. | |
2754 | * notes.txt: Update to show the two possible places where the | |
2755 | tempdir can be cleaned up. | |
2756 | ||
7c8db13e DM |
2757 | 2015-01-08 David Malcolm <dmalcolm@redhat.com> |
2758 | ||
2759 | * libgccjit.h (struct gcc_jit_context): Rewrite the descriptive | |
2760 | comment. | |
2761 | ||
303e1d56 DM |
2762 | 2015-01-08 David Malcolm <dmalcolm@redhat.com> |
2763 | ||
2764 | * docs/topics/contexts.rst (Error-handling): Document new | |
2765 | entrypoint gcc_jit_context_get_last_error. | |
2766 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2767 | * jit-recording.c (gcc::jit::recording::context::context): | |
2768 | Initialize new fields "m_last_error_str" and | |
2769 | "m_owns_last_error_str". | |
2770 | (gcc::jit::recording::context::~context): Clean up | |
2771 | m_last_error_str, if needed. | |
2772 | (gcc::jit::recording::context::add_error_va): Update | |
2773 | m_last_error_str and m_owns_last_error_str, freeing the old | |
2774 | value if appropriate. | |
2775 | (gcc::jit::recording::context::get_last_error): New function. | |
2776 | * jit-recording.h (gcc::jit::recording::context::get_last_error): | |
2777 | New function. | |
2778 | (gcc::jit::recording::context): New fields m_last_error_str and | |
2779 | m_owns_last_error_str. | |
2780 | * libgccjit.c (gcc_jit_context_get_last_error): New function. | |
2781 | * libgccjit.h (gcc_jit_context_get_last_error): New declaration. | |
2782 | * libgccjit.map (gcc_jit_context_get_last_error): New function. | |
2783 | ||
eb4c16eb DM |
2784 | 2015-01-08 David Malcolm <dmalcolm@redhat.com> |
2785 | ||
2786 | * Make-lang.in (jit_OBJS): Add jit/jit-logging.o. | |
2787 | * docs/internals/index.rst (Overview of code structure): Mention | |
2788 | gcc_jit_context_set_logfile, and embed the example logfile. | |
2789 | * docs/internals/test-hello-world.exe.log.txt: New file: example | |
2790 | of a logfile. | |
2791 | * docs/topics/contexts.rst (Debugging): Add documentation | |
2792 | for gcc_jit_context_set_logfile. | |
2793 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2794 | * dummy-frontend.c: Include "jit-logging.h". | |
2795 | (jit_langhook_init): Assert that there is an active playback | |
2796 | context. If it has a logger, log entry/exit to this function. | |
2797 | (jit_langhook_write_globals): Likewise. | |
2798 | * jit-common.h (gcc::jit::logger): New forward declaration. | |
2799 | * jit-logging.c: New file. | |
2800 | * jit-logging.h: New file. | |
2801 | * jit-playback.c: Include "jit-logging.h". | |
2802 | (gcc::jit::playback::context::context): Initialize the log_user | |
2803 | base class from the recording context's logger (if any). Use | |
2804 | JIT_LOG_SCOPE to log entry/exit from the function body. | |
2805 | (gcc::jit::playback::context::~context): Use JIT_LOG_SCOPE to | |
2806 | log entry/exit from the function body. | |
2807 | (gcc::jit::playback::build_stmt_list): Likewise. | |
2808 | (gcc::jit::playback::function::postprocess): Likewise. | |
2809 | (gcc::jit::playback::context::compile): Likewise. Log the | |
2810 | entry/exit to toplev::main and toplev::finalize. Log the | |
2811 | fake argv passed to toplev::main. | |
2812 | (gcc::jit::playback::context::acquire_mutex): Use JIT_LOG_SCOPE to | |
2813 | log entry/exit from the function body. | |
2814 | (gcc::jit::playback::context::release_mutex): Likewise. | |
2815 | (gcc::jit::playback::context::make_fake_args): Likewise. | |
2816 | (gcc::jit::playback::context::extract_any_requested_dumps): | |
2817 | Likewise. | |
2818 | (gcc::jit::playback::context::convert_to_dso): Likewise. Also, | |
2819 | log the arguments that the driver is invoked with. | |
2820 | (gcc::jit::playback::context::dlopen_built_dso): Likewise. Pass | |
2821 | the logger to the result object. | |
2822 | (gcc::jit::playback::context::replay): Use JIT_LOG_SCOPE to | |
2823 | log entry/exit from the function body. | |
2824 | (gcc::jit::playback::context::dump_generated_code): Likewise. | |
2825 | (gcc::jit::playback::context::handle_locations): Likewise. | |
2826 | * jit-playback.h (gcc::jit::playback::context): Make this be | |
2827 | a subclass of gcc::jit::log_user. | |
2828 | * jit-recording.c: Include "jit-logging.h". | |
2829 | (gcc::jit::recording::context::context: Initialize the logger to | |
2830 | NULL for root contexts, or to the parent's logger for child | |
2831 | contexts. | |
2832 | (gcc::jit::recording::context::~context): Use JIT_LOG_SCOPE to | |
2833 | log entry/exit from the function body. | |
2834 | (gcc::jit::recording::context::replay_into): Likewise. | |
2835 | (gcc::jit::recording::context::disassociate_from_playback): | |
2836 | Likewise. | |
2837 | (gcc::jit::recording::context::compile): Likewise. | |
2838 | (recording::context::add_error_va): Likewise. Also, log the | |
2839 | error. | |
2840 | (gcc::jit::recording::context::validate): Use JIT_LOG_SCOPE to | |
2841 | log entry/exit from the function body. | |
2842 | * jit-recording.h: Include "jit-logging.h". | |
2843 | (gcc::jit::recording::context): Make this be a subclass of | |
2844 | gcc::jit::log_user. | |
2845 | * jit-result.c: Include "jit-common.h" and "jit-logging.h". | |
2846 | (gcc::jit::result::result): Add logger param, recording it. | |
2847 | Use JIT_LOG_SCOPE to log entry/exit from the function body. | |
2848 | (gcc::jit::result::~result(): Use JIT_LOG_SCOPE to | |
2849 | log entry/exit from the function body. | |
2850 | (gcc::jit::result::get_code): Likewise. | |
2851 | * jit-result.h (gcc::jit::result): Make this be a subclass of | |
2852 | gcc::jit::log_user. | |
2853 | (gcc::jit::result::result): Add logger parameter. | |
2854 | * libgccjit++.h (gccjit::context::set_logfile): New function. | |
2855 | * libgccjit.c: Include "jit-logging.h". | |
2856 | (gcc_jit_context_acquire): Log the context. | |
2857 | (gcc_jit_context_release): Use JIT_LOG_FUNC to | |
2858 | log entry/exit from the function body, and log the context. | |
2859 | (gcc_jit_context_new_child_context): Likewise, logging both | |
2860 | contexts. | |
2861 | (gcc_jit_context_new_location): Use JIT_LOG_FUNC to | |
2862 | log entry/exit from the function body. | |
2863 | (gcc_jit_context_get_type): Likewise. | |
2864 | (gcc_jit_context_get_int_type): Likewise. | |
2865 | (gcc_jit_context_new_array_type): Likewise. | |
2866 | (gcc_jit_context_new_field): Likewise. | |
2867 | (gcc_jit_context_new_struct_type): Likewise. | |
2868 | (gcc_jit_context_new_opaque_struct): Likewise. | |
2869 | (gcc_jit_struct_set_fields): Likewise. | |
2870 | (gcc_jit_context_new_union_type): Likewise. | |
2871 | (gcc_jit_context_new_function_ptr_type): Likewise. | |
2872 | (gcc_jit_context_new_param): Likewise. | |
2873 | (gcc_jit_context_new_function): Likewise. | |
2874 | (gcc_jit_context_get_builtin_function): Likewise. | |
2875 | (gcc_jit_function_get_param): Likewise. | |
2876 | (gcc_jit_function_dump_to_dot): Likewise. | |
2877 | (gcc_jit_function_new_block): Likewise. | |
2878 | (gcc_jit_context_new_global): Likewise. | |
2879 | (gcc_jit_context_new_rvalue_from_int): Likewise. | |
2880 | (gcc_jit_context_zero): Likewise. | |
2881 | (gcc_jit_context_one): Likewise. | |
2882 | (gcc_jit_context_new_rvalue_from_double): Likewise. | |
2883 | (gcc_jit_context_new_rvalue_from_ptr): Likewise. | |
2884 | (gcc_jit_context_null): Likewise. | |
2885 | (gcc_jit_context_new_string_literal): Likewise. | |
2886 | (gcc_jit_context_new_unary_op): Likewise. | |
2887 | (gcc_jit_context_new_binary_op): Likewise. | |
2888 | (gcc_jit_context_new_comparison): Likewise. | |
2889 | (gcc_jit_context_new_call): Likewise. | |
2890 | (gcc_jit_context_new_call_through_ptr): Likewise. | |
2891 | (gcc_jit_context_new_cast): Likewise. | |
2892 | (gcc_jit_context_new_array_access): Likewise. | |
2893 | (gcc_jit_lvalue_access_field): Likewise. | |
2894 | (gcc_jit_rvalue_access_field): Likewise. | |
2895 | (gcc_jit_rvalue_dereference_field): Likewise. | |
2896 | (gcc_jit_rvalue_dereference): Likewise. | |
2897 | (gcc_jit_lvalue_get_address): Likewise. | |
2898 | (gcc_jit_function_new_local): Likewise. | |
2899 | (gcc_jit_block_add_eval): Likewise. | |
2900 | (gcc_jit_block_add_assignment): Likewise. | |
2901 | (gcc_jit_block_add_assignment_op): Likewise. | |
2902 | (gcc_jit_block_end_with_conditional): Likewise. | |
2903 | (gcc_jit_block_add_comment): Likewise. | |
2904 | (gcc_jit_block_end_with_jump): Likewise. | |
2905 | (gcc_jit_block_end_with_return): Likewise. | |
2906 | (gcc_jit_block_end_with_void_return): Likewise. | |
2907 | (gcc_jit_context_set_str_option): Likewise. | |
2908 | (gcc_jit_context_set_int_option): Likewise. | |
2909 | (gcc_jit_context_set_bool_option): Likewise. | |
2910 | (gcc_jit_context_enable_dump): Likewise. | |
2911 | (gcc_jit_context_compile): Likewise. Also log the context, | |
2912 | and the result. | |
2913 | (gcc_jit_context_dump_to_file): Likewise. | |
2914 | (gcc_jit_context_set_logfile): New function. | |
2915 | (gcc_jit_context_get_first_error): Use JIT_LOG_FUNC to | |
2916 | log entry/exit from the function body. | |
2917 | (gcc_jit_result_get_code): Likewise. Also log the fnname) | |
2918 | and the ptr to be returned. | |
2919 | (gcc_jit_result_release): Likewise. Also log the result. | |
2920 | * libgccjit.h: Include <stdio.h>, since we need FILE *. | |
2921 | (gcc_jit_context_set_logfile): New declaration. | |
2922 | * libgccjit.map (gcc_jit_context_set_logfile): New. | |
2923 | ||
c211cd23 DM |
2924 | 2015-01-07 David Malcolm <dmalcolm@redhat.com> |
2925 | ||
2926 | * jit-recording.h (gcc::jit::recording::type::is_void): New | |
2927 | virtual function. | |
2928 | (gcc::jit::recording::memento_of_get_type::is_void): New | |
2929 | function, overriding default implementation. | |
2930 | * libgccjit.c (gcc_jit_rvalue_dereference): Verify that | |
2931 | the underlying type is not "void". | |
2932 | ||
18146f45 DM |
2933 | 2015-01-07 David Malcolm <dmalcolm@redhat.com> |
2934 | ||
2935 | * docs/topics/expressions.rst (Unary Operations): Add | |
2936 | GCC_JIT_UNARY_OP_ABS. | |
2937 | * jit-playback.c (gcc::jit::playback::context::new_unary_op): | |
2938 | Likewise. | |
2939 | * jit-recording.c (unary_op_strings): Likewise. | |
2940 | * libgccjit.c (gcc_jit_context_new_unary_op): Update checking | |
2941 | of "op" to reflect addition of GCC_JIT_UNARY_OP_ABS. | |
2942 | * libgccjit.h (enum gcc_jit_unary_op): Add GCC_JIT_UNARY_OP_ABS. | |
2943 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2944 | ||
11af98ff DM |
2945 | 2015-01-07 David Malcolm <dmalcolm@redhat.com> |
2946 | ||
2947 | * jit-recording.h (gcc::jit::recording::memento_of_get_type): Fix | |
2948 | typo in comment. | |
2949 | ||
433d16df DM |
2950 | 2015-01-07 David Malcolm <dmalcolm@redhat.com> |
2951 | ||
2952 | * TODO.rst (Test suite): Remove item about running C++ testcases. | |
2953 | * docs/internals/index.rst (Working on the JIT library): Add | |
2954 | "c++" to the enabled languages in the suggested "configure" | |
2955 | invocation, and add a description of why this is necessary. | |
2956 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2957 | ||
50bb6c8e DM |
2958 | 2015-01-07 David Malcolm <dmalcolm@redhat.com> |
2959 | ||
2960 | * docs/internals/index.rst: Update to reflect that built | |
2961 | testcases are now test-foo.c.exe, rather than test-foo.exe. | |
2962 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2963 | ||
1e3b6a3d JJ |
2964 | 2015-01-05 Jakub Jelinek <jakub@redhat.com> |
2965 | ||
2966 | Update copyright years. | |
2967 | ||
e8af59bc DM |
2968 | 2014-12-19 David Malcolm <dmalcolm@redhat.com> |
2969 | ||
2970 | * jit-playback.c (gcc::jit::playback::context::build_cast): In | |
2971 | case BOOLEAN_TYPE, don't assume that the source expression is | |
2972 | of type "int". | |
2973 | ||
5afd44e3 DM |
2974 | 2014-12-19 David Malcolm <dmalcolm@redhat.com> |
2975 | ||
2976 | * jit-recording.c (gcc::jit::recording::context::context): When | |
2977 | copying string options from a parent context, take a copy of the | |
2978 | underlying buffers, rather than simply copying the pointer. | |
2979 | ||
1f0858d7 DM |
2980 | 2014-12-19 David Malcolm <dmalcolm@redhat.com> |
2981 | ||
2982 | * jit-recording.c (gcc::jit::recording::context::set_str_option): | |
2983 | Handle NULL. | |
2984 | ||
35291c7d DM |
2985 | 2014-12-11 David Malcolm <dmalcolm@redhat.com> |
2986 | ||
2987 | * docs/cp/topics/contexts.rst (gccjit::context::set_str_option): | |
2988 | Document new function. | |
2989 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
2990 | ||
7b31ff5e DM |
2991 | 2014-12-10 Ulrich Drepper <drepper@gmail.com> |
2992 | ||
2993 | Minor interface cleanups of libgccjit | |
2994 | * jit-playback.c (convert_to_dso): Use auto_vec instead | |
2995 | of automatic array to build up command line. | |
2996 | * jit-recording.c (recording::context::set_str_option): | |
2997 | Make copy of the string. | |
2998 | (recording::context::~context): Free string options. | |
2999 | * jit-recording.h (recording::context): Adjust type | |
3000 | of m_str_options member. | |
3001 | * libgccjit.h: Adjust comment about | |
3002 | gcc_jit_context_set_str_option parameter being used after | |
3003 | the call. | |
3004 | Update comment now that all interfaces are copy strings | |
3005 | if necessary. | |
3006 | * libgccjit++.h (gccjit::context): Add set_str_option | |
3007 | member function. | |
3008 | ||
29df5715 DM |
3009 | 2014-12-10 David Malcolm <dmalcolm@redhat.com> |
3010 | ||
3011 | * docs/cp/index.rst: New file. | |
3012 | * docs/cp/intro/index.rst: New file. | |
3013 | * docs/cp/intro/tutorial01.rst: New file. | |
3014 | * docs/cp/intro/tutorial02.rst: New file. | |
3015 | * docs/cp/intro/tutorial03.rst: New file. | |
3016 | * docs/cp/intro/tutorial04.rst: New file. | |
3017 | * docs/cp/topics/contexts.rst: New file. | |
3018 | * docs/cp/topics/expressions.rst: New file. | |
3019 | * docs/cp/topics/functions.rst: New file. | |
3020 | * docs/cp/topics/index.rst: New file. | |
3021 | * docs/cp/topics/locations.rst: New file. | |
3022 | * docs/cp/topics/objects.rst: New file. | |
3023 | * docs/cp/topics/results.rst: New file. | |
3024 | * docs/cp/topics/types.rst: New file. | |
3025 | * docs/examples/tut01-hello-world.cc: New file. | |
3026 | * docs/examples/tut02-square.c: Fix missing newline in output. | |
3027 | * docs/examples/tut02-square.cc: New file. | |
3028 | * docs/examples/tut03-sum-of-squares.cc: New file. | |
3029 | * docs/examples/tut04-toyvm/toyvm.cc: New file. | |
3030 | * docs/index.rst: Move summary to above the table of contents. | |
3031 | Add text about the C vs C++ APIs. | |
3032 | * docs/topics/contexts.rst: Fix a typo. | |
3033 | ||
3034 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
3035 | * docs/_build/texinfo/factorial1.png: New file. | |
3036 | * docs/_build/texinfo/sum-of-squares1.png: New file. | |
3037 | ||
5cd614ce DM |
3038 | 2014-12-09 David Malcolm <dmalcolm@redhat.com> |
3039 | ||
3040 | * docs/examples/tut04-toyvm/toyvm.c (toyvm_function_compile): Move | |
3041 | logic for determine "funcname" to new function... | |
3042 | (get_function_name): ...here, adding logic to skip any leading | |
3043 | path from the filename. | |
3044 | (toyvm_function_parse): Use the filename for fn_filename, rather | |
3045 | than "name", so that the debugger can locate the source .toy | |
3046 | file. | |
3047 | (toyvm_function_parse): Don't fclose a NULL FILE *. | |
3048 | ||
2712de78 DM |
3049 | 2014-12-09 David Malcolm <dmalcolm@redhat.com> |
3050 | ||
3051 | PR jit/63854 | |
3052 | * docs/internals/index.rst (Running under valgrind): New | |
3053 | subsection. | |
3054 | (docs/_build/texinfo/libgccjit.texi): Regenerate. | |
3055 | ||
d1e5f2c7 DM |
3056 | 2014-12-09 David Malcolm <dmalcolm@redhat.com> |
3057 | ||
92a285c1 | 3058 | PR jit/64206 |
d1e5f2c7 DM |
3059 | * Make-lang.in (jit_OBJS): Add jit/jit-tempdir.o. |
3060 | * jit-common.h (gcc::jit::tempdir): New forward decl. | |
3061 | * jit-playback.c: Include jit-tempdir.h. | |
3062 | (gcc::jit::playback::context::context): Initialize m_tempdir. | |
3063 | (gcc::jit::playback::context::~context): Move tempdir | |
3064 | cleanup to new file jit-tempdir.c | |
3065 | (make_tempdir_path_template): Move to new file jit-tempdir.c. | |
3066 | (gcc::jit::playback::context::compile): Move tempdir creation | |
3067 | to new tempdir object in new file jit-tempdir.c. | |
3068 | (gcc::jit::playback::context::make_fake_args): Get path from | |
3069 | tempdir object rather than from member data. | |
3070 | (gcc::jit::playback::context::convert_to_dso): Likewise. | |
3071 | (gcc::jit::playback::context::dlopen_built_dso): Likewise. | |
3072 | (gcc::jit::playback::context::dump_generated_code): Likewise. | |
3073 | (gcc::jit::playback::context::get_path_c_file): New function. | |
3074 | (gcc::jit::playback::context::get_path_s_file): New function. | |
3075 | (gcc::jit::playback::context::get_path_so_file): New function. | |
3076 | * jit-playback.h (gcc::jit::playback::context::get_path_c_file): | |
3077 | New function. | |
3078 | (gcc::jit::playback::context::get_path_s_file): New function. | |
3079 | (gcc::jit::playback::context::get_path_so_file): New function. | |
3080 | (gcc::jit::playback::context): Move fields "m_path_template", | |
3081 | "m_path_tempdir", "m_path_c_file", "m_path_s_file", | |
3082 | "m_path_so_file" to new jit::tempdir class; add field "m_tempdir". | |
3083 | * jit-tempdir.c: New file. | |
3084 | * jit-tempdir.h: New file. | |
3085 | ||
38771e4e DM |
3086 | 2014-12-09 David Malcolm <dmalcolm@redhat.com> |
3087 | ||
3088 | * jit-playback.c (gcc::jit::playback::context::compile): Acquire the | |
3089 | mutex here, immediately before using toplev, and release it here, on | |
3090 | each exit path after acquisition. | |
3091 | (jit_mutex): Move this variable here, from jit-recording.c. | |
3092 | (gcc::jit::playback::context::acquire_mutex): New function, based on | |
3093 | code in jit-recording.c. | |
3094 | (gcc::jit::playback::context::release_mutex): Likewise. | |
3095 | * jit-playback.h (gcc::jit::playback::context::acquire_mutex): New | |
3096 | function. | |
3097 | (gcc::jit::playback::context::release_mutex): New function. | |
3098 | * jit-recording.c (jit_mutex): Move this variable to jit-playback.c. | |
3099 | (gcc::jit::recording::context::compile): Move mutex-handling from | |
3100 | here into jit-playback.c's gcc::jit::playback::context::compile. | |
3101 | * notes.txt: Update to show the new locations of ACQUIRE_MUTEX | |
3102 | and RELEASE_MUTEX. | |
3103 | ||
38f4f641 DM |
3104 | 2014-12-09 David Malcolm <dmalcolm@redhat.com> |
3105 | ||
3106 | * jit-playback.c (gcc::jit::playback::context::compile): Move the | |
3107 | dlopen code into... | |
3108 | (gcc::jit::playback::context::dlopen_built_dso): ...this new | |
3109 | function. | |
3110 | * jit-playback.h (gcc::jit::playback::context::dlopen_built_dso): | |
3111 | New function. | |
3112 | ||
82e0c914 DM |
3113 | 2014-12-09 David Malcolm <dmalcolm@redhat.com> |
3114 | ||
3115 | PR jit/64166 | |
3116 | * docs/topics/contexts.rst (Debugging): Add description of | |
3117 | gcc_jit_context_enable_dump. | |
3118 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
3119 | * jit-playback.c: Include context.h. | |
3120 | (class auto_argvec): New class. | |
3121 | (auto_argvec::~auto_argvec): New function. | |
3122 | (gcc::jit::playback::context::compile): Convert fake_args to be | |
3123 | an auto_argvec, so that it can contain dynamically-allocated | |
3124 | strings. Construct a vec of all requested dumps, and pass it to | |
3125 | make_fake_args. Extract requested dumps between the calls to | |
3126 | toplev::main and toplev::finalize. | |
3127 | (gcc::jit::playback::context::make_fake_args): Convert param | |
3128 | "argvec" to be a vec <char *>, and gain a "requested_dumps" | |
3129 | param. Convert to dynamically-allocated arg strings by converting | |
3130 | ADD_ARG to take a copy of the arg, and add ADD_ARG_TAKE_OWNERSHIP | |
3131 | for args that are already a copy. Add args for all requested dumps. | |
3132 | (gcc::jit::playback::context::extract_any_requested_dumps): New | |
3133 | function. | |
3134 | (gcc::jit::playback::context::read_dump_file): New function. | |
3135 | * jit-playback.h (gcc::jit::playback::context::make_fake_args): | |
3136 | Convert param "argvec" to be a vec <char *>, and gain a | |
3137 | "requested_dumps" param. | |
3138 | (gcc::jit::playback::context::extract_any_requested_dumps): New | |
3139 | function. | |
3140 | (gcc::jit::playback::context::read_dump_file): New function. | |
3141 | * jit-recording.c (gcc::jit::recording::context::enable_dump): New | |
3142 | function. | |
3143 | (gcc::jit::recording::context::get_all_requested_dumps): New | |
3144 | function. | |
3145 | * jit-recording.h (gcc::jit::recording::requested_dump): New | |
3146 | struct. | |
3147 | (gcc::jit::recording::context::enable_dump): New function. | |
3148 | (gcc::jit::recording::context::get_all_requested_dumps): New | |
3149 | function. | |
3150 | (gcc::jit::recording::context::m_requested_dumps): New field. | |
3151 | * libgccjit.c (gcc_jit_context_enable_dump): New API entrypoint. | |
3152 | * libgccjit.h (gcc_jit_context_enable_dump): New API entrypoint. | |
3153 | * libgccjit.map (gcc_jit_context_enable_dump): New API entrypoint. | |
3154 | ||
53b730ff DM |
3155 | 2014-12-08 David Malcolm <dmalcolm@redhat.com> |
3156 | ||
3157 | * libgccjit++.h: Indent the forward declarations of the classes to | |
3158 | show the inheritance hierarchy. | |
3159 | ||
0f379445 DM |
3160 | 2014-12-08 David Malcolm <dmalcolm@redhat.com> |
3161 | ||
3162 | * notes.txt: Show the beginning and ending of | |
3163 | recording::context::compile vs playback::context::compile. Show | |
3164 | the creation and unlinking of the tempdir. Show toplev::finalize. | |
3165 | Move "RELEASE MUTEX" to the correct location. Show | |
3166 | gcc_jit_result_release, and indicate where the | |
3167 | dlopen/dlsym/dlclose occur. | |
3168 | ||
81ba15f1 DM |
3169 | 2014-12-01 David Malcolm <dmalcolm@redhat.com> |
3170 | ||
3171 | * docs/examples/tut02-square.c (main): Release the context | |
3172 | earlier, to show that this is possible. Update error-handling | |
3173 | to avoid a double-release of the context, and to avoid | |
3174 | releasing a NULL result. | |
3175 | * docs/intro/tutorial02.rst: Discuss gcc_jit_context_release. | |
3176 | * docs/topics/functions.rst (GCC_JIT_FUNCTION_EXPORTED): Emphasize | |
3177 | * docs/topics/results.rst (gcc_jit_result): Mention that this | |
3178 | controls the lifetimes of machine code functions. | |
3179 | (gcc_jit_result_get_code): Spell out the requirements for this | |
3180 | to succeed, and the lifetime of the result. | |
3181 | (gcc_jit_result_release): Mention that this invalidates any code | |
3182 | that was obtained from the result. | |
3183 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
3184 | ||
e250f0dc DM |
3185 | 2014-12-01 David Malcolm <dmalcolm@redhat.com> |
3186 | ||
3187 | PR jit/64018 | |
3188 | * docs/intro/tutorial02.rst: Spell out lifetime of generated code. | |
3189 | Add description of error-handling, taken in part from... | |
3190 | * docs/topics/contexts.rst (Error-handling): Expand, and move some | |
3191 | content to tutorial02.rst. | |
3192 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
3193 | ||
eeafb319 DM |
3194 | 2014-12-01 David Malcolm <dmalcolm@redhat.com> |
3195 | ||
3196 | PR jit/64020 | |
3197 | * docs/topics/types.rst (Standard types) Add new enum values to | |
3198 | the table of enum gcc_jit_types: GCC_JIT_TYPE_COMPLEX_FLOAT, | |
3199 | GCC_JIT_TYPE_COMPLEX_DOUBLE, GCC_JIT_TYPE_COMPLEX_LONG_DOUBLE. | |
3200 | Widen the left-hand column so that | |
3201 | GCC_JIT_TYPE_COMPLEX_LONG_DOUBLE will fit. | |
3202 | * docs/_build/texinfo/libgccjit.texi: Regenerate. | |
3203 | ||
3204 | * jit-builtins.c: Include stringpool.h and jit-playback.h. | |
3205 | Move everything out of the gcc::jit::recording namespace into | |
3206 | just gcc::jit. | |
3207 | (struct builtin_data): Add fields "fnclass", "attr", and | |
3208 | "implicit_p". | |
3209 | (DEF_BUILTIN): Update macro so populate the new fields. | |
3210 | (builtins_manager::builtins_manager): Update for move out of | |
3211 | recording namespace. Initialize the m_attributes array. | |
3212 | (builtins_manager::get_builtin_function): Likewise. | |
3213 | (builtins_manager::get_builtin_function_by_id): New function. | |
3214 | (builtins_manager::make_builtin_function): Update for move out of | |
3215 | recording namespace. Add fix for PR jit/64020 by detecting | |
3216 | specific builtin ids and having them ensure that builtins for | |
3217 | other ids are created as necessary. | |
3218 | (builtins_manager::get_type): Update for move out of recording | |
3219 | namespace. | |
3220 | (builtins_manager::make_type): Likewise. Add some missing | |
3221 | #undefs. | |
3222 | (builtins_manager::make_primitive_type): Update for move out of | |
3223 | recording namespace. Implement the three BT_COMPLEX_ cases and | |
3224 | BT_DOUBLE_PTR. | |
3225 | (builtins_manager::make_fn_type): Update for move out of recording | |
3226 | namespace. | |
3227 | (builtins_manager::make_ptr_type): Likewise. | |
3228 | (builtins_manager::finish_playback): New function. | |
3229 | (builtins_manager::get_class): New function. | |
3230 | (builtins_manager::implicit_p): New function. | |
3231 | (builtins_manager::get_attrs_tree): Two new functions. | |
3232 | (builtins_manager::make_attrs_tree): New function. | |
3233 | ||
3234 | * jit-builtins.h: Move everything out of the gcc::jit::recording | |
3235 | namespace into just gcc::jit. | |
3236 | (enum built_in_attribute): New. | |
3237 | (builtins_manager::builtins_manager): Update decl for namespace | |
3238 | change. | |
3239 | (builtins_manager::get_builtin_function): Likewise. | |
3240 | (builtins_manager::get_class): New. | |
3241 | (builtins_manager::implicit_p): New. | |
3242 | (builtins_manager::get_attrs_tree): Two new functions. | |
3243 | (builtins_manager::make_attrs_tree): New function. | |
3244 | (builtins_manager::finish_playback): New. | |
3245 | (builtins_manager::get_builtin_function_by_id): New. | |
3246 | (builtins_manager::make_builtin_function): Update decl for | |
3247 | namespace change. | |
3248 | (builtins_manager::get_type): Likewise. | |
3249 | (builtins_manager::make_type): Likewise. | |
3250 | (builtins_manager::make_primitive_type): Likewise. | |
3251 | (builtins_manager::make_fn_type): Likewise. | |
3252 | (builtins_manager::make_ptr_type): Likewise. | |
3253 | (builtins_manager): Likewise for fields. Add new field | |
3254 | "m_attributes". | |
3255 | ||
3256 | * jit-common.h (NUM_GCC_JIT_TYPES): Update. | |
3257 | (builtins_manager): Update forward decl to reflect namespace | |
3258 | change. | |
3259 | ||
3260 | * jit-playback.c: Include attribs.h and jit-builtins.h. | |
3261 | (gcc::jit::playback::context::get_tree_node_for_type): Add cases | |
3262 | for the new COMPLEX_ types. | |
3263 | (gcc::jit::playback::context::new_function): If creating a | |
3264 | builtin, set the DECL_BUILT_IN_CLASS and attributes on the fndecl, | |
3265 | and call set_builtin_decl. | |
3266 | (gcc::jit::playback::context::replay): If we have a | |
3267 | builtins_manager, call its finish_playback method when we're done. | |
3268 | ||
3269 | * jit-playback.h: | |
3270 | (gcc::jit::playback::context::get_builtins_manager): New function. | |
3271 | ||
3272 | * jit-recording.c | |
3273 | (gcc::jit::recording::context::get_builtins_manager): New function. | |
3274 | (gcc::jit::recording::get_builtin_function): Use | |
3275 | get_builtins_manager, in case we're a child context. | |
3276 | (gcc::jit::recording::memento_of_get_type::dereference): Add the | |
3277 | COMPLEX_ types. | |
3278 | (gcc::jit::recording::memento_of_get_type::is_int): Likewise. | |
3279 | (gcc::jit::recording::memento_of_get_type::is_float): Likewise. | |
3280 | (gcc::jit::recording::memento_of_get_type::is_bool): Likewise. | |
3281 | (get_type_strings): Likewise. | |
3282 | ||
3283 | * jit-recording.h | |
3284 | (gcc::jit::recording::context::get_builtins_manager): New. | |
3285 | ||
3286 | * libgccjit.h (enum gcc_jit_types): Add | |
3287 | GCC_JIT_TYPE_COMPLEX_FLOAT, GCC_JIT_TYPE_COMPLEX_DOUBLE, | |
3288 | GCC_JIT_TYPE_COMPLEX_LONG_DOUBLE. | |
3289 | ||
23844fd7 DM |
3290 | 2014-12-01 David Malcolm <dmalcolm@redhat.com> |
3291 | ||
3292 | * jit-builtins.c | |
3293 | (gcc::jit::recording::builtins_manager::get_builtin_function): | |
3294 | Check for NULL return from make_builtin_function. | |
3295 | (gcc::jit::recording::builtins_manager::make_builtin_function): | |
3296 | Check for NULL return from get_type. | |
3297 | ||
c6760a13 DM |
3298 | 2014-12-01 David Malcolm <dmalcolm@redhat.com> |
3299 | ||
3300 | * jit-playback.c (gcc::jit::playback::context::compile): Move DSO | |
3301 | creation code into... | |
3302 | (gcc::jit::playback::context::convert_to_dso): New function. | |
3303 | * jit-playback.h (gcc::jit::playback::context::convert_to_dso): | |
3304 | New function. | |
3305 | ||
8f50ee3c DM |
3306 | 2014-12-01 David Malcolm <dmalcolm@redhat.com> |
3307 | ||
3308 | * jit-playback.c (gcc::jit::playback::context::compile): Use an | |
3309 | auto_vec<const char *> rather than a const char *[20] for the | |
3310 | top-level argv, and move the logic to build it to... | |
3311 | (gcc::jit::playback::context::make_fake_args): New function. | |
3312 | * jit-playback.h (gcc::jit::playback::context::make_fake_args): | |
3313 | New function. | |
3314 | ||
56dea35f DM |
3315 | 2014-12-01 David Malcolm <dmalcolm@redhat.com> |
3316 | ||
3317 | * Make-lang.in (jit_OBJS): Add jit/jit-result.o. | |
3318 | * jit-playback.c: Include new header jit-result.h. | |
3319 | (gcc::jit::result::result): Move to new file jit-result.c. | |
3320 | (gcc::jit::result::~result): Likewise. | |
3321 | (gcc::jit::playback::result): Likewise. | |
3322 | * jit-recording.h (class gcc::jit::result): Move to new | |
3323 | header jit-result.h. | |
3324 | * jit-result.c: New file, to contain... | |
3325 | (gcc::jit::result::result): Move here from jit-playback.c, | |
3326 | removing erroneous "playback" namespace from comment. | |
3327 | (gcc::jit::result::~result): Likewise. | |
3328 | (gcc::jit::playback::result): Likewise. | |
3329 | * jit-result.h: New file, to contain... | |
3330 | (class gcc::jit::result): Move from jit-recording.h. | |
3331 | * libgccjit.c: Include jit-result.h. | |
3332 | (gcc_jit_result_get_code): Update comment to reflect move | |
3333 | of implementation. | |
3334 | (gcc_jit_result_release): Likewise. | |
3335 | ||
52b9468f DM |
3336 | 2014-12-01 David Malcolm <dmalcolm@redhat.com> |
3337 | ||
3338 | PR jit/63854 | |
3339 | * docs/examples/tut04-toyvm/toyvm.c | |
3340 | (toyvm_compiled_function): New typedef. | |
3341 | (toyvm_compiled_func) Rename to... | |
3342 | (toyvm_compiled_code) ...this. | |
3343 | (struct toyvm_compiled_function): New struct. | |
3344 | (toyvm_function_compile): Return a toyvm_compiled_function * | |
3345 | rather than a toyvm_compiled_func, so that the caller can fully | |
3346 | clean things up. Free "funcname". | |
3347 | (test_script): Update for change to toyvm_function_compile. | |
3348 | Clean up the toyvm_compiled_function. | |
3349 | (main): Likewise. | |
3350 | (docs/intro/tutorial04.rst): Update to reflect the above changes, | |
3351 | and to better spell out the lifetime of the compiled code. | |
3352 | ||
c8d19a69 DM |
3353 | 2014-12-01 David Malcolm <dmalcolm@redhat.com> |
3354 | ||
3355 | PR jit/63854 | |
3356 | * jit-builtins.c | |
3357 | (gcc::jit::recording::builtins_manager::make_fn_type): Call the | |
3358 | context's new_function_type method, rather than directly creating | |
3359 | a function_type instance. | |
3360 | * jit-recording.c | |
3361 | (gcc::jit::recording::context::new_function_type): New method, | |
3362 | adapted from part of... | |
3363 | (gcc::jit::recording::context::new_function_ptr_type): ...this. | |
3364 | Update to call new_function_type. | |
3365 | * jit-recording.h | |
3366 | (gcc::jit::recording::context::new_function_type): New method. | |
3367 | ||
c985705a DM |
3368 | 2014-12-01 David Malcolm <dmalcolm@redhat.com> |
3369 | ||
3370 | PR jit/63969 | |
3371 | * jit-playback.c: Ensure that ctxt_progname is non-NULL. | |
3372 | ||
b957b2e0 DM |
3373 | 2014-11-19 David Malcolm <dmalcolm@redhat.com> |
3374 | ||
3375 | PR jit/63854 | |
3376 | * jit-playback.c (gcc::jit::playback::compound_type::set_fields): | |
3377 | Convert param from const vec<playback::field *> & to | |
3378 | const auto_vec<playback::field *> *. | |
3379 | (gcc::jit::playback::context::new_function_type): Convert param | |
3380 | "param_types" from vec<type *> * to const auto_vec<type *> *. | |
3381 | (gcc::jit::playback::context::new_function): Convert param | |
3382 | "params" from vec<param *> * to const auto_vec<param *> *. | |
3383 | (gcc::jit::playback::context::build_call): Convert param "args" | |
3384 | from vec<rvalue *> to const auto_vec<rvalue *> *. | |
3385 | (gcc::jit::playback::context::new_call): Likewise. | |
3386 | (gcc::jit::playback::context::new_call_through_ptr): Likewise. | |
3387 | (wrapper_finalizer): New function. | |
3388 | (gcc::jit::playback::wrapper::operator new): Call the finalizer | |
3389 | variant of ggc_internal_cleared_alloc, supplying | |
3390 | wrapper_finalizer. | |
3391 | (gcc::jit::playback::function::finalizer): New. | |
3392 | (gcc::jit::playback::block::finalizer): New. | |
3393 | (gcc::jit::playback::source_file::finalizer): New. | |
3394 | (gcc::jit::playback::source_line::finalizer): New. | |
3395 | ||
3396 | * jit-playback.h | |
3397 | (gcc::jit::playback::context::new_function_type): Convert param | |
3398 | "param_types" from vec<type *> * to const auto_vec<type *> *. | |
3399 | (gcc::jit::playback::context::new_function): Convert param | |
3400 | "params" from vec<param *> * to const auto_vec<param *> *. | |
3401 | (gcc::jit::playback::context::new_call): Convert param | |
3402 | "args" from vec<rvalue *> to const auto_vec<rvalue *> *. | |
3403 | (gcc::jit::playback::context::new_call_through_ptr): Likewise. | |
3404 | (gcc::jit::playback::context::build_call): Likewise. | |
3405 | (gcc::jit::playback::context): Convert fields "m_functions", | |
3406 | "m_source_files", "m_cached_locations" from vec to auto_vec. | |
3407 | (gcc::jit::playback::wrapper::finalizer): New virtual function. | |
3408 | (gcc::jit::playback::compound_type::set_fields): Convert param fro | |
3409 | const vec<playback::field *> & to | |
3410 | const auto_vec<playback::field *> *. | |
3411 | (gcc::jit::playback::function::finalizer): New. | |
3412 | (gcc::jit::playback::block::finalizer): New. | |
3413 | (gcc::jit::playback::source_file::finalizer): New. | |
3414 | (gcc::jit::playback::source_line::finalizer): New. | |
3415 | ||
3416 | * jit-recording.c | |
3417 | (gcc::jit::recording::function_type::replay_into): Convert local | |
3418 | from a vec into an auto_vec. | |
3419 | (gcc::jit::recording::fields::replay_into): Likewise. | |
3420 | (gcc::jit::recording::function::replay_into): Likewise. | |
3421 | (gcc::jit::recording::call::replay_into): Likewise. | |
3422 | (gcc::jit::recording::call_through_ptr::replay_into): Likewise. | |
3423 | ||
3424 | * jit-recording.h (gcc::jit::recording::context): Convert fields | |
3425 | "m_mementos", "m_compound_types", "m_functions" from vec<> to | |
3426 | auto_vec <>. | |
3427 | (gcc::jit::recording::function_type::get_param_types): Convert | |
3428 | return type from vec<type *> to const vec<type *> &. | |
3429 | (gcc::jit::recording::function_type): Convert field | |
3430 | "m_param_types" from a vec<> to an auto_vec<>. | |
3431 | (gcc::jit::recording::fields): Likewise for field "m_fields". | |
3432 | (gcc::jit::recording::function::get_params): Convert return type | |
3433 | from vec <param *> to const vec<param *> &. | |
3434 | (gcc::jit::recording::function): Convert fields "m_params", | |
3435 | "m_locals", "m_blocks" from vec<> to auto_vec<>. | |
3436 | (gcc::jit::recording::block): Likewise for field "m_statements". | |
3437 | vec<> to auto_vec<>. | |
3438 | (gcc::jit::recording::call): Likewise for field "m_args". | |
3439 | (gcc::jit::recording::call_through_ptr): Likewise. | |
3440 | ||
79cafc7a DM |
3441 | 2014-11-19 David Malcolm <dmalcolm@redhat.com> |
3442 | ||
3443 | PR jit/63854 | |
3444 | * jit-recording.c (recording::function::validate): Convert | |
3445 | "worklist" from vec<> to autovec<> to fix a leak. | |
3446 | ||
35485da9 DM |
3447 | 2014-11-11 David Malcolm <dmalcolm@redhat.com> |
3448 | ||
3449 | * ChangeLog.jit: New. | |
3450 | * ChangeLog: New. | |
3451 | * Make-lang.in: New. | |
3452 | * TODO.rst: New. | |
3453 | * config-lang.in: New. | |
3454 | * docs/Makefile: New. | |
3455 | * docs/_build/texinfo/Makefile: New. | |
3456 | * docs/_build/texinfo/factorial.png: New. | |
3457 | * docs/_build/texinfo/libgccjit.texi: New. | |
3458 | * docs/_build/texinfo/sum-of-squares.png: New. | |
3459 | * docs/conf.py: New. | |
3460 | * docs/examples/tut01-hello-world.c: New. | |
3461 | * docs/examples/tut02-square.c: New. | |
3462 | * docs/examples/tut03-sum-of-squares.c: New. | |
3463 | * docs/examples/tut04-toyvm/Makefile: New. | |
3464 | * docs/examples/tut04-toyvm/factorial.toy: New. | |
3465 | * docs/examples/tut04-toyvm/fibonacci.toy: New. | |
3466 | * docs/examples/tut04-toyvm/toyvm.c: New. | |
3467 | * docs/index.rst: New. | |
3468 | * docs/internals/index.rst: New. | |
3469 | * docs/intro/factorial.png: New. | |
3470 | * docs/intro/index.rst: New. | |
3471 | * docs/intro/sum-of-squares.png: New. | |
3472 | * docs/intro/tutorial01.rst: New. | |
3473 | * docs/intro/tutorial02.rst: New. | |
3474 | * docs/intro/tutorial03.rst: New. | |
3475 | * docs/intro/tutorial04.rst: New. | |
3476 | * docs/topics/contexts.rst: New. | |
3477 | * docs/topics/expressions.rst: New. | |
3478 | * docs/topics/functions.rst: New. | |
3479 | * docs/topics/index.rst: New. | |
3480 | * docs/topics/locations.rst: New. | |
3481 | * docs/topics/objects.rst: New. | |
3482 | * docs/topics/results.rst: New. | |
3483 | * docs/topics/types.rst: New. | |
3484 | * dummy-frontend.c: New. | |
3485 | * jit-builtins.c: New. | |
3486 | * jit-builtins.h: New. | |
3487 | * jit-common.h: New. | |
3488 | * jit-playback.c: New. | |
3489 | * jit-playback.h: New. | |
3490 | * jit-recording.c: New. | |
3491 | * jit-recording.h: New. | |
3492 | * libgccjit++.h: New. | |
3493 | * libgccjit.c: New. | |
3494 | * libgccjit.h: New. | |
3495 | * libgccjit.map: New. | |
3496 | * notes.txt: New. | |
3497 | ||
3498 | 2013-07-26 David Malcolm <dmalcolm@redhat.com> | |
3499 | ||
3500 | * Initial creation | |
818ab71a | 3501 | \f |
877e3c2a | 3502 | Copyright (C) 2013-2022 Free Software Foundation, Inc. |
35485da9 DM |
3503 | |
3504 | Copying and distribution of this file, with or without modification, | |
3505 | are permitted in any medium without royalty provided the copyright | |
3506 | notice and this notice are preserved. |