]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/jit/ChangeLog
Daily bump.
[thirdparty/gcc.git] / gcc / jit / ChangeLog
CommitLineData
67d5b10e
GA
12024-02-10 Jakub Jelinek <jakub@redhat.com>
2
3 * jit-playback.cc (new_bitcast): Use HOST_WIDE_INT_PRINT_DEC instead
4 of "%ld" and casts to long.
5
4b7d4d8a
GA
62024-02-02 Antoni Boucher <bouanto@zoho.com>
7
8 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_27): New ABI tag.
9 * docs/topics/expressions.rst: Document gcc_jit_context_new_sizeof.
10 * jit-playback.cc (new_sizeof): New method.
11 * jit-playback.h (new_sizeof): New method.
12 * jit-recording.cc (recording::context::new_sizeof,
13 recording::memento_of_sizeof::replay_into,
14 recording::memento_of_sizeof::make_debug_string,
15 recording::memento_of_sizeof::write_reproducer): New methods.
16 * jit-recording.h (class memento_of_sizeof): New class.
17 * libgccjit.cc (gcc_jit_context_new_sizeof): New function.
18 * libgccjit.h (gcc_jit_context_new_sizeof): New function.
19 * libgccjit.map: New function.
20
c2544854
GA
212024-01-19 Antoni Boucher <bouanto@zoho.com>
22
23 * jit-builtins.cc (ensure_optimization_builtins_exist): Add
24 popcount builtins.
25
262024-01-19 Antoni Boucher <bouanto@zoho.com>
27
28 * jit-recording.h (is_numeric_vector, vector_type::new_int): New
29 functions.
30 * libgccjit.cc (gcc_jit_context_new_unary_op,
31 gcc_jit_context_new_binary_op): add checks for
32 is_numeric_vector.
33
444a31f3
GA
342024-01-12 Guillaume Gomez <guillaume1.gomez@gmail.com>
35 Antoni Boucher <bouanto@zoho.com>
36
37 * docs/topics/compatibility.rst: Add documentation for LIBGCCJIT_ABI_26.
38 * docs/topics/functions.rst: Add documentation for new functions.
39 * docs/topics/expressions.rst: Add documentation for new functions.
40
412024-01-12 Guillaume Gomez <guillaume1.gomez@gmail.com>
42 Antoni Boucher <bouanto@zoho.com>
43
44 * dummy-frontend.cc (handle_alias_attribute): New function.
45 (handle_always_inline_attribute): New function.
46 (handle_cold_attribute): New function.
47 (handle_fnspec_attribute): New function.
48 (handle_format_arg_attribute): New function.
49 (handle_format_attribute): New function.
50 (handle_noinline_attribute): New function.
51 (handle_target_attribute): New function.
52 (handle_used_attribute): New function.
53 (handle_visibility_attribute): New function.
54 (handle_weak_attribute): New function.
55 (handle_alias_ifunc_attribute): New function.
56 * jit-playback.cc (fn_attribute_to_string): New function.
57 (variable_attribute_to_string): New function.
58 (global_new_decl): Add attributes support.
59 (set_variable_attribute): New function.
60 (new_global): Add attributes support.
61 (new_global_initialized): Add attributes support.
62 (new_local): Add attributes support.
63 * jit-playback.h (fn_attribute_to_string): New function.
64 (set_variable_attribute): New function.
65 * jit-recording.cc (recording::lvalue::add_attribute): New function.
66 (recording::function::function): New function.
67 (recording::function::write_to_dump): Add attributes support.
68 (recording::function::add_attribute): New function.
69 (recording::function::add_string_attribute): New function.
70 (recording::function::add_integer_array_attribute): New function.
71 (recording::global::replay_into): Add attributes support.
72 (recording::local::replay_into): Add attributes support.
73 * jit-recording.h: Add attributes support.
74 * libgccjit.cc (gcc_jit_function_add_attribute): New function.
75 (gcc_jit_function_add_string_attribute): New function.
76 (gcc_jit_function_add_integer_array_attribute): New function.
77 (gcc_jit_lvalue_add_attribute): New function.
78 * libgccjit.h (enum gcc_jit_fn_attribute): New enum.
79 (gcc_jit_function_add_attribute): New function.
80 (gcc_jit_function_add_string_attribute): New function.
81 (gcc_jit_function_add_integer_array_attribute): New function.
82 (enum gcc_jit_variable_attribute): New function.
83 (gcc_jit_lvalue_add_string_attribute): New function.
84 * libgccjit.map: Declare new functions.
85
ae9e48e5
GA
862023-12-06 David Malcolm <dmalcolm@redhat.com>
87
88 * dummy-frontend.cc (jit_begin_diagnostic): Make diagnostic_info
89 param const.
90 (jit_end_diagnostic): Likewise. Pass to add_diagnostic by
91 reference.
92 * jit-playback.cc (jit::playback::context::add_diagnostic):
93 Convert diagnostic_info to const reference.
94 * jit-playback.h (jit::playback::context::add_diagnostic):
95 Likewise.
96
3dd09cd9
GA
972023-12-05 Richard Sandiford <richard.sandiford@arm.com>
98
99 * dummy-frontend.cc (jit_gnu_attribute_table): Add extra braces
100 to work around PR 16333 in older compilers.
101 (jit_format_attribute_table): Likewise.
102
04d4a494
GA
1032023-12-02 Richard Sandiford <richard.sandiford@arm.com>
104
105 * dummy-frontend.cc (jit_format_attribute_table): Change type to
106 scoped_attribute_specs, using...
107 (jit_format_attributes): ...this as the underlying array.
108 (jit_attribute_table): Change to an array of scoped_attribute_specs
109 pointers, using...
110 (jit_gnu_attributes, jit_gnu_attribute_table): ...these new globals
111 for the original array. Include the format attributes.
112 (LANG_HOOKS_COMMON_ATTRIBUTE_TABLE): Delete.
113 (LANG_HOOKS_FORMAT_ATTRIBUTE_TABLE): Delete.
114 (LANG_HOOKS_ATTRIBUTE_TABLE): Define.
115
b9fd8399
GA
1162023-11-09 Guillaume Gomez <guillaume1.gomez@gmail.com>
117
118 * libgccjit++.h:
119
eb4e1b62
GA
1202023-11-04 David Malcolm <dmalcolm@redhat.com>
121
122 * jit-playback.cc: Update for changes to diagnostic_context.
123 * jit-playback.h: Likewise.
124
f75fc1f0
GA
1252023-10-25 Vibhav Pant <vibhavp@gmail.com>
126
127 * jit-recording.cc (recording::global::write_to_dump): Fix
128 dump of string literal initializers.
129
3b632746
GA
1302023-10-22 Iain Sandoe <iain@sandoe.co.uk>
131
132 * Make-lang.in: Handle Darwin rpaths.
133
41d1c9a9
GA
1342023-10-02 David Malcolm <dmalcolm@redhat.com>
135
136 * dummy-frontend.cc (jit_langhook_init): Update for change to
137 diagnostic_context callbacks.
138
65c36ecc
GA
1392023-08-31 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
140
141 * jit-playback.cc: Change spelling to macOS.
142
ded52c9f
GA
1432023-08-29 Guillaume Gomez <guillaume1.gomez@gmail.com>
144
145 * docs/topics/compatibility.rst: Add documentation for LIBGCCJIT_ABI_25.
146 * docs/topics/types.rst: Add documentation for gcc_jit_type_get_restrict.
147
1482023-08-29 Guillaume Gomez <guillaume1.gomez@gmail.com>
149
150 * jit-playback.cc: Remove trailing whitespace characters.
151 * jit-playback.h: Add get_restrict method.
152 * jit-recording.cc: Add get_restrict methods.
153 * jit-recording.h: Add get_restrict methods.
154 * libgccjit++.h: Add get_restrict methods.
155 * libgccjit.cc: Add gcc_jit_type_get_restrict.
156 * libgccjit.h: Declare gcc_jit_type_get_restrict.
157 * libgccjit.map: Declare gcc_jit_type_get_restrict.
158
88cc4495
GA
1592023-02-16 Patrick Palka <ppalka@redhat.com>
160
161 * jit-dejagnu.h: Mechanically drop static from static inline
162 functions via s/^static inline/inline/g.
163 * jit-recording.h: Likewise.
164
d901bf8a
GA
1652023-01-07 LIU Hao <lh_mouse@126.com>
166
167 PR middle-end/108300
168 * jit-w32.h: Define `WIN32_LEAN_AND_MEAN` before <windows.h>.
169
de282a20
GA
1702022-12-21 Martin Liska <mliska@suse.cz>
171
172 * jit-playback.h: Use unused attribute.
173
26f4aefa
GA
1742022-12-14 Antoni Boucher <bouanto@zoho.com>
175 Guillaume Gomez <guillaume1.gomez@gmail.com>
176
177 PR jit/108078
178 * jit-recording.h: Add vector_type::is_same_type_as method
179
4bc2d9f6
GA
1802022-12-07 Antoni Boucher <bouanto@zoho.com>
181 Guillaume Gomez <guillaume1.gomez@gmail.com>
182
183 PR jit/107770
184 * jit-playback.cc: Fix vector float comparison
185 * jit-playback.h: Update comparison function signature
186 * jit-recording.cc: Update call for "new_comparison" function
187 * jit-recording.h: Fix vector float comparison
188
fb98ede8
GA
1892022-11-20 Jeff Law <jlaw@ventanamicro.com>
190
191 PR other/104044
192 * jit-playback.cc (playback::lvale::mark_addressable): Remove
193 extraeous semicolon
194
1952022-11-19 Jonathan Wakely <jwakely@redhat.com>
196 LIU Hao <lh_mouse@126.com>
197
198 * jit-playback.cc (playback::context::scoped_lock): Define RAII
199 lock type.
200 (playback::context::compile): Use scoped_lock to acquire mutex
201 for the active playback context.
202 (jit_mutex): Change to std::mutex.
203 (playback::context::acquire_mutex): Rename to ...
204 (playback::context::lock): ... this.
205 (playback::context::release_mutex): Rename to ...
206 (playback::context::unlock): ... this.
207 * jit-playback.h (playback::context): Rename members and declare
208 scoped_lock.
209 * jit-recording.cc (INCLUDE_PTHREAD_H): Remove unused define.
210 * libgccjit.cc (version_mutex): Change to std::mutex.
211 (struct jit_version_info): Use std::lock_guard to acquire and
212 release mutex.
213
83d400bd
GA
2142022-11-14 Martin Liska <mliska@suse.cz>
215
216 Revert:
217 2022-11-09 Martin Liska <mliska@suse.cz>
218
219 * Make-lang.in:
220 * docs/cp/index.rst: Moved to...
221 * doc/cp/index.rst: ...here.
222 * docs/cp/intro/index.rst: Moved to...
223 * doc/cp/intro/index.rst: ...here.
224 * docs/cp/intro/tutorial01.rst: Moved to...
225 * doc/cp/intro/tutorial01.rst: ...here.
226 * docs/cp/intro/tutorial02.rst: Moved to...
227 * doc/cp/intro/tutorial02.rst: ...here.
228 * docs/cp/intro/tutorial03.rst: Moved to...
229 * doc/cp/intro/tutorial03.rst: ...here.
230 * docs/cp/intro/tutorial04.rst: Moved to...
231 * doc/cp/intro/tutorial04.rst: ...here.
232 * docs/cp/topics/asm.rst: Moved to...
233 * doc/cp/topics/asm.rst: ...here.
234 * docs/cp/topics/compilation.rst: Moved to...
235 * doc/cp/topics/compilation.rst: ...here.
236 * docs/cp/topics/contexts.rst: Moved to...
237 * doc/cp/topics/contexts.rst: ...here.
238 * docs/cp/topics/expressions.rst: Moved to...
239 * doc/cp/topics/expressions.rst: ...here.
240 * docs/cp/topics/functions.rst: Moved to...
241 * doc/cp/topics/functions.rst: ...here.
242 * docs/cp/topics/index.rst: Moved to...
243 * doc/cp/topics/index.rst: ...here.
244 * docs/cp/topics/locations.rst: Moved to...
245 * doc/cp/topics/locations.rst: ...here.
246 * docs/cp/topics/objects.rst: Moved to...
247 * doc/cp/topics/objects.rst: ...here.
248 * docs/cp/topics/types.rst: Moved to...
249 * doc/cp/topics/types.rst: ...here.
250 * docs/examples/emit-alphabet.bf: Moved to...
251 * doc/examples/emit-alphabet.bf: ...here.
252 * docs/examples/tut01-hello-world.c: Moved to...
253 * doc/examples/tut01-hello-world.c: ...here.
254 * docs/examples/tut01-hello-world.cc: Moved to...
255 * doc/examples/tut01-hello-world.cc: ...here.
256 * docs/examples/tut02-square.c: Moved to...
257 * doc/examples/tut02-square.c: ...here.
258 * docs/examples/tut02-square.cc: Moved to...
259 * doc/examples/tut02-square.cc: ...here.
260 * docs/examples/tut03-sum-of-squares.c: Moved to...
261 * doc/examples/tut03-sum-of-squares.c: ...here.
262 * docs/examples/tut03-sum-of-squares.cc: Moved to...
263 * doc/examples/tut03-sum-of-squares.cc: ...here.
264 * docs/examples/tut04-toyvm/Makefile: Moved to...
265 * doc/examples/tut04-toyvm/Makefile: ...here.
266 * docs/examples/tut04-toyvm/factorial.toy: Moved to...
267 * doc/examples/tut04-toyvm/factorial.toy: ...here.
268 * docs/examples/tut04-toyvm/fibonacci.toy: Moved to...
269 * doc/examples/tut04-toyvm/fibonacci.toy: ...here.
270 * docs/examples/tut04-toyvm/toyvm.c: Moved to...
271 * doc/examples/tut04-toyvm/toyvm.c: ...here.
272 * docs/examples/tut04-toyvm/toyvm.cc: Moved to...
273 * doc/examples/tut04-toyvm/toyvm.cc: ...here.
274 * docs/examples/tut05-bf.c: Moved to...
275 * doc/examples/tut05-bf.c: ...here.
276 * docs/index.rst: Moved to...
277 * doc/index.rst: ...here.
278 * docs/internals/index.rst: Moved to...
279 * doc/internals/index.rst: ...here.
280 * docs/internals/test-hello-world.exe.log.txt: Moved to...
281 * doc/internals/test-hello-world.exe.log.txt: ...here.
282 * docs/_build/texinfo/libgccjit-figures/factorial.png: Moved to...
283 * doc/intro/factorial.png: ...here.
284 * docs/intro/index.rst: Moved to...
285 * doc/intro/index.rst: ...here.
286 * docs/_build/texinfo/libgccjit-figures/sum-of-squares.png: Moved to...
287 * doc/intro/sum-of-squares.png: ...here.
288 * docs/intro/tutorial01.rst: Moved to...
289 * doc/intro/tutorial01.rst: ...here.
290 * docs/intro/tutorial02.rst: Moved to...
291 * doc/intro/tutorial02.rst: ...here.
292 * docs/intro/tutorial03.rst: Moved to...
293 * doc/intro/tutorial03.rst: ...here.
294 * docs/intro/tutorial04.rst: Moved to...
295 * doc/intro/tutorial04.rst: ...here.
296 * docs/intro/tutorial05.rst: Moved to...
297 * doc/intro/tutorial05.rst: ...here.
298 * docs/topics/asm.rst: Moved to...
299 * doc/topics/asm.rst: ...here.
300 * docs/topics/compatibility.rst: Moved to...
301 * doc/topics/compatibility.rst: ...here.
302 * docs/topics/compilation.rst: Moved to...
303 * doc/topics/compilation.rst: ...here.
304 * docs/topics/contexts.rst: Moved to...
305 * doc/topics/contexts.rst: ...here.
306 * docs/topics/expressions.rst: Moved to...
307 * doc/topics/expressions.rst: ...here.
308 * docs/topics/function-pointers.rst: Moved to...
309 * doc/topics/function-pointers.rst: ...here.
310 * docs/topics/functions.rst: Moved to...
311 * doc/topics/functions.rst: ...here.
312 * docs/topics/index.rst: Moved to...
313 * doc/topics/index.rst: ...here.
314 * docs/topics/locations.rst: Moved to...
315 * doc/topics/locations.rst: ...here.
316 * docs/topics/objects.rst: Moved to...
317 * doc/topics/objects.rst: ...here.
318 * docs/topics/performance.rst: Moved to...
319 * doc/topics/performance.rst: ...here.
320 * docs/topics/types.rst: Moved to...
321 * doc/topics/types.rst: ...here.
322 * docs/Makefile: Removed.
323 * docs/_build/texinfo/Makefile: Removed.
324 * docs/_build/texinfo/libgccjit-figures/factorial1.png: Removed.
325 * docs/_build/texinfo/libgccjit-figures/sum-of-squares1.png: Removed.
326 * docs/_build/texinfo/libgccjit.texi: Removed.
327 * docs/conf.py: Removed.
328 * docs/intro/factorial.png: Removed.
329 * docs/intro/sum-of-squares.png: Removed.
330 * doc/conf.py: New file.
331
3322022-11-14 Martin Liska <mliska@suse.cz>
333
334 Revert:
335 2022-11-14 Martin Liska <mliska@suse.cz>
336
337 * Make-lang.in: Support --with-sphinx-build.
338
3392022-11-14 Martin Liska <mliska@suse.cz>
340
341 Revert:
342 2022-11-14 Martin Liska <mliska@suse.cz>
343
344 * doc/internals/index.rst: Fix cross manual refs.
345 * doc/topics/contexts.rst: Likewise.
346
3472022-11-14 Martin Liska <mliska@suse.cz>
348
349 Revert:
350 2022-11-14 Martin Liska <mliska@suse.cz>
351
352 * Make-lang.in:
353 Support installation if sphinx-build is missing.
354
3552022-11-14 Martin Liska <mliska@suse.cz>
356
357 Revert:
358 2022-11-14 Martin Liska <mliska@suse.cz>
359
360 * doc/cp/index.rst: Remove trailing .rst in toctree.
361 * doc/cp/intro/index.rst: Likewise.
362 * doc/cp/topics/index.rst: Likewise.
363 * doc/index.rst: Likewise.
364 * doc/intro/index.rst: Likewise.
365 * doc/topics/index.rst: Likewise.
366 * doc/indices-and-tables.rst: New file.
367
5b6ce16a
GA
3682022-11-11 Martin Liska <mliska@suse.cz>
369
370 * doc/cp/index.rst: Remove trailing .rst in toctree.
371 * doc/cp/intro/index.rst: Likewise.
372 * doc/cp/topics/index.rst: Likewise.
373 * doc/index.rst: Likewise.
374 * doc/intro/index.rst: Likewise.
375 * doc/topics/index.rst: Likewise.
376 * doc/indices-and-tables.rst: New file.
377
1cdfd0e5
GA
3782022-11-09 Martin Liska <mliska@suse.cz>
379
380 * Make-lang.in:
381 Support installation if sphinx-build is missing.
382
3832022-11-09 Martin Liska <mliska@suse.cz>
384
385 * doc/internals/index.rst: Fix cross manual refs.
386 * doc/topics/contexts.rst: Likewise.
387
3882022-11-09 Martin Liska <mliska@suse.cz>
389
390 * Make-lang.in: Support --with-sphinx-build.
391
3922022-11-09 Martin Liska <mliska@suse.cz>
393
394 * Make-lang.in:
395 * docs/cp/index.rst: Moved to...
396 * doc/cp/index.rst: ...here.
397 * docs/cp/intro/index.rst: Moved to...
398 * doc/cp/intro/index.rst: ...here.
399 * docs/cp/intro/tutorial01.rst: Moved to...
400 * doc/cp/intro/tutorial01.rst: ...here.
401 * docs/cp/intro/tutorial02.rst: Moved to...
402 * doc/cp/intro/tutorial02.rst: ...here.
403 * docs/cp/intro/tutorial03.rst: Moved to...
404 * doc/cp/intro/tutorial03.rst: ...here.
405 * docs/cp/intro/tutorial04.rst: Moved to...
406 * doc/cp/intro/tutorial04.rst: ...here.
407 * docs/cp/topics/asm.rst: Moved to...
408 * doc/cp/topics/asm.rst: ...here.
409 * docs/cp/topics/compilation.rst: Moved to...
410 * doc/cp/topics/compilation.rst: ...here.
411 * docs/cp/topics/contexts.rst: Moved to...
412 * doc/cp/topics/contexts.rst: ...here.
413 * docs/cp/topics/expressions.rst: Moved to...
414 * doc/cp/topics/expressions.rst: ...here.
415 * docs/cp/topics/functions.rst: Moved to...
416 * doc/cp/topics/functions.rst: ...here.
417 * docs/cp/topics/index.rst: Moved to...
418 * doc/cp/topics/index.rst: ...here.
419 * docs/cp/topics/locations.rst: Moved to...
420 * doc/cp/topics/locations.rst: ...here.
421 * docs/cp/topics/objects.rst: Moved to...
422 * doc/cp/topics/objects.rst: ...here.
423 * docs/cp/topics/types.rst: Moved to...
424 * doc/cp/topics/types.rst: ...here.
425 * docs/examples/emit-alphabet.bf: Moved to...
426 * doc/examples/emit-alphabet.bf: ...here.
427 * docs/examples/tut01-hello-world.c: Moved to...
428 * doc/examples/tut01-hello-world.c: ...here.
429 * docs/examples/tut01-hello-world.cc: Moved to...
430 * doc/examples/tut01-hello-world.cc: ...here.
431 * docs/examples/tut02-square.c: Moved to...
432 * doc/examples/tut02-square.c: ...here.
433 * docs/examples/tut02-square.cc: Moved to...
434 * doc/examples/tut02-square.cc: ...here.
435 * docs/examples/tut03-sum-of-squares.c: Moved to...
436 * doc/examples/tut03-sum-of-squares.c: ...here.
437 * docs/examples/tut03-sum-of-squares.cc: Moved to...
438 * doc/examples/tut03-sum-of-squares.cc: ...here.
439 * docs/examples/tut04-toyvm/Makefile: Moved to...
440 * doc/examples/tut04-toyvm/Makefile: ...here.
441 * docs/examples/tut04-toyvm/factorial.toy: Moved to...
442 * doc/examples/tut04-toyvm/factorial.toy: ...here.
443 * docs/examples/tut04-toyvm/fibonacci.toy: Moved to...
444 * doc/examples/tut04-toyvm/fibonacci.toy: ...here.
445 * docs/examples/tut04-toyvm/toyvm.c: Moved to...
446 * doc/examples/tut04-toyvm/toyvm.c: ...here.
447 * docs/examples/tut04-toyvm/toyvm.cc: Moved to...
448 * doc/examples/tut04-toyvm/toyvm.cc: ...here.
449 * docs/examples/tut05-bf.c: Moved to...
450 * doc/examples/tut05-bf.c: ...here.
451 * docs/index.rst: Moved to...
452 * doc/index.rst: ...here.
453 * docs/internals/index.rst: Moved to...
454 * doc/internals/index.rst: ...here.
455 * docs/internals/test-hello-world.exe.log.txt: Moved to...
456 * doc/internals/test-hello-world.exe.log.txt: ...here.
457 * docs/_build/texinfo/libgccjit-figures/factorial.png: Moved to...
458 * doc/intro/factorial.png: ...here.
459 * docs/intro/index.rst: Moved to...
460 * doc/intro/index.rst: ...here.
461 * docs/_build/texinfo/libgccjit-figures/sum-of-squares.png: Moved to...
462 * doc/intro/sum-of-squares.png: ...here.
463 * docs/intro/tutorial01.rst: Moved to...
464 * doc/intro/tutorial01.rst: ...here.
465 * docs/intro/tutorial02.rst: Moved to...
466 * doc/intro/tutorial02.rst: ...here.
467 * docs/intro/tutorial03.rst: Moved to...
468 * doc/intro/tutorial03.rst: ...here.
469 * docs/intro/tutorial04.rst: Moved to...
470 * doc/intro/tutorial04.rst: ...here.
471 * docs/intro/tutorial05.rst: Moved to...
472 * doc/intro/tutorial05.rst: ...here.
473 * docs/topics/asm.rst: Moved to...
474 * doc/topics/asm.rst: ...here.
475 * docs/topics/compatibility.rst: Moved to...
476 * doc/topics/compatibility.rst: ...here.
477 * docs/topics/compilation.rst: Moved to...
478 * doc/topics/compilation.rst: ...here.
479 * docs/topics/contexts.rst: Moved to...
480 * doc/topics/contexts.rst: ...here.
481 * docs/topics/expressions.rst: Moved to...
482 * doc/topics/expressions.rst: ...here.
483 * docs/topics/function-pointers.rst: Moved to...
484 * doc/topics/function-pointers.rst: ...here.
485 * docs/topics/functions.rst: Moved to...
486 * doc/topics/functions.rst: ...here.
487 * docs/topics/index.rst: Moved to...
488 * doc/topics/index.rst: ...here.
489 * docs/topics/locations.rst: Moved to...
490 * doc/topics/locations.rst: ...here.
491 * docs/topics/objects.rst: Moved to...
492 * doc/topics/objects.rst: ...here.
493 * docs/topics/performance.rst: Moved to...
494 * doc/topics/performance.rst: ...here.
495 * docs/topics/types.rst: Moved to...
496 * doc/topics/types.rst: ...here.
497 * docs/Makefile: Removed.
498 * docs/_build/texinfo/Makefile: Removed.
499 * docs/_build/texinfo/libgccjit-figures/factorial1.png: Removed.
500 * docs/_build/texinfo/libgccjit-figures/sum-of-squares1.png: Removed.
501 * docs/_build/texinfo/libgccjit.texi: Removed.
502 * docs/conf.py: Removed.
503 * docs/intro/factorial.png: Removed.
504 * docs/intro/sum-of-squares.png: Removed.
505 * doc/conf.py: New file.
506
d0fc05e8
GA
5072022-09-15 Richard Biener <rguenther@suse.de>
508
509 * dummy-frontend.cc (jit_langhook_init): Do not initialize
510 void_list_node.
511
6d001ec1
GA
5122022-08-09 Vibhav Pant <vibhavp@gmail.com>
513
514 * libgccjit.h (LIBGCCJIT_HAVE_gcc_jit_context_new_bitcast): Move
515 definition out of comment.
516
af086d19
GA
5172022-07-28 David Malcolm <dmalcolm@redhat.com>
518
519 * docs/internals/index.rst: Remove reference to ".c" extensions
520 of source files.
521
5222022-07-28 Martin Liška <mliska@suse.cz>
523
524 * docs/cp/intro/tutorial02.rst:
525 Shorten the assembly example so that there is not slider.
526 * docs/cp/intro/tutorial04.rst: Likewise.
527 * docs/intro/tutorial02.rst: Likewise.
528 * docs/intro/tutorial04.rst: Likewise.
529 * docs/topics/contexts.rst: Likewise.
530
5312022-07-28 marxin <mliska@suse.cz>
532
533 * docs/index.rst: Remove reference to module index
534 as we don't emit any.
535
5362022-07-28 marxin <mliska@suse.cz>
537
538 * docs/cp/intro/tutorial02.rst: Use :expr:`type *` for pointers to a type
539 * docs/cp/topics/asm.rst: Likewise.
540 * docs/cp/topics/contexts.rst: Likewise.
541 * docs/cp/topics/expressions.rst: Likewise.
542 * docs/cp/topics/functions.rst: Likewise.
543 * docs/cp/topics/objects.rst: Likewise.
544 * docs/intro/tutorial02.rst: Likewise.
545 * docs/intro/tutorial03.rst: Likewise.
546 * docs/intro/tutorial04.rst: Likewise.
547 * docs/intro/tutorial05.rst: Likewise.
548 * docs/topics/compilation.rst: Likewise.
549 * docs/topics/contexts.rst: Likewise.
550 * docs/topics/objects.rst: Likewise.
551
5522022-07-28 marxin <mliska@suse.cz>
553
554 * docs/cp/intro/tutorial04.rst: Use list-table.
555 * docs/intro/tutorial04.rst: Likewise.
556 * docs/intro/tutorial05.rst: Likewise.
557 * docs/topics/compilation.rst: Likewise.
558 * docs/topics/expressions.rst: Likewise.
559 * docs/topics/types.rst: Likewise.
560
5612022-07-28 marxin <mliska@suse.cz>
562
563 * docs/cp/topics/expressions.rst: Compact so that the generated
564 output is also more compact.
565
5662022-07-28 marxin <mliska@suse.cz>
567
568 * docs/cp/intro/tutorial02.rst: Use proper reference.
569 * docs/cp/topics/contexts.rst: Likewise.
570 * docs/cp/topics/functions.rst: Put `class` directive before a
571 function as it is not allowed declaring a class in a fn.
572 * docs/cp/topics/types.rst: Add template keyword.
573 * docs/examples/tut04-toyvm/toyvm.c (toyvm_function_compile):
574 Add removed comment used for code snippet ending detection.
575 * docs/intro/tutorial04.rst: Fix to match the real comment.
576
5772022-07-28 marxin <mliska@suse.cz>
578
579 * docs/cp/topics/expressions.rst: Use :expr: for basic types.
580 * docs/topics/compilation.rst: Likewise.
581 * docs/topics/expressions.rst: Likewise.
582 * docs/topics/function-pointers.rst: Likewise.
583
5842022-07-28 marxin <mliska@suse.cz>
585
586 * docs/conf.py: Add needs_sphinx = '3.0' where c:type was added.
587 * docs/index.rst: Remove note about it.
588 * docs/topics/compilation.rst: Use enum directive and reference.
589 * docs/topics/contexts.rst: Likewise.
590 * docs/topics/expressions.rst: Likewise.
591 * docs/topics/functions.rst: Likewise.
592
e0e07bc7
GA
5932022-07-14 Jonathan Wakely <jwakely@redhat.com>
594
595 * jit-recording.h (recording::memento): Define copy constructor
596 and copy assignment operator as deleted.
597 (recording::string): Likewise.
598 (recording::string::c_str): Add const qualifier.
599
ce600bc4
GA
6002022-06-29 Antoni Boucher <bouanto@zoho.com>
601
602 PR jit/105812
603 * jit-playback.cc: Use the correct return type when folding in
604 as_truth_value.
605
6062022-06-29 Sergei Trofimovich <siarheit@google.com>
607
608 PR c++/106102
609 * jit-playback.cc: Include <pthread.h> via "system.h" to avoid calloc()
610 poisoning.
611 * jit-recording.cc: Ditto.
612 * libgccjit.cc: Ditto.
613
ef1e4d80
GA
6142022-06-10 Antoni Boucher <bouanto@zoho.com>
615
616 PR jit/105829
617 * libgccjit.cc: Add support for floating-point types in
618 gcc_jit_type_get_size.
619
02b4e2de
GA
6202022-06-08 Yang Yujie <yangyujie@loongson.cn>
621
622 * Make-lang.in: only link objects from $(EXTRA_GCC_OBJS)
623 that's not in $(EXTRA_OBJS) into libgccjit.
624
168fc8bd
GA
6252022-05-23 David Malcolm <dmalcolm@redhat.com>
626
627 * jit-recording.h: Add "final" and "override" to all vfunc
628 implementations that were missing them, as appropriate.
629
57f2ce6a
GA
6302022-05-20 David Malcolm <dmalcolm@redhat.com>
631
632 * jit-playback.h: Replace uses of "FINAL" and "OVERRIDE" with
633 "final" and "override".
634 * jit-recording.cc: Likewise.
635 * jit-recording.h: Likewise.
636
702bd11f
GA
6372022-05-16 Martin Liska <mliska@suse.cz>
638
639 * jit-builtins.cc (find_builtin_by_name): Use ARRAY_SIZE.
640 (get_string_for_type_id): Likewise.
641 * jit-recording.cc (recording::context::context): Likewise.
642
031bd52e
GA
6432022-04-14 Iain Sandoe <iain@sandoe.co.uk>
644
645 * jit-playback.cc (new_bitcast): Cast values returned by tree_to_uhwi
646 to 'long' to match the print format.
647
504dae1d
GA
6482022-04-12 Antoni Boucher <bouanto@zoho.com>
649
650 PR jit/104293
651 * docs/_build/texinfo/libgccjit.texi: Regenerate.
652 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_24): New ABI tag.
653 * docs/topics/expressions.rst: Add documentation for the
654 functions gcc_jit_lvalue_set_alignment and
655 gcc_jit_lvalue_get_alignment.
656 * jit-playback.h: New function (set_alignment).
657 * jit-recording.cc: New function (set_alignment).
658 * jit-recording.h: New functions (set_alignment, get_alignment)
659 and new field (m_alignment).
660 * libgccjit.cc: New functions (gcc_jit_lvalue_get_alignment,
661 gcc_jit_lvalue_set_alignment)
662 * libgccjit.h: New functions (gcc_jit_lvalue_get_alignment,
663 gcc_jit_lvalue_set_alignment)
664 * libgccjit.map (LIBGCCJIT_ABI_24): New ABI tag.
665
6662022-04-12 Antoni Boucher <bouanto@zoho.com>
667
668 PR jit/104073
669 * docs/_build/texinfo/libgccjit.texi: Regenerate.
670 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_23): New ABI tag.
671 * docs/topics/contexts.rst: Add documentation for the new
672 function gcc_jit_context_set_bool_print_errors_to_stderr.
673 * jit-common.h: New enum value
674 (INNER_BOOL_OPTION_PRINT_ERRORS_TO_STDERR).
675 * jit-recording.cc: Handle the new option
676 INNER_BOOL_OPTION_PRINT_ERRORS_TO_STDERR.
677 * libgccjit.cc: New function
678 (gcc_jit_context_set_bool_print_errors_to_stderr).
679 * libgccjit.h: New function
680 (gcc_jit_context_set_bool_print_errors_to_stderr).
681 * libgccjit.map (LIBGCCJIT_ABI_23): New ABI tag.
682
6832022-04-12 Antoni Boucher <bouanto@zoho.com>
684
685 PR jit/104072
686 * docs/_build/texinfo/libgccjit.texi: Regenerate.
687 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_22): New ABI tag.
688 * docs/topics/expressions.rst: Add documentation for the
689 function gcc_jit_lvalue_set_register_name.
690 * jit-playback.h: New function (set_register_name).
691 * jit-recording.cc: New function (set_register_name) and add
692 support for register variables.
693 * jit-recording.h: New field (m_reg_name) and new function
694 (set_register_name).
695 * libgccjit.cc: New function (gcc_jit_lvalue_set_register_name).
696 * libgccjit.h: New function (gcc_jit_lvalue_set_register_name).
697 * libgccjit.map (LIBGCCJIT_ABI_22): New ABI tag.
698
6992022-04-12 Antoni Boucher <bouanto@zoho.com>
700
701 PR jit/104071
702 * docs/_build/texinfo/libgccjit.texi: Regenerate.
703 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_21): New ABI tag.
704 * docs/topics/expressions.rst: Add documentation for the
705 function gcc_jit_context_new_bitcast.
706 * jit-playback.cc: New function (new_bitcast).
707 * jit-playback.h: New function (new_bitcast).
708 * jit-recording.cc: New functions (new_bitcast,
709 bitcast::replay_into, bitcast::visit_children,
710 bitcast::make_debug_string, bitcast::write_reproducer).
711 * jit-recording.h: New class (bitcast) and new function
712 (new_bitcast, bitcast::replay_into, bitcast::visit_children,
713 bitcast::make_debug_string, bitcast::write_reproducer,
714 bitcast::get_precedence).
715 * libgccjit.cc: New function (gcc_jit_context_new_bitcast)
716 * libgccjit.h: New function (gcc_jit_context_new_bitcast)
717 * libgccjit.map (LIBGCCJIT_ABI_21): New ABI tag.
718
7192022-04-12 Antoni Boucher <bouanto@zoho.com>
720
721 PR target/95325
722 * docs/_build/texinfo/libgccjit.texi: Regenerate
723 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_20): New ABI tag.
724 * docs/topics/types.rst: Add documentation for the new types
725 GCC_JIT_TYPE_UINT8_T, GCC_JIT_TYPE_UINT16_T,
726 GCC_JIT_TYPE_UINT32_T, GCC_JIT_TYPE_UINT64_T,
727 GCC_JIT_TYPE_UINT128_T, GCC_JIT_TYPE_INT8_T, GCC_JIT_TYPE_INT16_T,
728 GCC_JIT_TYPE_INT32_T, GCC_JIT_TYPE_INT64_T, GCC_JIT_TYPE_INT128_T and
729 new functions (gcc_jit_compatible_types, gcc_jit_type_get_size).
730 * jit-builtins.cc: Add support for BT_UINT128.
731 * jit-common.h: Update the value of NUM_GCC_JIT_TYPES.
732 * jit-playback.cc: Add support for the sized integer types.
733 * jit-recording.cc: Add support for the sized integer types.
734 * jit-recording.h: Add support for comparing integer types
735 and new function (is_signed).
736 * libgccjit.cc (gcc_jit_compatible_types): New.
737 (gcc_jit_type_get_size) New.
738 * libgccjit.h: New enum variants for gcc_jit_types
739 (GCC_JIT_TYPE_UINT8_T, GCC_JIT_TYPE_UINT16_T,
740 GCC_JIT_TYPE_UINT32_T, GCC_JIT_TYPE_UINT64_T,
741 GCC_JIT_TYPE_UINT128_T, GCC_JIT_TYPE_INT8_T,
742 GCC_JIT_TYPE_INT16_T, GCC_JIT_TYPE_INT32_T,
743 GCC_JIT_TYPE_INT64_T, GCC_JIT_TYPE_INT128_T) and new functions
744 (gcc_jit_compatible_types, gcc_jit_type_get_size).
745 * libgccjit.map (LIBGCCJIT_ABI_20): New ABI tag.
746
80eb8ec6
GA
7472022-04-06 David Malcolm <dmalcolm@redhat.com>
748
749 PR jit/102824
750 * docs/_build/texinfo/factorial.png: Move to...
751 * docs/_build/texinfo/libgccjit-figures/factorial.png: ...here.
752 * docs/_build/texinfo/factorial1.png: Move to...
753 * docs/_build/texinfo/libgccjit-figures/factorial1.png: ...here.
754 * docs/_build/texinfo/sum-of-squares.png: Move to...
755 * docs/_build/texinfo/libgccjit-figures/sum-of-squares.png: ...here.
756 * docs/_build/texinfo/sum-of-squares1.png: Move to...
757 * docs/_build/texinfo/libgccjit-figures/sum-of-squares1.png: ...here.
758
8af4270d
GA
7592022-04-01 David Malcolm <dmalcolm@redhat.com>
760
761 * docs/topics/expressions.rst: Fix formatting.
762 * docs/topics/types.rst: Likewise.
763 * docs/_build/texinfo/libgccjit.texi: Regenerate
764
7652022-04-01 Petter Tomner <tomner@kth.se>
766
767 * docs/topics/compatibility.rst: Add 19 tag
768 * docs/topics/compilation.rst: Linking
769 * docs/topics/contexts.rst: Linking example
770 * docs/topics/expressions.rst: Fix formatting and dropped 's'
771
e6533e2e
GA
7722022-03-07 Jakub Jelinek <jakub@redhat.com>
773
774 * libgccjit.h: Fix up duplicated word issue in a comment.
775
fc829782
GA
7762022-01-17 Martin Liska <mliska@suse.cz>
777
778 * config-lang.in: Rename .c names to .cc.
779 * docs/_build/texinfo/libgccjit.texi: Likewise.
780 * docs/internals/index.rst: Likewise.
781 * jit-builtins.cc (builtins_manager::make_builtin_function): Likewise.
782 * jit-playback.cc (fold_const_var): Likewise.
783 (playback::context::~context): Likewise.
784 (new_field): Likewise.
785 (new_bitfield): Likewise.
786 (new_compound_type): Likewise.
787 (playback::compound_type::set_fields): Likewise.
788 (global_set_init_rvalue): Likewise.
789 (load_blob_in_ctor): Likewise.
790 (new_global_initialized): Likewise.
791 (double>): Likewise.
792 (new_string_literal): Likewise.
793 (as_truth_value): Likewise.
794 (build_call): Likewise.
795 (playback::context::build_cast): Likewise.
796 (new_array_access): Likewise.
797 (new_field_access): Likewise.
798 (dereference): Likewise.
799 (postprocess): Likewise.
800 (add_jump): Likewise.
801 (add_switch): Likewise.
802 (build_goto_operands): Likewise.
803 (playback::context::read_dump_file): Likewise.
804 (init_types): Likewise.
805 * jit-recording.cc (recording::context::get_int_type): Likewise.
806 * jit-recording.h: Likewise.
807 * libgccjit.cc (compatible_types): Likewise.
808 (gcc_jit_context_acquire): Likewise.
809 (gcc_jit_context_release): Likewise.
810 (gcc_jit_context_new_child_context): Likewise.
811 (gcc_jit_type_as_object): Likewise.
812 (gcc_jit_context_get_type): Likewise.
813 (gcc_jit_context_get_int_type): Likewise.
814 (gcc_jit_type_get_pointer): Likewise.
815 (gcc_jit_type_get_const): Likewise.
816 (gcc_jit_type_get_volatile): Likewise.
817 (gcc_jit_type_dyncast_array): Likewise.
818 (gcc_jit_type_is_bool): Likewise.
819 (gcc_jit_type_is_pointer): Likewise.
820 (gcc_jit_type_is_integral): Likewise.
821 (gcc_jit_type_dyncast_vector): Likewise.
822 (gcc_jit_type_is_struct): Likewise.
823 (gcc_jit_vector_type_get_num_units): Likewise.
824 (gcc_jit_vector_type_get_element_type): Likewise.
825 (gcc_jit_type_unqualified): Likewise.
826 (gcc_jit_type_dyncast_function_ptr_type): Likewise.
827 (gcc_jit_function_type_get_return_type): Likewise.
828 (gcc_jit_function_type_get_param_count): Likewise.
829 (gcc_jit_function_type_get_param_type): Likewise.
830 (gcc_jit_context_new_array_type): Likewise.
831 (gcc_jit_context_new_field): Likewise.
832 (gcc_jit_field_as_object): Likewise.
833 (gcc_jit_context_new_struct_type): Likewise.
834 (gcc_jit_struct_as_type): Likewise.
835 (gcc_jit_struct_set_fields): Likewise.
836 (gcc_jit_struct_get_field_count): Likewise.
837 (gcc_jit_context_new_union_type): Likewise.
838 (gcc_jit_context_new_function_ptr_type): Likewise.
839 (gcc_jit_param_as_rvalue): Likewise.
840 (gcc_jit_context_new_function): Likewise.
841 (gcc_jit_function_get_return_type): Likewise.
842 (gcc_jit_function_dump_to_dot): Likewise.
843 (gcc_jit_block_get_function): Likewise.
844 (gcc_jit_global_set_initializer_rvalue): Likewise.
845 (gcc_jit_rvalue_get_type): Likewise.
846 (gcc_jit_context_new_rvalue_from_int): Likewise.
847 (gcc_jit_context_one): Likewise.
848 (gcc_jit_context_new_rvalue_from_double): Likewise.
849 (gcc_jit_context_null): Likewise.
850 (gcc_jit_context_new_string_literal): Likewise.
851 (valid_binary_op_p): Likewise.
852 (gcc_jit_context_new_binary_op): Likewise.
853 (gcc_jit_context_new_comparison): Likewise.
854 (gcc_jit_context_new_call): Likewise.
855 (is_valid_cast): Likewise.
856 (gcc_jit_context_new_cast): Likewise.
857 (gcc_jit_object_get_context): Likewise.
858 (gcc_jit_object_get_debug_string): Likewise.
859 (gcc_jit_lvalue_access_field): Likewise.
860 (gcc_jit_rvalue_access_field): Likewise.
861 (gcc_jit_rvalue_dereference_field): Likewise.
862 (gcc_jit_rvalue_dereference): Likewise.
863 (gcc_jit_lvalue_get_address): Likewise.
864 (gcc_jit_lvalue_set_tls_model): Likewise.
865 (gcc_jit_lvalue_set_link_section): Likewise.
866 (gcc_jit_function_new_local): Likewise.
867 (gcc_jit_block_add_eval): Likewise.
868 (gcc_jit_block_add_assignment): Likewise.
869 (is_bool): Likewise.
870 (gcc_jit_block_end_with_conditional): Likewise.
871 (gcc_jit_block_add_comment): Likewise.
872 (gcc_jit_block_end_with_jump): Likewise.
873 (gcc_jit_block_end_with_return): Likewise.
874 (gcc_jit_block_end_with_void_return): Likewise.
875 (case_range_validator::case_range_validator): Likewise.
876 (case_range_validator::validate): Likewise.
877 (case_range_validator::get_wide_int): Likewise.
878 (gcc_jit_block_end_with_switch): Likewise.
879 (gcc_jit_context_set_str_option): Likewise.
880 (gcc_jit_context_set_int_option): Likewise.
881 (gcc_jit_context_set_bool_option): Likewise.
882 (gcc_jit_context_set_bool_allow_unreachable_blocks): Likewise.
883 (gcc_jit_context_set_bool_use_external_driver): Likewise.
884 (gcc_jit_context_add_command_line_option): Likewise.
885 (gcc_jit_context_add_driver_option): Likewise.
886 (gcc_jit_context_enable_dump): Likewise.
887 (gcc_jit_context_compile): Likewise.
888 (gcc_jit_context_compile_to_file): Likewise.
889 (gcc_jit_context_set_logfile): Likewise.
890 (gcc_jit_context_dump_reproducer_to_file): Likewise.
891 (gcc_jit_context_get_first_error): Likewise.
892 (gcc_jit_context_get_last_error): Likewise.
893 (gcc_jit_result_get_code): Likewise.
894 (gcc_jit_result_get_global): Likewise.
895 (gcc_jit_rvalue_set_bool_require_tail_call): Likewise.
896 (gcc_jit_type_get_aligned): Likewise.
897 (gcc_jit_type_get_vector): Likewise.
898 (gcc_jit_function_get_address): Likewise.
899 (gcc_jit_version_patchlevel): Likewise.
900 (gcc_jit_block_add_extended_asm): Likewise.
901 (gcc_jit_extended_asm_as_object): Likewise.
902 (gcc_jit_extended_asm_set_volatile_flag): Likewise.
903 (gcc_jit_extended_asm_set_inline_flag): Likewise.
904 (gcc_jit_extended_asm_add_output_operand): Likewise.
905 (gcc_jit_extended_asm_add_input_operand): Likewise.
906 (gcc_jit_extended_asm_add_clobber): Likewise.
907 * notes.txt: Likewise.
908
9092022-01-17 Martin Liska <mliska@suse.cz>
910
911 * dummy-frontend.c: Moved to...
912 * dummy-frontend.cc: ...here.
913 * jit-builtins.c: Moved to...
914 * jit-builtins.cc: ...here.
915 * jit-logging.c: Moved to...
916 * jit-logging.cc: ...here.
917 * jit-playback.c: Moved to...
918 * jit-playback.cc: ...here.
919 * jit-recording.c: Moved to...
920 * jit-recording.cc: ...here.
921 * jit-result.c: Moved to...
922 * jit-result.cc: ...here.
923 * jit-spec.c: Moved to...
924 * jit-spec.cc: ...here.
925 * jit-tempdir.c: Moved to...
926 * jit-tempdir.cc: ...here.
927 * jit-w32.c: Moved to...
928 * jit-w32.cc: ...here.
929 * libgccjit.c: Moved to...
930 * libgccjit.cc: ...here.
931
054e57e4
GA
9322021-12-28 Martin Liska <mliska@suse.cz>
933
934 * docs/_build/texinfo/libgccjit.texi: Replace http:// with https.
935 * docs/cp/index.rst: Likewise.
936 * docs/cp/intro/index.rst: Likewise.
937 * docs/cp/intro/tutorial01.rst: Likewise.
938 * docs/cp/intro/tutorial02.rst: Likewise.
939 * docs/cp/intro/tutorial03.rst: Likewise.
940 * docs/cp/intro/tutorial04.rst: Likewise.
941 * docs/cp/topics/asm.rst: Likewise.
942 * docs/cp/topics/compilation.rst: Likewise.
943 * docs/cp/topics/contexts.rst: Likewise.
944 * docs/cp/topics/expressions.rst: Likewise.
945 * docs/cp/topics/functions.rst: Likewise.
946 * docs/cp/topics/index.rst: Likewise.
947 * docs/cp/topics/locations.rst: Likewise.
948 * docs/cp/topics/objects.rst: Likewise.
949 * docs/cp/topics/types.rst: Likewise.
950 * docs/index.rst: Likewise.
951 * docs/internals/index.rst: Likewise.
952 * docs/intro/index.rst: Likewise.
953 * docs/intro/tutorial01.rst: Likewise.
954 * docs/intro/tutorial02.rst: Likewise.
955 * docs/intro/tutorial03.rst: Likewise.
956 * docs/intro/tutorial04.rst: Likewise.
957 * docs/intro/tutorial05.rst: Likewise.
958 * docs/topics/asm.rst: Likewise.
959 * docs/topics/compatibility.rst: Likewise.
960 * docs/topics/compilation.rst: Likewise.
961 * docs/topics/contexts.rst: Likewise.
962 * docs/topics/expressions.rst: Likewise.
963 * docs/topics/function-pointers.rst: Likewise.
964 * docs/topics/functions.rst: Likewise.
965 * docs/topics/index.rst: Likewise.
966 * docs/topics/locations.rst: Likewise.
967 * docs/topics/objects.rst: Likewise.
968 * docs/topics/performance.rst: Likewise.
969 * docs/topics/types.rst: Likewise.
970
7631a4d1
GA
9712021-12-20 Martin Liska <mliska@suse.cz>
972
973 * libgccjit.c (struct version_info): Rename to jit_version_info.
974 (struct jit_version_info): Likewise.
975 (gcc_jit_version_major): Likewise.
976 (gcc_jit_version_minor): Likewise.
977 (gcc_jit_version_patchlevel): Likewise.
978
9c6586bc
GA
9792021-12-14 Petter Tomner <tomner@kth.se>
980
981 * jit-common.h: New enum
982 * jit-playback.c : Folding an setting intitial
983 (global_new_decl) : Handle const global generation
984 (new_global) : New flag
985 (global_set_init_rvalue) : New
986 (new_ctor) : New
987 (new_global_initialized) : Flag
988 (as_truth_value) : Fold
989 (new_unary_op) : Fold
990 (new_binary_op) : Fold
991 (new_comparison) : Fold
992 (new_array_access) : Fold
993 (new_dereference) : Fold
994 (get_address) : Fold
995 * jit-playback.h :
996 (global_set_init_rvalue) : New
997 (new_ctor) : New
998 * jit-recording.c :
999 * jit-recording.h :
1000 (new_global_init_rvalue) : New
1001 (new_ctor) : New
1002 (ctor) : New, inherits rvalue
1003 (global_init_rvalue) : New, inherits memento
1004 (type::is_union) : New
1005 * libgccjit++.h : New entrypoints, see C-header
1006 * libgccjit.c : See .h
1007 * libgccjit.h : New entrypoints
1008 (gcc_jit_context_new_array_constructor) : New
1009 (gcc_jit_context_new_struct_constructor) : New
1010 (gcc_jit_context_new_union_constructor) : New
1011 (gcc_jit_global_set_initializer_rvalue) : New
1012 (LIBGCCJIT_HAVE_CTORS) : New feuture macro
1013 * libgccjit.map : New entrypoints added to ABI 19
1014 * docs/topics/expressions.rst : Updated docs
1015
c8dcf64b
GA
10162021-12-12 Antoni Boucher <bouanto@zoho.com>
1017
1018 PR target/100688
1019 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_18): New ABI
1020 tag.
1021 * docs/topics/expressions.rst: Add documentation for the
1022 function gcc_jit_lvalue_set_link_section.
1023 * jit-playback.h: New function (set_link_section).
1024 * jit-recording.c: New function (set_link_section) and
1025 support for setting the link section.
1026 * jit-recording.h: New function (set_link_section) and new
1027 field m_link_section.
1028 * libgccjit.c: New function (gcc_jit_lvalue_set_link_section).
1029 * libgccjit.h: New function (gcc_jit_lvalue_set_link_section).
1030 * libgccjit.map (LIBGCCJIT_ABI_18): New ABI tag.
1031
e8decbe7
GA
10322021-12-12 Antoni Boucher <bouanto@zoho.com>
1033
1034 PR target/95415
1035 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_17): New ABI
1036 tag.
1037 * docs/topics/expressions.rst: Add document for the function
1038 gcc_jit_lvalue_set_tls_model.
1039 * jit-playback.h: New function (set_tls_model).
1040 * jit-recording.c: New function (set_tls_model), new
1041 variables (tls_models and tls_model_enum_strings) and support
1042 for setting the tls model.
1043 * jit-recording.h: New function (set_tls_model) and new
1044 field m_tls_model.
1045 * libgccjit.c: New function (gcc_jit_lvalue_set_tls_model).
1046 * libgccjit.h: New function (gcc_jit_lvalue_set_tls_model)
1047 and new enum (gcc_jit_tls_model).
1048 * libgccjit.map (LIBGCCJIT_ABI_17): New ABI tag.
1049
10502021-12-11 Antoni Boucher <bouanto@zoho.com>
1051
1052 PR target/96066
1053 PR target/96067
1054 * jit-builtins.c: Implement missing types for builtins.
1055 * jit-recording.c:: Allow sending a volatile const void * as
1056 argument.
1057 * jit-recording.h: New functions (is_volatile, is_const) and
1058 allow comparing qualified types.
1059
0bceef16
GA
10602021-12-10 David Malcolm <dmalcolm@redhat.com>
1061
1062 PR jit/103562
1063 * jit-playback.c (gcc::jit::playback::context::new_function): Set
1064 DECL_CONTEXT of the result_decl.
1065
d62c8c74
GA
10662021-11-27 Petter Tomner <tomner@kth.se>
1067
1068 * libgccjit.c: %ld -> %zu
1069
d9ca4b45
GA
10702021-11-24 Martin Liska <mliska@suse.cz>
1071
1072 * jit-playback.c (function): Initialize m_blocks vector.
1073
f658f1d7
GA
10742021-11-20 Antoni Boucher <bouanto@zoho.com>
1075
1076 PR target/96889
1077 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_16): New ABI tag.
1078 * docs/topics/functions.rst: Add documentation for the
1079 functions gcc_jit_function_get_return_type and
1080 gcc_jit_function_get_param_count
1081 * docs/topics/types.rst: Add documentation for the functions
1082 gcc_jit_function_type_get_return_type,
1083 gcc_jit_function_type_get_param_count,
1084 gcc_jit_function_type_get_param_type,
1085 gcc_jit_type_unqualified, gcc_jit_type_dyncast_array,
1086 gcc_jit_type_is_bool,
1087 gcc_jit_type_dyncast_function_ptr_type,
1088 gcc_jit_type_is_integral, gcc_jit_type_is_pointer,
1089 gcc_jit_type_dyncast_vector,
1090 gcc_jit_vector_type_get_element_type,
1091 gcc_jit_vector_type_get_num_units,
1092 gcc_jit_struct_get_field, gcc_jit_type_is_struct,
1093 and gcc_jit_struct_get_field_count
1094 * libgccjit.c:
1095 (gcc_jit_function_get_return_type, gcc_jit_function_get_param_count,
1096 gcc_jit_function_type_get_return_type,
1097 gcc_jit_function_type_get_param_count,
1098 gcc_jit_function_type_get_param_type, gcc_jit_type_unqualified,
1099 gcc_jit_type_dyncast_array, gcc_jit_type_is_bool,
1100 gcc_jit_type_dyncast_function_ptr_type, gcc_jit_type_is_integral,
1101 gcc_jit_type_is_pointer, gcc_jit_type_dyncast_vector,
1102 gcc_jit_vector_type_get_element_type,
1103 gcc_jit_vector_type_get_num_units, gcc_jit_struct_get_field,
1104 gcc_jit_type_is_struct, gcc_jit_struct_get_field_count): New
1105 functions.
1106 (struct gcc_jit_function_type, struct gcc_jit_vector_type):
1107 New types.
1108 * libgccjit.h:
1109 (gcc_jit_function_get_return_type, gcc_jit_function_get_param_count,
1110 gcc_jit_function_type_get_return_type,
1111 gcc_jit_function_type_get_param_count,
1112 gcc_jit_function_type_get_param_type, gcc_jit_type_unqualified,
1113 gcc_jit_type_dyncast_array, gcc_jit_type_is_bool,
1114 gcc_jit_type_dyncast_function_ptr_type, gcc_jit_type_is_integral,
1115 gcc_jit_type_is_pointer, gcc_jit_type_dyncast_vector,
1116 gcc_jit_vector_type_get_element_type,
1117 gcc_jit_vector_type_get_num_units, gcc_jit_struct_get_field,
1118 gcc_jit_type_is_struct, gcc_jit_struct_get_field_count): New
1119 function declarations.
1120 (struct gcc_jit_function_type, struct gcc_jit_vector_type):
1121 New types.
1122 * jit-recording.h: New functions (is_struct and is_vector)
1123 * libgccjit.map (LIBGCCJIT_ABI_16): New ABI tag.
1124
af2852b9
GA
11252021-11-12 David Malcolm <dmalcolm@redhat.com>
1126
1127 PR jit/103199
1128 * docs/examples/tut04-toyvm/toyvm.c (toyvm_function_compile):
1129 Increase size of buffer.
1130 * docs/examples/tut04-toyvm/toyvm.cc
1131 (compilation_state::create_function): Likewise.
1132
a26206ec
GA
11332021-09-10 Petter Tomner <tomner@kth.se>
1134
1135 * jit-playback.c: Moved global var processing to after loc handling.
3d3b561f
ML
1136 Setting TYPE_NAME for fundamental types.
1137 Using common functions for finalizing globals.
a26206ec 1138 * jit-playback.h: New method init_types().
3d3b561f 1139 Changed get_tree_node_for_type() to method.
a26206ec 1140
b57fba5e
GA
11412021-08-19 Iain Sandoe <iain@sandoe.co.uk>
1142
1143 * docs/examples/tut04-toyvm/toyvm.c: Include jit-dejagnu.h.
1144 * docs/examples/tut04-toyvm/toyvm.cc: Likewise.
1145 * jit-dejagnu.h: New file, imported from dejagnu-1.6.2 and
1146 patched for this application.
1147
6e529985
GA
11482021-08-18 Iain Sandoe <iain@sandoe.co.uk>
1149
1150 PR jit/100613
1151 * Make-lang.in: Provide clauses for Darwin hosts.
1152
bdea84c4
GA
11532021-07-18 Antoni Boucher <bouanto@zoho.com>
1154
1155 PR target/95498
1156 * jit-playback.c (convert): Add support to handle truncation and
1157 extension in the convert function.
1158
65f32e5d
GA
11592021-05-19 Martin Liska <mliska@suse.cz>
1160
1161 PR testsuite/100658
1162 * libgccjit.c (gcc_jit_context_new_function): Fix typos.
1163
8bf52ffa
GA
11642021-03-24 Matthias Klose <doko@ubuntu.com>
1165
1166 * Make-lang.in (jit.sphinx.html, jit.sphinx.pdf): Use $(mkinstalldirs),
1167 (jit.install-headers): Depend on installdirs.
1168
50352c6c
GA
11692021-02-19 David Malcolm <dmalcolm@redhat.com>
1170
1171 PR jit/99126
1172 * jit-builtins.c
1173 (gcc::jit::builtins_manager::get_builtin_function_by_id):
1174 Update assertion to reject BUILT_IN_NONE.
1175 (gcc::jit::builtins_manager::ensure_optimization_builtins_exist):
1176 New.
1177 * jit-builtins.h
1178 (gcc::jit::builtins_manager::ensure_optimization_builtins_exist):
1179 New decl.
1180 * jit-playback.c (gcc::jit::playback::context::replay): Call it.
1181 Remove redundant conditional on bm.
1182
5fff80fd
GA
11832021-01-14 David Malcolm <dmalcolm@redhat.com>
1184
1185 * docs/cp/index.rst: Remove "Alpha" warning.
1186 * docs/index.rst: Likewise.
1187 * docs/_build/texinfo/libgccjit.texi: Regenerate
1188
360258da
GA
11892020-11-25 Martin Sebor <msebor@redhat.com>
1190
1191 PR bootstrap/94982
1192 * jit-recording.c (recording::function::dump_to_dot): Avoid
1193 -Wformat-diag.
1194 (recording::block::dump_to_dot): Same.
1195
82e5048e
GA
11962020-11-20 Jakub Jelinek <jakub@redhat.com>
1197
1198 PR other/97911
1199 * Make-lang.in (jit.serial): Change from goal to a
1200 variable.
1201 (.PHONY): Drop jit.serial and jit.prev.
1202 ($(LIBGCCJIT_FILENAME)): Depend on $(jit.serial) rather than
1203 jit.serial.
1204
25bb75f8
GA
12052020-11-18 Jakub Jelinek <jakub@redhat.com>
1206
1207 * Make-lang.in (jit.serial): New goal.
1208 (.PHONY): Add jit.serial jit.prev.
1209 ($(LIBGCCJIT_FILENAME)): Depend on jit.prev. Call LINK_PROGRESS.
1210
a5a11525
GA
12112020-11-12 David Malcolm <dmalcolm@redhat.com>
1212
1213 PR jit/87291
1214 * docs/cp/topics/asm.rst: New file.
1215 * docs/cp/topics/index.rst (Topic Reference): Add it.
1216 * docs/topics/asm.rst: New file.
1217 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_15): New.
1218 * docs/topics/functions.rst (Statements): Add link to extended
1219 asm.
1220 * docs/topics/index.rst (Topic Reference): Add asm.rst.
1221 * docs/topics/objects.rst: Add gcc_jit_extended_asm to ASCII art.
1222 * docs/_build/texinfo/Makefile: Regenerate.
1223 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1224 * jit-common.h (gcc::jit::recording::extended_asm): New forward
1225 decl.
1226 (gcc::jit::recording::top_level_asm): Likewise.
1227 * jit-playback.c: Include "stmt.h".
1228 (build_string): New.
1229 (gcc::jit::playback::context::new_string_literal): Disambiguate
1230 build_string call.
1231 (gcc::jit::playback::context::add_top_level_asm): New.
1232 (build_operand_chain): New.
1233 (build_clobbers): New.
1234 (build_goto_operands): New.
1235 (gcc::jit::playback::block::add_extended_asm): New.
1236 * jit-playback.h (gcc::jit::playback::context::add_top_level_asm):
1237 New decl.
1238 (struct gcc::jit::playback::asm_operand): New struct.
1239 (gcc::jit::playback::block::add_extended_asm): New decl.
1240 * jit-recording.c (gcc::jit::recording::context::dump_to_file):
1241 Dump top-level asms.
1242 (gcc::jit::recording::context::add_top_level_asm): New.
1243 (gcc::jit::recording::block::add_extended_asm): New.
1244 (gcc::jit::recording::block::end_with_extended_asm_goto): New.
1245 (gcc::jit::recording::asm_operand::asm_operand): New.
1246 (gcc::jit::recording::asm_operand::print): New.
1247 (gcc::jit::recording::asm_operand::make_debug_string): New.
1248 (gcc::jit::recording::output_asm_operand::write_reproducer): New.
1249 (gcc::jit::recording::output_asm_operand::print): New.
1250 (gcc::jit::recording::input_asm_operand::write_reproducer): New.
1251 (gcc::jit::recording::input_asm_operand::print): New.
1252 (gcc::jit::recording::extended_asm::add_output_operand): New.
1253 (gcc::jit::recording::extended_asm::add_input_operand): New.
1254 (gcc::jit::recording::extended_asm::add_clobber): New.
1255 (gcc::jit::recording::extended_asm::replay_into): New.
1256 (gcc::jit::recording::extended_asm::make_debug_string): New.
1257 (gcc::jit::recording::extended_asm::write_flags): New.
1258 (gcc::jit::recording::extended_asm::write_clobbers): New.
1259 (gcc::jit::recording::extended_asm_simple::write_reproducer): New.
1260 (gcc::jit::recording::extended_asm::maybe_populate_playback_blocks):
1261 New.
1262 (gcc::jit::recording::extended_asm_goto::extended_asm_goto): New.
1263 (gcc::jit::recording::extended_asm_goto::replay_into): New.
1264 (gcc::jit::recording::extended_asm_goto::write_reproducer): New.
1265 (gcc::jit::recording::extended_asm_goto::get_successor_blocks):
1266 New.
1267 (gcc::jit::recording::extended_asm_goto::maybe_print_gotos): New.
1268 (gcc::jit::recording::extended_asm_goto::maybe_populate_playback_blocks):
1269 New.
1270 (gcc::jit::recording::top_level_asm::top_level_asm): New.
1271 (gcc::jit::recording::top_level_asm::replay_into): New.
1272 (gcc::jit::recording::top_level_asm::make_debug_string): New.
1273 (gcc::jit::recording::top_level_asm::write_to_dump): New.
1274 (gcc::jit::recording::top_level_asm::write_reproducer): New.
1275 * jit-recording.h
1276 (gcc::jit::recording::context::add_top_level_asm): New decl.
1277 (gcc::jit::recording::context::m_top_level_asms): New field.
1278 (gcc::jit::recording::block::add_extended_asm): New decl.
1279 (gcc::jit::recording::block::end_with_extended_asm_goto): New
1280 decl.
1281 (gcc::jit::recording::asm_operand): New class.
1282 (gcc::jit::recording::output_asm_operand): New class.
1283 (gcc::jit::recording::input_asm_operand): New class.
1284 (gcc::jit::recording::extended_asm): New class.
1285 (gcc::jit::recording::extended_asm_simple): New class.
1286 (gcc::jit::recording::extended_asm_goto): New class.
1287 (gcc::jit::recording::top_level_asm): New class.
1288 * libgccjit++.h (gccjit::extended_asm): New forward decl.
1289 (gccjit::context::add_top_level_asm): New.
1290 (gccjit::block::add_extended_asm): New.
1291 (gccjit::block::end_with_extended_asm_goto): New.
1292 (gccjit::extended_asm): New class.
1293 (gccjit::extended_asm::extended_asm): New ctors.
1294 (gccjit::extended_asm::set_volatile_flag): New.
1295 (gccjit::extended_asm::set_inline_flag): New.
1296 (gccjit::extended_asm::add_output_operand): New.
1297 (gccjit::extended_asm::add_input_operand): New.
1298 (gccjit::extended_asm::add_clobber): New.
1299 (gccjit::extended_asm::get_inner_extended_asm): New.
1300 * libgccjit.c (struct gcc_jit_extended_asm): New.
1301 (jit_error): Make "loc" param take a gcc::jit::recording::location *
1302 rather than a gcc_jit_location *.
1303 (gcc_jit_block_add_extended_asm): New entrypoint.
1304 (gcc_jit_block_end_with_extended_asm_goto): New entrypoint.
1305 (gcc_jit_extended_asm_as_object): New entrypoint.
1306 (gcc_jit_extended_asm_set_volatile_flag): New entrypoint.
1307 (gcc_jit_extended_asm_set_inline_flag): New entrypoint.
1308 (gcc_jit_extended_asm_add_output_operand): New entrypoint.
1309 (gcc_jit_extended_asm_add_clobber): New entrypoint.
1310 (gcc_jit_context_add_top_level_asm): New entrypoint.
1311 * libgccjit.h: Add gcc_jit_extended_asm to ASCII art.
1312 (gcc_jit_extended_asm): New typedef.
1313 (LIBGCCJIT_HAVE_ASM_STATEMENTS): New define.
1314 (gcc_jit_block_add_extended_asm): New entrypoint.
1315 (gcc_jit_block_end_with_extended_asm_goto): New entrypoint.
1316 (gcc_jit_extended_asm_as_object): New entrypoint.
1317 (gcc_jit_extended_asm_set_volatile_flag): New entrypoint.
1318 (gcc_jit_extended_asm_set_inline_flag): New entrypoint.
1319 (gcc_jit_extended_asm_add_output_operand): New entrypoint.
1320 (gcc_jit_extended_asm_add_input_operand): New entrypoint.
1321 (gcc_jit_extended_asm_add_clobber): New entrypoint.
1322 (gcc_jit_context_add_top_level_asm): New entrypoint.
1323 * libgccjit.map (LIBGCCJIT_ABI_15): New.
1324
13252020-11-12 David Malcolm <dmalcolm@redhat.com>
1326
1327 * jit-recording.c (recording::context::new_string): Add "escaped"
1328 param and use it when creating the new recording::string instance.
1329 (recording::string::string): Add "escaped" param and use it to
1330 initialize m_escaped.
1331 (recording::string::make_debug_string): Replace check that first
1332 char is double-quote with use of m_escaped. Fix escaping of
1333 '\t' and '\n'. Set "escaped" on the result.
1334 * jit-recording.h (recording::context::new_string): Add "escaped"
1335 param.
1336 (recording::string::string): Add "escaped" param.
1337 (recording::string::m_escaped): New field.
1338
13392020-11-12 David Malcolm <dmalcolm@redhat.com>
1340
1341 * libgccjit.h: Fix typo in comment.
1342
50a71cd0
GA
13432020-09-14 Andrea Corallo <andrea.corallo@arm.com>
1344
1345 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1346
ac35c090
GA
13472020-09-11 Andrea Corallo <andrea.corallo@arm.com>
1348
1349 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_14): New ABI tag.
1350 * docs/topics/expressions.rst (gcc_jit_global_set_initializer):
1351 Document new entry point in section 'Global variables'.
1352 * jit-playback.c (global_new_decl, global_finalize_lvalue): New
1353 method.
1354 (playback::context::new_global): Make use of global_new_decl,
1355 global_finalize_lvalue.
1356 (load_blob_in_ctor): New template function in use by the
1357 following.
1358 (playback::context::new_global_initialized): New method.
1359 * jit-playback.h (class context): Decl 'new_global_initialized',
1360 'global_new_decl', 'global_finalize_lvalue'.
1361 (lvalue::set_initializer): Add implementation.
1362 * jit-recording.c (recording::memento_of_get_pointer::get_size)
1363 (recording::memento_of_get_type::get_size): Add implementation.
1364 (recording::global::write_initializer_reproducer): New function in
1365 use by 'recording::global::write_reproducer'.
1366 (recording::global::replay_into)
1367 (recording::global::write_to_dump)
1368 (recording::global::write_reproducer): Handle
1369 initialized case.
1370 * jit-recording.h (class type): Decl 'get_size' and
1371 'num_elements'.
1372 * libgccjit++.h (class lvalue): Declare new 'set_initializer'
1373 method.
1374 (class lvalue): Decl 'is_global' and 'set_initializer'.
1375 (class global) Decl 'write_initializer_reproducer'. Add
1376 'm_initializer', 'm_initializer_num_bytes' fields. Implement
1377 'set_initializer'. Add a destructor to free 'm_initializer'.
1378 * libgccjit.c (gcc_jit_global_set_initializer): New function.
1379 * libgccjit.h (gcc_jit_global_set_initializer): New function
1380 declaration.
1381 * libgccjit.map (LIBGCCJIT_ABI_14): New ABI tag.
1382
8f7ea26a
GA
13832020-08-28 Martin Sebor <msebor@redhat.com>
1384
1385 * jit-recording.c (recording::switch_::make_debug_string): Add argument
1386 to a call.
1387
e769f970
GA
13882020-08-22 Andrea Corallo <andrea.corallo@arm.com>
1389
1390 * libgccjit.c:
1391 (gcc_jit_context_new_rvalue_from_int)
1392 (gcc_jit_context_new_rvalue_from_long)
1393 (gcc_jit_context_new_rvalue_from_double)
1394 (gcc_jit_context_new_rvalue_from_ptr): Update function heading
1395 comments.
1396
6fb94d67
GA
13972020-06-16 Nicolas Bértolo <nicolasbertolo@gmail.com>
1398
1399 * Make-lang.in: Always define version, minor and release
1400 numbers. Create the Windows shared library as
1401 libgccjit-$(LIBGCCJIT_VERSION_NUM).dll.
1402
9a5b7438
GA
14032020-06-03 David Malcolm <dmalcolm@redhat.com>
1404
1405 PR jit/95306
1406 * jit-builtins.c (builtins_manager::make_primitive_type):
1407 Implement BT_CONST_VOLATILE_PTR.
1408
a9312a79
GA
14092020-06-02 David Malcolm <dmalcolm@redhat.com>
1410
1411 PR jit/95426
1412 * dummy-frontend.c: Include "options.h", "stringpool.h", and
1413 "attribs.h".
1414 (ATTR_EXCL): New, copied from lto/lto-lang.c.
1415 (attr_noreturn_exclusions): Likewise.
1416 (attr_returns_twice_exclusions): Likewise.
1417 (attr_const_pure_exclusions): Likewise.
1418 (jit_attribute_table): Likewise, copied from lto_attribute_table.
1419 (jit_format_attribute_table): Likewise, copied from
1420 lto_format_attribute_table.
1421 (handle_noreturn_attribute): New, copied from lto/lto-lang.c.
1422 (handle_leaf_attribute): Likewise.
1423 (handle_const_attribute): Likewise.
1424 (handle_malloc_attribute): Likewise.
1425 (handle_pure_attribute): Likewise.
1426 (handle_novops_attribute): Likewise.
1427 (get_nonnull_operand): Likewise.
1428 (handle_nonnull_attribute): Likewise.
1429 (handle_nothrow_attribute): Likewise.
1430 (handle_sentinel_attribute): Likewise.
1431 (handle_type_generic_attribute): Likewise.
1432 (handle_transaction_pure_attribute): Likewise.
1433 (handle_returns_twice_attribute): Likewise.
1434 (handle_patchable_function_entry_attribute): Likewise.
1435 (ignore_attribute): Likewise.
1436 (handle_format_attribute): Likewise.
1437 (handle_format_arg_attribute): Likewise.
1438 (handle_fnspec_attribute): Likewise.
1439 (LANG_HOOKS_COMMON_ATTRIBUTE_TABLE): Define.
1440 (LANG_HOOKS_FORMAT_ATTRIBUTE_TABLE): Define.
1441
53ffb43a
GA
14422020-05-28 Nicolas Bértolo <nicolasbertolo@gmail.com>
1443
1444 * Make-lang.in: Remove extra slash. Build libgccjit.dll and its
1445 import library in Windows.
1446 * config-lang.in: Update comment about --enable-host-shared.
1447 * jit-w32.h: New file.
1448 * jit-w32.c: New file.
1449 (print_last_error): New function that prints the error
1450 string corresponding to GetLastError().
1451 (get_TOKEN_USER_current_user): Helper function used for getting
1452 the SID belonging to the current user.
1453 (create_directory_for_current_user): Helper function to create
1454 a directory with permissions such that only the current user can
1455 access it.
1456 (win_mkdtemp): Create a temporary directory using Windows APIs.
1457 * jit-playback.c: Do not chmod files in Windows. Use LoadLibrary,
1458 FreeLibrary and GetProcAddress instead of libdl.
1459 * jit-result.h, jit-result.c: Introduce result::handle_t to
1460 abstract over the types used for dynamic library handles.
1461 * jit-tempdir.c: Do not use mkdtemp() in Windows, use
1462 win_mkdtemp().
1463
61f3b605
GA
14642020-05-27 David Malcolm <dmalcolm@redhat.com>
1465
1466 PR jit/95314
1467 * dummy-frontend.c (LANG_HOOKS_DEEP_UNSHARING): Define to be true.
1468 * jit-playback.h (gcc::jit::playback::rvalue): Mark tree node with
1469 TREE_VISITED.
1470
14712020-05-27 Tom Tromey <tromey@gcc.gnu.org>
1472
1473 PR jit/91330
1474 * docs/conf.py (texinfo_documents): Set description.
1475 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1476
c3a4169b
GA
14772020-05-26 David Malcolm <dmalcolm@redhat.com>
1478
1479 PR jit/95306
1480 * docs/topics/functions.rst
1481 (gcc_jit_context_get_builtin_function): Document.
1482 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1483 * dummy-frontend.c (jit_langhook_global_bindings_p): Remove
1484 gcc_unreachable.
1485 * jit-builtins.c (type_names): New array.
1486 (get_string_for_type_id): New function.
1487 (gcc::jit::builtins_manager::make_primitive_type): Show name of
1488 type in error messages. Update cases to reflect the order in
1489 builtin-types.def. Implement cases for BT_INT8, BT_INT16,
1490 BT_UINT8, BT_CONST_PTR, BT_VOLATILE_PTR, BT_INT_PTR, BT_FLOAT_PTR,
1491 BT_CONST_DOUBLE_PTR, BT_SIZE, BT_CONST_SIZE.
1492
14932020-05-26 David Malcolm <dmalcolm@redhat.com>
1494
1495 * docs/topics/compatibility.rst: Fix underline.
1496 Fix missing labels.
1497 * docs/topics/types.rst: Fix missing blank line.
1498 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1499
15002020-05-26 David Malcolm <dmalcolm@redhat.com>
1501
1502 PR jit/95296
1503 * docs/topics/expressions.rst (Unary Operations): Document that
1504 result_type of gcc_jit_context_new_unary_op must be a numeric type.
1505 (Binary Operations): Likewise for gcc_jit_context_new_binary_op.
1506 (Global variables): Document that "type" of
1507 gcc_jit_context_new_global must be non-`void`.
1508 * docs/topics/function-pointers.rst
1509 (gcc_jit_context_new_function_ptr_type): Document that the
1510 param_types must be non-void, but that return_type may be.
1511 * docs/topics/functions.rst (Params): Document that
1512 gcc_jit_context_new_param's type must be non-void.
1513 (Functions): Likewise for gcc_jit_function_new_local.
1514 * docs/topics/types.rst (gcc_jit_context_new_array_type): Document
1515 that the type must be non-void.
1516 (gcc_jit_context_new_field): Likewise.
1517 * docs/_build/texinfo/Makefile: Regenerate.
1518 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1519 * libgccjit.c (gcc_jit_context_new_array_type): Fail if
1520 element_type is void.
1521 (gcc_jit_context_new_field): Likewise for "type".
1522 (gcc_jit_context_new_function_ptr_type): Likewise for each
1523 element of param_types.
1524 (gcc_jit_context_new_param): Likewise for "type".
1525 (gcc_jit_context_new_global): Likewise.
1526 (gcc_jit_function_new_local): Likewise.
1527 (gcc_jit_type_get_aligned): Likewise.
1528
63b2923d
A
15292020-03-31 Andrea Corallo <andrea.corallo@arm.com>
1530 David Malcolm <dmalcolm@redhat.com>
1531
1532 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_13): New ABI tag
1533 plus add version paragraph.
1534 * libgccjit++.h (namespace gccjit::version): Add new namespace.
1535 * libgccjit.c (gcc_jit_version_major, gcc_jit_version_minor)
1536 (gcc_jit_version_patchlevel): New functions.
1537 * libgccjit.h (LIBGCCJIT_HAVE_gcc_jit_version): New macro.
1538 (gcc_jit_version_major, gcc_jit_version_minor)
1539 (gcc_jit_version_patchlevel): New functions.
1540 * libgccjit.map (LIBGCCJIT_ABI_13) New ABI tag.
1541
0cd55f9d
A
15422020-03-23 Andrea Corallo <andrea.corallo@arm.com>
1543
1544 * jit-playback.h
1545 (gcc::jit::playback::context m_recording_ctxt): Remove
1546 m_char_array_type_node field.
1547 * jit-playback.c
1548 (playback::context::context) Remove m_char_array_type_node from member
1549 initializer list.
1550 (playback::context::new_string_literal) Fix logic to handle string
1551 length > 200.
1552
8d9254fc
JJ
15532020-01-01 Jakub Jelinek <jakub@redhat.com>
1554
1555 Update copyright years.
1556
70ce1ab9
JB
15572019-11-29 Julian Brown <julian@codesourcery.com>
1558
1559 * jit-builtins.c (BT_DFLOAT32_PTR, BT_DFLOAT64_PTR, BT_DFLOAT128_PTR):
1560 Remove commented-out cases.
1561
56e04525
DM
15622019-11-20 David Malcolm <dmalcolm@redhat.com>
1563
1564 PR jit/92483
1565 * jit-playback.c (gcc::jit::playback::context::make_fake_args):
1566 Update GCC_JIT_BOOL_OPTION_SELFCHECK_GC for new --param syntax.
1567
4d732405
RS
15682019-08-13 Richard Sandiford <richard.sandiford@arm.com>
1569
1570 PR middle-end/91421
1571 * jit-playback.c (new_function): Use set_decl_built_in_function.
1572
ab20d992 15732019-07-22 Andrea Corallo <andrea.corallo@arm.com>
9afb91b2
AC
1574
1575 * jit-recording.c (unary_op_reproducer_strings): Make it extern.
1576 (binary_op_reproducer_strings): Likewise.
1577 * jit-recording.h (unary_op_reproducer_strings): Likewise.
1578 (binary_op_reproducer_strings): Likewise.
1579 * libgccjit.c (gcc_jit_context_new_unary_op): Check result_type to be a
1580 numeric type.
1581 * libgccjit.c (gcc_jit_context_new_binary_op): Improve error message.
1582
ab20d992 15832019-07-04 Andrea Corallo <andrea.corallo@arm.com>
2b442504
AC
1584
1585 * libgccjit.c (gcc_jit_context_new_binary_op): Check result_type to be a
1586 numeric type.
1587
ab20d992 15882019-07-04 Andrea Corallo <andrea.corallo@arm.com>
ee118c14
AC
1589
1590 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_12): New ABI tag.
1591 * docs/topics/types.rst: Add gcc_jit_context_new_bitfield.
1592 * jit-common.h (namespace recording): Add class bitfield.
1593 * jit-playback.c:
1594 (DECL_C_BIT_FIELD, SET_DECL_C_BIT_FIELD): Add macros.
1595 (playback::context::new_bitfield): New method.
1596 (playback::compound_type::set_fields): Add bitfield support.
1597 (playback::lvalue::mark_addressable): Was jit_mark_addressable make this
1598 a method of lvalue plus return a bool to communicate success.
1599 (playback::lvalue::get_address): Check for jit_mark_addressable return
1600 value.
1601 * jit-playback.h (new_bitfield): New method.
1602 (class bitfield): New class.
1603 (class lvalue): Add jit_mark_addressable method.
1604 * jit-recording.c (recording::context::new_bitfield): New method.
1605 (recording::bitfield::replay_into): New method.
1606 (recording::bitfield::write_to_dump): Likewise.
1607 (recording::bitfield::make_debug_string): Likewise.
1608 (recording::bitfield::write_reproducer): Likewise.
1609 * jit-recording.h (class context): Add new_bitfield method.
1610 (class field): Make it derivable by class bitfield.
1611 (class bitfield): Add new class.
1612 * libgccjit++.h (class context): Add new_bitfield method.
1613 * libgccjit.c (struct gcc_jit_bitfield): New structure.
1614 (gcc_jit_context_new_bitfield): New function.
1615 * libgccjit.h
1616 (LIBGCCJIT_HAVE_gcc_jit_context_new_bitfield) New macro.
1617 (gcc_jit_context_new_bitfield): New function.
1618 * libgccjit.map (LIBGCCJIT_ABI_12) New ABI tag.
1619
36a3a7a3
JJ
16202019-03-21 Jakub Jelinek <jakub@redhat.com>
1621
1622 * jit-recording.c (reproducer::m_set_identifiers): Use false as Lazy
1623 in hash_set template param.
1624
ab20d992 16252019-02-05 Andrea Corallo <andrea.corallo@arm.com>
216090cc
AC
1626
1627 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_11): New ABI tag.
1628 * docs/topics/contexts.rst (Additional driver options): New
1629 section.
1630 * jit-playback.c (invoke_driver): Add call to append_driver_options.
1631 * jit-recording.c: Within namespace gcc::jit...
1632 (recording::context::~context): Free the optnames within
1633 m_driver_options.
1634 (recording::context::add_driver_option): New method.
1635 (recording::context::append_driver_options): New method.
1636 (recording::context::dump_reproducer_to_file): Add driver
1637 options.
1638 * jit-recording.h: Within namespace gcc::jit...
1639 (recording::context::add_driver_option): New method.
1640 (recording::context::append_driver_options): New method.
1641 (recording::context::m_driver_options): New field.
1642 * libgccjit++.h (gccjit::context::add_driver_option): New
1643 method.
1644 * libgccjit.c (gcc_jit_context_add_driver_option): New API
1645 entrypoint.
1646 * libgccjit.h (gcc_jit_context_add_driver_option): New API
1647 entrypoint.
1648 (LIBGCCJIT_HAVE_gcc_jit_context_add_driver_option): New
1649 macro.
1650 * libgccjit.map (LIBGCCJIT_ABI_11): New ABI tag.
1651
a5544970
JJ
16522019-01-01 Jakub Jelinek <jakub@redhat.com>
1653
1654 Update copyright years.
1655
478dd60d
DM
16562018-11-15 David Malcolm <dmalcolm@redhat.com>
1657
1658 PR other/19165
1659 * dummy-frontend.c (jit_begin_diagnostic): Add diagnostic_t param.
1660
620e594b
DM
16612018-11-13 David Malcolm <dmalcolm@redhat.com>
1662
1663 * jit-playback.c: Replace "source_location" with "location_t".
1664
033eb567
DM
16652018-10-17 David Malcolm <dmalcolm@redhat.com>
1666
1667 * Make-lang.in (selftest-jit): New.
1668
98086b2b
ML
16692018-06-28 Martin Liska <mliska@suse.cz>
1670
1671 * jit-playback.c: Include opt-suggestions.h.
1672
3de37a5d
ML
16732018-06-28 Martin Liska <mliska@suse.cz>
1674
1675 * jit-playback.c (class auto_argvec): Moved to vec.h.
1676 (auto_argvec::~auto_argvec): Likewise.
1677 (compile): Use the renamed name.
1678 (invoke_driver): Likewise.
1679
ea143da7
RO
16802018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1681
1682 PR jit/84288
1683 * Make-lang.in ($(LIBGCCJIT_FILENAME)): Add $(EXTRA_GCC_LIBS).
1684
deb3da39
DM
16852018-03-09 David Malcolm <dmalcolm@redhat.com>
1686 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1687
1688 PR jit/64089
1689 PR jit/84288
1690 * Make-lang.in (COMMA): New.
1691 (LIBGCCJIT_VERSION_SCRIPT_OPTION): New.
1692 (LIBGCCJIT_SONAME_OPTION): New.
1693 (jit): Move --version-script and -soname linker options to the
1694 above.
1695
9aba6f77
DM
16962018-01-25 David Malcolm <dmalcolm@redhat.com>
1697
1698 PR jit/81672
1699 * jit-recording.h (gcc::jit::recording::union_): Remove fields
1700 "m_loc" and "m_name".
1701
85ec4feb
JJ
17022018-01-03 Jakub Jelinek <jakub@redhat.com>
1703
1704 Update copyright years.
1705
01512446
JJ
17062017-12-19 Jakub Jelinek <jakub@redhat.com>
1707
1708 * jit-playback.c (get_type, playback::compile_to_file::copy_file,
1709 playback::context::acquire_mutex): Replace Yoda conditions with
1710 typical order conditions.
1711 * libgccjit.c (gcc_jit_context_new_struct_type,
1712 gcc_jit_struct_set_fields, gcc_jit_context_new_union_type,
1713 gcc_jit_context_new_function, gcc_jit_timer_pop): Likewise.
1714 * jit-builtins.c (matches_builtin): Likewise.
1715 * jit-recording.c (recording::compound_type::set_fields,
1716 recording::fields::write_reproducer, recording::rvalue::set_scope,
1717 recording::function::validate): Likewise.
1718 * jit-logging.c (logger::decref): Likewise.
1719
5de73c05
JJ
17202017-11-30 Jakub Jelinek <jakub@redhat.com>
1721
1722 * jit-recording.c
1723 (recording::memento_of_new_rvalue_from_const <long>::write_reproducer):
1724 Use ; instead of ;;.
1725
9e851845
JJ
17262017-11-28 Jakub Jelinek <jakub@redhat.com>
1727
1728 * jit-playback.c (add_switch): Build SWITCH_EXPR using build2 instead
1729 of build3. Formatting fixes. Adjust funciton comment.
1730
120e92fc
TV
17312017-11-23 Tom de Vries <tom@codesourcery.com>
1732
1733 * libgccjit.c (RETURN_NULL_IF_FAIL_NONNULL_NUMERIC_TYPE): Wrap in
1734 JIT_{BEGIN,END}_STMT.
1735
77f4ead7
DM
17362017-10-31 David Malcolm <dmalcolm@redhat.com>
1737
1738 * docs/internals/index.rst (Running the test suite): Document
1739 PRESERVE_EXECUTABLES.
1740 (Running under valgrind): Add markup to RUN_UNDER_VALGRIND.
1741 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1742
6069fe72
DM
17432017-10-04 David Malcolm <dmalcolm@redhat.com>
1744
1745 * docs/cp/topics/expressions.rst (Vector expressions): New
1746 section.
1747 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_10): New ABI tag.
1748 * docs/topics/expressions.rst (Vector expressions): New section.
1749 * docs/topics/types.rst (gcc_jit_type_get_vector): Add link to
1750 gcc_jit_context_new_rvalue_from_vector.
1751 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1752 * jit-common.h (gcc::jit:recording::vector_type): New forward
1753 decl.
1754 * jit-playback.c
1755 (gcc::jit::playback::context::new_rvalue_from_vector): New method.
1756 * jit-playback.h
1757 (gcc::jit::playback::context::new_rvalue_from_vector): New method.
1758 * jit-recording.c: In namespace gcc::jit::
1759 (class comma_separated_string): New class.
1760 (comma_separated_string::comma_separated_string): New ctor,
1761 adapted from recording::call::make_debug_string.
1762 (comma_separated_string::~comma_separated_string): New dtor.
1763 In namespace gcc::jit::recording::
1764 (context::new_rvalue_from_vector): New method.
1765 (type::get_vector): Update for renaming of memento_of_get_vector.
1766 (class memento_of_get_vector): Rename to...
1767 (class vector_type): ..this.
1768 (memento_of_new_rvalue_from_vector::memento_of_new_rvalue_from_vector):
1769 New ctor.
1770 (memento_of_new_rvalue_from_vector::replay_into): New method.
1771 (memento_of_new_rvalue_from_vector::visit_children): New method.
1772 (memento_of_new_rvalue_from_vector::make_debug_string): New
1773 method.
1774 (memento_of_new_rvalue_from_vector::write_reproducer): New method.
1775 (call::make_debug_string): Split out arg-printing code into ctor
1776 for comma_separated_string.
1777 * jit-recording.h: In namespace gcc::jit::recording::
1778 (context::new_rvalue_from_vector): New method.
1779 (type::dyn_cast_vector_type): New virtual function.
1780 (class memento_of_get_vector): Rename to...
1781 (class vector_type): ...this.
1782 (vector_type::unqualified): Remove this vfunc override in favor
1783 of...
1784 (vector_type::get_element_type): ...this new method.
1785 (vector_type::get_num_units): New method.
1786 (vector_type::dyn_cast_vector_type): New vfunc override.
1787 (class memento_of_new_rvalue_from_vector): New class.
1788 * libgccjit++.h (gccjit::context::new_rvalue): Add overload for
1789 vector of rvalue.
1790 * libgccjit.c (gcc_jit_context_new_binary_op): Strip off type
1791 qualifications when checking that both operands have same type.
1792 (gcc_jit_context_new_rvalue_from_vector): New API entrypoint.
1793 * libgccjit.h
1794 (LIBGCCJIT_HAVE_gcc_jit_context_new_rvalue_from_vector): New
1795 macro.
1796 (gcc_jit_context_new_rvalue_from_vector): New API entrypoint.
1797 * libgccjit.map (LIBGCCJIT_ABI_10): New ABI tag.
1798
ecd5156d
DM
17992017-09-28 David Malcolm <dmalcolm@redhat.com>
1800
1801 * docs/topics/expressions.rst (Function calls): Add link to
1802 gcc_jit_context_new_function_ptr_type.
1803 (Function pointers): Convert to cross-references to
1804 function-pointers.rst, moving material there.
1805 * docs/topics/function-pointers.rst: New page.
1806 * docs/topics/index.rst: Add function-pointers.rst.
1807 * docs/topics/types.rst (Function pointer types): New section.
1808 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1809
5a47aa2c
DM
18102017-09-28 David Malcolm <dmalcolm@redhat.com>
1811
1812 * jit-recording.c
1813 (gcc::jit::recording::function_type::is_same_type_as): New function.
1814 * jit-recording.h: In namespace gcc::jit::recording::
1815 (type::accepts_writes_from): Use is_same_type_as rather than pointer
1816 equality.
1817 (type::is_same_type_as): New virtual function.
1818 (function_type::is_same_type_as): New override.
1819
15a65e63
DM
18202017-09-27 David Malcolm <dmalcolm@redhat.com>
1821
1822 * docs/cp/topics/expressions.rst (Function pointers): New section.
1823 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_9): New tag.
1824 * docs/topics/expressions.rst (Function pointers): New section.
1825 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1826 * jit-common.h (class gcc::jit::recording::function_pointer): New
1827 forward decl.
1828 * jit-playback.c (gcc::jit::playback::function::get_address): New
1829 method.
1830 * jit-playback.h (gcc::jit::playback::function::get_address): New
1831 method decl.
1832 * jit-recording.c: Within namespace gcc::jit::recording...
1833 (function::function): Initialize new field "m_fn_ptr_type".
1834 (function::get_address): New method.
1835 (function_pointer::replay_into): New method.
1836 (function_pointer::visit_children): New method.
1837 (function_pointer::make_debug_string): New method.
1838 (function_pointer::write_reproducer): New method.
1839 * jit-recording.h: Within namespace gcc::jit::recording...
1840 (function::get_address): New method.
1841 (function): Add field "m_fn_ptr_type".
1842 (class function_pointer): New subclass of rvalue.
1843 * libgccjit++.h (gccjit::function::get_address): New method.
1844 * libgccjit.c (gcc_jit_function_get_address): New function.
1845 * libgccjit.h (LIBGCCJIT_HAVE_gcc_jit_function_get_address): New
1846 macro.
1847 (gcc_jit_function_get_address): New API entrypoint.
1848 * libgccjit.map (LIBGCCJIT_ABI_9): New tag.
1849
595ced60
DM
18502017-09-14 David Malcolm <dmalcolm@redhat.com>
1851
1852 PR jit/82174
1853 * jit-builtins.c (matches_builtin): Ignore entries with a NULL
1854 name.
1855
953e520d
DM
18562017-08-18 David Malcolm <dmalcolm@redhat.com>
1857
1858 PR tree-optimization/46805
1859 * dummy-frontend.c (jit_langhook_parse_file): Handle vector types.
1860
519d0798
DM
18612017-08-18 David Malcolm <dmalcolm@redhat.com>
1862
1863 * jit-recording.c (class gcc::jit::reproducer): Rename field
1864 "m_identifiers" to "m_map_memento_to_identifier". Add field
1865 "m_set_identifiers" and struct hash_traits for it.
1866 (gcc::jit::reproducer::reproducer): Update for above.
1867 (convert_to_identifier): New function.
1868 (gcc::jit::reproducer::ensure_identifier_is_unique): New method.
1869 (gcc::jit::reproducer::make_identifier): Avoid appending the %p
1870 unless necessary for uniqueness. Update for field renaming.
1871 (gcc::jit::reproducer::get_identifier): Update for field renaming.
1872
47ee1b7c
DM
18732017-08-09 David Malcolm <dmalcolm@redhat.com>
1874
1875 * docs/cp/topics/types.rst (Vector types): New section.
1876 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_8): New tag.
1877 * docs/topics/types.rst (gcc_jit_context_get_type): Fix typo in
1878 example.
1879 (Vector types): New section.
1880 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1881 * jit-playback.c (gcc::jit::playback::type::get_vector): New
1882 method.
1883 * jit-playback.h (gcc::jit::playback::type::get_vector): New
1884 method.
1885 * jit-recording.c: In namespace gcc::jit::recording::
1886 (type::get_vector): New method.
1887 (memento_of_get_aligned::write_reproducer): Fix typo
1888 in leading comment.
1889 (memento_of_get_vector::replay_into): New method.
1890 (memento_of_get_vector::make_debug_string): New method.
1891 (memento_of_get_vector::write_reproducer): New method.
1892 * jit-recording.h: In namespace gcc::jit::recording::
1893 (type::get_vector): New
3d3b561f 1894 method.
47ee1b7c
DM
1895 (class memento_of_get_vector): New class.
1896 * libgccjit++.h (gccjit::type::get_vector): New method.
1897 * libgccjit.c (gcc_jit_type_get_vector): New public entrypoint.
1898 * libgccjit.h (LIBGCCJIT_HAVE_gcc_jit_type_get_vector): New
1899 define.
1900 (gcc_jit_type_get_vector): New decl.
1901 * libgccjit.map (LIBGCCJIT_ABI_8): New ABI tag.
1902
b8506a8a
RS
19032017-07-05 Richard Sandiford <richard.sandiford@linaro.org>
1904 Alan Hayward <alan.hayward@arm.com>
1905 David Sherwood <david.sherwood@arm.com>
1906
1907 * dummy-frontend.c (jit_langhook_type_for_mode): Remove "enum" before
1908 "machine_mode".
1909
0ebd1f00
DM
19102017-04-24 David Malcolm <dmalcolm@redhat.com>
1911
1912 * docs/cp/topics/types.rst (gccjit::type::get_const): Remove
1913 comment.
1914 (gccjit::type::get_aligned): Add.
1915 * docs/topics/compatibility.rst: Add LIBGCCJIT_ABI_7.
1916 * docs/topics/types.rst: Add gcc_jit_type_get_aligned.
1917 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1918 * jit-playback.c (gcc::jit::playback::type::get_aligned): New
1919 method.
1920 * jit-playback.h (gcc::jit::playback::type::get_aligned): New
1921 method.
1922 * jit-recording.c: Within namespace gcc::jit::recording...
1923 (type::get_aligned): New method.
1924 (memento_of_get_aligned::replay_into): New method.
1925 (memento_of_get_aligned::make_debug_string): New method.
1926 (memento_of_get_aligned::write_reproducer): New method.
1927 * jit-recording.h: Within namespace gcc::jit::recording...
1928 (type::get_aligned): New method.
1929 (type::accepts_writes_from): Strip off qualifications from
1930 this when comparing pointer equality.
1931 (decorated_type): New subclass of type, subsuming the
1932 commonality between memento_of_get_const and
1933 memento_of_get_volatile.
1934 (memento_of_get_const): Make a subclass of decorated_type,
1935 rather than type.
1936 (memento_of_get_volatile): Likewise.
1937 (memento_of_get_aligned): Likewise.
1938 * libgccjit++.h: Within namespace gccjit...
1939 (type::get_const): New method.
1940 (type::get_aligned): New method.
1941 * libgccjit.c (gcc_jit_type_get_aligned): New function.
1942 * libgccjit.h (gcc_jit_type_get_aligned): New decl.
1943 * libgccjit.map (LIBGCCJIT_ABI_7): New
1944 (gcc_jit_type_get_aligned): Add.
1945
8a3a6ab4
DM
19462017-01-19 David Malcolm <dmalcolm@redhat.com>
1947
1948 * dummy-frontend.c (jit_langhook_type_for_size): Delete.
1949 (LANG_HOOKS_TYPE_FOR_SIZE): Don't redefine.
1950
b37589b0
DM
19512017-01-18 David Malcolm <dmalcolm@redhat.com>
1952
1953 * dummy-frontend.c (jit_langhook_type_for_size): Implement, using
1954 lto's lto_type_for_size.
1955
cbe34bb5
JJ
19562017-01-01 Jakub Jelinek <jakub@redhat.com>
1957
1958 Update copyright years.
1959
15c671a7
DM
19602016-05-20 David Malcolm <dmalcolm@redhat.com>
1961
1962 * docs/topics/compatibility.rst: Add LIBGCCJIT_ABI_6.
1963 * docs/topics/expressions.rst (Function calls): Add documentation
1964 of gcc_jit_rvalue_set_bool_require_tail_call.
1965 * docs/_build/texinfo/libgccjit.texi: Regenerate.
1966 * jit-common.h (gcc::jit::recording::base_call): Add forward decl.
1967 * jit-playback.c: Within namespace gcc::jit::playback...
1968 (context::build_call) Add "require_tail_call" param and use it
1969 to set CALL_EXPR_MUST_TAIL_CALL.
1970 (context::new_call): Add "require_tail_call" param.
1971 (context::new_call_through_ptr): Likewise.
1972 * jit-playback.h: Within namespace gcc::jit::playback...
1973 (context::new_call: Add "require_tail_call" param.
1974 (context::new_call_through_ptr): Likewise.
1975 (context::build_call): Likewise.
1976 * jit-recording.c: Within namespace gcc::jit::recording...
1977 (base_call::base_call): New constructor.
1978 (base_call::write_reproducer_tail_call): New method.
1979 (call::call): Update for inheritance from base_call.
1980 (call::replay_into): Provide m_require_tail_call to call
1981 to new_call.
1982 (call::write_reproducer): Call write_reproducer_tail_call.
1983 (call_through_ptr::call_through_ptr): Update for inheritance from
1984 base_call.
1985 (call_through_ptr::replay_into): Provide m_require_tail_call to call
1986 to new_call_through_ptr.
1987 (recording::call_through_ptr::write_reproducer): Call
1988 write_reproducer_tail_call.
1989 * jit-recording.h: Within namespace gcc::jit::recording...
1990 (rvalue::dyn_cast_base_call): New virtual function.
1991 (class base_call): New subclass of class rvalue.
1992 (class call): Inherit from base_call rather than directly from
1993 rvalue, moving get_precedence and m_args to base_call.
1994 (class call_through_ptr): Likewise.
1995 * libgccjit.c (gcc_jit_rvalue_set_bool_require_tail_call): New
1996 function.
1997 * libgccjit.h
1998 (LIBGCCJIT_HAVE_gcc_jit_rvalue_set_bool_require_tail_call): New
1999 macro.
2000 (gcc_jit_rvalue_set_bool_require_tail_call): New function.
2001 * libgccjit.map (LIBGCCJIT_ABI_6): New.
2002 (gcc_jit_rvalue_set_bool_require_tail_call): Add.
2003
6b5423a5
DM
20042016-05-17 David Malcolm <dmalcolm@redhat.com>
2005
2006 * dummy-frontend.c: Include diagnostic.h.
2007 (jit_begin_diagnostic): New function.
2008 (jit_end_diagnostic): New function.
2009 (jit_langhook_init): Register jit_begin_diagnostic
2010 and jit_end_diagnostic with the global_dc.
2011 * jit-playback.c: Include diagnostic.h.
2012 (gcc::jit::playback::context::add_diagnostic): New method.
2013 * jit-playback.h (struct diagnostic_context): Add forward
2014 declaration.
2015 (gcc::jit::playback::context::add_diagnostic): New method.
2016
f51703a8
DM
20172016-05-17 David Malcolm <dmalcolm@redhat.com>
2018
2019 * docs/topics/expressions.rst (Function calls): Document
2020 gcc_jit_context_new_call_through_ptr.
2021 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2022
54ece5e2
DM
20232016-05-13 David Malcolm <dmalcolm@redhat.com>
2024
2025 * jit-playback.h: Within namespace gcc:jit::playback...
2026 (compile_to_memory::postprocess): Mark with FINAL OVERRIDE.
2027 (compile_to_file::postprocess): Likewise.
2028 (function::finalizer): Likewise.
2029 (block::finalizer): Likewise.
2030 (source_file::finalizer): Likewise.
2031 (source_line::finalizer): Likewise.
2032 * jit-recording.c (gcc::jit::rvalue_usage_validator):: Likewise.
2033 * jit-recording.h: Within namespace gcc::jit::recording...
2034 (string::replay_into): Mark with FINAL OVERRIDE.
2035 (string::make_debug_string): Likewise.
2036 (string::write_reproducer): Likewise.
2037 (location::replay_into): Likewise.
2038 (location::dyn_cast_location): Likewise.
2039 (location::make_debug_string): Likewise.
2040 (location::write_reproducer): Likewise.
2041 (memento_of_get_type::dereference): Likewise.
2042 (memento_of_get_type::accepts_writes_from): Likewise.
2043 (memento_of_get_type::is_int): Likewise.
2044 (memento_of_get_type::is_float): Likewise.
2045 (memento_of_get_type::is_bool): Likewise.
2046 (memento_of_get_type::is_pointer): Likewise.
2047 (memento_of_get_type::is_array): Likewise.
2048 (memento_of_get_type::is_void): Likewise.
2049 (memento_of_get_type::replay_into): Likewise.
2050 (memento_of_get_type::make_debug_string): Likewise.
2051 (memento_of_get_type::write_reproducer): Likewise.
2052 (memento_of_get_pointer::dereference): Likewise.
2053 (memento_of_get_pointer::accepts_writes_from): Likewise.
2054 (memento_of_get_pointer::replay_into): Likewise.
2055 (memento_of_get_pointer::is_int): Likewise.
2056 (memento_of_get_pointer::is_float): Likewise.
2057 (memento_of_get_pointer::is_bool): Likewise.
2058 (memento_of_get_pointer::is_pointer): Likewise.
2059 (memento_of_get_pointer::is_array): Likewise.
2060 (memento_of_get_pointer::make_debug_string): Likewise.
2061 (memento_of_get_pointer::write_reproducer): Likewise.
2062 (memento_of_get_const::dereference): Likewise.
2063 (memento_of_get_const::accepts_writes_from): Likewise.
2064 (memento_of_get_const::unqualified): Likewise.
2065 (memento_of_get_const::is_int): Likewise.
2066 (memento_of_get_const::is_float): Likewise.
2067 (memento_of_get_const::is_bool): Likewise.
2068 (memento_of_get_const::is_pointer): Likewise.
2069 (memento_of_get_const::is_array): Likewise.
2070 (memento_of_get_const::void replay_into): Likewise;
2071 (memento_of_get_const::make_debug_string): Likewise.
2072 (memento_of_get_const::write_reproducer): Likewise.
2073 (memento_of_get_volatile::dereference): Likewise.
2074 (memento_of_get_volatile::unqualified): Likewise.
2075 (memento_of_get_volatile::is_int): Likewise.
2076 (memento_of_get_volatile::is_float): Likewise.
2077 (memento_of_get_volatile::is_bool): Likewise.
2078 (memento_of_get_volatile::is_pointer): Likewise.
2079 (memento_of_get_volatile::is_array): Likewise.
2080 (memento_of_get_volatile::replay_into): Likewise;
2081 (memento_of_get_volatile::make_debug_string): Likewise.
2082 (memento_of_get_volatile::write_reproducer): Likewise.
2083 (array_type::dereference): Likewise.
2084 (array_type::is_int): Likewise.
2085 (array_type::is_float): Likewise.
2086 (array_type::is_bool): Likewise.
2087 (array_type::is_pointer): Likewise.
2088 (array_type::is_array): Likewise.
2089 (array_type::replay_into): Likewise;
2090 (array_type::make_debug_string): Likewise.
2091 (array_type::write_reproducer): Likewise.
2092 (function_type::dereference): Likewise.
2093 (function_type::function_dyn_cast_function_type): Likewise.
2094 (function_type::function_as_a_function_type): Likewise.
2095 (function_type::is_int): Likewise.
2096 (function_type::is_float): Likewise.
2097 (function_type::is_bool): Likewise.
2098 (function_type::is_pointer): Likewise.
2099 (function_type::is_array): Likewise.
2100 (function_type::replay_into): Likewise;
2101 (function_type::make_debug_string): Likewise.
2102 (function_type::write_reproducer): Likewise.
2103 (field::replay_into): Likewise;
2104 (field::write_to_dump): Likewise.
2105 (field::make_debug_string): Likewise.
2106 (field::write_reproducer): Likewise.
2107 (compound_type::dereference): Likewise.
2108 (compound_type::is_int): Likewise.
2109 (compound_type::is_float): Likewise.
2110 (compound_type::is_bool): Likewise.
2111 (compound_type::is_pointer): Likewise.
2112 (compound_type::is_array): Likewise.
2113 (compound_type::has_known_size): Likewise.
2114 (struct_::dyn_cast_struct): Likewise.
2115 (struct_::replay_into): Likewise.
2116 (struct_::access_as_type): Likewise.
2117 (struct_::make_debug_string): Likewise.
2118 (struct_::write_reproducer): Likewise.
2119 (fields::replay_into): Likewise.
2120 (fields::write_to_dump): Likewise.
2121 (fields::make_debug_string): Likewise.
2122 (fields::write_reproducer): Likewise.
2123 (union_::replay_into): Likewise.
2124 (union_::make_debug_string): Likewise.
2125 (union_::write_reproducer): Likewise.
2126 (lvalue::access_as_rvalue): Mark with OVERRIDE.
2127 (param::replay_into): Mark with FINAL OVERRIDE.
2128 (param::visit_children): Likewise.
2129 (param::dyn_cast_param): Likewise.
2130 (param::access_as_rvalue): Likewise.
2131 (param::access_as_lvalue): Likewise.
2132 (param::make_debug_string): Likewise.
2133 (param::write_reproducer): Likewise.
2134 (param::get_precedence): Likewise.
2135 (function::replay_into): Likewise.
2136 (function::write_to_dump): Likewise.
2137 (function::make_debug_string): Likewise.
2138 (function::write_reproducer): Likewise.
2139 (block::write_to_dump): Likewise.
2140 (block::make_debug_string): Likewise.
2141 (block::write_reproducer): Likewise.
2142 (block::replay_into): Likewise.
2143 (global::replay_into): Likewise;
2144 (global::visit_children): Likewise.
2145 (global::write_to_dump): Likewise.
2146 (global::make_debug_string): Likewise.
2147 (global::write_reproducer): Likewise.
2148 (global::get_precedence): Likewise.
2149 (memento_of_new_rvalue_from_const::replay_into): Likewise.
2150 (memento_of_new_rvalue_from_const::visit_children): Likewise.
2151 (memento_of_new_rvalue_from_const::is_constant): Likewise.
2152 (memento_of_new_rvalue_from_const::get_wide_int): Likewise.
2153 (memento_of_new_rvalue_from_const::make_debug_string): Likewise.
2154 (memento_of_new_rvalue_from_const::write_reproducer): Likewise.
2155 (memento_of_new_rvalue_from_const::get_precedence): Likewise.
2156 (memento_of_new_string_literal::replay_into): Likewise.
2157 (memento_of_new_string_literal::visit_children): Likewise.
2158 (memento_of_new_string_literal::make_debug_string): Likewise.
2159 (memento_of_new_string_literal::write_reproducer): Likewise.
2160 (memento_of_new_string_literal::get_precedence): Likewise.
2161 (unary_op::replay_into): Likewise.
2162 (unary_op::visit_children): Likewise.
2163 (unary_op::make_debug_string): Likewise.
2164 (unary_op::write_reproducer): Likewise.
2165 (unary_op::get_precedence): Likewise.
2166 (binary_op::replay_into): Likewise.
2167 (binary_op::visit_children): Likewise.
2168 (binary_op::make_debug_string): Likewise.
2169 (binary_op::write_reproducer): Likewise.
2170 (binary_op::get_precedence): Likewise.
2171 (comparison::replay_into): Likewise.
2172 (comparison::visit_children): Likewise.
2173 (comparison::make_debug_string): Likewise.
2174 (comparison::write_reproducer): Likewise.
2175 (comparison::get_precedence): Likewise.
2176 (cast::replay_into): Likewise.
2177 (cast::visit_children): Likewise.
2178 (cast::make_debug_string): Likewise.
2179 (cast::write_reproducer): Likewise.
2180 (cast::get_precedence): Likewise.
2181 (call::replay_into): Likewise.
2182 (call::visit_children): Likewise.
2183 (call::make_debug_string): Likewise.
2184 (call::write_reproducer): Likewise.
2185 (call::get_precedence): Likewise.
2186 (call_through_ptr::replay_into): Likewise.
2187 (call_through_ptr::visit_children): Likewise.
2188 (call_through_ptr::make_debug_string): Likewise.
2189 (call_through_ptr::write_reproducer): Likewise.
2190 (call_through_ptr::get_precedence): Likewise.
2191 (array_access::replay_into): Likewise.
2192 (array_access::visit_children): Likewise.
2193 (array_access::make_debug_string): Likewise.
2194 (array_access::write_reproducer): Likewise.
2195 (array_access::get_precedence): Likewise.
2196 (access_field_of_lvalue::replay_into): Likewise.
2197 (access_field_of_lvalue::visit_children): Likewise.
2198 (access_field_of_lvalue::make_debug_string): Likewise.
2199 (access_field_of_lvalue::write_reproducer): Likewise.
2200 (access_field_of_lvalue::get_precedence): Likewise.
2201 (access_field_rvalue::replay_into): Likewise.
2202 (access_field_rvalue::visit_children): Likewise.
2203 (access_field_rvalue::make_debug_string): Likewise.
2204 (access_field_rvalue::write_reproducer): Likewise.
2205 (access_field_rvalue::get_precedence): Likewise.
2206 (dereference_field_rvalue::replay_into): Likewise.
2207 (dereference_field_rvalue::visit_children): Likewise.
2208 (dereference_field_rvalue::make_debug_string): Likewise.
2209 (dereference_field_rvalue::write_reproducer): Likewise.
2210 (dereference_field_rvalue::get_precedence): Likewise.
2211 (dereference_rvalue::replay_into): Likewise.
2212 (dereference_rvalue::visit_children): Likewise.
2213 (dereference_rvalue::make_debug_string): Likewise.
2214 (dereference_rvalue::write_reproducer): Likewise.
2215 (dereference_rvalue::get_precedence): Likewise.
2216 (get_address_of_lvalue::replay_into): Likewise.
2217 (get_address_of_lvalue::visit_children): Likewise.
2218 (get_address_of_lvalue::make_debug_string): Likewise.
2219 (get_address_of_lvalue::write_reproducer): Likewise.
2220 (get_address_of_lvalue::get_precedence): Likewise.
2221 (local::replay_into): Likewise.
2222 (local::visit_children): Likewise.
2223 (local::write_to_dump): Likewise.
2224 (local::make_debug_string): Likewise.
2225 (local::write_reproducer): Likewise.
2226 (local::get_precedence): Likewise.
2227 (statement::write_to_dump): Likewise.
2228 (eval::replay_into): Likewise.
2229 (eval::make_debug_string): Likewise.
2230 (eval::write_reproducer): Likewise.
2231 (assignment::replay_into): Likewise.
2232 (assignment::make_debug_string): Likewise.
2233 (assignment::write_reproducer): Likewise.
2234 (assignment_op::replay_into): Likewise.
2235 (assignment_op::make_debug_string): Likewise.
2236 (assignment_op::write_reproducer): Likewise.
2237 (comment::replay_into): Likewise.
2238 (comment::make_debug_string): Likewise.
2239 (comment::write_reproducer): Likewise.
2240 (conditional::replay_into): Likewise.
2241 (conditional::get_successor_blocks): Likewise.
2242 (conditional::make_debug_string): Likewise.
2243 (conditional::write_reproducer): Likewise.
2244 (jump::replay_into): Likewise.
2245 (jump::get_successor_blocks): Likewise.
2246 (jump::make_debug_string): Likewise.
2247 (jump::write_reproducer): Likewise.
2248 (return_::replay_into): Likewise.
2249 (return_::get_successor_blocks): Likewise.
2250 (return_::make_debug_string): Likewise.
2251 (return_::write_reproducer): Likewise.
2252 (case_::replay_into): Likewise.
2253 (case_::write_reproducer): Likewise.
2254 (case_::make_debug_string): Likewise.
2255 (switch_::replay_into): Likewise.
2256 (switch_::get_successor_blocks): Likewise.
2257 (switch_::make_debug_string): Likewise.
2258 (switch_::write_reproducer): Likewise.
2259
f258ad62
DM
22602016-02-08 David Malcolm <dmalcolm@redhat.com>
2261
2262 * dummy-frontend.c (jit_langhook_init): Remove
2263 second argument to build_common_tree_nodes to
2264 track r233218.
2265
1c652ccb
IB
22662016-01-23 Iain Buclaw <ibuclaw@gdcproject.org>
2267
2268 * jit-playback.c: Include pthread.h.
2269
199501ea
DM
22702016-01-19 David Malcolm <dmalcolm@redhat.com>
2271
2272 PR jit/69144
2273 * jit-playback.c (gcc::jit::playback::compile_to_file::postprocess):
2274 Potentially add the temporary artifact to the tempdir's list of
2275 tempfiles needing additional cleanup.
2276 (gcc::jit::playback::context::extract_any_requested_dumps): Likewise
2277 for the dumpfile.
2278 * jit-tempdir.c (gcc::jit::tempdir::~tempdir): Clean up additional
2279 tempfiles.
2280 * jit-tempdir.h (gcc::jit::tempdir::add_temp_file): New method.
2281 (gcc::jit::tempdir::m_tempfiles): New field.
2282 * docs/cp/intro/tutorial04.rst: Update for changes to toyvm.cc.
2283 * docs/examples/tut04-toyvm/toyvm.cc (class compilation_result):
2284 New.
2285 (toyvm_function::compile): Change return type from function ptr
2286 to a compilation_result.
2287 (toyvm_function::get_function_name): New accessor.
2288 (toyvm_function::m_funcname): New field.
2289 (get_function_name): Convert to...
2290 (toyvm_function::make_function_name): ...this new method.
2291 (toyvm_function::parse): Call make_function_name.
2292 (toyvm_function::compile): Convert return type from function ptr
2293 to a compilation_result. Use get_function_name.
2294 (compilation_state::compile): Convert return type from
2295 gcc_jit_result * to a compilation_result.
2296 (test_script): Update for above changes, extracting the code from
2297 the compilation_result.
2298 (main): Likewise.
2299 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2300
818ab71a
JJ
23012016-01-04 Jakub Jelinek <jakub@redhat.com>
2302
2303 Update copyright years.
2304
69f293c9
AM
23052015-11-11 Andrew MacLeod <amacleod@redhat.com>
2306
2307 * dummy-frontend.c: Remove unused header files.
2308 * jit-builtins.c: Likewise.
2309 * jit-playback.c: Likewise.
2310 * jit-recording.c: Likewise.
2311 * jit-spec.c: Likewise.
2312 * libgccjit.c: Likewise.
2313
0aad0198
RS
23142015-11-07 Richard Sandiford <richard.sandiford@arm.com>
2315
2316 * jit-builtins.c: Don't undef DEF_BUILTIN.
2317
2adfab87
AM
23182015-10-29 Andrew MacLeod <amacleod@redhat.com>
2319
2320 * dummy-frontend.c: Reorder #include's and remove duplicates.
2321 * jit-builtins.c: Likewise.
2322 * jit-playback.c: Likewise.
2323 * jit-recording.c: Likewise.
2324 * libgccjit.c: Likewise.
2325
d9a6bd32
JJ
23262015-10-13 Jakub Jelinek <jakub@redhat.com>
2327
2328 * jit-builtins.c (DEF_FUNCTION_TYPE_9, DEF_FUNCTION_TYPE_10,
2329 DEF_FUNCTION_TYPE_11): Define.
2330 * jit-builtins.h (DEF_FUNCTION_TYPE_9, DEF_FUNCTION_TYPE_10,
2331 DEF_FUNCTION_TYPE_11): Define.
2332
fa83660d
TS
23332015-09-30 Thomas Schwinge <thomas@codesourcery.com>
2334 Ulrich Drepper <drepper@gmail.com>
2335
2336 * jit-builtins.h: Undefine DEF_FUNCTION_TYPE_VAR_6 after use.
2337
20a44562
MK
23382015-09-30 Matthias Klose <doko@ubuntu.com>
2339
2340 * jit-builtins.h Define DEF_FUNCTION_TYPE_VAR_6,
2341 remove DEF_FUNCTION_TYPE_VAR_11.
2342 * jit-builtins.c (builtins_manager::make_type): Define and handle
2343 DEF_FUNCTION_TYPE_VAR_6, remove DEF_FUNCTION_TYPE_VAR_11.
2344
9376dd63
DM
23452015-08-25 David Malcolm <dmalcolm@redhat.com>
2346
2347 * docs/cp/topics/contexts.rst
2348 (gccjit::context::set_bool_use_external_driver): New.
2349 * docs/internals/test-hello-world.exe.log.txt: Update.
2350 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_5): New.
2351 * docs/topics/contexts.rst
2352 (gcc_jit_context_set_bool_use_external_driver): New.
2353 * jit-common.h (enum inner_bool_option): Add
2354 INNER_BOOL_OPTION_USE_EXTERNAL_DRIVER.
2355 * jit-playback.c (gcc_driver_name): New global.
2356 (gcc:jit::playback::context::invoke_driver): Split out second
2357 half into...
2358 (gcc::jit::playback::context::invoke_embedded_driver): ...this new
2359 function, and...
2360 (gcc::jit::playback::context::invoke_external_driver): ...this new
2361 function.
2362 * jit-playback.h
2363 (gcc::jit::playback::context::get_inner_bool_option): New.
2364 (gcc::jit::playback::context::invoke_embedded_driver): New.
2365 (gcc::jit::playback::context::invoke_external_driver): New.
2366 * jit-recording.c (inner_bool_option_reproducer_strings):
2367 Add entry for INNER_BOOL_OPTION_USE_EXTERNAL_DRIVER.
2368 * libgccjit++.h
2369 (gccjit::context::set_bool_use_external_driver): New.
2370 * libgccjit.c (gcc_jit_context_set_bool_use_external_driver): New.
2371 * libgccjit.h (gcc_jit_context_set_bool_use_external_driver): New.
2372 (LIBGCCJIT_HAVE_gcc_jit_context_set_bool_use_external_driver):
2373 New.
2374 * libgccjit.map (LIBGCCJIT_ABI_5): New.
2375 * notes.txt: Show invocation of embedded copy of driver.
2376 * docs/internals/test-hello-world.exe.log.txt: Update
2377
baf3fbad
DM
23782015-08-13 David Malcolm <dmalcolm@redhat.com>
2379
2380 * jit-playback.c (invoke_driver): On OS X, add
2381 "-Wl,-undefined,dynamic_lookup" to the driver arguments.
2382
afed3459
DM
23832015-08-03 David Malcolm <dmalcolm@redhat.com>
2384
2385 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_4): New.
2386 * docs/topics/contexts.rst (GCC_JIT_BOOL_OPTION_DUMP_SUMMARY):
2387 We no longer show a profile.
2388 * docs/topics/index.rst (Topic Reference): Add performance.rst.
2389 * docs/topics/performance.rst: New file.
2390 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2391 * jit-playback.c (gcc::jit::playback::context::compile): Add timer
2392 param when constructing the "toplev" instance.
2393 (gcc::jit::playback::context::acquire_mutex): Add timer param when
2394 constructing auto_timevar instance.
2395 (gcc::jit::playback::context::make_fake_args): If we have a timer,
2396 add "-ftime-report".
2397 (gcc::jit::playback::context::invoke_driver): Add timer param when
2398 constructing auto_timevar instance.
2399 (gcc::jit::playback::context::dlopen_built_dso): Likewise.
2400 * jit-playback.h (gcc::jit::playback::context::get_timer): New accessor.
2401 * jit-recording.c: Include timevar.h.
2402 (gcc::jit::recording::context::context): Initialize field "m_timer".
2403 * jit-recording.h: Add forward declaration of class timer.
2404 (gcc::jit::recording::context::set_timer): New method.
2405 (gcc::jit::recording::context::get_timer): New method.
2406 (gcc::jit::recording::context::m_timer): New field.
2407 * libgccjit++.h (gccjit::timer): New class.
2408 (gccjit::auto_time): New class.
2409 (gccjit::context::set_timer): New method.
2410 (gccjit::context::get_timer): New.
2411 (gccjit::timer::timer): New.
2412 (gccjit::timer::push): New.
2413 (gccjit::timer::pop): New.
2414 (timer::print): New.
2415 (timer::get_inner_timer): New.
2416 (timer::release): New.
2417 (auto_time::auto_time): New.
2418 (auto_time::~auto_time): New.
2419 * libgccjit.c: Include timevar.h.
2420 (struct gcc_jit_timer): New.
2421 (gcc_jit_timer_new): New function.
2422 (gcc_jit_timer_release): New function.
2423 (gcc_jit_context_set_timer): New function.
2424 (gcc_jit_context_get_timer): New function.
2425 (gcc_jit_timer_push): New function.
2426 (gcc_jit_timer_pop): New function.
2427 (gcc_jit_timer_print): New function.
2428 * libgccjit.h (LIBGCCJIT_HAVE_TIMING_API): New macro.
2429 (gcc_jit_timer): New typedef.
2430 (gcc_jit_timer_new): New function.
2431 (gcc_jit_timer_release): New function.
2432 (gcc_jit_context_set_timer): New function.
2433 (gcc_jit_context_get_timer): New function.
2434 (gcc_jit_timer_push): New function.
2435 (gcc_jit_timer_pop): New function.
2436 (gcc_jit_timer_print): New function.
2437 * libgccjit.map (LIBGCCJIT_ABI_4): New.
2438 (gcc_jit_timer_new): New function.
2439 (gcc_jit_timer_release): New function.
2440 (gcc_jit_context_set_timer): New function.
2441 (gcc_jit_context_get_timer): New function.
2442 (gcc_jit_timer_push): New function.
2443 (gcc_jit_timer_pop): New function.
2444 (gcc_jit_timer_print): New function.
2445
eb3982c1
DM
24462015-07-23 David Malcolm <dmalcolm@redhat.com>
2447
2448 * jit-playback.c (invoke_driver): Convert local "argvec"
2449 to an auto_argvec, so that it owns copies of the strings,
2450 rather than borrows them, updating ADD_ARG to use xstrdup
2451 and special-casing the NULL terminator to avoid
2452 xstrdup (NULL). Call add_multilib_driver_arguments at the front
2453 of the arguments.
2454 (MULTILIB_DEFAULTS): Provide a default definition.
2455 (multilib_defaults_raw): New constant array.
2456 (gcc::jit::playback::context::add_multilib_driver_arguments): New
2457 method.
2458 * jit-playback.h
2459 (gcc::jit::playback::context::add_multilib_driver_arguments): New
2460 method.
2461 * docs/internals/test-hello-world.exe.log.txt: Update.
2462 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2463
1470e75f
DM
24642015-07-16 David Malcolm <dmalcolm@redhat.com>
2465
2466 * docs/internals/index.rst (Overview of code structure): Add note
2467 that the implementation is in C++, despite the .c extension.
2468 (Submitting patches): New subsection.
2469 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2470
1916bcb5
AM
24712015-07-09 Andrew MacLeod <amacleod@redhat.com>
2472
2473 * dummy-frontend.c: Adjust includes for flags.h changes.
2474 * jit-common.h: Likewise.
2475 * jit-playback.c: Likewise.
2476
58c5ad40
DM
24772015-07-08 David Malcolm <dmalcolm@redhat.com>
2478
2479 PR jit/66783
2480 * libgccjit.c (gcc_jit_context_new_field): Show name of field in
2481 "unknown size" error message.
2482 (gcc_jit_struct_set_fields): Show name of struct in error message.
2483 (gcc_jit_context_new_global): Show name of global in
2484 "unknown size" error message.
2485 (gcc_jit_function_new_local): Likewise for local.
2486
c7131fb2
AM
24872015-07-07 Andrew MacLeod <amacleod@redhat.com>
2488
2489 * dummy-frontend.c: Adjust includes.
2490 * jit-common.h: Likewise.
2491 * jit-playback.c: Likewise.
2492
3457d39e
DM
24932015-07-07 David Malcolm <dmalcolm@redhat.com>
2494
2495 PR jit/66783
2496 * jit-recording.h: Within namespace gcc:jit::recording...
2497 (type::has_known_size): New virtual function.
2498 (struct_has_known_size): New function.
2499 * libgccjit.c (gcc_jit_context_new_field): Verify that the type
2500 has a known size.
2501 (gcc_jit_context_new_global): Likewise.
2502 (gcc_jit_function_new_local): Likewise.
2503
bada4bed
DM
25042015-07-07 David Malcolm <dmalcolm@redhat.com>
2505
2506 PR jit/66779
2507 * dummy-frontend.c (jit_langhook_type_for_mode): Ensure that we
2508 handle modes QI, HI, SI, DI, TI.
2509
e09abfa4
DM
25102015-07-01 David Malcolm <dmalcolm@redhat.com>
2511
2512 PR jit/66700
2513 * jit-playback.c (jit_mark_addressable): New function.
2514 (gcc::jit::playback::lvalue::get_address): Call
2515 jit_mark_addressable on the underlying tree.
2516
e807aeaa
DM
25172015-07-01 David Malcolm <dmalcolm@redhat.com>
2518
2519 * docs/topics/types.rst (gcc_jit_context_new_union_type): Add
2520 documentation.
2521 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2522
c575221a
DM
25232015-07-01 David Malcolm <dmalcolm@redhat.com>
2524
2525 * docs/topics/contexts.rst (gcc_jit_context_set_bool_option):
2526 Clarify lack of lifetime requirements on (const char *) parameter.
2527 * docs/topics/expressions.rst
2528 (gcc_jit_context_new_string_literal): Likewise.
2529 (gcc_jit_context_new_global): Likewise.
2530 * docs/topics/functions.rst (gcc_jit_context_new_param): Likewise.
2531 (gcc_jit_context_new_function): Likewise.
2532 (gcc_jit_function_new_block): Likewise.
2533 (gcc_jit_block_add_comment): Likewise.
2534 * docs/topics/locations.rst (gcc_jit_context_new_location):
2535 Likewise.
2536 * docs/topics/types.rst (gcc_jit_context_new_field): Likewise.
2537 (gcc_jit_context_new_struct_type): Likewise.
2538 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2539
ec5d0088
DM
25402015-06-30 David Malcolm <dmalcolm@redhat.com>
2541
2542 * docs/cp/topics/functions.rst (Blocks): Add switch statements to
2543 list of ways to terminate a block.
2544 (gccjit::block::end_with_switch): Add function description.
2545 (gccjit::case_): Add class.
2546 (gccjit::context::new_case): Add function description.
2547 * docs/cp/topics/objects.rst: Add "case_" to class hierarchy.
2548 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_3): New.
2549 * docs/topics/functions.rst (Blocks): Add switch statements to
2550 list of ways to terminate a block.
2551 (gcc_jit_block_end_with_switch): Add function description.
2552 (gcc_jit_case): Add type.
2553 (gcc_jit_context_new_case): Add function description.
2554 (gcc_jit_case_as_object): Add function description.
2555 * docs/topics/objects.rst: Add gcc_jit_case to class hierarchy.
2556 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2557 * jit-common.h (gcc::jit::recording::case_): Add forward decl.
2558 (gcc::jit::playback::case_): Add forward decl.
2559 * jit-playback.c (add_case): New function.
2560 (gcc::jit::playback::block::add_switch): New function.
2561 * jit-playback.h (gcc::jit::playback::case_): New struct.
2562 (gcc::jit::playback::block::get_function): New method.
2563 (gcc::jit::playback::block::add_switch): New method.
2564 * jit-recording.c: Within namespace gcc::jit...
2565 (recording::context::new_case): New method.
2566 (recording::function::validate): Update for change to
2567 get_successor_blocks.
2568 (recording::block::end_with_switch): New method.
2569 (recording::block::get_successor_blocks): Update to support an
2570 arbitrary number of successor blocks.
2571 (recording::block::dump_edges_to_dot): Likewise.
2572 (memento_of_new_rvalue_from_const <int>::get_wide_int): New.
2573 (memento_of_new_rvalue_from_const <long>::get_wide_int): New.
2574 (memento_of_new_rvalue_from_const <double>::get_wide_int): New.
2575 (memento_of_new_rvalue_from_const <void *>::get_wide_int): New.
2576 (recording::statement::get_successor_blocks): Update to support an
2577 arbitrary number of successor blocks.
2578 (recording::conditional::get_successor_blocks): Likewise.
2579 (recording::jump::get_successor_blocks): Likewise.
2580 (recording::return_::get_successor_blocks): Likewise.
2581 (recording::case_::write_reproducer): New.
2582 (recording::case_::make_debug_string): New.
2583 (recording::switch_::switch_): New.
2584 (recording::switch_::replay_into): New.
2585 (recording::switch_::get_successor_blocks): New.
2586 (recording::switch_::make_debug_string): New.
2587 (recording::switch_::write_reproducer): New.
2588 * jit-recording.h: Within namespace gcc::jit::recording...
2589 (context::new_case): New.
2590 (rvalue::is_constant): New.
2591 (rvalue::get_wide_int): New.
2592 (block::end_with_switch): New.
2593 (block::get_successor_blocks): Update to support an arbitrary
2594 number of successor blocks.
2595 (memento_of_new_rvalue_from_const::is_constant): New.
2596 (memento_of_new_rvalue_from_const::get_wide_int): New.
2597 (statement::get_successor_blocks): Update to support an arbitrary
2598 number of successor blocks.
2599 (conditional::get_successor_blocks): Likewise.
2600 (jump::get_successor_blocks): Likewise.
2601 (return_::get_successor_blocks): Likewise.
2602 (case_): New subclass of memento.
2603 (switch_): New subclass of statement.
2604 * libgccjit++.h (gccjit::case_): New subclass of gccjit::object.
2605 (gccjit::context::new_case): New method.
2606 (gccjit::block::end_with_switch): New method.
2607 (gccjit::case_::case): New ctors.
2608 (gccjit::case_::get_inner_case): New method.
2609 * libgccjit.c: Include "typed-splay-tree.h"
2610 (struct gcc_jit_case): New.
2611 (gcc_jit_context_new_case): New function.
2612 (gcc_jit_case_as_object): New function.
2613 (valid_dest_for_switch): New function.
2614 (valid_case_for_switch): New function.
2615 (class api_call_validator): New class.
2616 (class case_range_validator): New class.
2617 (case_range_validator::case_range_validator): New.
2618 (case_range_validator::validate): New.
2619 (case_range_validator::case_compare): New.
2620 (case_range_validator::get_wide_int): new.
2621 (gcc_jit_block_end_with_switch): New.
2622 * libgccjit.h: Add gcc_jit_case to class hierarchy comment.
2623 (gcc_jit_case): New typedef.
2624 (gcc_jit_context_new_case): New function.
2625 (gcc_jit_case_as_object): New function.
2626 (gcc_jit_block_end_with_switch): New function.
2627 (LIBGCCJIT_HAVE_SWITCH_STATEMENTS): New.
2628 * libgccjit.map: Add gcc_jit_block_end_with_switch,
2629 gcc_jit_case_as_object and gcc_jit_context_new_case.
2630
6a3603e3
DM
26312015-06-30 David Malcolm <dmalcolm@redhat.com>
2632
2633 PR jit/66546
2634 * docs/cp/topics/contexts.rst
2635 (gccjit::context::set_bool_allow_unreachable_blocks): New.
2636 * docs/topics/compatibility.rst (LIBGCCJIT_ABI_2): New.
2637 * docs/topics/contexts.rst (Options): Add notes discussing the
2638 transition from enums to entrypoints for new options.
2639 (gcc_jit_context_set_bool_allow_unreachable_blocks): New.
2640 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2641 * jit-common.h (gcc::jit::inner_bool_option): New enum.
2642 * jit-recording.c: Within namespace gcc::jit...
2643 (recording::context::context): Handle m_inner_bool_options.
2644 (recording::context::set_inner_bool_option): New.
2645 (inner_bool_option_reproducer_strings): New.
2646 (recording::context::log_all_options): Log the "inner" bool
2647 options.
2648 (recording::context::log_inner_bool_option): New.
2649 (recording::context::dump_reproducer_to_file): Write initializers
2650 for "inner" bool options.
2651 (recording::function::validate): Don't check for block
2652 reachability if INNER_BOOL_OPTION_ALLOW_UNREACHABLE_BLOCKS is set.
2653 * jit-recording.h: Within namespace gcc::jit...
2654 (recording::context::set_inner_bool_option): New.
2655 (recording::context::get_inner_bool_option): New.
2656 (recording::context::log_inner_bool_option): New.
2657 (recording::context::m_inner_bool_options): New.
2658 * libgccjit++.h
2659 (gccjit::context::set_bool_allow_unreachable_blocks): New.
2660 * libgccjit.c
2661 (gcc_jit_context_set_bool_allow_unreachable_blocks): New.
2662 * libgccjit.h: Add note about options present in the
2663 initial release of libgccjit.
2664 (gcc_jit_context_set_bool_allow_unreachable_blocks): New API
2665 entrypoint.
2666 (LIBGCCJIT_HAVE_gcc_jit_context_set_bool_allow_unreachable_blocks):
2667 New macro.
2668 * libgccjit.map (LIBGCCJIT_ABI_2): New, containing...
2669 (gcc_jit_context_set_bool_allow_unreachable_blocks): ...this new
2670 entrypoint.
2671
fa22c20d
DM
26722015-06-30 David Malcolm <dmalcolm@redhat.com>
2673
2674 PR jit/66628
2675 * docs/cp/topics/contexts.rst (Additional command-line options):
2676 New section.
2677 * docs/topics/compatibility.rst: New file.
2678 * docs/topics/contexts.rst (Additional command-line options): New
2679 section.
2680 * docs/topics/index.rst: Add compatibility.rst.
2681 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2682 * jit-playback.c (make_fake_args): Add call to
2683 append_command_line_options.
2684 * jit-recording.c: Within namespace gcc::jit...
2685 (recording::context::~context): Free the optnames within
2686 m_command_line_options.
2687 (recording::context::set_bool_option): Likewise.
2688 (recording::context::add_command_line_option): New method.
2689 (recording::context::append_command_line_options): New method.
2690 (recording::context::dump_reproducer_to_file): Add command-line
2691 options.
2692 * jit-recording.h: Within namespace gcc::jit...
2693 (recording::context::add_command_line_option): New method.
2694 (recording::context::append_command_line_options): New method.
2695 (recording::context::m_command_line_options): New field.
2696 * libgccjit++.h (gccjit::context::add_command_line_option): New
2697 method.
2698 * libgccjit.c (gcc_jit_context_add_command_line_option): New API
2699 entrypoint.
2700 * libgccjit.h (gcc_jit_context_add_command_line_option): New API
2701 entrypoint.
2702 (LIBGCCJIT_HAVE_gcc_jit_context_add_command_line_option): New
2703 macro.
2704 * libgccjit.map: Put existing symbols within LIBGCCJIT_ABI_0; add
2705 LIBGCCJIT_ABI_1 and gcc_jit_context_add_command_line_option.
2706
a6314e15
DM
27072015-06-30 David Malcolm <dmalcolm@redhat.com>
2708
2709 * jit-recording.c
2710 (gcc::jit::recording::context::dump_reproducer_to_file):
2711 Add pragma to generated reproducers to disable -Wunused-variable.
2712 Fix handling of NULL string options.
2713
adb6d84b
DM
27142015-06-30 David Malcolm <dmalcolm@redhat.com>
2715
2716 * docs/cp/topics/expressions.rst: Remove stray semicolon.
2717 * docs/cp/topics/functions.rst: Remove stray backslash.
2718 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2719
f0889939
AM
27202015-06-25 Andrew MacLeod <amacleod@redhat.com>
2721
2722 * dummy-frontend.c: Remove ipa-ref.h and plugin-api.h from include list.
2723 * jit-playback.c: Likewise.
2724
9cad7a76
AM
27252015-06-25 Andrew Macleod <amacleod@redhat.com>
2726
2727 * jit-common.h: Don't include alias.h.
2728
41571b55
DM
27292015-06-17 David Malcolm <dmalcolm@redhat.com>
2730
2731 * libgccjit.c (gcc_jit_lvalue_access_field): Verify that the field
2732 is for the correct struct.
2733 (gcc_jit_rvalue_access_field): Likewise.
2734
abb226c9
AM
27352015-06-17 Andrew MacLeod <amacleod@redhat.com>
2736
2737 * dummy-frontend.c: Do not include input.h, line-map.h or is-a.h.
2738 * jit-common.h: Likewise.
2739 * jit-playback.c: Likewise.
2740
bd93aa1a
DM
27412015-06-16 David Malcolm <dmalcolm@redhat.com>
2742
2743 PR jit/66539
2744 * jit-recording.c: Within namespace gcc::jit::recording::
2745 (rvalue::get_debug_string_parens): New function.
2746 (binary_op::make_debug_string): Update to mimic C precedence
2747 rules.
2748 (binary_op_precedence): New array.
2749 (binary_op::get_precedence): New function.
2750 (comparison::make_debug_string): Update to mimic C precedence
2751 rules.
2752 (comparison_precedence): New array.
2753 (comparison::get_precedence): New function.
2754 (cast::make_debug_string): Update to mimic C precedence rules.
2755 (call::make_debug_string): Likewise.
2756 (call_through_ptr::make_debug_string): Likewise.
2757 (array_access::make_debug_string): Likewise.
2758 (access_field_of_lvalue::make_debug_string): Likewise.
2759 (access_field_rvalue::make_debug_string): Likewise.
2760 (dereference_field_rvalue::make_debug_string): Likewise.
2761 (dereference_rvalue::make_debug_string): Likewise.
2762 (get_address_of_lvalue::make_debug_string): Likewise.
2763 * jit-recording.h: Within namespace gcc::jit::recording::
2764 (precedence): New enum.
2765 (rvalue::rvalue): Initialize field "m_parenthesized_string".
2766 (rvalue::get_debug_string_parens): New method.
2767 (rvalue::get_precedence): New pure virtual function.
2768 (rvalue::m_parenthesized_string): New field.
2769 (param::get_precedence): New function.
2770 (global::get_precedence): New function.
2771 (memento_of_new_rvalue_from_const::get_precedence): New function.
2772 (memento_of_new_string_literal::get_precedence): New function.
2773 (unary_op::get_precedence): New function.
2774 (binary_op::get_precedence): New function.
2775 (comparison::get_precedence): New function.
2776 (cast::get_precedence): New function.
2777 (call::get_precedence): New function.
2778 (call_through_ptr::get_precedence): New function.
2779 (array_access::get_precedence): New function.
2780 (access_field_of_lvalue::get_precedence): New function.
2781 (access_field_rvalue::get_precedence): New function.
2782 (dereference_field_rvalue::get_precedence): New function.
2783 (dereference_rvalue::get_precedence): New function.
2784 (get_address_of_lvalue::get_precedence): New function.
2785 (local::get_precedence): New function.
2786
83c1b80e
MK
27872015-06-09 Matthias Klose <doko@ubuntu.com>
2788
2789 * Make-lang.in (jit.install-common): Install headers using INSTALL_DATA.
2790
13fdf2e2
AM
27912015-06-08 Andrew MacLeod <amacleod@redhat.com>
2792
2793 * dummy-frontend.c : Adjust include files.
2794 * jit-common.h : Likewise.
2795 * jit-playback.c : Likewise.
2796
e4753451
DM
27972015-06-05 David Malcolm <dmalcolm@redhat.com>
2798
2799 * dummy-frontend.c
2800 (jit_langhook_post_compilation_parsing_cleanups): Remove.
2801 (LANG_HOOKS_POST_COMPILATION_PARSING_CLEANUPS): Remove
2802 * jit-playback.c (gcc::jit::playback::context::new_global): Add
2803 call to varpool_node::finalize_decl.
2804 (gcc::jit::playback::context::finalize_global_decls): Remove.
2805 * jit-playback.h
2806 (gcc::jit::playback::context::finalize_global_decls): Remove.
2807
e7547bc6
DM
28082015-06-05 David Malcolm <dmalcolm@redhat.com>
2809
2810 * dummy-frontend.c (jit_langhook_write_globals): Rename to...
2811 (jit_langhook_post_compilation_parsing_cleanups): ...this, and
2812 eliminate calls to finalize_compilation_unit and
2813 write_global_decls_2.
2814 (LANG_HOOKS_WRITE_GLOBALS): Rename to...
2815 (LANG_HOOKS_POST_COMPILATION_PARSING_CLEANUPS): ...this and
2816 redirect from jit_langhook_write_globals to
2817 jit_langhook_post_compilation_parsing_cleanups.
2818 * jit-playback.c
2819 (gcc::jit::playback::context::write_global_decls_1): Rename to...
2820 (gcc::jit::playback::context::finalize_global_decls): ...this.
2821 (gcc::jit::playback::context::write_global_decls_1): Delete.
2822 * jit-playback.h
2823 (gcc::jit::playback::context::write_global_decls_1): Rename to...
2824 (gcc::jit::playback::context::finalize_global_decls): ...this.
2825 (gcc::jit::playback::context::write_global_decls_1): Delete.
2826
ecb9f223
AM
28272015-06-04 Andrew MacLeod <amacleod@redhat.com>
2828
2829 * dummy-frontend.c: Adjust includes for restructured coretypes.h.
2830 * jit-common.h: Likewise.
2831 * jit-playback.c: Likewise.
2832
2637afb7
DM
28332015-05-12 David Malcolm <dmalcolm@redhat.com>
2834
2835 * jit-builtins.c: Include vec.h before target.h.
2836
46bf0b0a
JW
28372015-04-27 Jim Wilson <jim.wilson@linaro.org>
2838
2839 * Make-lang.in (jit.mostlyclean): Remove shared libraries and object
2840 files.
2841
51c5c6b5
DM
28422015-04-09 David Malcolm <dmalcolm@redhat.com>
2843
2844 PR jit/65691
2845 * docs/cp/topics/expressions.rst (Simple expressions): Fix copy
2846 and paste error in description of gccjit::context::one.
2847 * docs/topics/expressions.rst (Simple expressions): Likewise in
2848 description of gcc_jit_context_one.
2849 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2850
f40fd895
UB
28512015-03-13 Uros Bizjak <ubizjak@gmail.com>
2852
2853 * jit-recording.c (dump::write): Also check vasprintf return value.
2854 (recording::context::add_error_va): Ditto.
2855 (recording::string::from_printf): Ditto.
2856
18eb0d13
DM
28572015-03-13 David Malcolm <dmalcolm@redhat.com>
2858
2859 * docs/internals/index.rst (Packaging notes): New section.
2860 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2861
7ef96183
DM
28622015-03-05 David Malcolm <dmalcolm@redhat.com>
2863
2864 * docs/cp/intro/tutorial03.rst: Add missing arguments to
2865 gccjit::block::end_with_conditional call. Add on_true/on_false
2866 comments. Tweak the wording.
2867 * docs/intro/tutorial03.rst: Add missing arguments to
2868 gcc_jit_block_end_with_conditional call. Add some clarifying
2869 comments.
2870 * docs/topics/compilation.rst: Tweak the wording to avoid an
2871 ambiguous use of "this".
2872 * docs/topics/contexts.rst: Fix a typo.
2873 * docs/topics/expressions.rst (GCC_JIT_BINARY_OP_MINUS): Remove
2874 a stray backtick.
2875 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2876
56a9f6bc
TS
28772015-02-24 Thomas Schwinge <thomas@codesourcery.com>
2878
2879 PR libgomp/64625
2880 * jit-builtins.c (DEF_FUNCTION_TYPE_VAR_8)
2881 (DEF_FUNCTION_TYPE_VAR_12): Remove macros.
2882 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
2883 * jit-builtins.h (DEF_FUNCTION_TYPE_VAR_8)
2884 (DEF_FUNCTION_TYPE_VAR_12): Remove macros.
2885 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
2886
a4be4e91
DM
28872015-02-04 David Malcolm <dmalcolm@redhat.com>
2888
2889 PR jit/64257
2890 * docs/conf.py (html_theme): Change from 'pyramid'
2891 to 'sphinxdoc'.
2892
f435bff3
DM
28932015-02-04 David Malcolm <dmalcolm@redhat.com>
2894
2895 * docs/topics/contexts.rst (gcc_jit_context_acquire): Fix
2896 typo.
2897 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2898
0ed4f017
DM
28992015-02-03 David Malcolm <dmalcolm@redhat.com>
2900
2901 * jit-logging.h (gcc::jit::log_user::log): Make const.
2902 * jit-recording.c (gcc::jit::recording::context::set_str_option):
2903 Log the new value of the option.
2904 (gcc::jit::recording::context::set_int_option): Likewise.
2905 (gcc::jit::recording::context::set_bool_option): Likewise.
2906 (gcc::jit::recording::context::compile): Log the value of all
2907 options.
2908 (gcc::jit::recording::context::compile_to_file): Likewise.
2909 (gcc::jit::recording::context::log_all_options): New function.
2910 (gcc::jit::recording::context::log_str_option): New function.
2911 (gcc::jit::recording::context::log_int_option): New function.
2912 (gcc::jit::recording::context::log_bool_option): New function.
2913 * jit-recording.h (gcc::jit::recording::context::log_all_options):
2914 New function.
2915 (gcc::jit::recording::context::log_str_option): New function.
2916 (gcc::jit::recording::context::log_int_option): New function.
2917 (gcc::jit::recording::context::log_bool_option): New function.
2918 * docs/internals/test-hello-world.exe.log.txt: Update for above
2919 changes.
2920 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2921
2cb844ce
DM
29222015-02-03 David Malcolm <dmalcolm@redhat.com>
2923
2924 PR jit/64810
2925 * Make-lang.in (jit_OBJS): Add jit/jit-spec.o and gcc.o.
2926 (LIBGCCJIT_FILENAME): Add EXTRA_GCC_OBJS.
2927 * jit-playback.c: Include gcc.h.
2928 (gcc::jit::playback::context::compile): Move mutex acquisition
2929 to before the call to make_fake_args.
2930 (append_arg_from_driver): New function.
2931 (gcc::jit::playback::context::make_fake_args): On the first call,
2932 call into driver_get_configure_time_options to get configure-time
2933 default options and cache them. Add them to the args for
2934 toplev::main.
2935 * jit-spec.c: New source file.
2936 * docs/internals/test-hello-world.exe.log.txt: Update to reflect
2937 above changes.
2938 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2939
16a71c50
DM
29402015-02-02 David Malcolm <dmalcolm@redhat.com>
2941
2942 PR jit/64810
2943 * dummy-frontend.c (jit_langhook_type_for_mode): Support
2944 TYPE_MODE (long_long_integer_type_node).
2945
53c04ec9
DM
29462015-01-27 David Malcolm <dmalcolm@redhat.com>
2947
2948 * docs/internals/test-hello-world.exe.log.txt: Add example version
2949 lines.
2950 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2951 * jit-common.h (gcc::jit::dump::get_file): New accessor.
2952 * jit-logging.c: Include toplev.h.
2953 (gcc::jit::logger::logger): Log the GCC version.
2954 * jit-recording.c: Include toplev.h.
2955 (gcc:jit::recording::context::dump_reproducer_to_file): Log the
2956 GCC version.
2957
dc44ee3a
DM
29582015-01-26 David Malcolm <dmalcolm@redhat.com>
2959
2960 * docs/topics/compilation.rst (gcc_jit_result_get_code): Fix typo.
2961 * docs/topics/contexts.rst (gcc_jit_context_get_last_error): The
2962 error buffer is only valid until the next call to the context.
2963 * docs/_build/texinfo/libgccjit.texi: Regenerate.
2964 * libgccjit.h (gcc_jit_context_get_first_error): Reword the
2965 comment to omit mention of compiling.
2966 (gcc_jit_context_get_last_error): The error buffer is only valid
2967 until the next call to the context.
2968
3349605d
DM
29692015-01-26 David Malcolm <dmalcolm@redhat.com>
2970
2971 PR jit/64708
2972 * config-lang.in (compilers): Drop "libgccjit.so".
2973
6fc2d0f3
DM
29742015-01-23 David Malcolm <dmalcolm@redhat.com>
2975
2976 PR jit/64721
2977 * jit-playback.c (gcc::jit::playback::context::compile): Construct
2978 toplev instances with init_signals=false.
2979
fdce7209
DM
29802015-01-19 David Malcolm <dmalcolm@redhat.com>
2981
2982 * docs/cp/topics/results.rst: Rename to...
2983 * docs/cp/topics/compilation.rst: ...this, and add section on
2984 ahead-of-time compilation.
2985 * docs/cp/topics/index.rst: Update for renaming of results.rst
2986 to compilation.rst.
2987 * docs/examples/emit-alphabet.bf: New file, a sample "brainf"
2988 script.
2989 * docs/examples/tut05-bf.c: New file, implementing a compiler
2990 for "brainf".
2991 * docs/internals/test-hello-world.exe.log.txt: Update to reflect
2992 changes to logger output.
2993 * docs/intro/index.rst: Add tutorial05.rst
2994 * docs/intro/tutorial05.rst: New file.
2995 * docs/topics/results.rst: Rename to...
2996 * docs/topics/compilation.rst: ...this, and add section on
2997 ahead-of-time compilation.
2998 * docs/topics/index.rst: Update for renaming of results.rst to
2999 compilation.rst.
3000 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3001 * jit-playback.c (gcc::jit::playback::context::compile): Convert
3002 return type from result * to void. Move the code to convert to
3003 dso and dlopen the result to a new pure virtual "postprocess"
3004 method.
3005 (gcc::jit::playback::compile_to_memory::compile_to_memory): New
3006 function.
3007 (gcc::jit::playback::compile_to_memory::postprocess): New
3008 function, based on playback::context::compile.
3009 (gcc::jit::playback::compile_to_file::compile_to_file): New
3010 function.
3011 (gcc::jit::playback::compile_to_file::postprocess): New function.
3012 (gcc::jit::playback::compile_to_file::copy_file): New function.
3013 (gcc::jit::playback::context::convert_to_dso): Move internals
3014 to...
3015 (gcc::jit::playback::context::invoke_driver): New method. Add
3016 "-shared" and "-c" options to driver's argv as needed.
3017 * jit-playback.h: Include "timevar.h".
3018 (gcc::jit::playback::context::compile): Convert return type from
3019 result * to void.
3020 (gcc::jit::playback::context::postprocess): New pure virtual
3021 function, making this an abstract base class.
3022 (gcc::jit::playback::context::get_tempdir): New accessor.
3023 (gcc::jit::playback::context::invoke_driver): New function.
3024 (class gcc::jit::playback::compile_to_memory): New subclass of
3025 playback::context.
3026 (class gcc::jit::playback::compile_to_file): Likewise.
3027 * jit-recording.c (gcc::jit::recording::context::compile): Use a
3028 playback::compile_to_memory, and extract its result.
3029 (gcc::jit::recording::context::compile_to_file): New function.
3030 * jit-recording.h (gcc::jit::recording::context::compile_to_file):
3031 New function.
3032 * libgccjit++.h (gccjit::context::compile_to_file): New method.
3033 * libgccjit.c (gcc_jit_context_compile): Update log message to
3034 clarify that this is an in-memory compile.
3035 (gcc_jit_context_compile_to_file): New function.
3036 * libgccjit.h (gcc_jit_context): Clarify that you can compile
3037 a context more than once, and that you can compile to a file
3038 as well as to memory.
3039 (gcc_jit_result): Clarify that this is the result of an
3040 in-memory compilation.
3041 (gcc_jit_context_compile): Clarify that you can compile, and that
3042 this is an in-memory compilation.
3043 (enum gcc_jit_output_kind): New enum.
3044 (gcc_jit_context_compile_to_file): New function.
3045 (gcc_jit_context_enable_dump): Clarify comment to cover both forms
3046 of compilation.
3047 * libgccjit.map (gcc_jit_context_compile_to_file): New API
3048 entrypoint.
3049 * notes.txt: Update to show the playback::context::postprocess
3050 virtual function.
3051
450e225b
DM
30522015-01-19 David Malcolm <dmalcolm@redhat.com>
3053
3054 * jit-recording.c
3055 (gcc::jit::recording::memento_of_new_string_literal::make_debug_string):
3056 Add missing format string.
3057
499de348
DM
30582015-01-16 David Malcolm <dmalcolm@redhat.com>
3059
3060 * Make-lang.in (lang_checks_parallelized): Add "check-jit".
3061 (check_jit_parallelize): Set this to an arbitrary value (10).
3062
e989e68d
JJ
30632015-01-16 Jakub Jelinek <jakub@redhat.com>
3064
3065 * jit-builtins.h (DEF_FUNCTION_TYPE_VAR_5): Fix spelling of
3066 last argument.
3067 (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12): Define and
3068 undef afterwards.
3069 * jit-builtins.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
3070 Likewise.
3071
179ed8f5
RS
30722015-01-15 Richard Sandiford <richard.sandiford@arm.com>
3073
3074 Update copyright years in docs/.
3075
96a87981
DM
30762015-01-15 David Malcolm <dmalcolm@redhat.com>
3077
3078 * libgccjit.c (gcc_jit_block_add_assignment_op): Check that the
3079 lvalue and the rvalue are of compatible type.
3080
86d0ac88
DM
30812015-01-13 David Malcolm <dmalcolm@redhat.com>
3082
3083 * docs/cp/topics/contexts.rst (Debugging): Add
3084 gccjit::context::dump_reproducer_to_file.
3085 * docs/internals/index.rst (Design notes): New section,
3086 discussing input validation and
3087 gcc_jit_context_dump_reproducer_to_file.
3088 * docs/topics/contexts.rst (Debugging): Add
3089 gcc_jit_context_dump_reproducer_to_file.
3090 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3091 * jit-common.h (gcc::jit::dump::get_context): New accessor.
3092 * jit-recording.c: Include "hash-map.h".
3093 Within namespace ::gcc::jit...
3094 (dump::write): Flush each line.
3095 (dump::make_location): Pass false for new param "created_by_user".
3096 (class allocator): New class.
3097 (allocator::~allocator): New function.
3098 (allocator::xstrdup_printf): New function.
3099 (allocator::xstrdup_printf_va): New function.
3100 (class reproducer): New subclass of dump.
3101 (reproducer::reproducer): New function.
3102 (reproducer::write_params): New function.
3103 (reproducer::write_args): New function.
3104 (reproducer::make_identifier): New function.
3105 (reproducer::make_tmp_identifier): New function.
3106 (reproducer::get_identifier): New pair of functions.
3107 (reproducer::get_identifier_as_rvalue): New function.
3108 (reproducer::get_identifier_as_lvalue): New function.
3109 (reproducer::get_identifier_as_type): New function.
3110 (reproducer::xstrdup_printf): New function.
3111 (recording::context::context): Initialize m_toplevel_ctxt.
3112 (recording::context::new_location): Add param created_by_user.
3113 (str_option_reproducer_strings): New table of strings.
3114 (int_option_reproducer_strings): Likewise.
3115 (bool_option_reproducer_strings): Likewise.
3116 (get_type_enum_strings): Likewise.
3117 (names_of_function_kinds): Likewise.
3118 (global_kind_reproducer_strings): Likewise.
3119 (unary_op_reproducer_strings): Likewise.
3120 (binary_op_reproducer_strings): Likewise.
3121 (comparison_reproducer_strings): Likewise.
3122 Within namespace ::gcc::jit::recording::...
3123 (context::dump_reproducer_to_file): New function.
3124 (string::write_reproducer): Likewise.
3125 (location::write_reproducer): Likewise.
3126 (type::access_as_type): Likewise.
3127 (memento_of_get_type::write_reproducer): Likewise.
3128 (memento_of_get_pointer::write_reproducer): Likewise.
3129 (memento_of_get_const::write_reproducer): Likewise.
3130 (memento_of_get_volatile::write_reproducer): Likewise.
3131 (array_type::write_reproducer): Likewise.
3132 (function_type::write_reproducer): Likewise.
3133 (function_type::write_deferred_reproducer): Likewise.
3134 (field::write_reproducer): Likewise.
3135 (struct_::access_as_type): Likewise.
3136 (struct_::write_reproducer): Likewise.
3137 (union_::write_reproducer): Likewise.
3138 (fields::write_reproducer): Likewise.
3139 (rvalue::access_as_rvalue): Likewise.
3140 (lvalue::access_as_rvalue): Likewise.
3141 (lvalue::access_as_lvalue): Likewise.
3142 (param::access_as_rvalue): Likewise.
3143 (param::access_as_lvalue): Likewise.
3144 (param::write_reproducer): Likewise.
3145 (function::write_reproducer): Likewise.
3146 (block::write_reproducer): Likewise.
3147 (global::write_reproducer): Likewise.
3148 (memento_of_new_rvalue_from_const <int>::write_reproducer):
3149 Likewise.
3150 (memento_of_new_rvalue_from_const <long>::write_reproducer):
3151 Likewise.
3152 (memento_of_new_rvalue_from_const <double>::write_reproducer):
3153 Likewise.
3154 (memento_of_new_rvalue_from_const <void *>::write_reproducer):
3155 Likewise.
3156 (memento_of_new_string_literal::write_reproducer): Likewise.
3157 (unary_op::write_reproducer): Likewise.
3158 (binary_op::write_reproducer): Likewise.
3159 (comparison::write_reproducer): Likewise.
3160 (cast::write_reproducer): Likewise.
3161 (call::write_reproducer): Likewise.
3162 (call_through_ptr::write_reproducer): Likewise.
3163 (array_access::write_reproducer): Likewise.
3164 (access_field_of_lvalue::write_reproducer): Likewise.
3165 (access_field_rvalue::write_reproducer): Likewise.
3166 (dereference_field_rvalue::write_reproducer): Likewise.
3167 (dereference_rvalue::write_reproducer): Likewise.
3168 (get_address_of_lvalue::write_reproducer): Likewise.
3169 (local::write_reproducer): Likewise.
3170 (eval::write_reproducer): Likewise.
3171 (assignment::write_reproducer): Likewise.
3172 (assignment_op::write_reproducer): Likewise.
3173 (comment::write_reproducer): Likewise.
3174 (conditional::write_reproducer): Likewise.
3175 (jump::write_reproducer): Likewise.
3176 (return_::write_reproducer): Likewise.
3177 * jit-recording.h (gcc::jit::reproducer): New forward declararion.
3178 Within namespace ::gcc::jit::recording::...
3179 (context::new_location): Add "created_by_user" param.
3180 (context::dump_reproducer_to_file): New method.
3181 (context::m_toplevel_ctxt): New field.
3182 (memento::write_reproducer): New pure virtual function.
3183 (memento::dyn_cast_location): New virtual function.
3184 (string::write_reproducer):
3185 (location::location): Add "created_by_user" param.
3186 (location::dyn_cast_location): New function.
3187 (location::created_by_user): New accessor.
3188 (location::write_reproducer): New function.
3189 (location::m_created_by_user): New field.
3190 (type::access_as_type): New virtual function.
3191 (location::write_reproducer): Likewise.
3192 (type::access_as_type): Likewise.
3193 (memento_of_get_type::write_reproducer): Likewise.
3194 (memento_of_get_pointer::write_reproducer): Likewise.
3195 (memento_of_get_const::write_reproducer): Likewise.
3196 (memento_of_get_volatile::write_reproducer): Likewise.
3197 (array_type::write_reproducer): Likewise.
3198 (function_type::write_reproducer): Likewise.
3199 (function_type::write_deferred_reproducer): Likewise.
3200 (field::write_reproducer): Likewise.
3201 (struct_::access_as_type): Likewise.
3202 (struct_::write_reproducer): Likewise.
3203 (union_::write_reproducer): Likewise.
3204 (union_::m_fields): Remove stray unused field.
3205 (fields::length): New accessor.
3206 (fields::get_field): New accessor.
3207 (fields::write_reproducer): New function.
3208 (rvalue::access_as_rvalue): Likewise.
3209 (lvalue::access_as_rvalue): Likewise.
3210 (lvalue::access_as_lvalue): Likewise.
3211 (param::access_as_rvalue): Likewise.
3212 (param::access_as_lvalue): Likewise.
3213 (param::write_reproducer): Likewise.
3214 (function::write_reproducer): Likewise.
3215 (block::write_reproducer): Likewise.
3216 (global::write_reproducer): Likewise.
3217 (memento_of_new_rvalue_from_const <HOST_TYPE>::write_reproducer):
3218 Likewise.
3219 (memento_of_new_string_literal::write_reproducer): Likewise.
3220 (unary_op::write_reproducer): Likewise.
3221 (binary_op::write_reproducer): Likewise.
3222 (comparison::write_reproducer): Likewise.
3223 (cast::write_reproducer): Likewise.
3224 (call::write_reproducer): Likewise.
3225 (call_through_ptr::write_reproducer): Likewise.
3226 (array_access::write_reproducer): Likewise.
3227 (access_field_of_lvalue::write_reproducer): Likewise.
3228 (access_field_rvalue::write_reproducer): Likewise.
3229 (dereference_field_rvalue::write_reproducer): Likewise.
3230 (dereference_rvalue::write_reproducer): Likewise.
3231 (get_address_of_lvalue::write_reproducer): Likewise.
3232 (local::write_reproducer): Likewise.
3233 (eval::write_reproducer): Likewise.
3234 (assignment::write_reproducer): Likewise.
3235 (assignment_op::write_reproducer): Likewise.
3236 (comment::write_reproducer): Likewise.
3237 (conditional::write_reproducer): Likewise.
3238 (jump::write_reproducer): Likewise.
3239 (return_::write_reproducer): Likewise.
3240 * libgccjit++.h (gccjit::context::dump_reproducer_to_file): New.
3241 * libgccjit.c (gcc_jit_context_new_location): Pass "true" as
3242 param "created_by_user".
3243 (gcc_jit_context_dump_reproducer_to_file): New API entrypoint.
3244 * libgccjit.h (gcc_jit_context_dump_reproducer_to_file): New API
3245 entrypoint.
3246 * libgccjit.map (gcc_jit_context_dump_reproducer_to_file): New API
3247 entrypoint.
3248
f6f2b019
DM
32492015-01-12 David Malcolm <dmalcolm@redhat.com>
3250
3251 * jit-recording.c (class gcc::jit::rvalue_usage_validator): New.
3252 (gcc::jit::rvalue_usage_validator::rvalue_usage_validator): New
3253 ctor.
3254 (gcc::jit::rvalue_usage_validator::visit): New function.
3255 (gcc::jit::recording::rvalue::verify_valid_within_stmt): New
3256 function.
3257 (gcc::jit::recording::rvalue::set_scope): New function.
3258 (gcc::jit::recording::function::function): Call set_scope on each
3259 param, issuing errors for any params that already have a function.
3260 (gcc::jit::recording::block::add_eval): Return the new statement;
3261 update the comment given that some error-checking now happens after
3262 this returns.
3263 (gcc::jit::recording::block::add_assignment): Likewise.
3264 (gcc::jit::recording::block::add_assignment_op): Likewise.
3265 (gcc::jit::recording::block::add_comment): Likewise.
3266 (gcc::jit::recording::block::end_with_conditional): Likewise.
3267 (gcc::jit::recording::block::end_with_jump): Likewise.
3268 (gcc::jit::recording::block::end_with_return): Likewise.
3269 (gcc::jit::recording::block::validate): Add a comment.
3270 (gcc::jit::recording::unary_op::visit_children): New function.
3271 (gcc::jit::recording::binary_op::visit_children): New function.
3272 (gcc::jit::recording::comparison::visit_children): New function.
3273 (gcc::jit::recording::cast::visit_children): New function.
3274 (gcc::jit::recording::call::visit_children): New function.
3275 (gcc::jit::recording::call_through_ptr::visit_children): New function.
3276 (gcc::jit::recording::array_access::visit_children): New function.
3277 (gcc::jit::recording::access_field_of_lvalue::visit_children): New
3278 function.
3279 (gcc::jit::recording::access_field_rvalue::visit_children): New
3280 function.
3281 (gcc::jit::recording::dereference_field_rvalue::visit_children):
3282 New function.
3283 (gcc::jit::recording::dereference_rvalue::visit_children): New
3284 function.
3285 (gcc::jit::recording::get_address_of_lvalue::visit_children): New
3286 function.
3287 * jit-recording.h: Within namespace gcc::jit::recording...
3288 (class rvalue_visitor): New.
3289 (rvalue::rvalue): Initialize m_scope.
3290 (rvalue::get_loc): New accessor.
3291 (rvalue::verify_valid_within_stmt): New function.
3292 (rvalue::visit_children): New pure virtual function.
3293 (rvalue::set_scope): New function.
3294 (rvalue::get_scope): New function.
3295 (rvalue::dyn_cast_param): New function.
3296 (rvalue::m_scope): New field.
3297 (param::visit_children): New empty function.
3298 (param::dyn_cast_param): New function.
3299 (function::get_loc): New function.
3300 (block::add_eval): Return the new statement.
3301 (block::add_assignment): Likewise.
3302 (block::add_assignment_op): Likewise.
3303 (block::add_comment): Likewise.
3304 (block::end_with_conditional): Likewise.
3305 (block::end_with_jump): Likewise.
3306 (block::end_with_return): Likewise.
3307 (global::visit_children): New function.
3308 (memento_of_new_rvalue_from_const<HOST_TYPE>::visit_children):
3309 New function.
3310 (memento_of_new_string_literal::visit_children): New function.
3311 (unary_op::visit_children): New function.
3312 (binary_op::visit_children): New function.
3313 (comparison::visit_children): New function.
3314 (cast::visit_children): New function.
3315 (call::visit_children): New function.
3316 (call_through_ptr::visit_children): New function.
3317 (array_access::visit_children): New function.
3318 (access_field_of_lvalue::visit_children): New function.
3319 (access_field_rvalue::visit_children): New function.
3320 (dereference_field_rvalue::visit_children): New function.
3321 (dereference_rvalue::visit_children): New function.
3322 (get_address_of_lvalue::visit_children): New function.
3323 (local::local): Call set_scope.
3324 (local::visit_children): New function.
3325 (statement::get_block): Make public.
3326 * libgccjit.c (RETURN_VAL_IF_FAIL_PRINTF5): New macro.
3327 (RETURN_NULL_IF_FAIL_PRINTF5): New macro.
3328 (gcc_jit_context_new_function): Verify that each param has
3329 not yet been used for creating another function.
3330 (gcc_jit_block_add_eval): After creating the stmt, verify
3331 that the rvalue expression tree is valid to use within it.
3332 (gcc_jit_block_add_assignment): Likewise for the lvalue and
3333 rvalue expression trees.
3334 (gcc_jit_block_add_assignment_op): Likewise.
3335 (gcc_jit_block_end_with_conditional): Likewise for the boolval
3336 expression tree.
3337 (gcc_jit_block_end_with_return): Likewise for the rvalue
3338 expression tree.
3339 (gcc_jit_block_end_with_void_return): Remove return of "void",
3340 now that block::end_with_return is now non-void.
3341
1c35cc2c
DM
33422015-01-12 David Malcolm <dmalcolm@redhat.com>
3343
3344 * jit-playback.c (gcc::jit::playback::context::read_dump_file):
3345 Add missing fclose on error-handling path.
3346
791cfef8
DM
33472015-01-12 David Malcolm <dmalcolm@redhat.com>
3348
3349 * docs/cp/topics/expressions.rst (Global variables): Add
3350 enum gcc_jit_global_kind param to gccjit::context::new_global.
3351 * docs/topics/expressions.rst (Global variables): Likewise.
3352 Document the new enum.
3353 * docs/topics/results.rst (Compilation results): Document
3354 globals-handling.
3355 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3356 * dummy-frontend.c (jit_langhook_write_globals): Call into the
3357 playback context's write_global_decls_1 and write_global_decls_2
3358 before and after calling symtab->finalize_compilation_unit ().
3359 * jit-playback.c: Include "debug.h".
3360 (gcc::jit::playback::context::new_global): Add "kind" param and
3361 use it to set TREE_PUBLIC, TREE_STATIC and DECL_EXTERNAL on the
3362 underlying VAR_DECL. Call varpool_node::get_create on the
3363 VAR_DECL, and add it to m_globals.
3364 (gcc::jit::playback::context::write_global_decls_1): New function.
3365 (gcc::jit::playback::context::write_global_decls_2): New function.
3366 * jit-playback.h (gcc::jit::playback::context::context): Call
3367 create on m_globals.
3368 (gcc::jit::playback::context::new_global): Add "kind" param.
3369 (gcc::jit::playback::context::write_global_decls_1): New function.
3370 (gcc::jit::playback::context::write_global_decls_2): New function.
3371 (gcc::jit::playback::context::m_globals): New field.
3372 * jit-recording.c (gcc::jit::recording::context::context):
3373 Initialize m_globals.
3374 (gcc::jit::recording::context::new_global): Add param "kind".
3375 Add the new global to m_globals.
3376 (gcc::jit::recording::context::dump_to_file): Dump the globals.
3377 (gcc::jit::recording::global::replay_into): Add field m_kind.
3378 (gcc::jit::recording::global::write_to_dump): New override.
3379 * jit-recording.h (gcc::jit::recording::context::new_global): Add
3380 param "kind".
3381 (gcc::jit::recording::context::m_globals): New field.
3382 (gcc::jit::recording::global::global): Add param kind.
3383 (gcc::jit::recording::global::write_to_dump): New override.
3384 (gcc::jit::recording::global::m_kind): New field.
3385 * jit-result.c (gcc::jit::result::get_global): New function.
3386 * jit-result.h (gcc::jit::result::get_global): New function.
3387 * libgccjit++.h (gccjit::context::new_global): Add "kind" param.
3388 * libgccjit.c (gcc_jit_context_new_global): Likewise.
3389 (gcc_jit_result_get_global): New API entrypoint.
3390 * libgccjit.h (gcc_jit_result_get_global): New API entrypoint.
3391 (enum gcc_jit_global_kind): New enum.
3392 (gcc_jit_context_new_global): API change: add "kind" param.
3393 * libgccjit.map (gcc_jit_result_get_global): New symbol.
3394
860e981c
DM
33952015-01-09 David Malcolm <dmalcolm@redhat.com>
3396
3397 * dummy-frontend.c: Include "fixed-value.h", "alias.h", "flags.h",
3398 "symtab.h", "inchash.h". Move include of "hash-set.h" much
3399 earlier.
3400 * jit-builtins.c: Remove redundant includes of "opts.h" and
3401 "tree.h".
3402 * jit-common.h: Include "hash-set.h", "input.h", "vec.h",
3403 "double-int.h", "alias.h", "flags.h", "symtab.h", "inchash.h".
3404 * jit-playback.c: Include "hashtab.h", "machmode.h", "input.h",
3405 "statistics.h", "vec.h", "double-int.h", "real.h",
3406 "fixed-value.h", "alias.h", "flags.h", "symtab.h", "tree-core.h",
3407 "inchash.h", "fold-const.h". Move include of "hash-set.h" to
3408 earlier.
3409 * jit-recording.c: Remove redundant includes of "opts.h" and
3410 "tree.h".
3411
ccce3b2a
DM
34122015-01-09 David Malcolm <dmalcolm@redhat.com>
3413
3414 * docs/cp/topics/expressions.rst (Simple expressions): Use
3415 ":c:type:" for C types. Document new overload of
3416 gcc::jit::context::new_rvalue.
3417 * docs/topics/expressions.rst (Simple expressions): Use
3418 ":c:type:" for C types. Document new entrypoint
3419 gcc_jit_context_new_rvalue_from_long.
3420 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3421 * jit-playback.c: Within namespace gcc::jit::playback...
3422 (context::new_rvalue_from_int): Eliminate in favor of...
3423 (context::new_rvalue_from_const <int>): ...this.
3424 (context::new_rvalue_from_double): Eliminate in favor of...
3425 (context::new_rvalue_from_const <double>): ...this.
3426 (context::new_rvalue_from_const <long>): New.
3427 (context::new_rvalue_from_ptr): Eliminate in favor of...
3428 (context::new_rvalue_from_const <void *>): ...this.
3429 * jit-playback.h: Within namespace gcc::jit::playback...
3430 (context::new_rvalue_from_int): Eliminate in favor of...
3431 (context::new_rvalue_from_const <HOST_TYPE>): ...this.
3432 (context::new_rvalue_from_double): Likewise.
3433 (context::new_rvalue_from_ptr): Likewise.
3434 * jit-recording.c: Within namespace gcc::jit::recording...
3435 (context::new_rvalue_from_int): Eliminate.
3436 (context::new_rvalue_from_double): Likewise.
3437 (context::new_rvalue_from_ptr): Likewise.
3438 (class memento_of_new_rvalue_from_const <int>):
3439 Add explicit specialization.
3440 (class memento_of_new_rvalue_from_const <long>):
3441 Likewise.
3442 (class memento_of_new_rvalue_from_const <double>):
3443 Likewise.
3444 (class memento_of_new_rvalue_from_const <void *>):
3445 Likewise.
3446 (memento_of_new_rvalue_from_int::replay_into):
3447 Generalize into...
3448 (memento_of_new_rvalue_from_const <HOST_TYPE>::replay_into):
3449 ...this...
3450 (memento_of_new_rvalue_from_double::replay_into):
3451 ...allowing this...
3452 (memento_of_new_rvalue_from_ptr::replay_into):
3453 ...and this to be deleted.
3454 (memento_of_new_rvalue_from_int::make_debug_string):
3455 Convert to...
3456 (memento_of_new_rvalue_from_const <int>::make_debug_string):
3457 ...this.
3458 (memento_of_new_rvalue_from_double::make_debug_string):
3459 Convert to...
3460 (memento_of_new_rvalue_from_const <double>::make_debug_string):
3461 ...this.
3462 (memento_of_new_rvalue_from_ptr::make_debug_string)
3463 Convert to...
3464 (memento_of_new_rvalue_from_const <void *>::make_debug_string):
3465 ...this.
3466 (memento_of_new_rvalue_from_const <long>::make_debug_string):
3467 New function.
3468 * jit-recording.h: Within namespace gcc::jit::recording...
3469 (context::new_rvalue_from_int): Eliminate.
3470 (context::new_rvalue_from_double): Likewise.
3471 (context::new_rvalue_from_ptr): Likewise, all in favor of...
3472 (context::new_rvalue_from_const <HOST_TYPE>): New family of
3473 methods.
3474 (class memento_of_new_rvalue_from_int): Eliminate.
3475 (class memento_of_new_rvalue_from_double): Likewise.
3476 (class memento_of_new_rvalue_from_ptr): Likewise.
3477 (class memento_of_new_rvalue_from_const <HOST_TYPE>): New family
3478 of rvalue subclasses.
3479 * libgccjit++.h (gccjit::context::new_rvalue): New overload, for
3480 "long".
3481 * libgccjit.c (gcc_jit_context_new_rvalue_from_int): Update for
3482 rewriting of recording::context::new_rvalue_from_int to
3483 recording::context::new_rvalue_from_const <int>.
3484 (gcc_jit_context_new_rvalue_from_long): New API entrypoint.
3485 (gcc_jit_context_new_rvalue_from_double): Update for
3486 rewriting of recording::context::new_rvalue_from_double to
3487 recording::context::new_rvalue_from_const <double>.
3488 (gcc_jit_context_new_rvalue_from_ptr): Update for
3489 rewriting of recording::context::new_rvalue_from_ptr to
3490 recording::context::new_rvalue_from_const <void *>.
3491 * libgccjit.h (gcc_jit_context_new_rvalue_from_long): New API
3492 entrypoint.
3493 * libgccjit.map (gcc_jit_context_new_rvalue_from_long): Likewise.
3494
d2286af3
DM
34952015-01-09 David Malcolm <dmalcolm@redhat.com>
3496
3497 PR jit/64206
3498 * docs/internals/test-hello-world.exe.log.txt: Update, the log now
3499 shows tempdir creation/cleanup.
3500 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3501 * jit-logging.h (class gcc::jit::log_user): Add gcc::jit::tempdir
3502 to the list of subclasses in the comment.
3503 * jit-playback.c (gcc::jit::playback::context::context): Add a
3504 comment clarifying when the tempdir gets cleaned up.
3505 (gcc::jit::playback::context::compile): Pass the context's logger,
3506 if any, to the tempdir.
3507 (gcc::jit::playback::context::dlopen_built_dso): When creating the
3508 gcc::jit::result, if GCC_JIT_BOOL_OPTION_DEBUGINFO is set, hand
3509 over ownership of the tempdir to it.
3510 * jit-result.c: Include "jit-tempdir.h".
3511 (gcc::jit::result::result): Add tempdir param, saving it as
3512 m_tempdir.
3513 (gcc::jit::result::~result): Delete m_tempdir.
3514 * jit-result.h (gcc::jit::result::result): Add tempdir param.
3515 (gcc::jit::result::m_tempdir): New field.
3516 * jit-tempdir.c (gcc::jit::tempdir::tempdir): Add logger param;
3517 add JIT_LOG_SCOPE.
3518 (gcc::jit::tempdir::create): Add JIT_LOG_SCOPE to log entry/exit,
3519 and log m_path_template and m_path_tempdir.
3520 (gcc::jit::tempdir::~tempdir): Add JIT_LOG_SCOPE to log
3521 entry/exit, and log the unlink and rmdir calls.
3522 * jit-tempdir.h: Include "jit-logging.h".
3523 (class gcc::jit::tempdir): Make this be a subclass of log_user.
3524 (gcc::jit::tempdir::tempdir): Add logger param.
3525 * notes.txt: Update to show the two possible places where the
3526 tempdir can be cleaned up.
3527
7c8db13e
DM
35282015-01-08 David Malcolm <dmalcolm@redhat.com>
3529
3530 * libgccjit.h (struct gcc_jit_context): Rewrite the descriptive
3531 comment.
3532
303e1d56
DM
35332015-01-08 David Malcolm <dmalcolm@redhat.com>
3534
3535 * docs/topics/contexts.rst (Error-handling): Document new
3536 entrypoint gcc_jit_context_get_last_error.
3537 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3538 * jit-recording.c (gcc::jit::recording::context::context):
3539 Initialize new fields "m_last_error_str" and
3540 "m_owns_last_error_str".
3541 (gcc::jit::recording::context::~context): Clean up
3542 m_last_error_str, if needed.
3543 (gcc::jit::recording::context::add_error_va): Update
3544 m_last_error_str and m_owns_last_error_str, freeing the old
3545 value if appropriate.
3546 (gcc::jit::recording::context::get_last_error): New function.
3547 * jit-recording.h (gcc::jit::recording::context::get_last_error):
3548 New function.
3549 (gcc::jit::recording::context): New fields m_last_error_str and
3550 m_owns_last_error_str.
3551 * libgccjit.c (gcc_jit_context_get_last_error): New function.
3552 * libgccjit.h (gcc_jit_context_get_last_error): New declaration.
3553 * libgccjit.map (gcc_jit_context_get_last_error): New function.
3554
eb4c16eb
DM
35552015-01-08 David Malcolm <dmalcolm@redhat.com>
3556
3557 * Make-lang.in (jit_OBJS): Add jit/jit-logging.o.
3558 * docs/internals/index.rst (Overview of code structure): Mention
3559 gcc_jit_context_set_logfile, and embed the example logfile.
3560 * docs/internals/test-hello-world.exe.log.txt: New file: example
3561 of a logfile.
3562 * docs/topics/contexts.rst (Debugging): Add documentation
3563 for gcc_jit_context_set_logfile.
3564 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3565 * dummy-frontend.c: Include "jit-logging.h".
3566 (jit_langhook_init): Assert that there is an active playback
3567 context. If it has a logger, log entry/exit to this function.
3568 (jit_langhook_write_globals): Likewise.
3569 * jit-common.h (gcc::jit::logger): New forward declaration.
3570 * jit-logging.c: New file.
3571 * jit-logging.h: New file.
3572 * jit-playback.c: Include "jit-logging.h".
3573 (gcc::jit::playback::context::context): Initialize the log_user
3574 base class from the recording context's logger (if any). Use
3575 JIT_LOG_SCOPE to log entry/exit from the function body.
3576 (gcc::jit::playback::context::~context): Use JIT_LOG_SCOPE to
3577 log entry/exit from the function body.
3578 (gcc::jit::playback::build_stmt_list): Likewise.
3579 (gcc::jit::playback::function::postprocess): Likewise.
3580 (gcc::jit::playback::context::compile): Likewise. Log the
3581 entry/exit to toplev::main and toplev::finalize. Log the
3582 fake argv passed to toplev::main.
3583 (gcc::jit::playback::context::acquire_mutex): Use JIT_LOG_SCOPE to
3584 log entry/exit from the function body.
3585 (gcc::jit::playback::context::release_mutex): Likewise.
3586 (gcc::jit::playback::context::make_fake_args): Likewise.
3587 (gcc::jit::playback::context::extract_any_requested_dumps):
3588 Likewise.
3589 (gcc::jit::playback::context::convert_to_dso): Likewise. Also,
3590 log the arguments that the driver is invoked with.
3591 (gcc::jit::playback::context::dlopen_built_dso): Likewise. Pass
3592 the logger to the result object.
3593 (gcc::jit::playback::context::replay): Use JIT_LOG_SCOPE to
3594 log entry/exit from the function body.
3595 (gcc::jit::playback::context::dump_generated_code): Likewise.
3596 (gcc::jit::playback::context::handle_locations): Likewise.
3597 * jit-playback.h (gcc::jit::playback::context): Make this be
3598 a subclass of gcc::jit::log_user.
3599 * jit-recording.c: Include "jit-logging.h".
3600 (gcc::jit::recording::context::context: Initialize the logger to
3601 NULL for root contexts, or to the parent's logger for child
3602 contexts.
3603 (gcc::jit::recording::context::~context): Use JIT_LOG_SCOPE to
3604 log entry/exit from the function body.
3605 (gcc::jit::recording::context::replay_into): Likewise.
3606 (gcc::jit::recording::context::disassociate_from_playback):
3607 Likewise.
3608 (gcc::jit::recording::context::compile): Likewise.
3609 (recording::context::add_error_va): Likewise. Also, log the
3610 error.
3611 (gcc::jit::recording::context::validate): Use JIT_LOG_SCOPE to
3612 log entry/exit from the function body.
3613 * jit-recording.h: Include "jit-logging.h".
3614 (gcc::jit::recording::context): Make this be a subclass of
3615 gcc::jit::log_user.
3616 * jit-result.c: Include "jit-common.h" and "jit-logging.h".
3617 (gcc::jit::result::result): Add logger param, recording it.
3618 Use JIT_LOG_SCOPE to log entry/exit from the function body.
3619 (gcc::jit::result::~result(): Use JIT_LOG_SCOPE to
3620 log entry/exit from the function body.
3621 (gcc::jit::result::get_code): Likewise.
3622 * jit-result.h (gcc::jit::result): Make this be a subclass of
3623 gcc::jit::log_user.
3624 (gcc::jit::result::result): Add logger parameter.
3625 * libgccjit++.h (gccjit::context::set_logfile): New function.
3626 * libgccjit.c: Include "jit-logging.h".
3627 (gcc_jit_context_acquire): Log the context.
3628 (gcc_jit_context_release): Use JIT_LOG_FUNC to
3629 log entry/exit from the function body, and log the context.
3630 (gcc_jit_context_new_child_context): Likewise, logging both
3631 contexts.
3632 (gcc_jit_context_new_location): Use JIT_LOG_FUNC to
3633 log entry/exit from the function body.
3634 (gcc_jit_context_get_type): Likewise.
3635 (gcc_jit_context_get_int_type): Likewise.
3636 (gcc_jit_context_new_array_type): Likewise.
3637 (gcc_jit_context_new_field): Likewise.
3638 (gcc_jit_context_new_struct_type): Likewise.
3639 (gcc_jit_context_new_opaque_struct): Likewise.
3640 (gcc_jit_struct_set_fields): Likewise.
3641 (gcc_jit_context_new_union_type): Likewise.
3642 (gcc_jit_context_new_function_ptr_type): Likewise.
3643 (gcc_jit_context_new_param): Likewise.
3644 (gcc_jit_context_new_function): Likewise.
3645 (gcc_jit_context_get_builtin_function): Likewise.
3646 (gcc_jit_function_get_param): Likewise.
3647 (gcc_jit_function_dump_to_dot): Likewise.
3648 (gcc_jit_function_new_block): Likewise.
3649 (gcc_jit_context_new_global): Likewise.
3650 (gcc_jit_context_new_rvalue_from_int): Likewise.
3651 (gcc_jit_context_zero): Likewise.
3652 (gcc_jit_context_one): Likewise.
3653 (gcc_jit_context_new_rvalue_from_double): Likewise.
3654 (gcc_jit_context_new_rvalue_from_ptr): Likewise.
3655 (gcc_jit_context_null): Likewise.
3656 (gcc_jit_context_new_string_literal): Likewise.
3657 (gcc_jit_context_new_unary_op): Likewise.
3658 (gcc_jit_context_new_binary_op): Likewise.
3659 (gcc_jit_context_new_comparison): Likewise.
3660 (gcc_jit_context_new_call): Likewise.
3661 (gcc_jit_context_new_call_through_ptr): Likewise.
3662 (gcc_jit_context_new_cast): Likewise.
3663 (gcc_jit_context_new_array_access): Likewise.
3664 (gcc_jit_lvalue_access_field): Likewise.
3665 (gcc_jit_rvalue_access_field): Likewise.
3666 (gcc_jit_rvalue_dereference_field): Likewise.
3667 (gcc_jit_rvalue_dereference): Likewise.
3668 (gcc_jit_lvalue_get_address): Likewise.
3669 (gcc_jit_function_new_local): Likewise.
3670 (gcc_jit_block_add_eval): Likewise.
3671 (gcc_jit_block_add_assignment): Likewise.
3672 (gcc_jit_block_add_assignment_op): Likewise.
3673 (gcc_jit_block_end_with_conditional): Likewise.
3674 (gcc_jit_block_add_comment): Likewise.
3675 (gcc_jit_block_end_with_jump): Likewise.
3676 (gcc_jit_block_end_with_return): Likewise.
3677 (gcc_jit_block_end_with_void_return): Likewise.
3678 (gcc_jit_context_set_str_option): Likewise.
3679 (gcc_jit_context_set_int_option): Likewise.
3680 (gcc_jit_context_set_bool_option): Likewise.
3681 (gcc_jit_context_enable_dump): Likewise.
3682 (gcc_jit_context_compile): Likewise. Also log the context,
3683 and the result.
3684 (gcc_jit_context_dump_to_file): Likewise.
3685 (gcc_jit_context_set_logfile): New function.
3686 (gcc_jit_context_get_first_error): Use JIT_LOG_FUNC to
3687 log entry/exit from the function body.
3688 (gcc_jit_result_get_code): Likewise. Also log the fnname)
3689 and the ptr to be returned.
3690 (gcc_jit_result_release): Likewise. Also log the result.
3691 * libgccjit.h: Include <stdio.h>, since we need FILE *.
3692 (gcc_jit_context_set_logfile): New declaration.
3693 * libgccjit.map (gcc_jit_context_set_logfile): New.
3694
c211cd23
DM
36952015-01-07 David Malcolm <dmalcolm@redhat.com>
3696
3697 * jit-recording.h (gcc::jit::recording::type::is_void): New
3698 virtual function.
3699 (gcc::jit::recording::memento_of_get_type::is_void): New
3700 function, overriding default implementation.
3701 * libgccjit.c (gcc_jit_rvalue_dereference): Verify that
3702 the underlying type is not "void".
3703
18146f45
DM
37042015-01-07 David Malcolm <dmalcolm@redhat.com>
3705
3706 * docs/topics/expressions.rst (Unary Operations): Add
3707 GCC_JIT_UNARY_OP_ABS.
3708 * jit-playback.c (gcc::jit::playback::context::new_unary_op):
3709 Likewise.
3710 * jit-recording.c (unary_op_strings): Likewise.
3711 * libgccjit.c (gcc_jit_context_new_unary_op): Update checking
3712 of "op" to reflect addition of GCC_JIT_UNARY_OP_ABS.
3713 * libgccjit.h (enum gcc_jit_unary_op): Add GCC_JIT_UNARY_OP_ABS.
3714 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3715
11af98ff
DM
37162015-01-07 David Malcolm <dmalcolm@redhat.com>
3717
3718 * jit-recording.h (gcc::jit::recording::memento_of_get_type): Fix
3719 typo in comment.
3720
433d16df
DM
37212015-01-07 David Malcolm <dmalcolm@redhat.com>
3722
3723 * TODO.rst (Test suite): Remove item about running C++ testcases.
3724 * docs/internals/index.rst (Working on the JIT library): Add
3725 "c++" to the enabled languages in the suggested "configure"
3726 invocation, and add a description of why this is necessary.
3727 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3728
50bb6c8e
DM
37292015-01-07 David Malcolm <dmalcolm@redhat.com>
3730
3731 * docs/internals/index.rst: Update to reflect that built
3732 testcases are now test-foo.c.exe, rather than test-foo.exe.
3733 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3734
1e3b6a3d
JJ
37352015-01-05 Jakub Jelinek <jakub@redhat.com>
3736
3737 Update copyright years.
3738
e8af59bc
DM
37392014-12-19 David Malcolm <dmalcolm@redhat.com>
3740
3741 * jit-playback.c (gcc::jit::playback::context::build_cast): In
3742 case BOOLEAN_TYPE, don't assume that the source expression is
3743 of type "int".
3744
5afd44e3
DM
37452014-12-19 David Malcolm <dmalcolm@redhat.com>
3746
3747 * jit-recording.c (gcc::jit::recording::context::context): When
3748 copying string options from a parent context, take a copy of the
3749 underlying buffers, rather than simply copying the pointer.
3750
1f0858d7
DM
37512014-12-19 David Malcolm <dmalcolm@redhat.com>
3752
3753 * jit-recording.c (gcc::jit::recording::context::set_str_option):
3754 Handle NULL.
3755
35291c7d
DM
37562014-12-11 David Malcolm <dmalcolm@redhat.com>
3757
3758 * docs/cp/topics/contexts.rst (gccjit::context::set_str_option):
3759 Document new function.
3760 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3761
7b31ff5e
DM
37622014-12-10 Ulrich Drepper <drepper@gmail.com>
3763
3764 Minor interface cleanups of libgccjit
3765 * jit-playback.c (convert_to_dso): Use auto_vec instead
3766 of automatic array to build up command line.
3767 * jit-recording.c (recording::context::set_str_option):
3768 Make copy of the string.
3769 (recording::context::~context): Free string options.
3770 * jit-recording.h (recording::context): Adjust type
3771 of m_str_options member.
3772 * libgccjit.h: Adjust comment about
3773 gcc_jit_context_set_str_option parameter being used after
3774 the call.
3775 Update comment now that all interfaces are copy strings
3776 if necessary.
3777 * libgccjit++.h (gccjit::context): Add set_str_option
3778 member function.
3779
29df5715
DM
37802014-12-10 David Malcolm <dmalcolm@redhat.com>
3781
3782 * docs/cp/index.rst: New file.
3783 * docs/cp/intro/index.rst: New file.
3784 * docs/cp/intro/tutorial01.rst: New file.
3785 * docs/cp/intro/tutorial02.rst: New file.
3786 * docs/cp/intro/tutorial03.rst: New file.
3787 * docs/cp/intro/tutorial04.rst: New file.
3788 * docs/cp/topics/contexts.rst: New file.
3789 * docs/cp/topics/expressions.rst: New file.
3790 * docs/cp/topics/functions.rst: New file.
3791 * docs/cp/topics/index.rst: New file.
3792 * docs/cp/topics/locations.rst: New file.
3793 * docs/cp/topics/objects.rst: New file.
3794 * docs/cp/topics/results.rst: New file.
3795 * docs/cp/topics/types.rst: New file.
3796 * docs/examples/tut01-hello-world.cc: New file.
3797 * docs/examples/tut02-square.c: Fix missing newline in output.
3798 * docs/examples/tut02-square.cc: New file.
3799 * docs/examples/tut03-sum-of-squares.cc: New file.
3800 * docs/examples/tut04-toyvm/toyvm.cc: New file.
3801 * docs/index.rst: Move summary to above the table of contents.
3802 Add text about the C vs C++ APIs.
3803 * docs/topics/contexts.rst: Fix a typo.
3804
3805 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3806 * docs/_build/texinfo/factorial1.png: New file.
3807 * docs/_build/texinfo/sum-of-squares1.png: New file.
3808
5cd614ce
DM
38092014-12-09 David Malcolm <dmalcolm@redhat.com>
3810
3811 * docs/examples/tut04-toyvm/toyvm.c (toyvm_function_compile): Move
3812 logic for determine "funcname" to new function...
3813 (get_function_name): ...here, adding logic to skip any leading
3814 path from the filename.
3815 (toyvm_function_parse): Use the filename for fn_filename, rather
3816 than "name", so that the debugger can locate the source .toy
3817 file.
3818 (toyvm_function_parse): Don't fclose a NULL FILE *.
3819
2712de78
DM
38202014-12-09 David Malcolm <dmalcolm@redhat.com>
3821
3822 PR jit/63854
3823 * docs/internals/index.rst (Running under valgrind): New
3824 subsection.
3825 (docs/_build/texinfo/libgccjit.texi): Regenerate.
3826
d1e5f2c7
DM
38272014-12-09 David Malcolm <dmalcolm@redhat.com>
3828
92a285c1 3829 PR jit/64206
d1e5f2c7
DM
3830 * Make-lang.in (jit_OBJS): Add jit/jit-tempdir.o.
3831 * jit-common.h (gcc::jit::tempdir): New forward decl.
3832 * jit-playback.c: Include jit-tempdir.h.
3833 (gcc::jit::playback::context::context): Initialize m_tempdir.
3834 (gcc::jit::playback::context::~context): Move tempdir
3835 cleanup to new file jit-tempdir.c
3836 (make_tempdir_path_template): Move to new file jit-tempdir.c.
3837 (gcc::jit::playback::context::compile): Move tempdir creation
3838 to new tempdir object in new file jit-tempdir.c.
3839 (gcc::jit::playback::context::make_fake_args): Get path from
3840 tempdir object rather than from member data.
3841 (gcc::jit::playback::context::convert_to_dso): Likewise.
3842 (gcc::jit::playback::context::dlopen_built_dso): Likewise.
3843 (gcc::jit::playback::context::dump_generated_code): Likewise.
3844 (gcc::jit::playback::context::get_path_c_file): New function.
3845 (gcc::jit::playback::context::get_path_s_file): New function.
3846 (gcc::jit::playback::context::get_path_so_file): New function.
3847 * jit-playback.h (gcc::jit::playback::context::get_path_c_file):
3848 New function.
3849 (gcc::jit::playback::context::get_path_s_file): New function.
3850 (gcc::jit::playback::context::get_path_so_file): New function.
3851 (gcc::jit::playback::context): Move fields "m_path_template",
3852 "m_path_tempdir", "m_path_c_file", "m_path_s_file",
3853 "m_path_so_file" to new jit::tempdir class; add field "m_tempdir".
3854 * jit-tempdir.c: New file.
3855 * jit-tempdir.h: New file.
3856
38771e4e
DM
38572014-12-09 David Malcolm <dmalcolm@redhat.com>
3858
3859 * jit-playback.c (gcc::jit::playback::context::compile): Acquire the
3860 mutex here, immediately before using toplev, and release it here, on
3861 each exit path after acquisition.
3862 (jit_mutex): Move this variable here, from jit-recording.c.
3863 (gcc::jit::playback::context::acquire_mutex): New function, based on
3864 code in jit-recording.c.
3865 (gcc::jit::playback::context::release_mutex): Likewise.
3866 * jit-playback.h (gcc::jit::playback::context::acquire_mutex): New
3867 function.
3868 (gcc::jit::playback::context::release_mutex): New function.
3869 * jit-recording.c (jit_mutex): Move this variable to jit-playback.c.
3870 (gcc::jit::recording::context::compile): Move mutex-handling from
3871 here into jit-playback.c's gcc::jit::playback::context::compile.
3872 * notes.txt: Update to show the new locations of ACQUIRE_MUTEX
3873 and RELEASE_MUTEX.
3874
38f4f641
DM
38752014-12-09 David Malcolm <dmalcolm@redhat.com>
3876
3877 * jit-playback.c (gcc::jit::playback::context::compile): Move the
3878 dlopen code into...
3879 (gcc::jit::playback::context::dlopen_built_dso): ...this new
3880 function.
3881 * jit-playback.h (gcc::jit::playback::context::dlopen_built_dso):
3882 New function.
3883
82e0c914
DM
38842014-12-09 David Malcolm <dmalcolm@redhat.com>
3885
3886 PR jit/64166
3887 * docs/topics/contexts.rst (Debugging): Add description of
3888 gcc_jit_context_enable_dump.
3889 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3890 * jit-playback.c: Include context.h.
3891 (class auto_argvec): New class.
3892 (auto_argvec::~auto_argvec): New function.
3893 (gcc::jit::playback::context::compile): Convert fake_args to be
3894 an auto_argvec, so that it can contain dynamically-allocated
3895 strings. Construct a vec of all requested dumps, and pass it to
3896 make_fake_args. Extract requested dumps between the calls to
3897 toplev::main and toplev::finalize.
3898 (gcc::jit::playback::context::make_fake_args): Convert param
3899 "argvec" to be a vec <char *>, and gain a "requested_dumps"
3900 param. Convert to dynamically-allocated arg strings by converting
3901 ADD_ARG to take a copy of the arg, and add ADD_ARG_TAKE_OWNERSHIP
3902 for args that are already a copy. Add args for all requested dumps.
3903 (gcc::jit::playback::context::extract_any_requested_dumps): New
3904 function.
3905 (gcc::jit::playback::context::read_dump_file): New function.
3906 * jit-playback.h (gcc::jit::playback::context::make_fake_args):
3907 Convert param "argvec" to be a vec <char *>, and gain a
3908 "requested_dumps" param.
3909 (gcc::jit::playback::context::extract_any_requested_dumps): New
3910 function.
3911 (gcc::jit::playback::context::read_dump_file): New function.
3912 * jit-recording.c (gcc::jit::recording::context::enable_dump): New
3913 function.
3914 (gcc::jit::recording::context::get_all_requested_dumps): New
3915 function.
3916 * jit-recording.h (gcc::jit::recording::requested_dump): New
3917 struct.
3918 (gcc::jit::recording::context::enable_dump): New function.
3919 (gcc::jit::recording::context::get_all_requested_dumps): New
3920 function.
3921 (gcc::jit::recording::context::m_requested_dumps): New field.
3922 * libgccjit.c (gcc_jit_context_enable_dump): New API entrypoint.
3923 * libgccjit.h (gcc_jit_context_enable_dump): New API entrypoint.
3924 * libgccjit.map (gcc_jit_context_enable_dump): New API entrypoint.
3925
53b730ff
DM
39262014-12-08 David Malcolm <dmalcolm@redhat.com>
3927
3928 * libgccjit++.h: Indent the forward declarations of the classes to
3929 show the inheritance hierarchy.
3930
0f379445
DM
39312014-12-08 David Malcolm <dmalcolm@redhat.com>
3932
3933 * notes.txt: Show the beginning and ending of
3934 recording::context::compile vs playback::context::compile. Show
3935 the creation and unlinking of the tempdir. Show toplev::finalize.
3936 Move "RELEASE MUTEX" to the correct location. Show
3937 gcc_jit_result_release, and indicate where the
3938 dlopen/dlsym/dlclose occur.
3939
81ba15f1
DM
39402014-12-01 David Malcolm <dmalcolm@redhat.com>
3941
3942 * docs/examples/tut02-square.c (main): Release the context
3943 earlier, to show that this is possible. Update error-handling
3944 to avoid a double-release of the context, and to avoid
3945 releasing a NULL result.
3946 * docs/intro/tutorial02.rst: Discuss gcc_jit_context_release.
3947 * docs/topics/functions.rst (GCC_JIT_FUNCTION_EXPORTED): Emphasize
3948 * docs/topics/results.rst (gcc_jit_result): Mention that this
3949 controls the lifetimes of machine code functions.
3950 (gcc_jit_result_get_code): Spell out the requirements for this
3951 to succeed, and the lifetime of the result.
3952 (gcc_jit_result_release): Mention that this invalidates any code
3953 that was obtained from the result.
3954 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3955
e250f0dc
DM
39562014-12-01 David Malcolm <dmalcolm@redhat.com>
3957
3958 PR jit/64018
3959 * docs/intro/tutorial02.rst: Spell out lifetime of generated code.
3960 Add description of error-handling, taken in part from...
3961 * docs/topics/contexts.rst (Error-handling): Expand, and move some
3962 content to tutorial02.rst.
3963 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3964
eeafb319
DM
39652014-12-01 David Malcolm <dmalcolm@redhat.com>
3966
3967 PR jit/64020
3968 * docs/topics/types.rst (Standard types) Add new enum values to
3969 the table of enum gcc_jit_types: GCC_JIT_TYPE_COMPLEX_FLOAT,
3970 GCC_JIT_TYPE_COMPLEX_DOUBLE, GCC_JIT_TYPE_COMPLEX_LONG_DOUBLE.
3971 Widen the left-hand column so that
3972 GCC_JIT_TYPE_COMPLEX_LONG_DOUBLE will fit.
3973 * docs/_build/texinfo/libgccjit.texi: Regenerate.
3974
3975 * jit-builtins.c: Include stringpool.h and jit-playback.h.
3976 Move everything out of the gcc::jit::recording namespace into
3977 just gcc::jit.
3978 (struct builtin_data): Add fields "fnclass", "attr", and
3979 "implicit_p".
3980 (DEF_BUILTIN): Update macro so populate the new fields.
3981 (builtins_manager::builtins_manager): Update for move out of
3982 recording namespace. Initialize the m_attributes array.
3983 (builtins_manager::get_builtin_function): Likewise.
3984 (builtins_manager::get_builtin_function_by_id): New function.
3985 (builtins_manager::make_builtin_function): Update for move out of
3986 recording namespace. Add fix for PR jit/64020 by detecting
3987 specific builtin ids and having them ensure that builtins for
3988 other ids are created as necessary.
3989 (builtins_manager::get_type): Update for move out of recording
3990 namespace.
3991 (builtins_manager::make_type): Likewise. Add some missing
3992 #undefs.
3993 (builtins_manager::make_primitive_type): Update for move out of
3994 recording namespace. Implement the three BT_COMPLEX_ cases and
3995 BT_DOUBLE_PTR.
3996 (builtins_manager::make_fn_type): Update for move out of recording
3997 namespace.
3998 (builtins_manager::make_ptr_type): Likewise.
3999 (builtins_manager::finish_playback): New function.
4000 (builtins_manager::get_class): New function.
4001 (builtins_manager::implicit_p): New function.
4002 (builtins_manager::get_attrs_tree): Two new functions.
4003 (builtins_manager::make_attrs_tree): New function.
4004
4005 * jit-builtins.h: Move everything out of the gcc::jit::recording
4006 namespace into just gcc::jit.
4007 (enum built_in_attribute): New.
4008 (builtins_manager::builtins_manager): Update decl for namespace
4009 change.
4010 (builtins_manager::get_builtin_function): Likewise.
4011 (builtins_manager::get_class): New.
4012 (builtins_manager::implicit_p): New.
4013 (builtins_manager::get_attrs_tree): Two new functions.
4014 (builtins_manager::make_attrs_tree): New function.
4015 (builtins_manager::finish_playback): New.
4016 (builtins_manager::get_builtin_function_by_id): New.
4017 (builtins_manager::make_builtin_function): Update decl for
4018 namespace change.
4019 (builtins_manager::get_type): Likewise.
4020 (builtins_manager::make_type): Likewise.
4021 (builtins_manager::make_primitive_type): Likewise.
4022 (builtins_manager::make_fn_type): Likewise.
4023 (builtins_manager::make_ptr_type): Likewise.
4024 (builtins_manager): Likewise for fields. Add new field
4025 "m_attributes".
4026
4027 * jit-common.h (NUM_GCC_JIT_TYPES): Update.
4028 (builtins_manager): Update forward decl to reflect namespace
4029 change.
4030
4031 * jit-playback.c: Include attribs.h and jit-builtins.h.
4032 (gcc::jit::playback::context::get_tree_node_for_type): Add cases
4033 for the new COMPLEX_ types.
4034 (gcc::jit::playback::context::new_function): If creating a
4035 builtin, set the DECL_BUILT_IN_CLASS and attributes on the fndecl,
4036 and call set_builtin_decl.
4037 (gcc::jit::playback::context::replay): If we have a
4038 builtins_manager, call its finish_playback method when we're done.
4039
4040 * jit-playback.h:
4041 (gcc::jit::playback::context::get_builtins_manager): New function.
4042
4043 * jit-recording.c
4044 (gcc::jit::recording::context::get_builtins_manager): New function.
4045 (gcc::jit::recording::get_builtin_function): Use
4046 get_builtins_manager, in case we're a child context.
4047 (gcc::jit::recording::memento_of_get_type::dereference): Add the
4048 COMPLEX_ types.
4049 (gcc::jit::recording::memento_of_get_type::is_int): Likewise.
4050 (gcc::jit::recording::memento_of_get_type::is_float): Likewise.
4051 (gcc::jit::recording::memento_of_get_type::is_bool): Likewise.
4052 (get_type_strings): Likewise.
4053
4054 * jit-recording.h
4055 (gcc::jit::recording::context::get_builtins_manager): New.
4056
4057 * libgccjit.h (enum gcc_jit_types): Add
4058 GCC_JIT_TYPE_COMPLEX_FLOAT, GCC_JIT_TYPE_COMPLEX_DOUBLE,
4059 GCC_JIT_TYPE_COMPLEX_LONG_DOUBLE.
4060
23844fd7
DM
40612014-12-01 David Malcolm <dmalcolm@redhat.com>
4062
4063 * jit-builtins.c
4064 (gcc::jit::recording::builtins_manager::get_builtin_function):
4065 Check for NULL return from make_builtin_function.
4066 (gcc::jit::recording::builtins_manager::make_builtin_function):
4067 Check for NULL return from get_type.
4068
c6760a13
DM
40692014-12-01 David Malcolm <dmalcolm@redhat.com>
4070
4071 * jit-playback.c (gcc::jit::playback::context::compile): Move DSO
4072 creation code into...
4073 (gcc::jit::playback::context::convert_to_dso): New function.
4074 * jit-playback.h (gcc::jit::playback::context::convert_to_dso):
4075 New function.
4076
8f50ee3c
DM
40772014-12-01 David Malcolm <dmalcolm@redhat.com>
4078
4079 * jit-playback.c (gcc::jit::playback::context::compile): Use an
4080 auto_vec<const char *> rather than a const char *[20] for the
4081 top-level argv, and move the logic to build it to...
4082 (gcc::jit::playback::context::make_fake_args): New function.
4083 * jit-playback.h (gcc::jit::playback::context::make_fake_args):
4084 New function.
4085
56dea35f
DM
40862014-12-01 David Malcolm <dmalcolm@redhat.com>
4087
4088 * Make-lang.in (jit_OBJS): Add jit/jit-result.o.
4089 * jit-playback.c: Include new header jit-result.h.
4090 (gcc::jit::result::result): Move to new file jit-result.c.
4091 (gcc::jit::result::~result): Likewise.
4092 (gcc::jit::playback::result): Likewise.
4093 * jit-recording.h (class gcc::jit::result): Move to new
4094 header jit-result.h.
4095 * jit-result.c: New file, to contain...
4096 (gcc::jit::result::result): Move here from jit-playback.c,
4097 removing erroneous "playback" namespace from comment.
4098 (gcc::jit::result::~result): Likewise.
4099 (gcc::jit::playback::result): Likewise.
4100 * jit-result.h: New file, to contain...
4101 (class gcc::jit::result): Move from jit-recording.h.
4102 * libgccjit.c: Include jit-result.h.
4103 (gcc_jit_result_get_code): Update comment to reflect move
4104 of implementation.
4105 (gcc_jit_result_release): Likewise.
4106
52b9468f
DM
41072014-12-01 David Malcolm <dmalcolm@redhat.com>
4108
4109 PR jit/63854
4110 * docs/examples/tut04-toyvm/toyvm.c
4111 (toyvm_compiled_function): New typedef.
4112 (toyvm_compiled_func) Rename to...
4113 (toyvm_compiled_code) ...this.
4114 (struct toyvm_compiled_function): New struct.
4115 (toyvm_function_compile): Return a toyvm_compiled_function *
4116 rather than a toyvm_compiled_func, so that the caller can fully
4117 clean things up. Free "funcname".
4118 (test_script): Update for change to toyvm_function_compile.
4119 Clean up the toyvm_compiled_function.
4120 (main): Likewise.
4121 (docs/intro/tutorial04.rst): Update to reflect the above changes,
4122 and to better spell out the lifetime of the compiled code.
4123
c8d19a69
DM
41242014-12-01 David Malcolm <dmalcolm@redhat.com>
4125
4126 PR jit/63854
4127 * jit-builtins.c
4128 (gcc::jit::recording::builtins_manager::make_fn_type): Call the
4129 context's new_function_type method, rather than directly creating
4130 a function_type instance.
4131 * jit-recording.c
4132 (gcc::jit::recording::context::new_function_type): New method,
4133 adapted from part of...
4134 (gcc::jit::recording::context::new_function_ptr_type): ...this.
4135 Update to call new_function_type.
4136 * jit-recording.h
4137 (gcc::jit::recording::context::new_function_type): New method.
4138
c985705a
DM
41392014-12-01 David Malcolm <dmalcolm@redhat.com>
4140
4141 PR jit/63969
4142 * jit-playback.c: Ensure that ctxt_progname is non-NULL.
4143
b957b2e0
DM
41442014-11-19 David Malcolm <dmalcolm@redhat.com>
4145
4146 PR jit/63854
4147 * jit-playback.c (gcc::jit::playback::compound_type::set_fields):
4148 Convert param from const vec<playback::field *> & to
4149 const auto_vec<playback::field *> *.
4150 (gcc::jit::playback::context::new_function_type): Convert param
4151 "param_types" from vec<type *> * to const auto_vec<type *> *.
4152 (gcc::jit::playback::context::new_function): Convert param
4153 "params" from vec<param *> * to const auto_vec<param *> *.
4154 (gcc::jit::playback::context::build_call): Convert param "args"
4155 from vec<rvalue *> to const auto_vec<rvalue *> *.
4156 (gcc::jit::playback::context::new_call): Likewise.
4157 (gcc::jit::playback::context::new_call_through_ptr): Likewise.
4158 (wrapper_finalizer): New function.
4159 (gcc::jit::playback::wrapper::operator new): Call the finalizer
4160 variant of ggc_internal_cleared_alloc, supplying
4161 wrapper_finalizer.
4162 (gcc::jit::playback::function::finalizer): New.
4163 (gcc::jit::playback::block::finalizer): New.
4164 (gcc::jit::playback::source_file::finalizer): New.
4165 (gcc::jit::playback::source_line::finalizer): New.
4166
4167 * jit-playback.h
4168 (gcc::jit::playback::context::new_function_type): Convert param
4169 "param_types" from vec<type *> * to const auto_vec<type *> *.
4170 (gcc::jit::playback::context::new_function): Convert param
4171 "params" from vec<param *> * to const auto_vec<param *> *.
4172 (gcc::jit::playback::context::new_call): Convert param
4173 "args" from vec<rvalue *> to const auto_vec<rvalue *> *.
4174 (gcc::jit::playback::context::new_call_through_ptr): Likewise.
4175 (gcc::jit::playback::context::build_call): Likewise.
4176 (gcc::jit::playback::context): Convert fields "m_functions",
4177 "m_source_files", "m_cached_locations" from vec to auto_vec.
4178 (gcc::jit::playback::wrapper::finalizer): New virtual function.
4179 (gcc::jit::playback::compound_type::set_fields): Convert param fro
4180 const vec<playback::field *> & to
4181 const auto_vec<playback::field *> *.
4182 (gcc::jit::playback::function::finalizer): New.
4183 (gcc::jit::playback::block::finalizer): New.
4184 (gcc::jit::playback::source_file::finalizer): New.
4185 (gcc::jit::playback::source_line::finalizer): New.
4186
4187 * jit-recording.c
4188 (gcc::jit::recording::function_type::replay_into): Convert local
4189 from a vec into an auto_vec.
4190 (gcc::jit::recording::fields::replay_into): Likewise.
4191 (gcc::jit::recording::function::replay_into): Likewise.
4192 (gcc::jit::recording::call::replay_into): Likewise.
4193 (gcc::jit::recording::call_through_ptr::replay_into): Likewise.
4194
4195 * jit-recording.h (gcc::jit::recording::context): Convert fields
4196 "m_mementos", "m_compound_types", "m_functions" from vec<> to
4197 auto_vec <>.
4198 (gcc::jit::recording::function_type::get_param_types): Convert
4199 return type from vec<type *> to const vec<type *> &.
4200 (gcc::jit::recording::function_type): Convert field
4201 "m_param_types" from a vec<> to an auto_vec<>.
4202 (gcc::jit::recording::fields): Likewise for field "m_fields".
4203 (gcc::jit::recording::function::get_params): Convert return type
4204 from vec <param *> to const vec<param *> &.
4205 (gcc::jit::recording::function): Convert fields "m_params",
4206 "m_locals", "m_blocks" from vec<> to auto_vec<>.
4207 (gcc::jit::recording::block): Likewise for field "m_statements".
4208 vec<> to auto_vec<>.
4209 (gcc::jit::recording::call): Likewise for field "m_args".
4210 (gcc::jit::recording::call_through_ptr): Likewise.
4211
79cafc7a
DM
42122014-11-19 David Malcolm <dmalcolm@redhat.com>
4213
4214 PR jit/63854
4215 * jit-recording.c (recording::function::validate): Convert
4216 "worklist" from vec<> to autovec<> to fix a leak.
4217
35485da9
DM
42182014-11-11 David Malcolm <dmalcolm@redhat.com>
4219
4220 * ChangeLog.jit: New.
4221 * ChangeLog: New.
4222 * Make-lang.in: New.
4223 * TODO.rst: New.
4224 * config-lang.in: New.
4225 * docs/Makefile: New.
4226 * docs/_build/texinfo/Makefile: New.
4227 * docs/_build/texinfo/factorial.png: New.
4228 * docs/_build/texinfo/libgccjit.texi: New.
4229 * docs/_build/texinfo/sum-of-squares.png: New.
4230 * docs/conf.py: New.
4231 * docs/examples/tut01-hello-world.c: New.
4232 * docs/examples/tut02-square.c: New.
4233 * docs/examples/tut03-sum-of-squares.c: New.
4234 * docs/examples/tut04-toyvm/Makefile: New.
4235 * docs/examples/tut04-toyvm/factorial.toy: New.
4236 * docs/examples/tut04-toyvm/fibonacci.toy: New.
4237 * docs/examples/tut04-toyvm/toyvm.c: New.
4238 * docs/index.rst: New.
4239 * docs/internals/index.rst: New.
4240 * docs/intro/factorial.png: New.
4241 * docs/intro/index.rst: New.
4242 * docs/intro/sum-of-squares.png: New.
4243 * docs/intro/tutorial01.rst: New.
4244 * docs/intro/tutorial02.rst: New.
4245 * docs/intro/tutorial03.rst: New.
4246 * docs/intro/tutorial04.rst: New.
4247 * docs/topics/contexts.rst: New.
4248 * docs/topics/expressions.rst: New.
4249 * docs/topics/functions.rst: New.
4250 * docs/topics/index.rst: New.
4251 * docs/topics/locations.rst: New.
4252 * docs/topics/objects.rst: New.
4253 * docs/topics/results.rst: New.
4254 * docs/topics/types.rst: New.
4255 * dummy-frontend.c: New.
4256 * jit-builtins.c: New.
4257 * jit-builtins.h: New.
4258 * jit-common.h: New.
4259 * jit-playback.c: New.
4260 * jit-playback.h: New.
4261 * jit-recording.c: New.
4262 * jit-recording.h: New.
4263 * libgccjit++.h: New.
4264 * libgccjit.c: New.
4265 * libgccjit.h: New.
4266 * libgccjit.map: New.
4267 * notes.txt: New.
4268
42692013-07-26 David Malcolm <dmalcolm@redhat.com>
4270
4271 * Initial creation
818ab71a 4272\f
6a720d41 4273Copyright (C) 2013-2024 Free Software Foundation, Inc.
35485da9
DM
4274
4275Copying and distribution of this file, with or without modification,
4276are permitted in any medium without royalty provided the copyright
4277notice and this notice are preserved.