1 2017-12-19 Jakub Jelinek <jakub@redhat.com>
3 * jit-playback.c (get_type, playback::compile_to_file::copy_file,
4 playback::context::acquire_mutex): Replace Yoda conditions with
5 typical order conditions.
6 * libgccjit.c (gcc_jit_context_new_struct_type,
7 gcc_jit_struct_set_fields, gcc_jit_context_new_union_type,
8 gcc_jit_context_new_function, gcc_jit_timer_pop): Likewise.
9 * jit-builtins.c (matches_builtin): Likewise.
10 * jit-recording.c (recording::compound_type::set_fields,
11 recording::fields::write_reproducer, recording::rvalue::set_scope,
12 recording::function::validate): Likewise.
13 * jit-logging.c (logger::decref): Likewise.
15 2017-11-30 Jakub Jelinek <jakub@redhat.com>
18 (recording::memento_of_new_rvalue_from_const <long>::write_reproducer):
21 2017-11-28 Jakub Jelinek <jakub@redhat.com>
23 * jit-playback.c (add_switch): Build SWITCH_EXPR using build2 instead
24 of build3. Formatting fixes. Adjust funciton comment.
26 2017-11-23 Tom de Vries <tom@codesourcery.com>
28 * libgccjit.c (RETURN_NULL_IF_FAIL_NONNULL_NUMERIC_TYPE): Wrap in
31 2017-10-31 David Malcolm <dmalcolm@redhat.com>
33 * docs/internals/index.rst (Running the test suite): Document
35 (Running under valgrind): Add markup to RUN_UNDER_VALGRIND.
36 * docs/_build/texinfo/libgccjit.texi: Regenerate.
38 2017-10-04 David Malcolm <dmalcolm@redhat.com>
40 * docs/cp/topics/expressions.rst (Vector expressions): New
42 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_10): New ABI tag.
43 * docs/topics/expressions.rst (Vector expressions): New section.
44 * docs/topics/types.rst (gcc_jit_type_get_vector): Add link to
45 gcc_jit_context_new_rvalue_from_vector.
46 * docs/_build/texinfo/libgccjit.texi: Regenerate.
47 * jit-common.h (gcc::jit:recording::vector_type): New forward
50 (gcc::jit::playback::context::new_rvalue_from_vector): New method.
52 (gcc::jit::playback::context::new_rvalue_from_vector): New method.
53 * jit-recording.c: In namespace gcc::jit::
54 (class comma_separated_string): New class.
55 (comma_separated_string::comma_separated_string): New ctor,
56 adapted from recording::call::make_debug_string.
57 (comma_separated_string::~comma_separated_string): New dtor.
58 In namespace gcc::jit::recording::
59 (context::new_rvalue_from_vector): New method.
60 (type::get_vector): Update for renaming of memento_of_get_vector.
61 (class memento_of_get_vector): Rename to...
62 (class vector_type): ..this.
63 (memento_of_new_rvalue_from_vector::memento_of_new_rvalue_from_vector):
65 (memento_of_new_rvalue_from_vector::replay_into): New method.
66 (memento_of_new_rvalue_from_vector::visit_children): New method.
67 (memento_of_new_rvalue_from_vector::make_debug_string): New
69 (memento_of_new_rvalue_from_vector::write_reproducer): New method.
70 (call::make_debug_string): Split out arg-printing code into ctor
71 for comma_separated_string.
72 * jit-recording.h: In namespace gcc::jit::recording::
73 (context::new_rvalue_from_vector): New method.
74 (type::dyn_cast_vector_type): New virtual function.
75 (class memento_of_get_vector): Rename to...
76 (class vector_type): ...this.
77 (vector_type::unqualified): Remove this vfunc override in favor
79 (vector_type::get_element_type): ...this new method.
80 (vector_type::get_num_units): New method.
81 (vector_type::dyn_cast_vector_type): New vfunc override.
82 (class memento_of_new_rvalue_from_vector): New class.
83 * libgccjit++.h (gccjit::context::new_rvalue): Add overload for
85 * libgccjit.c (gcc_jit_context_new_binary_op): Strip off type
86 qualifications when checking that both operands have same type.
87 (gcc_jit_context_new_rvalue_from_vector): New API entrypoint.
89 (LIBGCCJIT_HAVE_gcc_jit_context_new_rvalue_from_vector): New
91 (gcc_jit_context_new_rvalue_from_vector): New API entrypoint.
92 * libgccjit.map (LIBGCCJIT_ABI_10): New ABI tag.
94 2017-09-28 David Malcolm <dmalcolm@redhat.com>
96 * docs/topics/expressions.rst (Function calls): Add link to
97 gcc_jit_context_new_function_ptr_type.
98 (Function pointers): Convert to cross-references to
99 function-pointers.rst, moving material there.
100 * docs/topics/function-pointers.rst: New page.
101 * docs/topics/index.rst: Add function-pointers.rst.
102 * docs/topics/types.rst (Function pointer types): New section.
103 * docs/_build/texinfo/libgccjit.texi: Regenerate.
105 2017-09-28 David Malcolm <dmalcolm@redhat.com>
108 (gcc::jit::recording::function_type::is_same_type_as): New function.
109 * jit-recording.h: In namespace gcc::jit::recording::
110 (type::accepts_writes_from): Use is_same_type_as rather than pointer
112 (type::is_same_type_as): New virtual function.
113 (function_type::is_same_type_as): New override.
115 2017-09-27 David Malcolm <dmalcolm@redhat.com>
117 * docs/cp/topics/expressions.rst (Function pointers): New section.
118 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_9): New tag.
119 * docs/topics/expressions.rst (Function pointers): New section.
120 * docs/_build/texinfo/libgccjit.texi: Regenerate.
121 * jit-common.h (class gcc::jit::recording::function_pointer): New
123 * jit-playback.c (gcc::jit::playback::function::get_address): New
125 * jit-playback.h (gcc::jit::playback::function::get_address): New
127 * jit-recording.c: Within namespace gcc::jit::recording...
128 (function::function): Initialize new field "m_fn_ptr_type".
129 (function::get_address): New method.
130 (function_pointer::replay_into): New method.
131 (function_pointer::visit_children): New method.
132 (function_pointer::make_debug_string): New method.
133 (function_pointer::write_reproducer): New method.
134 * jit-recording.h: Within namespace gcc::jit::recording...
135 (function::get_address): New method.
136 (function): Add field "m_fn_ptr_type".
137 (class function_pointer): New subclass of rvalue.
138 * libgccjit++.h (gccjit::function::get_address): New method.
139 * libgccjit.c (gcc_jit_function_get_address): New function.
140 * libgccjit.h (LIBGCCJIT_HAVE_gcc_jit_function_get_address): New
142 (gcc_jit_function_get_address): New API entrypoint.
143 * libgccjit.map (LIBGCCJIT_ABI_9): New tag.
145 2017-09-14 David Malcolm <dmalcolm@redhat.com>
148 * jit-builtins.c (matches_builtin): Ignore entries with a NULL
151 2017-08-18 David Malcolm <dmalcolm@redhat.com>
153 PR tree-optimization/46805
154 * dummy-frontend.c (jit_langhook_parse_file): Handle vector types.
156 2017-08-18 David Malcolm <dmalcolm@redhat.com>
158 * jit-recording.c (class gcc::jit::reproducer): Rename field
159 "m_identifiers" to "m_map_memento_to_identifier". Add field
160 "m_set_identifiers" and struct hash_traits for it.
161 (gcc::jit::reproducer::reproducer): Update for above.
162 (convert_to_identifier): New function.
163 (gcc::jit::reproducer::ensure_identifier_is_unique): New method.
164 (gcc::jit::reproducer::make_identifier): Avoid appending the %p
165 unless necessary for uniqueness. Update for field renaming.
166 (gcc::jit::reproducer::get_identifier): Update for field renaming.
168 2017-08-09 David Malcolm <dmalcolm@redhat.com>
170 * docs/cp/topics/types.rst (Vector types): New section.
171 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_8): New tag.
172 * docs/topics/types.rst (gcc_jit_context_get_type): Fix typo in
174 (Vector types): New section.
175 * docs/_build/texinfo/libgccjit.texi: Regenerate.
176 * jit-playback.c (gcc::jit::playback::type::get_vector): New
178 * jit-playback.h (gcc::jit::playback::type::get_vector): New
180 * jit-recording.c: In namespace gcc::jit::recording::
181 (type::get_vector): New method.
182 (memento_of_get_aligned::write_reproducer): Fix typo
184 (memento_of_get_vector::replay_into): New method.
185 (memento_of_get_vector::make_debug_string): New method.
186 (memento_of_get_vector::write_reproducer): New method.
187 * jit-recording.h: In namespace gcc::jit::recording::
188 (type::get_vector): New
190 (class memento_of_get_vector): New class.
191 * libgccjit++.h (gccjit::type::get_vector): New method.
192 * libgccjit.c (gcc_jit_type_get_vector): New public entrypoint.
193 * libgccjit.h (LIBGCCJIT_HAVE_gcc_jit_type_get_vector): New
195 (gcc_jit_type_get_vector): New decl.
196 * libgccjit.map (LIBGCCJIT_ABI_8): New ABI tag.
198 2017-07-05 Richard Sandiford <richard.sandiford@linaro.org>
199 Alan Hayward <alan.hayward@arm.com>
200 David Sherwood <david.sherwood@arm.com>
202 * dummy-frontend.c (jit_langhook_type_for_mode): Remove "enum" before
205 2017-04-24 David Malcolm <dmalcolm@redhat.com>
207 * docs/cp/topics/types.rst (gccjit::type::get_const): Remove
209 (gccjit::type::get_aligned): Add.
210 * docs/topics/compatibility.rst: Add LIBGCCJIT_ABI_7.
211 * docs/topics/types.rst: Add gcc_jit_type_get_aligned.
212 * docs/_build/texinfo/libgccjit.texi: Regenerate.
213 * jit-playback.c (gcc::jit::playback::type::get_aligned): New
215 * jit-playback.h (gcc::jit::playback::type::get_aligned): New
217 * jit-recording.c: Within namespace gcc::jit::recording...
218 (type::get_aligned): New method.
219 (memento_of_get_aligned::replay_into): New method.
220 (memento_of_get_aligned::make_debug_string): New method.
221 (memento_of_get_aligned::write_reproducer): New method.
222 * jit-recording.h: Within namespace gcc::jit::recording...
223 (type::get_aligned): New method.
224 (type::accepts_writes_from): Strip off qualifications from
225 this when comparing pointer equality.
226 (decorated_type): New subclass of type, subsuming the
227 commonality between memento_of_get_const and
228 memento_of_get_volatile.
229 (memento_of_get_const): Make a subclass of decorated_type,
231 (memento_of_get_volatile): Likewise.
232 (memento_of_get_aligned): Likewise.
233 * libgccjit++.h: Within namespace gccjit...
234 (type::get_const): New method.
235 (type::get_aligned): New method.
236 * libgccjit.c (gcc_jit_type_get_aligned): New function.
237 * libgccjit.h (gcc_jit_type_get_aligned): New decl.
238 * libgccjit.map (LIBGCCJIT_ABI_7): New
239 (gcc_jit_type_get_aligned): Add.
241 2017-01-19 David Malcolm <dmalcolm@redhat.com>
243 * dummy-frontend.c (jit_langhook_type_for_size): Delete.
244 (LANG_HOOKS_TYPE_FOR_SIZE): Don't redefine.
246 2017-01-18 David Malcolm <dmalcolm@redhat.com>
248 * dummy-frontend.c (jit_langhook_type_for_size): Implement, using
249 lto's lto_type_for_size.
251 2017-01-01 Jakub Jelinek <jakub@redhat.com>
253 Update copyright years.
255 2016-05-20 David Malcolm <dmalcolm@redhat.com>
257 * docs/topics/compatibility.rst: Add LIBGCCJIT_ABI_6.
258 * docs/topics/expressions.rst (Function calls): Add documentation
259 of gcc_jit_rvalue_set_bool_require_tail_call.
260 * docs/_build/texinfo/libgccjit.texi: Regenerate.
261 * jit-common.h (gcc::jit::recording::base_call): Add forward decl.
262 * jit-playback.c: Within namespace gcc::jit::playback...
263 (context::build_call) Add "require_tail_call" param and use it
264 to set CALL_EXPR_MUST_TAIL_CALL.
265 (context::new_call): Add "require_tail_call" param.
266 (context::new_call_through_ptr): Likewise.
267 * jit-playback.h: Within namespace gcc::jit::playback...
268 (context::new_call: Add "require_tail_call" param.
269 (context::new_call_through_ptr): Likewise.
270 (context::build_call): Likewise.
271 * jit-recording.c: Within namespace gcc::jit::recording...
272 (base_call::base_call): New constructor.
273 (base_call::write_reproducer_tail_call): New method.
274 (call::call): Update for inheritance from base_call.
275 (call::replay_into): Provide m_require_tail_call to call
277 (call::write_reproducer): Call write_reproducer_tail_call.
278 (call_through_ptr::call_through_ptr): Update for inheritance from
280 (call_through_ptr::replay_into): Provide m_require_tail_call to call
281 to new_call_through_ptr.
282 (recording::call_through_ptr::write_reproducer): Call
283 write_reproducer_tail_call.
284 * jit-recording.h: Within namespace gcc::jit::recording...
285 (rvalue::dyn_cast_base_call): New virtual function.
286 (class base_call): New subclass of class rvalue.
287 (class call): Inherit from base_call rather than directly from
288 rvalue, moving get_precedence and m_args to base_call.
289 (class call_through_ptr): Likewise.
290 * libgccjit.c (gcc_jit_rvalue_set_bool_require_tail_call): New
293 (LIBGCCJIT_HAVE_gcc_jit_rvalue_set_bool_require_tail_call): New
295 (gcc_jit_rvalue_set_bool_require_tail_call): New function.
296 * libgccjit.map (LIBGCCJIT_ABI_6): New.
297 (gcc_jit_rvalue_set_bool_require_tail_call): Add.
299 2016-05-17 David Malcolm <dmalcolm@redhat.com>
301 * dummy-frontend.c: Include diagnostic.h.
302 (jit_begin_diagnostic): New function.
303 (jit_end_diagnostic): New function.
304 (jit_langhook_init): Register jit_begin_diagnostic
305 and jit_end_diagnostic with the global_dc.
306 * jit-playback.c: Include diagnostic.h.
307 (gcc::jit::playback::context::add_diagnostic): New method.
308 * jit-playback.h (struct diagnostic_context): Add forward
310 (gcc::jit::playback::context::add_diagnostic): New method.
312 2016-05-17 David Malcolm <dmalcolm@redhat.com>
314 * docs/topics/expressions.rst (Function calls): Document
315 gcc_jit_context_new_call_through_ptr.
316 * docs/_build/texinfo/libgccjit.texi: Regenerate.
318 2016-05-13 David Malcolm <dmalcolm@redhat.com>
320 * jit-playback.h: Within namespace gcc:jit::playback...
321 (compile_to_memory::postprocess): Mark with FINAL OVERRIDE.
322 (compile_to_file::postprocess): Likewise.
323 (function::finalizer): Likewise.
324 (block::finalizer): Likewise.
325 (source_file::finalizer): Likewise.
326 (source_line::finalizer): Likewise.
327 * jit-recording.c (gcc::jit::rvalue_usage_validator):: Likewise.
328 * jit-recording.h: Within namespace gcc::jit::recording...
329 (string::replay_into): Mark with FINAL OVERRIDE.
330 (string::make_debug_string): Likewise.
331 (string::write_reproducer): Likewise.
332 (location::replay_into): Likewise.
333 (location::dyn_cast_location): Likewise.
334 (location::make_debug_string): Likewise.
335 (location::write_reproducer): Likewise.
336 (memento_of_get_type::dereference): Likewise.
337 (memento_of_get_type::accepts_writes_from): Likewise.
338 (memento_of_get_type::is_int): Likewise.
339 (memento_of_get_type::is_float): Likewise.
340 (memento_of_get_type::is_bool): Likewise.
341 (memento_of_get_type::is_pointer): Likewise.
342 (memento_of_get_type::is_array): Likewise.
343 (memento_of_get_type::is_void): Likewise.
344 (memento_of_get_type::replay_into): Likewise.
345 (memento_of_get_type::make_debug_string): Likewise.
346 (memento_of_get_type::write_reproducer): Likewise.
347 (memento_of_get_pointer::dereference): Likewise.
348 (memento_of_get_pointer::accepts_writes_from): Likewise.
349 (memento_of_get_pointer::replay_into): Likewise.
350 (memento_of_get_pointer::is_int): Likewise.
351 (memento_of_get_pointer::is_float): Likewise.
352 (memento_of_get_pointer::is_bool): Likewise.
353 (memento_of_get_pointer::is_pointer): Likewise.
354 (memento_of_get_pointer::is_array): Likewise.
355 (memento_of_get_pointer::make_debug_string): Likewise.
356 (memento_of_get_pointer::write_reproducer): Likewise.
357 (memento_of_get_const::dereference): Likewise.
358 (memento_of_get_const::accepts_writes_from): Likewise.
359 (memento_of_get_const::unqualified): Likewise.
360 (memento_of_get_const::is_int): Likewise.
361 (memento_of_get_const::is_float): Likewise.
362 (memento_of_get_const::is_bool): Likewise.
363 (memento_of_get_const::is_pointer): Likewise.
364 (memento_of_get_const::is_array): Likewise.
365 (memento_of_get_const::void replay_into): Likewise;
366 (memento_of_get_const::make_debug_string): Likewise.
367 (memento_of_get_const::write_reproducer): Likewise.
368 (memento_of_get_volatile::dereference): Likewise.
369 (memento_of_get_volatile::unqualified): Likewise.
370 (memento_of_get_volatile::is_int): Likewise.
371 (memento_of_get_volatile::is_float): Likewise.
372 (memento_of_get_volatile::is_bool): Likewise.
373 (memento_of_get_volatile::is_pointer): Likewise.
374 (memento_of_get_volatile::is_array): Likewise.
375 (memento_of_get_volatile::replay_into): Likewise;
376 (memento_of_get_volatile::make_debug_string): Likewise.
377 (memento_of_get_volatile::write_reproducer): Likewise.
378 (array_type::dereference): Likewise.
379 (array_type::is_int): Likewise.
380 (array_type::is_float): Likewise.
381 (array_type::is_bool): Likewise.
382 (array_type::is_pointer): Likewise.
383 (array_type::is_array): Likewise.
384 (array_type::replay_into): Likewise;
385 (array_type::make_debug_string): Likewise.
386 (array_type::write_reproducer): Likewise.
387 (function_type::dereference): Likewise.
388 (function_type::function_dyn_cast_function_type): Likewise.
389 (function_type::function_as_a_function_type): Likewise.
390 (function_type::is_int): Likewise.
391 (function_type::is_float): Likewise.
392 (function_type::is_bool): Likewise.
393 (function_type::is_pointer): Likewise.
394 (function_type::is_array): Likewise.
395 (function_type::replay_into): Likewise;
396 (function_type::make_debug_string): Likewise.
397 (function_type::write_reproducer): Likewise.
398 (field::replay_into): Likewise;
399 (field::write_to_dump): Likewise.
400 (field::make_debug_string): Likewise.
401 (field::write_reproducer): Likewise.
402 (compound_type::dereference): Likewise.
403 (compound_type::is_int): Likewise.
404 (compound_type::is_float): Likewise.
405 (compound_type::is_bool): Likewise.
406 (compound_type::is_pointer): Likewise.
407 (compound_type::is_array): Likewise.
408 (compound_type::has_known_size): Likewise.
409 (struct_::dyn_cast_struct): Likewise.
410 (struct_::replay_into): Likewise.
411 (struct_::access_as_type): Likewise.
412 (struct_::make_debug_string): Likewise.
413 (struct_::write_reproducer): Likewise.
414 (fields::replay_into): Likewise.
415 (fields::write_to_dump): Likewise.
416 (fields::make_debug_string): Likewise.
417 (fields::write_reproducer): Likewise.
418 (union_::replay_into): Likewise.
419 (union_::make_debug_string): Likewise.
420 (union_::write_reproducer): Likewise.
421 (lvalue::access_as_rvalue): Mark with OVERRIDE.
422 (param::replay_into): Mark with FINAL OVERRIDE.
423 (param::visit_children): Likewise.
424 (param::dyn_cast_param): Likewise.
425 (param::access_as_rvalue): Likewise.
426 (param::access_as_lvalue): Likewise.
427 (param::make_debug_string): Likewise.
428 (param::write_reproducer): Likewise.
429 (param::get_precedence): Likewise.
430 (function::replay_into): Likewise.
431 (function::write_to_dump): Likewise.
432 (function::make_debug_string): Likewise.
433 (function::write_reproducer): Likewise.
434 (block::write_to_dump): Likewise.
435 (block::make_debug_string): Likewise.
436 (block::write_reproducer): Likewise.
437 (block::replay_into): Likewise.
438 (global::replay_into): Likewise;
439 (global::visit_children): Likewise.
440 (global::write_to_dump): Likewise.
441 (global::make_debug_string): Likewise.
442 (global::write_reproducer): Likewise.
443 (global::get_precedence): Likewise.
444 (memento_of_new_rvalue_from_const::replay_into): Likewise.
445 (memento_of_new_rvalue_from_const::visit_children): Likewise.
446 (memento_of_new_rvalue_from_const::is_constant): Likewise.
447 (memento_of_new_rvalue_from_const::get_wide_int): Likewise.
448 (memento_of_new_rvalue_from_const::make_debug_string): Likewise.
449 (memento_of_new_rvalue_from_const::write_reproducer): Likewise.
450 (memento_of_new_rvalue_from_const::get_precedence): Likewise.
451 (memento_of_new_string_literal::replay_into): Likewise.
452 (memento_of_new_string_literal::visit_children): Likewise.
453 (memento_of_new_string_literal::make_debug_string): Likewise.
454 (memento_of_new_string_literal::write_reproducer): Likewise.
455 (memento_of_new_string_literal::get_precedence): Likewise.
456 (unary_op::replay_into): Likewise.
457 (unary_op::visit_children): Likewise.
458 (unary_op::make_debug_string): Likewise.
459 (unary_op::write_reproducer): Likewise.
460 (unary_op::get_precedence): Likewise.
461 (binary_op::replay_into): Likewise.
462 (binary_op::visit_children): Likewise.
463 (binary_op::make_debug_string): Likewise.
464 (binary_op::write_reproducer): Likewise.
465 (binary_op::get_precedence): Likewise.
466 (comparison::replay_into): Likewise.
467 (comparison::visit_children): Likewise.
468 (comparison::make_debug_string): Likewise.
469 (comparison::write_reproducer): Likewise.
470 (comparison::get_precedence): Likewise.
471 (cast::replay_into): Likewise.
472 (cast::visit_children): Likewise.
473 (cast::make_debug_string): Likewise.
474 (cast::write_reproducer): Likewise.
475 (cast::get_precedence): Likewise.
476 (call::replay_into): Likewise.
477 (call::visit_children): Likewise.
478 (call::make_debug_string): Likewise.
479 (call::write_reproducer): Likewise.
480 (call::get_precedence): Likewise.
481 (call_through_ptr::replay_into): Likewise.
482 (call_through_ptr::visit_children): Likewise.
483 (call_through_ptr::make_debug_string): Likewise.
484 (call_through_ptr::write_reproducer): Likewise.
485 (call_through_ptr::get_precedence): Likewise.
486 (array_access::replay_into): Likewise.
487 (array_access::visit_children): Likewise.
488 (array_access::make_debug_string): Likewise.
489 (array_access::write_reproducer): Likewise.
490 (array_access::get_precedence): Likewise.
491 (access_field_of_lvalue::replay_into): Likewise.
492 (access_field_of_lvalue::visit_children): Likewise.
493 (access_field_of_lvalue::make_debug_string): Likewise.
494 (access_field_of_lvalue::write_reproducer): Likewise.
495 (access_field_of_lvalue::get_precedence): Likewise.
496 (access_field_rvalue::replay_into): Likewise.
497 (access_field_rvalue::visit_children): Likewise.
498 (access_field_rvalue::make_debug_string): Likewise.
499 (access_field_rvalue::write_reproducer): Likewise.
500 (access_field_rvalue::get_precedence): Likewise.
501 (dereference_field_rvalue::replay_into): Likewise.
502 (dereference_field_rvalue::visit_children): Likewise.
503 (dereference_field_rvalue::make_debug_string): Likewise.
504 (dereference_field_rvalue::write_reproducer): Likewise.
505 (dereference_field_rvalue::get_precedence): Likewise.
506 (dereference_rvalue::replay_into): Likewise.
507 (dereference_rvalue::visit_children): Likewise.
508 (dereference_rvalue::make_debug_string): Likewise.
509 (dereference_rvalue::write_reproducer): Likewise.
510 (dereference_rvalue::get_precedence): Likewise.
511 (get_address_of_lvalue::replay_into): Likewise.
512 (get_address_of_lvalue::visit_children): Likewise.
513 (get_address_of_lvalue::make_debug_string): Likewise.
514 (get_address_of_lvalue::write_reproducer): Likewise.
515 (get_address_of_lvalue::get_precedence): Likewise.
516 (local::replay_into): Likewise.
517 (local::visit_children): Likewise.
518 (local::write_to_dump): Likewise.
519 (local::make_debug_string): Likewise.
520 (local::write_reproducer): Likewise.
521 (local::get_precedence): Likewise.
522 (statement::write_to_dump): Likewise.
523 (eval::replay_into): Likewise.
524 (eval::make_debug_string): Likewise.
525 (eval::write_reproducer): Likewise.
526 (assignment::replay_into): Likewise.
527 (assignment::make_debug_string): Likewise.
528 (assignment::write_reproducer): Likewise.
529 (assignment_op::replay_into): Likewise.
530 (assignment_op::make_debug_string): Likewise.
531 (assignment_op::write_reproducer): Likewise.
532 (comment::replay_into): Likewise.
533 (comment::make_debug_string): Likewise.
534 (comment::write_reproducer): Likewise.
535 (conditional::replay_into): Likewise.
536 (conditional::get_successor_blocks): Likewise.
537 (conditional::make_debug_string): Likewise.
538 (conditional::write_reproducer): Likewise.
539 (jump::replay_into): Likewise.
540 (jump::get_successor_blocks): Likewise.
541 (jump::make_debug_string): Likewise.
542 (jump::write_reproducer): Likewise.
543 (return_::replay_into): Likewise.
544 (return_::get_successor_blocks): Likewise.
545 (return_::make_debug_string): Likewise.
546 (return_::write_reproducer): Likewise.
547 (case_::replay_into): Likewise.
548 (case_::write_reproducer): Likewise.
549 (case_::make_debug_string): Likewise.
550 (switch_::replay_into): Likewise.
551 (switch_::get_successor_blocks): Likewise.
552 (switch_::make_debug_string): Likewise.
553 (switch_::write_reproducer): Likewise.
555 2016-02-08 David Malcolm <dmalcolm@redhat.com>
557 * dummy-frontend.c (jit_langhook_init): Remove
558 second argument to build_common_tree_nodes to
561 2016-01-23 Iain Buclaw <ibuclaw@gdcproject.org>
563 * jit-playback.c: Include pthread.h.
565 2016-01-19 David Malcolm <dmalcolm@redhat.com>
568 * jit-playback.c (gcc::jit::playback::compile_to_file::postprocess):
569 Potentially add the temporary artifact to the tempdir's list of
570 tempfiles needing additional cleanup.
571 (gcc::jit::playback::context::extract_any_requested_dumps): Likewise
573 * jit-tempdir.c (gcc::jit::tempdir::~tempdir): Clean up additional
575 * jit-tempdir.h (gcc::jit::tempdir::add_temp_file): New method.
576 (gcc::jit::tempdir::m_tempfiles): New field.
577 * docs/cp/intro/tutorial04.rst: Update for changes to toyvm.cc.
578 * docs/examples/tut04-toyvm/toyvm.cc (class compilation_result):
580 (toyvm_function::compile): Change return type from function ptr
581 to a compilation_result.
582 (toyvm_function::get_function_name): New accessor.
583 (toyvm_function::m_funcname): New field.
584 (get_function_name): Convert to...
585 (toyvm_function::make_function_name): ...this new method.
586 (toyvm_function::parse): Call make_function_name.
587 (toyvm_function::compile): Convert return type from function ptr
588 to a compilation_result. Use get_function_name.
589 (compilation_state::compile): Convert return type from
590 gcc_jit_result * to a compilation_result.
591 (test_script): Update for above changes, extracting the code from
592 the compilation_result.
594 * docs/_build/texinfo/libgccjit.texi: Regenerate.
596 2016-01-04 Jakub Jelinek <jakub@redhat.com>
598 Update copyright years.
600 2015-11-11 Andrew MacLeod <amacleod@redhat.com>
602 * dummy-frontend.c: Remove unused header files.
603 * jit-builtins.c: Likewise.
604 * jit-playback.c: Likewise.
605 * jit-recording.c: Likewise.
606 * jit-spec.c: Likewise.
607 * libgccjit.c: Likewise.
609 2015-11-07 Richard Sandiford <richard.sandiford@arm.com>
611 * jit-builtins.c: Don't undef DEF_BUILTIN.
613 2015-10-29 Andrew MacLeod <amacleod@redhat.com>
615 * dummy-frontend.c: Reorder #include's and remove duplicates.
616 * jit-builtins.c: Likewise.
617 * jit-playback.c: Likewise.
618 * jit-recording.c: Likewise.
619 * libgccjit.c: Likewise.
621 2015-10-13 Jakub Jelinek <jakub@redhat.com>
623 * jit-builtins.c (DEF_FUNCTION_TYPE_9, DEF_FUNCTION_TYPE_10,
624 DEF_FUNCTION_TYPE_11): Define.
625 * jit-builtins.h (DEF_FUNCTION_TYPE_9, DEF_FUNCTION_TYPE_10,
626 DEF_FUNCTION_TYPE_11): Define.
628 2015-09-30 Thomas Schwinge <thomas@codesourcery.com>
629 Ulrich Drepper <drepper@gmail.com>
631 * jit-builtins.h: Undefine DEF_FUNCTION_TYPE_VAR_6 after use.
633 2015-09-30 Matthias Klose <doko@ubuntu.com>
635 * jit-builtins.h Define DEF_FUNCTION_TYPE_VAR_6,
636 remove DEF_FUNCTION_TYPE_VAR_11.
637 * jit-builtins.c (builtins_manager::make_type): Define and handle
638 DEF_FUNCTION_TYPE_VAR_6, remove DEF_FUNCTION_TYPE_VAR_11.
640 2015-08-25 David Malcolm <dmalcolm@redhat.com>
642 * docs/cp/topics/contexts.rst
643 (gccjit::context::set_bool_use_external_driver): New.
644 * docs/internals/test-hello-world.exe.log.txt: Update.
645 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_5): New.
646 * docs/topics/contexts.rst
647 (gcc_jit_context_set_bool_use_external_driver): New.
648 * jit-common.h (enum inner_bool_option): Add
649 INNER_BOOL_OPTION_USE_EXTERNAL_DRIVER.
650 * jit-playback.c (gcc_driver_name): New global.
651 (gcc:jit::playback::context::invoke_driver): Split out second
653 (gcc::jit::playback::context::invoke_embedded_driver): ...this new
655 (gcc::jit::playback::context::invoke_external_driver): ...this new
658 (gcc::jit::playback::context::get_inner_bool_option): New.
659 (gcc::jit::playback::context::invoke_embedded_driver): New.
660 (gcc::jit::playback::context::invoke_external_driver): New.
661 * jit-recording.c (inner_bool_option_reproducer_strings):
662 Add entry for INNER_BOOL_OPTION_USE_EXTERNAL_DRIVER.
664 (gccjit::context::set_bool_use_external_driver): New.
665 * libgccjit.c (gcc_jit_context_set_bool_use_external_driver): New.
666 * libgccjit.h (gcc_jit_context_set_bool_use_external_driver): New.
667 (LIBGCCJIT_HAVE_gcc_jit_context_set_bool_use_external_driver):
669 * libgccjit.map (LIBGCCJIT_ABI_5): New.
670 * notes.txt: Show invocation of embedded copy of driver.
671 * docs/internals/test-hello-world.exe.log.txt: Update
673 2015-08-13 David Malcolm <dmalcolm@redhat.com>
675 * jit-playback.c (invoke_driver): On OS X, add
676 "-Wl,-undefined,dynamic_lookup" to the driver arguments.
678 2015-08-03 David Malcolm <dmalcolm@redhat.com>
680 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_4): New.
681 * docs/topics/contexts.rst (GCC_JIT_BOOL_OPTION_DUMP_SUMMARY):
682 We no longer show a profile.
683 * docs/topics/index.rst (Topic Reference): Add performance.rst.
684 * docs/topics/performance.rst: New file.
685 * docs/_build/texinfo/libgccjit.texi: Regenerate.
686 * jit-playback.c (gcc::jit::playback::context::compile): Add timer
687 param when constructing the "toplev" instance.
688 (gcc::jit::playback::context::acquire_mutex): Add timer param when
689 constructing auto_timevar instance.
690 (gcc::jit::playback::context::make_fake_args): If we have a timer,
692 (gcc::jit::playback::context::invoke_driver): Add timer param when
693 constructing auto_timevar instance.
694 (gcc::jit::playback::context::dlopen_built_dso): Likewise.
695 * jit-playback.h (gcc::jit::playback::context::get_timer): New accessor.
696 * jit-recording.c: Include timevar.h.
697 (gcc::jit::recording::context::context): Initialize field "m_timer".
698 * jit-recording.h: Add forward declaration of class timer.
699 (gcc::jit::recording::context::set_timer): New method.
700 (gcc::jit::recording::context::get_timer): New method.
701 (gcc::jit::recording::context::m_timer): New field.
702 * libgccjit++.h (gccjit::timer): New class.
703 (gccjit::auto_time): New class.
704 (gccjit::context::set_timer): New method.
705 (gccjit::context::get_timer): New.
706 (gccjit::timer::timer): New.
707 (gccjit::timer::push): New.
708 (gccjit::timer::pop): New.
710 (timer::get_inner_timer): New.
711 (timer::release): New.
712 (auto_time::auto_time): New.
713 (auto_time::~auto_time): New.
714 * libgccjit.c: Include timevar.h.
715 (struct gcc_jit_timer): New.
716 (gcc_jit_timer_new): New function.
717 (gcc_jit_timer_release): New function.
718 (gcc_jit_context_set_timer): New function.
719 (gcc_jit_context_get_timer): New function.
720 (gcc_jit_timer_push): New function.
721 (gcc_jit_timer_pop): New function.
722 (gcc_jit_timer_print): New function.
723 * libgccjit.h (LIBGCCJIT_HAVE_TIMING_API): New macro.
724 (gcc_jit_timer): New typedef.
725 (gcc_jit_timer_new): New function.
726 (gcc_jit_timer_release): New function.
727 (gcc_jit_context_set_timer): New function.
728 (gcc_jit_context_get_timer): New function.
729 (gcc_jit_timer_push): New function.
730 (gcc_jit_timer_pop): New function.
731 (gcc_jit_timer_print): New function.
732 * libgccjit.map (LIBGCCJIT_ABI_4): New.
733 (gcc_jit_timer_new): New function.
734 (gcc_jit_timer_release): New function.
735 (gcc_jit_context_set_timer): New function.
736 (gcc_jit_context_get_timer): New function.
737 (gcc_jit_timer_push): New function.
738 (gcc_jit_timer_pop): New function.
739 (gcc_jit_timer_print): New function.
741 2015-07-23 David Malcolm <dmalcolm@redhat.com>
743 * jit-playback.c (invoke_driver): Convert local "argvec"
744 to an auto_argvec, so that it owns copies of the strings,
745 rather than borrows them, updating ADD_ARG to use xstrdup
746 and special-casing the NULL terminator to avoid
747 xstrdup (NULL). Call add_multilib_driver_arguments at the front
749 (MULTILIB_DEFAULTS): Provide a default definition.
750 (multilib_defaults_raw): New constant array.
751 (gcc::jit::playback::context::add_multilib_driver_arguments): New
754 (gcc::jit::playback::context::add_multilib_driver_arguments): New
756 * docs/internals/test-hello-world.exe.log.txt: Update.
757 * docs/_build/texinfo/libgccjit.texi: Regenerate.
759 2015-07-16 David Malcolm <dmalcolm@redhat.com>
761 * docs/internals/index.rst (Overview of code structure): Add note
762 that the implementation is in C++, despite the .c extension.
763 (Submitting patches): New subsection.
764 * docs/_build/texinfo/libgccjit.texi: Regenerate.
766 2015-07-09 Andrew MacLeod <amacleod@redhat.com>
768 * dummy-frontend.c: Adjust includes for flags.h changes.
769 * jit-common.h: Likewise.
770 * jit-playback.c: Likewise.
772 2015-07-08 David Malcolm <dmalcolm@redhat.com>
775 * libgccjit.c (gcc_jit_context_new_field): Show name of field in
776 "unknown size" error message.
777 (gcc_jit_struct_set_fields): Show name of struct in error message.
778 (gcc_jit_context_new_global): Show name of global in
779 "unknown size" error message.
780 (gcc_jit_function_new_local): Likewise for local.
782 2015-07-07 Andrew MacLeod <amacleod@redhat.com>
784 * dummy-frontend.c: Adjust includes.
785 * jit-common.h: Likewise.
786 * jit-playback.c: Likewise.
788 2015-07-07 David Malcolm <dmalcolm@redhat.com>
791 * jit-recording.h: Within namespace gcc:jit::recording...
792 (type::has_known_size): New virtual function.
793 (struct_has_known_size): New function.
794 * libgccjit.c (gcc_jit_context_new_field): Verify that the type
796 (gcc_jit_context_new_global): Likewise.
797 (gcc_jit_function_new_local): Likewise.
799 2015-07-07 David Malcolm <dmalcolm@redhat.com>
802 * dummy-frontend.c (jit_langhook_type_for_mode): Ensure that we
803 handle modes QI, HI, SI, DI, TI.
805 2015-07-01 David Malcolm <dmalcolm@redhat.com>
808 * jit-playback.c (jit_mark_addressable): New function.
809 (gcc::jit::playback::lvalue::get_address): Call
810 jit_mark_addressable on the underlying tree.
812 2015-07-01 David Malcolm <dmalcolm@redhat.com>
814 * docs/topics/types.rst (gcc_jit_context_new_union_type): Add
816 * docs/_build/texinfo/libgccjit.texi: Regenerate.
818 2015-07-01 David Malcolm <dmalcolm@redhat.com>
820 * docs/topics/contexts.rst (gcc_jit_context_set_bool_option):
821 Clarify lack of lifetime requirements on (const char *) parameter.
822 * docs/topics/expressions.rst
823 (gcc_jit_context_new_string_literal): Likewise.
824 (gcc_jit_context_new_global): Likewise.
825 * docs/topics/functions.rst (gcc_jit_context_new_param): Likewise.
826 (gcc_jit_context_new_function): Likewise.
827 (gcc_jit_function_new_block): Likewise.
828 (gcc_jit_block_add_comment): Likewise.
829 * docs/topics/locations.rst (gcc_jit_context_new_location):
831 * docs/topics/types.rst (gcc_jit_context_new_field): Likewise.
832 (gcc_jit_context_new_struct_type): Likewise.
833 * docs/_build/texinfo/libgccjit.texi: Regenerate.
835 2015-06-30 David Malcolm <dmalcolm@redhat.com>
837 * docs/cp/topics/functions.rst (Blocks): Add switch statements to
838 list of ways to terminate a block.
839 (gccjit::block::end_with_switch): Add function description.
840 (gccjit::case_): Add class.
841 (gccjit::context::new_case): Add function description.
842 * docs/cp/topics/objects.rst: Add "case_" to class hierarchy.
843 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_3): New.
844 * docs/topics/functions.rst (Blocks): Add switch statements to
845 list of ways to terminate a block.
846 (gcc_jit_block_end_with_switch): Add function description.
847 (gcc_jit_case): Add type.
848 (gcc_jit_context_new_case): Add function description.
849 (gcc_jit_case_as_object): Add function description.
850 * docs/topics/objects.rst: Add gcc_jit_case to class hierarchy.
851 * docs/_build/texinfo/libgccjit.texi: Regenerate.
852 * jit-common.h (gcc::jit::recording::case_): Add forward decl.
853 (gcc::jit::playback::case_): Add forward decl.
854 * jit-playback.c (add_case): New function.
855 (gcc::jit::playback::block::add_switch): New function.
856 * jit-playback.h (gcc::jit::playback::case_): New struct.
857 (gcc::jit::playback::block::get_function): New method.
858 (gcc::jit::playback::block::add_switch): New method.
859 * jit-recording.c: Within namespace gcc::jit...
860 (recording::context::new_case): New method.
861 (recording::function::validate): Update for change to
862 get_successor_blocks.
863 (recording::block::end_with_switch): New method.
864 (recording::block::get_successor_blocks): Update to support an
865 arbitrary number of successor blocks.
866 (recording::block::dump_edges_to_dot): Likewise.
867 (memento_of_new_rvalue_from_const <int>::get_wide_int): New.
868 (memento_of_new_rvalue_from_const <long>::get_wide_int): New.
869 (memento_of_new_rvalue_from_const <double>::get_wide_int): New.
870 (memento_of_new_rvalue_from_const <void *>::get_wide_int): New.
871 (recording::statement::get_successor_blocks): Update to support an
872 arbitrary number of successor blocks.
873 (recording::conditional::get_successor_blocks): Likewise.
874 (recording::jump::get_successor_blocks): Likewise.
875 (recording::return_::get_successor_blocks): Likewise.
876 (recording::case_::write_reproducer): New.
877 (recording::case_::make_debug_string): New.
878 (recording::switch_::switch_): New.
879 (recording::switch_::replay_into): New.
880 (recording::switch_::get_successor_blocks): New.
881 (recording::switch_::make_debug_string): New.
882 (recording::switch_::write_reproducer): New.
883 * jit-recording.h: Within namespace gcc::jit::recording...
884 (context::new_case): New.
885 (rvalue::is_constant): New.
886 (rvalue::get_wide_int): New.
887 (block::end_with_switch): New.
888 (block::get_successor_blocks): Update to support an arbitrary
889 number of successor blocks.
890 (memento_of_new_rvalue_from_const::is_constant): New.
891 (memento_of_new_rvalue_from_const::get_wide_int): New.
892 (statement::get_successor_blocks): Update to support an arbitrary
893 number of successor blocks.
894 (conditional::get_successor_blocks): Likewise.
895 (jump::get_successor_blocks): Likewise.
896 (return_::get_successor_blocks): Likewise.
897 (case_): New subclass of memento.
898 (switch_): New subclass of statement.
899 * libgccjit++.h (gccjit::case_): New subclass of gccjit::object.
900 (gccjit::context::new_case): New method.
901 (gccjit::block::end_with_switch): New method.
902 (gccjit::case_::case): New ctors.
903 (gccjit::case_::get_inner_case): New method.
904 * libgccjit.c: Include "typed-splay-tree.h"
905 (struct gcc_jit_case): New.
906 (gcc_jit_context_new_case): New function.
907 (gcc_jit_case_as_object): New function.
908 (valid_dest_for_switch): New function.
909 (valid_case_for_switch): New function.
910 (class api_call_validator): New class.
911 (class case_range_validator): New class.
912 (case_range_validator::case_range_validator): New.
913 (case_range_validator::validate): New.
914 (case_range_validator::case_compare): New.
915 (case_range_validator::get_wide_int): new.
916 (gcc_jit_block_end_with_switch): New.
917 * libgccjit.h: Add gcc_jit_case to class hierarchy comment.
918 (gcc_jit_case): New typedef.
919 (gcc_jit_context_new_case): New function.
920 (gcc_jit_case_as_object): New function.
921 (gcc_jit_block_end_with_switch): New function.
922 (LIBGCCJIT_HAVE_SWITCH_STATEMENTS): New.
923 * libgccjit.map: Add gcc_jit_block_end_with_switch,
924 gcc_jit_case_as_object and gcc_jit_context_new_case.
926 2015-06-30 David Malcolm <dmalcolm@redhat.com>
929 * docs/cp/topics/contexts.rst
930 (gccjit::context::set_bool_allow_unreachable_blocks): New.
931 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_2): New.
932 * docs/topics/contexts.rst (Options): Add notes discussing the
933 transition from enums to entrypoints for new options.
934 (gcc_jit_context_set_bool_allow_unreachable_blocks): New.
935 * docs/_build/texinfo/libgccjit.texi: Regenerate.
936 * jit-common.h (gcc::jit::inner_bool_option): New enum.
937 * jit-recording.c: Within namespace gcc::jit...
938 (recording::context::context): Handle m_inner_bool_options.
939 (recording::context::set_inner_bool_option): New.
940 (inner_bool_option_reproducer_strings): New.
941 (recording::context::log_all_options): Log the "inner" bool
943 (recording::context::log_inner_bool_option): New.
944 (recording::context::dump_reproducer_to_file): Write initializers
945 for "inner" bool options.
946 (recording::function::validate): Don't check for block
947 reachability if INNER_BOOL_OPTION_ALLOW_UNREACHABLE_BLOCKS is set.
948 * jit-recording.h: Within namespace gcc::jit...
949 (recording::context::set_inner_bool_option): New.
950 (recording::context::get_inner_bool_option): New.
951 (recording::context::log_inner_bool_option): New.
952 (recording::context::m_inner_bool_options): New.
954 (gccjit::context::set_bool_allow_unreachable_blocks): New.
956 (gcc_jit_context_set_bool_allow_unreachable_blocks): New.
957 * libgccjit.h: Add note about options present in the
958 initial release of libgccjit.
959 (gcc_jit_context_set_bool_allow_unreachable_blocks): New API
961 (LIBGCCJIT_HAVE_gcc_jit_context_set_bool_allow_unreachable_blocks):
963 * libgccjit.map (LIBGCCJIT_ABI_2): New, containing...
964 (gcc_jit_context_set_bool_allow_unreachable_blocks): ...this new
967 2015-06-30 David Malcolm <dmalcolm@redhat.com>
970 * docs/cp/topics/contexts.rst (Additional command-line options):
972 * docs/topics/compatibility.rst: New file.
973 * docs/topics/contexts.rst (Additional command-line options): New
975 * docs/topics/index.rst: Add compatibility.rst.
976 * docs/_build/texinfo/libgccjit.texi: Regenerate.
977 * jit-playback.c (make_fake_args): Add call to
978 append_command_line_options.
979 * jit-recording.c: Within namespace gcc::jit...
980 (recording::context::~context): Free the optnames within
981 m_command_line_options.
982 (recording::context::set_bool_option): Likewise.
983 (recording::context::add_command_line_option): New method.
984 (recording::context::append_command_line_options): New method.
985 (recording::context::dump_reproducer_to_file): Add command-line
987 * jit-recording.h: Within namespace gcc::jit...
988 (recording::context::add_command_line_option): New method.
989 (recording::context::append_command_line_options): New method.
990 (recording::context::m_command_line_options): New field.
991 * libgccjit++.h (gccjit::context::add_command_line_option): New
993 * libgccjit.c (gcc_jit_context_add_command_line_option): New API
995 * libgccjit.h (gcc_jit_context_add_command_line_option): New API
997 (LIBGCCJIT_HAVE_gcc_jit_context_add_command_line_option): New
999 * libgccjit.map: Put existing symbols within LIBGCCJIT_ABI_0; add
1000 LIBGCCJIT_ABI_1 and gcc_jit_context_add_command_line_option.
1002 2015-06-30 David Malcolm <dmalcolm@redhat.com>
1005 (gcc::jit::recording::context::dump_reproducer_to_file):
1006 Add pragma to generated reproducers to disable -Wunused-variable.
1007 Fix handling of NULL string options.
1009 2015-06-30 David Malcolm <dmalcolm@redhat.com>
1011 * docs/cp/topics/expressions.rst: Remove stray semicolon.
1012 * docs/cp/topics/functions.rst: Remove stray backslash.
1013 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1015 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
1017 * dummy-frontend.c: Remove ipa-ref.h and plugin-api.h from include list.
1018 * jit-playback.c: Likewise.
1020 2015-06-25 Andrew Macleod <amacleod@redhat.com>
1022 * jit-common.h: Don't include alias.h.
1024 2015-06-17 David Malcolm <dmalcolm@redhat.com>
1026 * libgccjit.c (gcc_jit_lvalue_access_field): Verify that the field
1027 is for the correct struct.
1028 (gcc_jit_rvalue_access_field): Likewise.
1030 2015-06-17 Andrew MacLeod <amacleod@redhat.com>
1032 * dummy-frontend.c: Do not include input.h, line-map.h or is-a.h.
1033 * jit-common.h: Likewise.
1034 * jit-playback.c: Likewise.
1036 2015-06-16 David Malcolm <dmalcolm@redhat.com>
1039 * jit-recording.c: Within namespace gcc::jit::recording::
1040 (rvalue::get_debug_string_parens): New function.
1041 (binary_op::make_debug_string): Update to mimic C precedence
1043 (binary_op_precedence): New array.
1044 (binary_op::get_precedence): New function.
1045 (comparison::make_debug_string): Update to mimic C precedence
1047 (comparison_precedence): New array.
1048 (comparison::get_precedence): New function.
1049 (cast::make_debug_string): Update to mimic C precedence rules.
1050 (call::make_debug_string): Likewise.
1051 (call_through_ptr::make_debug_string): Likewise.
1052 (array_access::make_debug_string): Likewise.
1053 (access_field_of_lvalue::make_debug_string): Likewise.
1054 (access_field_rvalue::make_debug_string): Likewise.
1055 (dereference_field_rvalue::make_debug_string): Likewise.
1056 (dereference_rvalue::make_debug_string): Likewise.
1057 (get_address_of_lvalue::make_debug_string): Likewise.
1058 * jit-recording.h: Within namespace gcc::jit::recording::
1059 (precedence): New enum.
1060 (rvalue::rvalue): Initialize field "m_parenthesized_string".
1061 (rvalue::get_debug_string_parens): New method.
1062 (rvalue::get_precedence): New pure virtual function.
1063 (rvalue::m_parenthesized_string): New field.
1064 (param::get_precedence): New function.
1065 (global::get_precedence): New function.
1066 (memento_of_new_rvalue_from_const::get_precedence): New function.
1067 (memento_of_new_string_literal::get_precedence): New function.
1068 (unary_op::get_precedence): New function.
1069 (binary_op::get_precedence): New function.
1070 (comparison::get_precedence): New function.
1071 (cast::get_precedence): New function.
1072 (call::get_precedence): New function.
1073 (call_through_ptr::get_precedence): New function.
1074 (array_access::get_precedence): New function.
1075 (access_field_of_lvalue::get_precedence): New function.
1076 (access_field_rvalue::get_precedence): New function.
1077 (dereference_field_rvalue::get_precedence): New function.
1078 (dereference_rvalue::get_precedence): New function.
1079 (get_address_of_lvalue::get_precedence): New function.
1080 (local::get_precedence): New function.
1082 2015-06-09 Matthias Klose <doko@ubuntu.com>
1084 * Make-lang.in (jit.install-common): Install headers using INSTALL_DATA.
1086 2015-06-08 Andrew MacLeod <amacleod@redhat.com>
1088 * dummy-frontend.c : Adjust include files.
1089 * jit-common.h : Likewise.
1090 * jit-playback.c : Likewise.
1092 2015-06-05 David Malcolm <dmalcolm@redhat.com>
1095 (jit_langhook_post_compilation_parsing_cleanups): Remove.
1096 (LANG_HOOKS_POST_COMPILATION_PARSING_CLEANUPS): Remove
1097 * jit-playback.c (gcc::jit::playback::context::new_global): Add
1098 call to varpool_node::finalize_decl.
1099 (gcc::jit::playback::context::finalize_global_decls): Remove.
1101 (gcc::jit::playback::context::finalize_global_decls): Remove.
1103 2015-06-05 David Malcolm <dmalcolm@redhat.com>
1105 * dummy-frontend.c (jit_langhook_write_globals): Rename to...
1106 (jit_langhook_post_compilation_parsing_cleanups): ...this, and
1107 eliminate calls to finalize_compilation_unit and
1108 write_global_decls_2.
1109 (LANG_HOOKS_WRITE_GLOBALS): Rename to...
1110 (LANG_HOOKS_POST_COMPILATION_PARSING_CLEANUPS): ...this and
1111 redirect from jit_langhook_write_globals to
1112 jit_langhook_post_compilation_parsing_cleanups.
1114 (gcc::jit::playback::context::write_global_decls_1): Rename to...
1115 (gcc::jit::playback::context::finalize_global_decls): ...this.
1116 (gcc::jit::playback::context::write_global_decls_1): Delete.
1118 (gcc::jit::playback::context::write_global_decls_1): Rename to...
1119 (gcc::jit::playback::context::finalize_global_decls): ...this.
1120 (gcc::jit::playback::context::write_global_decls_1): Delete.
1122 2015-06-04 Andrew MacLeod <amacleod@redhat.com>
1124 * dummy-frontend.c: Adjust includes for restructured coretypes.h.
1125 * jit-common.h: Likewise.
1126 * jit-playback.c: Likewise.
1128 2015-05-12 David Malcolm <dmalcolm@redhat.com>
1130 * jit-builtins.c: Include vec.h before target.h.
1132 2015-04-27 Jim Wilson <jim.wilson@linaro.org>
1134 * Make-lang.in (jit.mostlyclean): Remove shared libraries and object
1137 2015-04-09 David Malcolm <dmalcolm@redhat.com>
1140 * docs/cp/topics/expressions.rst (Simple expressions): Fix copy
1141 and paste error in description of gccjit::context::one.
1142 * docs/topics/expressions.rst (Simple expressions): Likewise in
1143 description of gcc_jit_context_one.
1144 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1146 2015-03-13 Uros Bizjak <ubizjak@gmail.com>
1148 * jit-recording.c (dump::write): Also check vasprintf return value.
1149 (recording::context::add_error_va): Ditto.
1150 (recording::string::from_printf): Ditto.
1152 2015-03-13 David Malcolm <dmalcolm@redhat.com>
1154 * docs/internals/index.rst (Packaging notes): New section.
1155 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1157 2015-03-05 David Malcolm <dmalcolm@redhat.com>
1159 * docs/cp/intro/tutorial03.rst: Add missing arguments to
1160 gccjit::block::end_with_conditional call. Add on_true/on_false
1161 comments. Tweak the wording.
1162 * docs/intro/tutorial03.rst: Add missing arguments to
1163 gcc_jit_block_end_with_conditional call. Add some clarifying
1165 * docs/topics/compilation.rst: Tweak the wording to avoid an
1166 ambiguous use of "this".
1167 * docs/topics/contexts.rst: Fix a typo.
1168 * docs/topics/expressions.rst (GCC_JIT_BINARY_OP_MINUS): Remove
1170 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1172 2015-02-24 Thomas Schwinge <thomas@codesourcery.com>
1175 * jit-builtins.c (DEF_FUNCTION_TYPE_VAR_8)
1176 (DEF_FUNCTION_TYPE_VAR_12): Remove macros.
1177 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
1178 * jit-builtins.h (DEF_FUNCTION_TYPE_VAR_8)
1179 (DEF_FUNCTION_TYPE_VAR_12): Remove macros.
1180 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
1182 2015-02-04 David Malcolm <dmalcolm@redhat.com>
1185 * docs/conf.py (html_theme): Change from 'pyramid'
1188 2015-02-04 David Malcolm <dmalcolm@redhat.com>
1190 * docs/topics/contexts.rst (gcc_jit_context_acquire): Fix
1192 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1194 2015-02-03 David Malcolm <dmalcolm@redhat.com>
1196 * jit-logging.h (gcc::jit::log_user::log): Make const.
1197 * jit-recording.c (gcc::jit::recording::context::set_str_option):
1198 Log the new value of the option.
1199 (gcc::jit::recording::context::set_int_option): Likewise.
1200 (gcc::jit::recording::context::set_bool_option): Likewise.
1201 (gcc::jit::recording::context::compile): Log the value of all
1203 (gcc::jit::recording::context::compile_to_file): Likewise.
1204 (gcc::jit::recording::context::log_all_options): New function.
1205 (gcc::jit::recording::context::log_str_option): New function.
1206 (gcc::jit::recording::context::log_int_option): New function.
1207 (gcc::jit::recording::context::log_bool_option): New function.
1208 * jit-recording.h (gcc::jit::recording::context::log_all_options):
1210 (gcc::jit::recording::context::log_str_option): New function.
1211 (gcc::jit::recording::context::log_int_option): New function.
1212 (gcc::jit::recording::context::log_bool_option): New function.
1213 * docs/internals/test-hello-world.exe.log.txt: Update for above
1215 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1217 2015-02-03 David Malcolm <dmalcolm@redhat.com>
1220 * Make-lang.in (jit_OBJS): Add jit/jit-spec.o and gcc.o.
1221 (LIBGCCJIT_FILENAME): Add EXTRA_GCC_OBJS.
1222 * jit-playback.c: Include gcc.h.
1223 (gcc::jit::playback::context::compile): Move mutex acquisition
1224 to before the call to make_fake_args.
1225 (append_arg_from_driver): New function.
1226 (gcc::jit::playback::context::make_fake_args): On the first call,
1227 call into driver_get_configure_time_options to get configure-time
1228 default options and cache them. Add them to the args for
1230 * jit-spec.c: New source file.
1231 * docs/internals/test-hello-world.exe.log.txt: Update to reflect
1233 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1235 2015-02-02 David Malcolm <dmalcolm@redhat.com>
1238 * dummy-frontend.c (jit_langhook_type_for_mode): Support
1239 TYPE_MODE (long_long_integer_type_node).
1241 2015-01-27 David Malcolm <dmalcolm@redhat.com>
1243 * docs/internals/test-hello-world.exe.log.txt: Add example version
1245 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1246 * jit-common.h (gcc::jit::dump::get_file): New accessor.
1247 * jit-logging.c: Include toplev.h.
1248 (gcc::jit::logger::logger): Log the GCC version.
1249 * jit-recording.c: Include toplev.h.
1250 (gcc:jit::recording::context::dump_reproducer_to_file): Log the
1253 2015-01-26 David Malcolm <dmalcolm@redhat.com>
1255 * docs/topics/compilation.rst (gcc_jit_result_get_code): Fix typo.
1256 * docs/topics/contexts.rst (gcc_jit_context_get_last_error): The
1257 error buffer is only valid until the next call to the context.
1258 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1259 * libgccjit.h (gcc_jit_context_get_first_error): Reword the
1260 comment to omit mention of compiling.
1261 (gcc_jit_context_get_last_error): The error buffer is only valid
1262 until the next call to the context.
1264 2015-01-26 David Malcolm <dmalcolm@redhat.com>
1267 * config-lang.in (compilers): Drop "libgccjit.so".
1269 2015-01-23 David Malcolm <dmalcolm@redhat.com>
1272 * jit-playback.c (gcc::jit::playback::context::compile): Construct
1273 toplev instances with init_signals=false.
1275 2015-01-19 David Malcolm <dmalcolm@redhat.com>
1277 * docs/cp/topics/results.rst: Rename to...
1278 * docs/cp/topics/compilation.rst: ...this, and add section on
1279 ahead-of-time compilation.
1280 * docs/cp/topics/index.rst: Update for renaming of results.rst
1282 * docs/examples/emit-alphabet.bf: New file, a sample "brainf"
1284 * docs/examples/tut05-bf.c: New file, implementing a compiler
1286 * docs/internals/test-hello-world.exe.log.txt: Update to reflect
1287 changes to logger output.
1288 * docs/intro/index.rst: Add tutorial05.rst
1289 * docs/intro/tutorial05.rst: New file.
1290 * docs/topics/results.rst: Rename to...
1291 * docs/topics/compilation.rst: ...this, and add section on
1292 ahead-of-time compilation.
1293 * docs/topics/index.rst: Update for renaming of results.rst to
1295 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1296 * jit-playback.c (gcc::jit::playback::context::compile): Convert
1297 return type from result * to void. Move the code to convert to
1298 dso and dlopen the result to a new pure virtual "postprocess"
1300 (gcc::jit::playback::compile_to_memory::compile_to_memory): New
1302 (gcc::jit::playback::compile_to_memory::postprocess): New
1303 function, based on playback::context::compile.
1304 (gcc::jit::playback::compile_to_file::compile_to_file): New
1306 (gcc::jit::playback::compile_to_file::postprocess): New function.
1307 (gcc::jit::playback::compile_to_file::copy_file): New function.
1308 (gcc::jit::playback::context::convert_to_dso): Move internals
1310 (gcc::jit::playback::context::invoke_driver): New method. Add
1311 "-shared" and "-c" options to driver's argv as needed.
1312 * jit-playback.h: Include "timevar.h".
1313 (gcc::jit::playback::context::compile): Convert return type from
1315 (gcc::jit::playback::context::postprocess): New pure virtual
1316 function, making this an abstract base class.
1317 (gcc::jit::playback::context::get_tempdir): New accessor.
1318 (gcc::jit::playback::context::invoke_driver): New function.
1319 (class gcc::jit::playback::compile_to_memory): New subclass of
1321 (class gcc::jit::playback::compile_to_file): Likewise.
1322 * jit-recording.c (gcc::jit::recording::context::compile): Use a
1323 playback::compile_to_memory, and extract its result.
1324 (gcc::jit::recording::context::compile_to_file): New function.
1325 * jit-recording.h (gcc::jit::recording::context::compile_to_file):
1327 * libgccjit++.h (gccjit::context::compile_to_file): New method.
1328 * libgccjit.c (gcc_jit_context_compile): Update log message to
1329 clarify that this is an in-memory compile.
1330 (gcc_jit_context_compile_to_file): New function.
1331 * libgccjit.h (gcc_jit_context): Clarify that you can compile
1332 a context more than once, and that you can compile to a file
1333 as well as to memory.
1334 (gcc_jit_result): Clarify that this is the result of an
1335 in-memory compilation.
1336 (gcc_jit_context_compile): Clarify that you can compile, and that
1337 this is an in-memory compilation.
1338 (enum gcc_jit_output_kind): New enum.
1339 (gcc_jit_context_compile_to_file): New function.
1340 (gcc_jit_context_enable_dump): Clarify comment to cover both forms
1342 * libgccjit.map (gcc_jit_context_compile_to_file): New API
1344 * notes.txt: Update to show the playback::context::postprocess
1347 2015-01-19 David Malcolm <dmalcolm@redhat.com>
1350 (gcc::jit::recording::memento_of_new_string_literal::make_debug_string):
1351 Add missing format string.
1353 2015-01-16 David Malcolm <dmalcolm@redhat.com>
1355 * Make-lang.in (lang_checks_parallelized): Add "check-jit".
1356 (check_jit_parallelize): Set this to an arbitrary value (10).
1358 2015-01-16 Jakub Jelinek <jakub@redhat.com>
1360 * jit-builtins.h (DEF_FUNCTION_TYPE_VAR_5): Fix spelling of
1362 (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12): Define and
1364 * jit-builtins.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
1367 2015-01-15 Richard Sandiford <richard.sandiford@arm.com>
1369 Update copyright years in docs/.
1371 2015-01-15 David Malcolm <dmalcolm@redhat.com>
1373 * libgccjit.c (gcc_jit_block_add_assignment_op): Check that the
1374 lvalue and the rvalue are of compatible type.
1376 2015-01-13 David Malcolm <dmalcolm@redhat.com>
1378 * docs/cp/topics/contexts.rst (Debugging): Add
1379 gccjit::context::dump_reproducer_to_file.
1380 * docs/internals/index.rst (Design notes): New section,
1381 discussing input validation and
1382 gcc_jit_context_dump_reproducer_to_file.
1383 * docs/topics/contexts.rst (Debugging): Add
1384 gcc_jit_context_dump_reproducer_to_file.
1385 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1386 * jit-common.h (gcc::jit::dump::get_context): New accessor.
1387 * jit-recording.c: Include "hash-map.h".
1388 Within namespace ::gcc::jit...
1389 (dump::write): Flush each line.
1390 (dump::make_location): Pass false for new param "created_by_user".
1391 (class allocator): New class.
1392 (allocator::~allocator): New function.
1393 (allocator::xstrdup_printf): New function.
1394 (allocator::xstrdup_printf_va): New function.
1395 (class reproducer): New subclass of dump.
1396 (reproducer::reproducer): New function.
1397 (reproducer::write_params): New function.
1398 (reproducer::write_args): New function.
1399 (reproducer::make_identifier): New function.
1400 (reproducer::make_tmp_identifier): New function.
1401 (reproducer::get_identifier): New pair of functions.
1402 (reproducer::get_identifier_as_rvalue): New function.
1403 (reproducer::get_identifier_as_lvalue): New function.
1404 (reproducer::get_identifier_as_type): New function.
1405 (reproducer::xstrdup_printf): New function.
1406 (recording::context::context): Initialize m_toplevel_ctxt.
1407 (recording::context::new_location): Add param created_by_user.
1408 (str_option_reproducer_strings): New table of strings.
1409 (int_option_reproducer_strings): Likewise.
1410 (bool_option_reproducer_strings): Likewise.
1411 (get_type_enum_strings): Likewise.
1412 (names_of_function_kinds): Likewise.
1413 (global_kind_reproducer_strings): Likewise.
1414 (unary_op_reproducer_strings): Likewise.
1415 (binary_op_reproducer_strings): Likewise.
1416 (comparison_reproducer_strings): Likewise.
1417 Within namespace ::gcc::jit::recording::...
1418 (context::dump_reproducer_to_file): New function.
1419 (string::write_reproducer): Likewise.
1420 (location::write_reproducer): Likewise.
1421 (type::access_as_type): Likewise.
1422 (memento_of_get_type::write_reproducer): Likewise.
1423 (memento_of_get_pointer::write_reproducer): Likewise.
1424 (memento_of_get_const::write_reproducer): Likewise.
1425 (memento_of_get_volatile::write_reproducer): Likewise.
1426 (array_type::write_reproducer): Likewise.
1427 (function_type::write_reproducer): Likewise.
1428 (function_type::write_deferred_reproducer): Likewise.
1429 (field::write_reproducer): Likewise.
1430 (struct_::access_as_type): Likewise.
1431 (struct_::write_reproducer): Likewise.
1432 (union_::write_reproducer): Likewise.
1433 (fields::write_reproducer): Likewise.
1434 (rvalue::access_as_rvalue): Likewise.
1435 (lvalue::access_as_rvalue): Likewise.
1436 (lvalue::access_as_lvalue): Likewise.
1437 (param::access_as_rvalue): Likewise.
1438 (param::access_as_lvalue): Likewise.
1439 (param::write_reproducer): Likewise.
1440 (function::write_reproducer): Likewise.
1441 (block::write_reproducer): Likewise.
1442 (global::write_reproducer): Likewise.
1443 (memento_of_new_rvalue_from_const <int>::write_reproducer):
1445 (memento_of_new_rvalue_from_const <long>::write_reproducer):
1447 (memento_of_new_rvalue_from_const <double>::write_reproducer):
1449 (memento_of_new_rvalue_from_const <void *>::write_reproducer):
1451 (memento_of_new_string_literal::write_reproducer): Likewise.
1452 (unary_op::write_reproducer): Likewise.
1453 (binary_op::write_reproducer): Likewise.
1454 (comparison::write_reproducer): Likewise.
1455 (cast::write_reproducer): Likewise.
1456 (call::write_reproducer): Likewise.
1457 (call_through_ptr::write_reproducer): Likewise.
1458 (array_access::write_reproducer): Likewise.
1459 (access_field_of_lvalue::write_reproducer): Likewise.
1460 (access_field_rvalue::write_reproducer): Likewise.
1461 (dereference_field_rvalue::write_reproducer): Likewise.
1462 (dereference_rvalue::write_reproducer): Likewise.
1463 (get_address_of_lvalue::write_reproducer): Likewise.
1464 (local::write_reproducer): Likewise.
1465 (eval::write_reproducer): Likewise.
1466 (assignment::write_reproducer): Likewise.
1467 (assignment_op::write_reproducer): Likewise.
1468 (comment::write_reproducer): Likewise.
1469 (conditional::write_reproducer): Likewise.
1470 (jump::write_reproducer): Likewise.
1471 (return_::write_reproducer): Likewise.
1472 * jit-recording.h (gcc::jit::reproducer): New forward declararion.
1473 Within namespace ::gcc::jit::recording::...
1474 (context::new_location): Add "created_by_user" param.
1475 (context::dump_reproducer_to_file): New method.
1476 (context::m_toplevel_ctxt): New field.
1477 (memento::write_reproducer): New pure virtual function.
1478 (memento::dyn_cast_location): New virtual function.
1479 (string::write_reproducer):
1480 (location::location): Add "created_by_user" param.
1481 (location::dyn_cast_location): New function.
1482 (location::created_by_user): New accessor.
1483 (location::write_reproducer): New function.
1484 (location::m_created_by_user): New field.
1485 (type::access_as_type): New virtual function.
1486 (location::write_reproducer): Likewise.
1487 (type::access_as_type): Likewise.
1488 (memento_of_get_type::write_reproducer): Likewise.
1489 (memento_of_get_pointer::write_reproducer): Likewise.
1490 (memento_of_get_const::write_reproducer): Likewise.
1491 (memento_of_get_volatile::write_reproducer): Likewise.
1492 (array_type::write_reproducer): Likewise.
1493 (function_type::write_reproducer): Likewise.
1494 (function_type::write_deferred_reproducer): Likewise.
1495 (field::write_reproducer): Likewise.
1496 (struct_::access_as_type): Likewise.
1497 (struct_::write_reproducer): Likewise.
1498 (union_::write_reproducer): Likewise.
1499 (union_::m_fields): Remove stray unused field.
1500 (fields::length): New accessor.
1501 (fields::get_field): New accessor.
1502 (fields::write_reproducer): New function.
1503 (rvalue::access_as_rvalue): Likewise.
1504 (lvalue::access_as_rvalue): Likewise.
1505 (lvalue::access_as_lvalue): Likewise.
1506 (param::access_as_rvalue): Likewise.
1507 (param::access_as_lvalue): Likewise.
1508 (param::write_reproducer): Likewise.
1509 (function::write_reproducer): Likewise.
1510 (block::write_reproducer): Likewise.
1511 (global::write_reproducer): Likewise.
1512 (memento_of_new_rvalue_from_const <HOST_TYPE>::write_reproducer):
1514 (memento_of_new_string_literal::write_reproducer): Likewise.
1515 (unary_op::write_reproducer): Likewise.
1516 (binary_op::write_reproducer): Likewise.
1517 (comparison::write_reproducer): Likewise.
1518 (cast::write_reproducer): Likewise.
1519 (call::write_reproducer): Likewise.
1520 (call_through_ptr::write_reproducer): Likewise.
1521 (array_access::write_reproducer): Likewise.
1522 (access_field_of_lvalue::write_reproducer): Likewise.
1523 (access_field_rvalue::write_reproducer): Likewise.
1524 (dereference_field_rvalue::write_reproducer): Likewise.
1525 (dereference_rvalue::write_reproducer): Likewise.
1526 (get_address_of_lvalue::write_reproducer): Likewise.
1527 (local::write_reproducer): Likewise.
1528 (eval::write_reproducer): Likewise.
1529 (assignment::write_reproducer): Likewise.
1530 (assignment_op::write_reproducer): Likewise.
1531 (comment::write_reproducer): Likewise.
1532 (conditional::write_reproducer): Likewise.
1533 (jump::write_reproducer): Likewise.
1534 (return_::write_reproducer): Likewise.
1535 * libgccjit++.h (gccjit::context::dump_reproducer_to_file): New.
1536 * libgccjit.c (gcc_jit_context_new_location): Pass "true" as
1537 param "created_by_user".
1538 (gcc_jit_context_dump_reproducer_to_file): New API entrypoint.
1539 * libgccjit.h (gcc_jit_context_dump_reproducer_to_file): New API
1541 * libgccjit.map (gcc_jit_context_dump_reproducer_to_file): New API
1544 2015-01-12 David Malcolm <dmalcolm@redhat.com>
1546 * jit-recording.c (class gcc::jit::rvalue_usage_validator): New.
1547 (gcc::jit::rvalue_usage_validator::rvalue_usage_validator): New
1549 (gcc::jit::rvalue_usage_validator::visit): New function.
1550 (gcc::jit::recording::rvalue::verify_valid_within_stmt): New
1552 (gcc::jit::recording::rvalue::set_scope): New function.
1553 (gcc::jit::recording::function::function): Call set_scope on each
1554 param, issuing errors for any params that already have a function.
1555 (gcc::jit::recording::block::add_eval): Return the new statement;
1556 update the comment given that some error-checking now happens after
1558 (gcc::jit::recording::block::add_assignment): Likewise.
1559 (gcc::jit::recording::block::add_assignment_op): Likewise.
1560 (gcc::jit::recording::block::add_comment): Likewise.
1561 (gcc::jit::recording::block::end_with_conditional): Likewise.
1562 (gcc::jit::recording::block::end_with_jump): Likewise.
1563 (gcc::jit::recording::block::end_with_return): Likewise.
1564 (gcc::jit::recording::block::validate): Add a comment.
1565 (gcc::jit::recording::unary_op::visit_children): New function.
1566 (gcc::jit::recording::binary_op::visit_children): New function.
1567 (gcc::jit::recording::comparison::visit_children): New function.
1568 (gcc::jit::recording::cast::visit_children): New function.
1569 (gcc::jit::recording::call::visit_children): New function.
1570 (gcc::jit::recording::call_through_ptr::visit_children): New function.
1571 (gcc::jit::recording::array_access::visit_children): New function.
1572 (gcc::jit::recording::access_field_of_lvalue::visit_children): New
1574 (gcc::jit::recording::access_field_rvalue::visit_children): New
1576 (gcc::jit::recording::dereference_field_rvalue::visit_children):
1578 (gcc::jit::recording::dereference_rvalue::visit_children): New
1580 (gcc::jit::recording::get_address_of_lvalue::visit_children): New
1582 * jit-recording.h: Within namespace gcc::jit::recording...
1583 (class rvalue_visitor): New.
1584 (rvalue::rvalue): Initialize m_scope.
1585 (rvalue::get_loc): New accessor.
1586 (rvalue::verify_valid_within_stmt): New function.
1587 (rvalue::visit_children): New pure virtual function.
1588 (rvalue::set_scope): New function.
1589 (rvalue::get_scope): New function.
1590 (rvalue::dyn_cast_param): New function.
1591 (rvalue::m_scope): New field.
1592 (param::visit_children): New empty function.
1593 (param::dyn_cast_param): New function.
1594 (function::get_loc): New function.
1595 (block::add_eval): Return the new statement.
1596 (block::add_assignment): Likewise.
1597 (block::add_assignment_op): Likewise.
1598 (block::add_comment): Likewise.
1599 (block::end_with_conditional): Likewise.
1600 (block::end_with_jump): Likewise.
1601 (block::end_with_return): Likewise.
1602 (global::visit_children): New function.
1603 (memento_of_new_rvalue_from_const<HOST_TYPE>::visit_children):
1605 (memento_of_new_string_literal::visit_children): New function.
1606 (unary_op::visit_children): New function.
1607 (binary_op::visit_children): New function.
1608 (comparison::visit_children): New function.
1609 (cast::visit_children): New function.
1610 (call::visit_children): New function.
1611 (call_through_ptr::visit_children): New function.
1612 (array_access::visit_children): New function.
1613 (access_field_of_lvalue::visit_children): New function.
1614 (access_field_rvalue::visit_children): New function.
1615 (dereference_field_rvalue::visit_children): New function.
1616 (dereference_rvalue::visit_children): New function.
1617 (get_address_of_lvalue::visit_children): New function.
1618 (local::local): Call set_scope.
1619 (local::visit_children): New function.
1620 (statement::get_block): Make public.
1621 * libgccjit.c (RETURN_VAL_IF_FAIL_PRINTF5): New macro.
1622 (RETURN_NULL_IF_FAIL_PRINTF5): New macro.
1623 (gcc_jit_context_new_function): Verify that each param has
1624 not yet been used for creating another function.
1625 (gcc_jit_block_add_eval): After creating the stmt, verify
1626 that the rvalue expression tree is valid to use within it.
1627 (gcc_jit_block_add_assignment): Likewise for the lvalue and
1628 rvalue expression trees.
1629 (gcc_jit_block_add_assignment_op): Likewise.
1630 (gcc_jit_block_end_with_conditional): Likewise for the boolval
1632 (gcc_jit_block_end_with_return): Likewise for the rvalue
1634 (gcc_jit_block_end_with_void_return): Remove return of "void",
1635 now that block::end_with_return is now non-void.
1637 2015-01-12 David Malcolm <dmalcolm@redhat.com>
1639 * jit-playback.c (gcc::jit::playback::context::read_dump_file):
1640 Add missing fclose on error-handling path.
1642 2015-01-12 David Malcolm <dmalcolm@redhat.com>
1644 * docs/cp/topics/expressions.rst (Global variables): Add
1645 enum gcc_jit_global_kind param to gccjit::context::new_global.
1646 * docs/topics/expressions.rst (Global variables): Likewise.
1647 Document the new enum.
1648 * docs/topics/results.rst (Compilation results): Document
1650 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1651 * dummy-frontend.c (jit_langhook_write_globals): Call into the
1652 playback context's write_global_decls_1 and write_global_decls_2
1653 before and after calling symtab->finalize_compilation_unit ().
1654 * jit-playback.c: Include "debug.h".
1655 (gcc::jit::playback::context::new_global): Add "kind" param and
1656 use it to set TREE_PUBLIC, TREE_STATIC and DECL_EXTERNAL on the
1657 underlying VAR_DECL. Call varpool_node::get_create on the
1658 VAR_DECL, and add it to m_globals.
1659 (gcc::jit::playback::context::write_global_decls_1): New function.
1660 (gcc::jit::playback::context::write_global_decls_2): New function.
1661 * jit-playback.h (gcc::jit::playback::context::context): Call
1662 create on m_globals.
1663 (gcc::jit::playback::context::new_global): Add "kind" param.
1664 (gcc::jit::playback::context::write_global_decls_1): New function.
1665 (gcc::jit::playback::context::write_global_decls_2): New function.
1666 (gcc::jit::playback::context::m_globals): New field.
1667 * jit-recording.c (gcc::jit::recording::context::context):
1668 Initialize m_globals.
1669 (gcc::jit::recording::context::new_global): Add param "kind".
1670 Add the new global to m_globals.
1671 (gcc::jit::recording::context::dump_to_file): Dump the globals.
1672 (gcc::jit::recording::global::replay_into): Add field m_kind.
1673 (gcc::jit::recording::global::write_to_dump): New override.
1674 * jit-recording.h (gcc::jit::recording::context::new_global): Add
1676 (gcc::jit::recording::context::m_globals): New field.
1677 (gcc::jit::recording::global::global): Add param kind.
1678 (gcc::jit::recording::global::write_to_dump): New override.
1679 (gcc::jit::recording::global::m_kind): New field.
1680 * jit-result.c (gcc::jit::result::get_global): New function.
1681 * jit-result.h (gcc::jit::result::get_global): New function.
1682 * libgccjit++.h (gccjit::context::new_global): Add "kind" param.
1683 * libgccjit.c (gcc_jit_context_new_global): Likewise.
1684 (gcc_jit_result_get_global): New API entrypoint.
1685 * libgccjit.h (gcc_jit_result_get_global): New API entrypoint.
1686 (enum gcc_jit_global_kind): New enum.
1687 (gcc_jit_context_new_global): API change: add "kind" param.
1688 * libgccjit.map (gcc_jit_result_get_global): New symbol.
1690 2015-01-09 David Malcolm <dmalcolm@redhat.com>
1692 * dummy-frontend.c: Include "fixed-value.h", "alias.h", "flags.h",
1693 "symtab.h", "inchash.h". Move include of "hash-set.h" much
1695 * jit-builtins.c: Remove redundant includes of "opts.h" and
1697 * jit-common.h: Include "hash-set.h", "input.h", "vec.h",
1698 "double-int.h", "alias.h", "flags.h", "symtab.h", "inchash.h".
1699 * jit-playback.c: Include "hashtab.h", "machmode.h", "input.h",
1700 "statistics.h", "vec.h", "double-int.h", "real.h",
1701 "fixed-value.h", "alias.h", "flags.h", "symtab.h", "tree-core.h",
1702 "inchash.h", "fold-const.h". Move include of "hash-set.h" to
1704 * jit-recording.c: Remove redundant includes of "opts.h" and
1707 2015-01-09 David Malcolm <dmalcolm@redhat.com>
1709 * docs/cp/topics/expressions.rst (Simple expressions): Use
1710 ":c:type:" for C types. Document new overload of
1711 gcc::jit::context::new_rvalue.
1712 * docs/topics/expressions.rst (Simple expressions): Use
1713 ":c:type:" for C types. Document new entrypoint
1714 gcc_jit_context_new_rvalue_from_long.
1715 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1716 * jit-playback.c: Within namespace gcc::jit::playback...
1717 (context::new_rvalue_from_int): Eliminate in favor of...
1718 (context::new_rvalue_from_const <int>): ...this.
1719 (context::new_rvalue_from_double): Eliminate in favor of...
1720 (context::new_rvalue_from_const <double>): ...this.
1721 (context::new_rvalue_from_const <long>): New.
1722 (context::new_rvalue_from_ptr): Eliminate in favor of...
1723 (context::new_rvalue_from_const <void *>): ...this.
1724 * jit-playback.h: Within namespace gcc::jit::playback...
1725 (context::new_rvalue_from_int): Eliminate in favor of...
1726 (context::new_rvalue_from_const <HOST_TYPE>): ...this.
1727 (context::new_rvalue_from_double): Likewise.
1728 (context::new_rvalue_from_ptr): Likewise.
1729 * jit-recording.c: Within namespace gcc::jit::recording...
1730 (context::new_rvalue_from_int): Eliminate.
1731 (context::new_rvalue_from_double): Likewise.
1732 (context::new_rvalue_from_ptr): Likewise.
1733 (class memento_of_new_rvalue_from_const <int>):
1734 Add explicit specialization.
1735 (class memento_of_new_rvalue_from_const <long>):
1737 (class memento_of_new_rvalue_from_const <double>):
1739 (class memento_of_new_rvalue_from_const <void *>):
1741 (memento_of_new_rvalue_from_int::replay_into):
1743 (memento_of_new_rvalue_from_const <HOST_TYPE>::replay_into):
1745 (memento_of_new_rvalue_from_double::replay_into):
1747 (memento_of_new_rvalue_from_ptr::replay_into):
1748 ...and this to be deleted.
1749 (memento_of_new_rvalue_from_int::make_debug_string):
1751 (memento_of_new_rvalue_from_const <int>::make_debug_string):
1753 (memento_of_new_rvalue_from_double::make_debug_string):
1755 (memento_of_new_rvalue_from_const <double>::make_debug_string):
1757 (memento_of_new_rvalue_from_ptr::make_debug_string)
1759 (memento_of_new_rvalue_from_const <void *>::make_debug_string):
1761 (memento_of_new_rvalue_from_const <long>::make_debug_string):
1763 * jit-recording.h: Within namespace gcc::jit::recording...
1764 (context::new_rvalue_from_int): Eliminate.
1765 (context::new_rvalue_from_double): Likewise.
1766 (context::new_rvalue_from_ptr): Likewise, all in favor of...
1767 (context::new_rvalue_from_const <HOST_TYPE>): New family of
1769 (class memento_of_new_rvalue_from_int): Eliminate.
1770 (class memento_of_new_rvalue_from_double): Likewise.
1771 (class memento_of_new_rvalue_from_ptr): Likewise.
1772 (class memento_of_new_rvalue_from_const <HOST_TYPE>): New family
1773 of rvalue subclasses.
1774 * libgccjit++.h (gccjit::context::new_rvalue): New overload, for
1776 * libgccjit.c (gcc_jit_context_new_rvalue_from_int): Update for
1777 rewriting of recording::context::new_rvalue_from_int to
1778 recording::context::new_rvalue_from_const <int>.
1779 (gcc_jit_context_new_rvalue_from_long): New API entrypoint.
1780 (gcc_jit_context_new_rvalue_from_double): Update for
1781 rewriting of recording::context::new_rvalue_from_double to
1782 recording::context::new_rvalue_from_const <double>.
1783 (gcc_jit_context_new_rvalue_from_ptr): Update for
1784 rewriting of recording::context::new_rvalue_from_ptr to
1785 recording::context::new_rvalue_from_const <void *>.
1786 * libgccjit.h (gcc_jit_context_new_rvalue_from_long): New API
1788 * libgccjit.map (gcc_jit_context_new_rvalue_from_long): Likewise.
1790 2015-01-09 David Malcolm <dmalcolm@redhat.com>
1793 * docs/internals/test-hello-world.exe.log.txt: Update, the log now
1794 shows tempdir creation/cleanup.
1795 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1796 * jit-logging.h (class gcc::jit::log_user): Add gcc::jit::tempdir
1797 to the list of subclasses in the comment.
1798 * jit-playback.c (gcc::jit::playback::context::context): Add a
1799 comment clarifying when the tempdir gets cleaned up.
1800 (gcc::jit::playback::context::compile): Pass the context's logger,
1801 if any, to the tempdir.
1802 (gcc::jit::playback::context::dlopen_built_dso): When creating the
1803 gcc::jit::result, if GCC_JIT_BOOL_OPTION_DEBUGINFO is set, hand
1804 over ownership of the tempdir to it.
1805 * jit-result.c: Include "jit-tempdir.h".
1806 (gcc::jit::result::result): Add tempdir param, saving it as
1808 (gcc::jit::result::~result): Delete m_tempdir.
1809 * jit-result.h (gcc::jit::result::result): Add tempdir param.
1810 (gcc::jit::result::m_tempdir): New field.
1811 * jit-tempdir.c (gcc::jit::tempdir::tempdir): Add logger param;
1813 (gcc::jit::tempdir::create): Add JIT_LOG_SCOPE to log entry/exit,
1814 and log m_path_template and m_path_tempdir.
1815 (gcc::jit::tempdir::~tempdir): Add JIT_LOG_SCOPE to log
1816 entry/exit, and log the unlink and rmdir calls.
1817 * jit-tempdir.h: Include "jit-logging.h".
1818 (class gcc::jit::tempdir): Make this be a subclass of log_user.
1819 (gcc::jit::tempdir::tempdir): Add logger param.
1820 * notes.txt: Update to show the two possible places where the
1821 tempdir can be cleaned up.
1823 2015-01-08 David Malcolm <dmalcolm@redhat.com>
1825 * libgccjit.h (struct gcc_jit_context): Rewrite the descriptive
1828 2015-01-08 David Malcolm <dmalcolm@redhat.com>
1830 * docs/topics/contexts.rst (Error-handling): Document new
1831 entrypoint gcc_jit_context_get_last_error.
1832 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1833 * jit-recording.c (gcc::jit::recording::context::context):
1834 Initialize new fields "m_last_error_str" and
1835 "m_owns_last_error_str".
1836 (gcc::jit::recording::context::~context): Clean up
1837 m_last_error_str, if needed.
1838 (gcc::jit::recording::context::add_error_va): Update
1839 m_last_error_str and m_owns_last_error_str, freeing the old
1840 value if appropriate.
1841 (gcc::jit::recording::context::get_last_error): New function.
1842 * jit-recording.h (gcc::jit::recording::context::get_last_error):
1844 (gcc::jit::recording::context): New fields m_last_error_str and
1845 m_owns_last_error_str.
1846 * libgccjit.c (gcc_jit_context_get_last_error): New function.
1847 * libgccjit.h (gcc_jit_context_get_last_error): New declaration.
1848 * libgccjit.map (gcc_jit_context_get_last_error): New function.
1850 2015-01-08 David Malcolm <dmalcolm@redhat.com>
1852 * Make-lang.in (jit_OBJS): Add jit/jit-logging.o.
1853 * docs/internals/index.rst (Overview of code structure): Mention
1854 gcc_jit_context_set_logfile, and embed the example logfile.
1855 * docs/internals/test-hello-world.exe.log.txt: New file: example
1857 * docs/topics/contexts.rst (Debugging): Add documentation
1858 for gcc_jit_context_set_logfile.
1859 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1860 * dummy-frontend.c: Include "jit-logging.h".
1861 (jit_langhook_init): Assert that there is an active playback
1862 context. If it has a logger, log entry/exit to this function.
1863 (jit_langhook_write_globals): Likewise.
1864 * jit-common.h (gcc::jit::logger): New forward declaration.
1865 * jit-logging.c: New file.
1866 * jit-logging.h: New file.
1867 * jit-playback.c: Include "jit-logging.h".
1868 (gcc::jit::playback::context::context): Initialize the log_user
1869 base class from the recording context's logger (if any). Use
1870 JIT_LOG_SCOPE to log entry/exit from the function body.
1871 (gcc::jit::playback::context::~context): Use JIT_LOG_SCOPE to
1872 log entry/exit from the function body.
1873 (gcc::jit::playback::build_stmt_list): Likewise.
1874 (gcc::jit::playback::function::postprocess): Likewise.
1875 (gcc::jit::playback::context::compile): Likewise. Log the
1876 entry/exit to toplev::main and toplev::finalize. Log the
1877 fake argv passed to toplev::main.
1878 (gcc::jit::playback::context::acquire_mutex): Use JIT_LOG_SCOPE to
1879 log entry/exit from the function body.
1880 (gcc::jit::playback::context::release_mutex): Likewise.
1881 (gcc::jit::playback::context::make_fake_args): Likewise.
1882 (gcc::jit::playback::context::extract_any_requested_dumps):
1884 (gcc::jit::playback::context::convert_to_dso): Likewise. Also,
1885 log the arguments that the driver is invoked with.
1886 (gcc::jit::playback::context::dlopen_built_dso): Likewise. Pass
1887 the logger to the result object.
1888 (gcc::jit::playback::context::replay): Use JIT_LOG_SCOPE to
1889 log entry/exit from the function body.
1890 (gcc::jit::playback::context::dump_generated_code): Likewise.
1891 (gcc::jit::playback::context::handle_locations): Likewise.
1892 * jit-playback.h (gcc::jit::playback::context): Make this be
1893 a subclass of gcc::jit::log_user.
1894 * jit-recording.c: Include "jit-logging.h".
1895 (gcc::jit::recording::context::context: Initialize the logger to
1896 NULL for root contexts, or to the parent's logger for child
1898 (gcc::jit::recording::context::~context): Use JIT_LOG_SCOPE to
1899 log entry/exit from the function body.
1900 (gcc::jit::recording::context::replay_into): Likewise.
1901 (gcc::jit::recording::context::disassociate_from_playback):
1903 (gcc::jit::recording::context::compile): Likewise.
1904 (recording::context::add_error_va): Likewise. Also, log the
1906 (gcc::jit::recording::context::validate): Use JIT_LOG_SCOPE to
1907 log entry/exit from the function body.
1908 * jit-recording.h: Include "jit-logging.h".
1909 (gcc::jit::recording::context): Make this be a subclass of
1911 * jit-result.c: Include "jit-common.h" and "jit-logging.h".
1912 (gcc::jit::result::result): Add logger param, recording it.
1913 Use JIT_LOG_SCOPE to log entry/exit from the function body.
1914 (gcc::jit::result::~result(): Use JIT_LOG_SCOPE to
1915 log entry/exit from the function body.
1916 (gcc::jit::result::get_code): Likewise.
1917 * jit-result.h (gcc::jit::result): Make this be a subclass of
1919 (gcc::jit::result::result): Add logger parameter.
1920 * libgccjit++.h (gccjit::context::set_logfile): New function.
1921 * libgccjit.c: Include "jit-logging.h".
1922 (gcc_jit_context_acquire): Log the context.
1923 (gcc_jit_context_release): Use JIT_LOG_FUNC to
1924 log entry/exit from the function body, and log the context.
1925 (gcc_jit_context_new_child_context): Likewise, logging both
1927 (gcc_jit_context_new_location): Use JIT_LOG_FUNC to
1928 log entry/exit from the function body.
1929 (gcc_jit_context_get_type): Likewise.
1930 (gcc_jit_context_get_int_type): Likewise.
1931 (gcc_jit_context_new_array_type): Likewise.
1932 (gcc_jit_context_new_field): Likewise.
1933 (gcc_jit_context_new_struct_type): Likewise.
1934 (gcc_jit_context_new_opaque_struct): Likewise.
1935 (gcc_jit_struct_set_fields): Likewise.
1936 (gcc_jit_context_new_union_type): Likewise.
1937 (gcc_jit_context_new_function_ptr_type): Likewise.
1938 (gcc_jit_context_new_param): Likewise.
1939 (gcc_jit_context_new_function): Likewise.
1940 (gcc_jit_context_get_builtin_function): Likewise.
1941 (gcc_jit_function_get_param): Likewise.
1942 (gcc_jit_function_dump_to_dot): Likewise.
1943 (gcc_jit_function_new_block): Likewise.
1944 (gcc_jit_context_new_global): Likewise.
1945 (gcc_jit_context_new_rvalue_from_int): Likewise.
1946 (gcc_jit_context_zero): Likewise.
1947 (gcc_jit_context_one): Likewise.
1948 (gcc_jit_context_new_rvalue_from_double): Likewise.
1949 (gcc_jit_context_new_rvalue_from_ptr): Likewise.
1950 (gcc_jit_context_null): Likewise.
1951 (gcc_jit_context_new_string_literal): Likewise.
1952 (gcc_jit_context_new_unary_op): Likewise.
1953 (gcc_jit_context_new_binary_op): Likewise.
1954 (gcc_jit_context_new_comparison): Likewise.
1955 (gcc_jit_context_new_call): Likewise.
1956 (gcc_jit_context_new_call_through_ptr): Likewise.
1957 (gcc_jit_context_new_cast): Likewise.
1958 (gcc_jit_context_new_array_access): Likewise.
1959 (gcc_jit_lvalue_access_field): Likewise.
1960 (gcc_jit_rvalue_access_field): Likewise.
1961 (gcc_jit_rvalue_dereference_field): Likewise.
1962 (gcc_jit_rvalue_dereference): Likewise.
1963 (gcc_jit_lvalue_get_address): Likewise.
1964 (gcc_jit_function_new_local): Likewise.
1965 (gcc_jit_block_add_eval): Likewise.
1966 (gcc_jit_block_add_assignment): Likewise.
1967 (gcc_jit_block_add_assignment_op): Likewise.
1968 (gcc_jit_block_end_with_conditional): Likewise.
1969 (gcc_jit_block_add_comment): Likewise.
1970 (gcc_jit_block_end_with_jump): Likewise.
1971 (gcc_jit_block_end_with_return): Likewise.
1972 (gcc_jit_block_end_with_void_return): Likewise.
1973 (gcc_jit_context_set_str_option): Likewise.
1974 (gcc_jit_context_set_int_option): Likewise.
1975 (gcc_jit_context_set_bool_option): Likewise.
1976 (gcc_jit_context_enable_dump): Likewise.
1977 (gcc_jit_context_compile): Likewise. Also log the context,
1979 (gcc_jit_context_dump_to_file): Likewise.
1980 (gcc_jit_context_set_logfile): New function.
1981 (gcc_jit_context_get_first_error): Use JIT_LOG_FUNC to
1982 log entry/exit from the function body.
1983 (gcc_jit_result_get_code): Likewise. Also log the fnname)
1984 and the ptr to be returned.
1985 (gcc_jit_result_release): Likewise. Also log the result.
1986 * libgccjit.h: Include <stdio.h>, since we need FILE *.
1987 (gcc_jit_context_set_logfile): New declaration.
1988 * libgccjit.map (gcc_jit_context_set_logfile): New.
1990 2015-01-07 David Malcolm <dmalcolm@redhat.com>
1992 * jit-recording.h (gcc::jit::recording::type::is_void): New
1994 (gcc::jit::recording::memento_of_get_type::is_void): New
1995 function, overriding default implementation.
1996 * libgccjit.c (gcc_jit_rvalue_dereference): Verify that
1997 the underlying type is not "void".
1999 2015-01-07 David Malcolm <dmalcolm@redhat.com>
2001 * docs/topics/expressions.rst (Unary Operations): Add
2002 GCC_JIT_UNARY_OP_ABS.
2003 * jit-playback.c (gcc::jit::playback::context::new_unary_op):
2005 * jit-recording.c (unary_op_strings): Likewise.
2006 * libgccjit.c (gcc_jit_context_new_unary_op): Update checking
2007 of "op" to reflect addition of GCC_JIT_UNARY_OP_ABS.
2008 * libgccjit.h (enum gcc_jit_unary_op): Add GCC_JIT_UNARY_OP_ABS.
2009 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2011 2015-01-07 David Malcolm <dmalcolm@redhat.com>
2013 * jit-recording.h (gcc::jit::recording::memento_of_get_type): Fix
2016 2015-01-07 David Malcolm <dmalcolm@redhat.com>
2018 * TODO.rst (Test suite): Remove item about running C++ testcases.
2019 * docs/internals/index.rst (Working on the JIT library): Add
2020 "c++" to the enabled languages in the suggested "configure"
2021 invocation, and add a description of why this is necessary.
2022 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2024 2015-01-07 David Malcolm <dmalcolm@redhat.com>
2026 * docs/internals/index.rst: Update to reflect that built
2027 testcases are now test-foo.c.exe, rather than test-foo.exe.
2028 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2030 2015-01-05 Jakub Jelinek <jakub@redhat.com>
2032 Update copyright years.
2034 2014-12-19 David Malcolm <dmalcolm@redhat.com>
2036 * jit-playback.c (gcc::jit::playback::context::build_cast): In
2037 case BOOLEAN_TYPE, don't assume that the source expression is
2040 2014-12-19 David Malcolm <dmalcolm@redhat.com>
2042 * jit-recording.c (gcc::jit::recording::context::context): When
2043 copying string options from a parent context, take a copy of the
2044 underlying buffers, rather than simply copying the pointer.
2046 2014-12-19 David Malcolm <dmalcolm@redhat.com>
2048 * jit-recording.c (gcc::jit::recording::context::set_str_option):
2051 2014-12-11 David Malcolm <dmalcolm@redhat.com>
2053 * docs/cp/topics/contexts.rst (gccjit::context::set_str_option):
2054 Document new function.
2055 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2057 2014-12-10 Ulrich Drepper <drepper@gmail.com>
2059 Minor interface cleanups of libgccjit
2060 * jit-playback.c (convert_to_dso): Use auto_vec instead
2061 of automatic array to build up command line.
2062 * jit-recording.c (recording::context::set_str_option):
2063 Make copy of the string.
2064 (recording::context::~context): Free string options.
2065 * jit-recording.h (recording::context): Adjust type
2066 of m_str_options member.
2067 * libgccjit.h: Adjust comment about
2068 gcc_jit_context_set_str_option parameter being used after
2070 Update comment now that all interfaces are copy strings
2072 * libgccjit++.h (gccjit::context): Add set_str_option
2075 2014-12-10 David Malcolm <dmalcolm@redhat.com>
2077 * docs/cp/index.rst: New file.
2078 * docs/cp/intro/index.rst: New file.
2079 * docs/cp/intro/tutorial01.rst: New file.
2080 * docs/cp/intro/tutorial02.rst: New file.
2081 * docs/cp/intro/tutorial03.rst: New file.
2082 * docs/cp/intro/tutorial04.rst: New file.
2083 * docs/cp/topics/contexts.rst: New file.
2084 * docs/cp/topics/expressions.rst: New file.
2085 * docs/cp/topics/functions.rst: New file.
2086 * docs/cp/topics/index.rst: New file.
2087 * docs/cp/topics/locations.rst: New file.
2088 * docs/cp/topics/objects.rst: New file.
2089 * docs/cp/topics/results.rst: New file.
2090 * docs/cp/topics/types.rst: New file.
2091 * docs/examples/tut01-hello-world.cc: New file.
2092 * docs/examples/tut02-square.c: Fix missing newline in output.
2093 * docs/examples/tut02-square.cc: New file.
2094 * docs/examples/tut03-sum-of-squares.cc: New file.
2095 * docs/examples/tut04-toyvm/toyvm.cc: New file.
2096 * docs/index.rst: Move summary to above the table of contents.
2097 Add text about the C vs C++ APIs.
2098 * docs/topics/contexts.rst: Fix a typo.
2100 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2101 * docs/_build/texinfo/factorial1.png: New file.
2102 * docs/_build/texinfo/sum-of-squares1.png: New file.
2104 2014-12-09 David Malcolm <dmalcolm@redhat.com>
2106 * docs/examples/tut04-toyvm/toyvm.c (toyvm_function_compile): Move
2107 logic for determine "funcname" to new function...
2108 (get_function_name): ...here, adding logic to skip any leading
2109 path from the filename.
2110 (toyvm_function_parse): Use the filename for fn_filename, rather
2111 than "name", so that the debugger can locate the source .toy
2113 (toyvm_function_parse): Don't fclose a NULL FILE *.
2115 2014-12-09 David Malcolm <dmalcolm@redhat.com>
2118 * docs/internals/index.rst (Running under valgrind): New
2120 (docs/_build/texinfo/libgccjit.texi): Regenerate.
2122 2014-12-09 David Malcolm <dmalcolm@redhat.com>
2125 * Make-lang.in (jit_OBJS): Add jit/jit-tempdir.o.
2126 * jit-common.h (gcc::jit::tempdir): New forward decl.
2127 * jit-playback.c: Include jit-tempdir.h.
2128 (gcc::jit::playback::context::context): Initialize m_tempdir.
2129 (gcc::jit::playback::context::~context): Move tempdir
2130 cleanup to new file jit-tempdir.c
2131 (make_tempdir_path_template): Move to new file jit-tempdir.c.
2132 (gcc::jit::playback::context::compile): Move tempdir creation
2133 to new tempdir object in new file jit-tempdir.c.
2134 (gcc::jit::playback::context::make_fake_args): Get path from
2135 tempdir object rather than from member data.
2136 (gcc::jit::playback::context::convert_to_dso): Likewise.
2137 (gcc::jit::playback::context::dlopen_built_dso): Likewise.
2138 (gcc::jit::playback::context::dump_generated_code): Likewise.
2139 (gcc::jit::playback::context::get_path_c_file): New function.
2140 (gcc::jit::playback::context::get_path_s_file): New function.
2141 (gcc::jit::playback::context::get_path_so_file): New function.
2142 * jit-playback.h (gcc::jit::playback::context::get_path_c_file):
2144 (gcc::jit::playback::context::get_path_s_file): New function.
2145 (gcc::jit::playback::context::get_path_so_file): New function.
2146 (gcc::jit::playback::context): Move fields "m_path_template",
2147 "m_path_tempdir", "m_path_c_file", "m_path_s_file",
2148 "m_path_so_file" to new jit::tempdir class; add field "m_tempdir".
2149 * jit-tempdir.c: New file.
2150 * jit-tempdir.h: New file.
2152 2014-12-09 David Malcolm <dmalcolm@redhat.com>
2154 * jit-playback.c (gcc::jit::playback::context::compile): Acquire the
2155 mutex here, immediately before using toplev, and release it here, on
2156 each exit path after acquisition.
2157 (jit_mutex): Move this variable here, from jit-recording.c.
2158 (gcc::jit::playback::context::acquire_mutex): New function, based on
2159 code in jit-recording.c.
2160 (gcc::jit::playback::context::release_mutex): Likewise.
2161 * jit-playback.h (gcc::jit::playback::context::acquire_mutex): New
2163 (gcc::jit::playback::context::release_mutex): New function.
2164 * jit-recording.c (jit_mutex): Move this variable to jit-playback.c.
2165 (gcc::jit::recording::context::compile): Move mutex-handling from
2166 here into jit-playback.c's gcc::jit::playback::context::compile.
2167 * notes.txt: Update to show the new locations of ACQUIRE_MUTEX
2170 2014-12-09 David Malcolm <dmalcolm@redhat.com>
2172 * jit-playback.c (gcc::jit::playback::context::compile): Move the
2174 (gcc::jit::playback::context::dlopen_built_dso): ...this new
2176 * jit-playback.h (gcc::jit::playback::context::dlopen_built_dso):
2179 2014-12-09 David Malcolm <dmalcolm@redhat.com>
2182 * docs/topics/contexts.rst (Debugging): Add description of
2183 gcc_jit_context_enable_dump.
2184 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2185 * jit-playback.c: Include context.h.
2186 (class auto_argvec): New class.
2187 (auto_argvec::~auto_argvec): New function.
2188 (gcc::jit::playback::context::compile): Convert fake_args to be
2189 an auto_argvec, so that it can contain dynamically-allocated
2190 strings. Construct a vec of all requested dumps, and pass it to
2191 make_fake_args. Extract requested dumps between the calls to
2192 toplev::main and toplev::finalize.
2193 (gcc::jit::playback::context::make_fake_args): Convert param
2194 "argvec" to be a vec <char *>, and gain a "requested_dumps"
2195 param. Convert to dynamically-allocated arg strings by converting
2196 ADD_ARG to take a copy of the arg, and add ADD_ARG_TAKE_OWNERSHIP
2197 for args that are already a copy. Add args for all requested dumps.
2198 (gcc::jit::playback::context::extract_any_requested_dumps): New
2200 (gcc::jit::playback::context::read_dump_file): New function.
2201 * jit-playback.h (gcc::jit::playback::context::make_fake_args):
2202 Convert param "argvec" to be a vec <char *>, and gain a
2203 "requested_dumps" param.
2204 (gcc::jit::playback::context::extract_any_requested_dumps): New
2206 (gcc::jit::playback::context::read_dump_file): New function.
2207 * jit-recording.c (gcc::jit::recording::context::enable_dump): New
2209 (gcc::jit::recording::context::get_all_requested_dumps): New
2211 * jit-recording.h (gcc::jit::recording::requested_dump): New
2213 (gcc::jit::recording::context::enable_dump): New function.
2214 (gcc::jit::recording::context::get_all_requested_dumps): New
2216 (gcc::jit::recording::context::m_requested_dumps): New field.
2217 * libgccjit.c (gcc_jit_context_enable_dump): New API entrypoint.
2218 * libgccjit.h (gcc_jit_context_enable_dump): New API entrypoint.
2219 * libgccjit.map (gcc_jit_context_enable_dump): New API entrypoint.
2221 2014-12-08 David Malcolm <dmalcolm@redhat.com>
2223 * libgccjit++.h: Indent the forward declarations of the classes to
2224 show the inheritance hierarchy.
2226 2014-12-08 David Malcolm <dmalcolm@redhat.com>
2228 * notes.txt: Show the beginning and ending of
2229 recording::context::compile vs playback::context::compile. Show
2230 the creation and unlinking of the tempdir. Show toplev::finalize.
2231 Move "RELEASE MUTEX" to the correct location. Show
2232 gcc_jit_result_release, and indicate where the
2233 dlopen/dlsym/dlclose occur.
2235 2014-12-01 David Malcolm <dmalcolm@redhat.com>
2237 * docs/examples/tut02-square.c (main): Release the context
2238 earlier, to show that this is possible. Update error-handling
2239 to avoid a double-release of the context, and to avoid
2240 releasing a NULL result.
2241 * docs/intro/tutorial02.rst: Discuss gcc_jit_context_release.
2242 * docs/topics/functions.rst (GCC_JIT_FUNCTION_EXPORTED): Emphasize
2243 * docs/topics/results.rst (gcc_jit_result): Mention that this
2244 controls the lifetimes of machine code functions.
2245 (gcc_jit_result_get_code): Spell out the requirements for this
2246 to succeed, and the lifetime of the result.
2247 (gcc_jit_result_release): Mention that this invalidates any code
2248 that was obtained from the result.
2249 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2251 2014-12-01 David Malcolm <dmalcolm@redhat.com>
2254 * docs/intro/tutorial02.rst: Spell out lifetime of generated code.
2255 Add description of error-handling, taken in part from...
2256 * docs/topics/contexts.rst (Error-handling): Expand, and move some
2257 content to tutorial02.rst.
2258 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2260 2014-12-01 David Malcolm <dmalcolm@redhat.com>
2263 * docs/topics/types.rst (Standard types) Add new enum values to
2264 the table of enum gcc_jit_types: GCC_JIT_TYPE_COMPLEX_FLOAT,
2265 GCC_JIT_TYPE_COMPLEX_DOUBLE, GCC_JIT_TYPE_COMPLEX_LONG_DOUBLE.
2266 Widen the left-hand column so that
2267 GCC_JIT_TYPE_COMPLEX_LONG_DOUBLE will fit.
2268 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2270 * jit-builtins.c: Include stringpool.h and jit-playback.h.
2271 Move everything out of the gcc::jit::recording namespace into
2273 (struct builtin_data): Add fields "fnclass", "attr", and
2275 (DEF_BUILTIN): Update macro so populate the new fields.
2276 (builtins_manager::builtins_manager): Update for move out of
2277 recording namespace. Initialize the m_attributes array.
2278 (builtins_manager::get_builtin_function): Likewise.
2279 (builtins_manager::get_builtin_function_by_id): New function.
2280 (builtins_manager::make_builtin_function): Update for move out of
2281 recording namespace. Add fix for PR jit/64020 by detecting
2282 specific builtin ids and having them ensure that builtins for
2283 other ids are created as necessary.
2284 (builtins_manager::get_type): Update for move out of recording
2286 (builtins_manager::make_type): Likewise. Add some missing
2288 (builtins_manager::make_primitive_type): Update for move out of
2289 recording namespace. Implement the three BT_COMPLEX_ cases and
2291 (builtins_manager::make_fn_type): Update for move out of recording
2293 (builtins_manager::make_ptr_type): Likewise.
2294 (builtins_manager::finish_playback): New function.
2295 (builtins_manager::get_class): New function.
2296 (builtins_manager::implicit_p): New function.
2297 (builtins_manager::get_attrs_tree): Two new functions.
2298 (builtins_manager::make_attrs_tree): New function.
2300 * jit-builtins.h: Move everything out of the gcc::jit::recording
2301 namespace into just gcc::jit.
2302 (enum built_in_attribute): New.
2303 (builtins_manager::builtins_manager): Update decl for namespace
2305 (builtins_manager::get_builtin_function): Likewise.
2306 (builtins_manager::get_class): New.
2307 (builtins_manager::implicit_p): New.
2308 (builtins_manager::get_attrs_tree): Two new functions.
2309 (builtins_manager::make_attrs_tree): New function.
2310 (builtins_manager::finish_playback): New.
2311 (builtins_manager::get_builtin_function_by_id): New.
2312 (builtins_manager::make_builtin_function): Update decl for
2314 (builtins_manager::get_type): Likewise.
2315 (builtins_manager::make_type): Likewise.
2316 (builtins_manager::make_primitive_type): Likewise.
2317 (builtins_manager::make_fn_type): Likewise.
2318 (builtins_manager::make_ptr_type): Likewise.
2319 (builtins_manager): Likewise for fields. Add new field
2322 * jit-common.h (NUM_GCC_JIT_TYPES): Update.
2323 (builtins_manager): Update forward decl to reflect namespace
2326 * jit-playback.c: Include attribs.h and jit-builtins.h.
2327 (gcc::jit::playback::context::get_tree_node_for_type): Add cases
2328 for the new COMPLEX_ types.
2329 (gcc::jit::playback::context::new_function): If creating a
2330 builtin, set the DECL_BUILT_IN_CLASS and attributes on the fndecl,
2331 and call set_builtin_decl.
2332 (gcc::jit::playback::context::replay): If we have a
2333 builtins_manager, call its finish_playback method when we're done.
2336 (gcc::jit::playback::context::get_builtins_manager): New function.
2339 (gcc::jit::recording::context::get_builtins_manager): New function.
2340 (gcc::jit::recording::get_builtin_function): Use
2341 get_builtins_manager, in case we're a child context.
2342 (gcc::jit::recording::memento_of_get_type::dereference): Add the
2344 (gcc::jit::recording::memento_of_get_type::is_int): Likewise.
2345 (gcc::jit::recording::memento_of_get_type::is_float): Likewise.
2346 (gcc::jit::recording::memento_of_get_type::is_bool): Likewise.
2347 (get_type_strings): Likewise.
2350 (gcc::jit::recording::context::get_builtins_manager): New.
2352 * libgccjit.h (enum gcc_jit_types): Add
2353 GCC_JIT_TYPE_COMPLEX_FLOAT, GCC_JIT_TYPE_COMPLEX_DOUBLE,
2354 GCC_JIT_TYPE_COMPLEX_LONG_DOUBLE.
2356 2014-12-01 David Malcolm <dmalcolm@redhat.com>
2359 (gcc::jit::recording::builtins_manager::get_builtin_function):
2360 Check for NULL return from make_builtin_function.
2361 (gcc::jit::recording::builtins_manager::make_builtin_function):
2362 Check for NULL return from get_type.
2364 2014-12-01 David Malcolm <dmalcolm@redhat.com>
2366 * jit-playback.c (gcc::jit::playback::context::compile): Move DSO
2367 creation code into...
2368 (gcc::jit::playback::context::convert_to_dso): New function.
2369 * jit-playback.h (gcc::jit::playback::context::convert_to_dso):
2372 2014-12-01 David Malcolm <dmalcolm@redhat.com>
2374 * jit-playback.c (gcc::jit::playback::context::compile): Use an
2375 auto_vec<const char *> rather than a const char *[20] for the
2376 top-level argv, and move the logic to build it to...
2377 (gcc::jit::playback::context::make_fake_args): New function.
2378 * jit-playback.h (gcc::jit::playback::context::make_fake_args):
2381 2014-12-01 David Malcolm <dmalcolm@redhat.com>
2383 * Make-lang.in (jit_OBJS): Add jit/jit-result.o.
2384 * jit-playback.c: Include new header jit-result.h.
2385 (gcc::jit::result::result): Move to new file jit-result.c.
2386 (gcc::jit::result::~result): Likewise.
2387 (gcc::jit::playback::result): Likewise.
2388 * jit-recording.h (class gcc::jit::result): Move to new
2389 header jit-result.h.
2390 * jit-result.c: New file, to contain...
2391 (gcc::jit::result::result): Move here from jit-playback.c,
2392 removing erroneous "playback" namespace from comment.
2393 (gcc::jit::result::~result): Likewise.
2394 (gcc::jit::playback::result): Likewise.
2395 * jit-result.h: New file, to contain...
2396 (class gcc::jit::result): Move from jit-recording.h.
2397 * libgccjit.c: Include jit-result.h.
2398 (gcc_jit_result_get_code): Update comment to reflect move
2400 (gcc_jit_result_release): Likewise.
2402 2014-12-01 David Malcolm <dmalcolm@redhat.com>
2405 * docs/examples/tut04-toyvm/toyvm.c
2406 (toyvm_compiled_function): New typedef.
2407 (toyvm_compiled_func) Rename to...
2408 (toyvm_compiled_code) ...this.
2409 (struct toyvm_compiled_function): New struct.
2410 (toyvm_function_compile): Return a toyvm_compiled_function *
2411 rather than a toyvm_compiled_func, so that the caller can fully
2412 clean things up. Free "funcname".
2413 (test_script): Update for change to toyvm_function_compile.
2414 Clean up the toyvm_compiled_function.
2416 (docs/intro/tutorial04.rst): Update to reflect the above changes,
2417 and to better spell out the lifetime of the compiled code.
2419 2014-12-01 David Malcolm <dmalcolm@redhat.com>
2423 (gcc::jit::recording::builtins_manager::make_fn_type): Call the
2424 context's new_function_type method, rather than directly creating
2425 a function_type instance.
2427 (gcc::jit::recording::context::new_function_type): New method,
2428 adapted from part of...
2429 (gcc::jit::recording::context::new_function_ptr_type): ...this.
2430 Update to call new_function_type.
2432 (gcc::jit::recording::context::new_function_type): New method.
2434 2014-12-01 David Malcolm <dmalcolm@redhat.com>
2437 * jit-playback.c: Ensure that ctxt_progname is non-NULL.
2439 2014-11-19 David Malcolm <dmalcolm@redhat.com>
2442 * jit-playback.c (gcc::jit::playback::compound_type::set_fields):
2443 Convert param from const vec<playback::field *> & to
2444 const auto_vec<playback::field *> *.
2445 (gcc::jit::playback::context::new_function_type): Convert param
2446 "param_types" from vec<type *> * to const auto_vec<type *> *.
2447 (gcc::jit::playback::context::new_function): Convert param
2448 "params" from vec<param *> * to const auto_vec<param *> *.
2449 (gcc::jit::playback::context::build_call): Convert param "args"
2450 from vec<rvalue *> to const auto_vec<rvalue *> *.
2451 (gcc::jit::playback::context::new_call): Likewise.
2452 (gcc::jit::playback::context::new_call_through_ptr): Likewise.
2453 (wrapper_finalizer): New function.
2454 (gcc::jit::playback::wrapper::operator new): Call the finalizer
2455 variant of ggc_internal_cleared_alloc, supplying
2457 (gcc::jit::playback::function::finalizer): New.
2458 (gcc::jit::playback::block::finalizer): New.
2459 (gcc::jit::playback::source_file::finalizer): New.
2460 (gcc::jit::playback::source_line::finalizer): New.
2463 (gcc::jit::playback::context::new_function_type): Convert param
2464 "param_types" from vec<type *> * to const auto_vec<type *> *.
2465 (gcc::jit::playback::context::new_function): Convert param
2466 "params" from vec<param *> * to const auto_vec<param *> *.
2467 (gcc::jit::playback::context::new_call): Convert param
2468 "args" from vec<rvalue *> to const auto_vec<rvalue *> *.
2469 (gcc::jit::playback::context::new_call_through_ptr): Likewise.
2470 (gcc::jit::playback::context::build_call): Likewise.
2471 (gcc::jit::playback::context): Convert fields "m_functions",
2472 "m_source_files", "m_cached_locations" from vec to auto_vec.
2473 (gcc::jit::playback::wrapper::finalizer): New virtual function.
2474 (gcc::jit::playback::compound_type::set_fields): Convert param fro
2475 const vec<playback::field *> & to
2476 const auto_vec<playback::field *> *.
2477 (gcc::jit::playback::function::finalizer): New.
2478 (gcc::jit::playback::block::finalizer): New.
2479 (gcc::jit::playback::source_file::finalizer): New.
2480 (gcc::jit::playback::source_line::finalizer): New.
2483 (gcc::jit::recording::function_type::replay_into): Convert local
2484 from a vec into an auto_vec.
2485 (gcc::jit::recording::fields::replay_into): Likewise.
2486 (gcc::jit::recording::function::replay_into): Likewise.
2487 (gcc::jit::recording::call::replay_into): Likewise.
2488 (gcc::jit::recording::call_through_ptr::replay_into): Likewise.
2490 * jit-recording.h (gcc::jit::recording::context): Convert fields
2491 "m_mementos", "m_compound_types", "m_functions" from vec<> to
2493 (gcc::jit::recording::function_type::get_param_types): Convert
2494 return type from vec<type *> to const vec<type *> &.
2495 (gcc::jit::recording::function_type): Convert field
2496 "m_param_types" from a vec<> to an auto_vec<>.
2497 (gcc::jit::recording::fields): Likewise for field "m_fields".
2498 (gcc::jit::recording::function::get_params): Convert return type
2499 from vec <param *> to const vec<param *> &.
2500 (gcc::jit::recording::function): Convert fields "m_params",
2501 "m_locals", "m_blocks" from vec<> to auto_vec<>.
2502 (gcc::jit::recording::block): Likewise for field "m_statements".
2503 vec<> to auto_vec<>.
2504 (gcc::jit::recording::call): Likewise for field "m_args".
2505 (gcc::jit::recording::call_through_ptr): Likewise.
2507 2014-11-19 David Malcolm <dmalcolm@redhat.com>
2510 * jit-recording.c (recording::function::validate): Convert
2511 "worklist" from vec<> to autovec<> to fix a leak.
2513 2014-11-11 David Malcolm <dmalcolm@redhat.com>
2515 * ChangeLog.jit: New.
2517 * Make-lang.in: New.
2519 * config-lang.in: New.
2520 * docs/Makefile: New.
2521 * docs/_build/texinfo/Makefile: New.
2522 * docs/_build/texinfo/factorial.png: New.
2523 * docs/_build/texinfo/libgccjit.texi: New.
2524 * docs/_build/texinfo/sum-of-squares.png: New.
2525 * docs/conf.py: New.
2526 * docs/examples/tut01-hello-world.c: New.
2527 * docs/examples/tut02-square.c: New.
2528 * docs/examples/tut03-sum-of-squares.c: New.
2529 * docs/examples/tut04-toyvm/Makefile: New.
2530 * docs/examples/tut04-toyvm/factorial.toy: New.
2531 * docs/examples/tut04-toyvm/fibonacci.toy: New.
2532 * docs/examples/tut04-toyvm/toyvm.c: New.
2533 * docs/index.rst: New.
2534 * docs/internals/index.rst: New.
2535 * docs/intro/factorial.png: New.
2536 * docs/intro/index.rst: New.
2537 * docs/intro/sum-of-squares.png: New.
2538 * docs/intro/tutorial01.rst: New.
2539 * docs/intro/tutorial02.rst: New.
2540 * docs/intro/tutorial03.rst: New.
2541 * docs/intro/tutorial04.rst: New.
2542 * docs/topics/contexts.rst: New.
2543 * docs/topics/expressions.rst: New.
2544 * docs/topics/functions.rst: New.
2545 * docs/topics/index.rst: New.
2546 * docs/topics/locations.rst: New.
2547 * docs/topics/objects.rst: New.
2548 * docs/topics/results.rst: New.
2549 * docs/topics/types.rst: New.
2550 * dummy-frontend.c: New.
2551 * jit-builtins.c: New.
2552 * jit-builtins.h: New.
2553 * jit-common.h: New.
2554 * jit-playback.c: New.
2555 * jit-playback.h: New.
2556 * jit-recording.c: New.
2557 * jit-recording.h: New.
2558 * libgccjit++.h: New.
2561 * libgccjit.map: New.
2564 2013-07-26 David Malcolm <dmalcolm@redhat.com>
2568 Copyright (C) 2013-2017 Free Software Foundation, Inc.
2570 Copying and distribution of this file, with or without modification,
2571 are permitted in any medium without royalty provided the copyright
2572 notice and this notice are preserved.