* expprint.c (print_subexp_standard): Compare against builtin type
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
2
3 * expprint.c (print_subexp_standard): Compare against builtin type
4 associated with exp->gdbarch instead of builtin_type_char.
5
6 * f-valprint.c (f_val_print): Use extract_unsigned_integer to
7 extract values of arbitrary logical type. Handle arbitrary
8 complex types.
9
10 * printcmd.c (float_type_from_length): New function.
11 (print_scalar_formatted, printf_command): Use it.
12
13 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
14
15 * valops.c: Include "objfiles.h" and "symtab.h".
16 (find_function_in_inferior): New argument OBJF_P. Use it to return
17 objfile where function is defined. Use per-objfile arch types
18 instead of builtin_type_ to define default return type.
19
20 * linux-fork.c (checkpoint_command): Update calls. Use per-objfile
21 architecture to define inferior call argument types.
22 * gcore.c (derive_heap_segment): Likewise.
23 * objc-lang.c (value_nsstring): Likewise.
24 * scm-lang.c (scm_lookup_name): Likewise.
25 * scm-valprint.c (scm_inferior_print): Likewise.
26 * valops.c (value_allocate_space_in_inferior): Likewise.
27
28 * eval.c (evaluate_subexp_standard): Update calls.
29 * objc-lang.c (lookup_objc_class, print_object_command): Likewise.
30
31 * linux-fork.c: Include "objfiles.h".
32 * scm-lang.c: Include "objfiles.h".
33 * scm-valprint.c: Include "objfiles.h".
34
35 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
36
37 * gdbarch.sh (name_of_malloc): Remove.
38 * gdbarch.c, gdbarch.h: Re-generate.
39 * valops.c (value_allocate_space_in_inferior): Do not call
40 gdbarch_name_of_malloc.
41
42 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
43
44 * valarith.c (value_x_unop): Use builtin_type_int8 as type for
45 UNOP_POSTINCREMENT/UNOP_POSTDECREMENT constant 0 argument.
46 (value_bit_index): Use extract_unsigned_integer
47 instead of unpack_long to read single byte.
48
49 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
50
51 * infcall.c (value_arg_coerce): Add GDBARCH parameter. Use its
52 associates types instead of builtin_type_ macros.
53 (find_function_addr): Leave output VALUE_TYPE NULL if unknown.
54 (call_function_by_hand): Use per-architecture "int" type as
55 fall-back if find_function_addr returns NULL VALUE_TYPE.
56 Update call to value_arg_coerce.
57
58 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
59
60 * cp-abi.h (cplus_method_ptr_size): Add TO_TYPE parameter.
61 (cplus_make_method_ptr): Add TYPE parameter.
62 * cp-abi.c (cplus_method_ptr_size): Add TO_TYPE parameter. Pass it
63 on to current_cp_abi.method_ptr_size callback.
64 (cplus_make_method_ptr): Add TYPE parameter. Pass it on to
65 current_cp_abi.make_method_ptr callback.
66
67 * gdbtypes.c (lookup_methodptr_type): Pass target type
68 argument to cplus_method_ptr_size.
69 * valops.c (value_cast): Pass type argument to cplus_make_method_ptr.
70 (value_struct_elt_for_reference): Likewise.
71
72 * gnu-v3-abi.c (get_class_arch): New function.
73 (vtable_address_point_offset): Add GDBARCH parameter. Use it
74 instead of current_gdbarch. Update all callers.
75 (gnuv3_get_vtable): Likewise.
76 (gnuv3_get_virtual_fn): Likewise.
77 (gnuv3_decode_method_ptr): Likewise.
78 (gnuv3_rtti_type): Call get_class_arch to determine architecture.
79 Use it instead of current_gdbarch.
80 (gnuv3_virtual_fn_field): Likewise.
81 (gnuv3_baseclass_offset): Likewise.
82 (gnuv3_print_method_ptr): Likewise.
83 (gnuv3_method_ptr_to_value): Likewise.
84 (gnuv3_method_ptr_size): Add TYPE parameter. Use it to determine
85 class architecture. Use architecture types instead of builtin types.
86 (gnuv3_make_method_ptr): Likewise.
87
88 * cp-valprint.c (cp_print_class_member): Expect pointer type
89 instead of class type. Use its length when extracting value.
90 * c-valprint.c (c_val_print): Update call to cp_print_class_member.
91
92 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
93
94 * stack.c (return_command): Use frame architecture to determine
95 default integer return type.
96
97 * f-valprint.c (f77_get_dynamic_lowerbound): Use frame architecture
98 to determine pointer types.
99 (f77_get_dynamic_upperbound): Likewise.
100
101 * objc-lang.c (OBJC_FETCH_POINTER_ARGUMENT): Remove.
102 (resolve_msgsend): Use architecture of current frame to determine
103 pointer types. Inline OBJC_FETCH_POINTER_ARGUMENT.
104 (resolve_msgsend_stret, resolve_msgsend_super,
105 resolve_msgsend_super_stret): Likewise.
106
107 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
108
109 * alpha-tdep.c (alpha_register_type): Use builtin_type (gdbarch)
110 instead of builtin_type_ macros.
111 * amd64-tdep.c (amd64_register_type): Likewise.
112 (amd64_get_longjmp_target): Likewise.
113 * arm-tdep.c (arm_register_type): Likewise.
114 * avr-tdep.c (avr_register_type): Likewise.
115 * cris-tdep.c (cris_register_type, crisv32_register_type): Likewise.
116 * frv-tdep.c (frv_register_type): Likewise.
117 * h8300-tdep.c (h8300_register_type): Likewise.
118 * hppa-tdep.c (hppa32_convert_from_func_ptr_addr,
119 hppa_skip_trampoline_code): Likewise.
120 * i386-tdep.c (i386_register_type): Likewise.
121 (i386_unwind_pc, i386_sse_type): Likewise.
122 * ia64-tdep.c (ia64_register_type): Likewise.
123 * m32r-tdep.c (m32r_register_type): Likewise.
124 * m68k-tdep.c (m68k_register_type, m68k_unwind_pc): Likewise.
125 * m88k-tdep.c (m88k_register_type): Likewise.
126 * mep-tdep.c (mep_register_type): Likewise.
127 * mips-tdep.c (mips_pseudo_register_type): Likewise.
128 * mn10300-tdep.c (mn10300_register_type): Likewise.
129 * mt-tdep.c (mt_copro_register_type): Likewise.
130 * rs6000-tdep.c (rs6000_builtin_type_vec64): Likewise.
131 (rs6000_convert_register_p, rs6000_register_to_value,
132 rs6000_value_to_register): Likewise.
133 * s390-tdep.c (s390_register_type): Likewise.
134 * sh64-tdep.c (sh64_register_type): Likewise.
135 (sh64_build_float_register_type, sh64_do_fp_register): Likewise.
136 * sh-tdep.c (sh_sh2a_register_type, sh_sh3e_register_type,
137 sh_sh4_build_float_register_type, sh_sh4_register_type,
138 sh_default_register_type): Likewise.
139 * sparc64-tdep.c (sparc64_register_type): Likewise.
140 * sparc-tdep.c (sparc32_register_type): Likewise.
141 * spu-tdep.c (spu_builtin_type_vec128, spu_register_type): Likewise.
142 * v850-tdep.c (v850_register_type): Likewise.
143 * vax-tdep.c (vax_register_type): Likewise.
144 * xtensa-tdep.c (xtensa_register_type, xtensa_unwind_pc,
145 xtensa_push_dummy_call): Likewise.
146
147 * std-regs.c (value_of_builtin_frame_fp_reg,
148 value_of_builtin_frame_pc_reg): Likewise.
149 * target-descriptions.c (tdesc_register_type): Likewise.
150
151 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
152
153 * ada-lang.c (ada_coerce_to_simple_array_type): Use builtin_type_int32
154 instead of builtin_type_int as default unspecified integral type.
155 (ada_index_type, ada_array_bound_from_type, ada_variant_discrim_type,
156 assign_component, to_fixed_range_type): Likewise.
157 * ada-typeprint.c (print_range, print_range_bound,
158 print_range_type_named): Likewise.
159 * ada-valprint.c (print_optional_low_bound, ada_val_print_1): Likewise.
160 * eval.c (evaluate_subexp_standard): Likewise.
161 * gnu-v2-abi.c (gnuv2_virtual_fn_field): Likewise.
162 * gnu-v3-abi.c (gnuv3_get_virtual_fn, gnuv3_baseclass_offset,
163 build_gdb_vtable_type): Likewise.
164 * jv-lang.c (java_array_type): Likewise.
165 * m2-typeprint.c (m2_print_bounds, m2_is_long_set_of_type): Likewise.
166 * m2-valprint.c (m2_print_long_set): Likewise.
167 * parse.c (follow_types): Likewise.
168 * p-typeprint.c (pascal_type_print_base): Likewise.
169 * valops.c (value_one, value_array, value_string,
170 value_bitstring): Likewise.
171 * value.c (allocate_repeat_value, value_from_string): Likewise.
172 * varobj.c (c_describe_child): Likewise.
173 * mt-tdep.c (mt_register_type): Likewise.
174 * sh-tdep.c (sh_sh4_build_float_register_type): Likewise.
175 * sh64-tdep.c (sh64_build_float_register_type): Likewise.
176
177 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
178
179 * gdbtypes.h (struct builtin_type): Remove builtin_true_char
180 and builtin_true_unsigned_char.
181 (builtin_type_true_char): Remove macro, add extern declaration.
182 (builtin_type_true_unsigned_char): Add extern declaration.
183 * gdbtypes.c (builtin_type_true_char): New global variable.
184 (builtin_type_true_unsigned_char): Likewise.
185 (_initialize_gdbtypes): Initialize them.
186 (gdbtypes_post_init): Do not initialize builtin_true_char
187 and builtin_true_unsigned_char members of struct builtin_type.
188
189 * printcmd.c (print_scalar_formatted): Do not use builtin_type;
190 use builtin_type_true_unsigned_char instead.
191
192 * ada-valprint.c (ada_val_print_1): Use builtin_type_true_char
193 instead of builtin_type_char for internal string.
194
195 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
196
197 * gdbtypes.h (builtin_type_void): Remove macro, add declaration.
198 (builtin_type_f_void): Remove macro.
199 * gdbtypes.c (builtin_type_void): New global variable.
200 (_initialize_gdbtypes): Initialize it.
201
202 * gnu-v3-abi.c (build_gdb_vtable_type): Do not call
203 lookup_pointer_type or lookup_function_type on builtin_type_void.
204 * printcmd.c (set_next_address): Likewise.
205 * objc-lang.c (value_nsstring): Likewise.
206 * mt-tdep.c (mt_copro_register_type): Likewise.
207 * xtensa-tdep.c (xtensa_register_type): Likewise.
208
209 * symfile.c (syms_from_objfile): Remove special handling
210 of builtin_type_void and builtin_type_char.
211
212 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
213
214 * eval.c (evaluate_subexp_standard): Use exp->gdbarch types instead
215 of builtin_type_ macros when handling OP_OBJC_ operations.
216 * objc-lang.c (print_object_command): Likewise.
217
218 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
219
220 * ada-valprint.c: Include "objfiles.h".
221 (ada_val_print_1): Use the gdbarch associated with the objfile whether
222 a System.Address type is defined to retrieve the proper pointer type
223 to use to print it.
224
225 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
226
227 * ada-lang.c (value_pos_atr): Add TYPE argument. Use it as
228 result type instead of builtin_type_int.
229 (value_subscript_packed): Use pos_atr instead of value_pos_atr.
230 (ada_value_subscript): Update call to value_pos_atr.
231 (ada_value_ptr_subscript): Likewise.
232 (ada_evaluate_subexp): Likewise.
233
234 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
235
236 * ada-lang.c (cast_to_fixed): Do not cast to builtin_type_double.
237 (cast_from_fixed_to_double): Rename to ...
238 (cast_from_fixed): ... this. Add TYPE parameter. Use it instead
239 of builtin_type_double.
240 (ada_value_cast): Use cast_from_fixed instead of casting result
241 of cast_from_fixed_to_double.
242 (ada_evaluate_subexp): Update calls to cast_from_fixed_to_double.
243
244 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
245
246 * valops.c (value_ind): No longer allow dereferencing an
247 integer type.
248 * eval.c (evaluate_subexp_standard): Handle deferencing an
249 integer type here.
250 * ada-lang.c (ada_evaluate_subexp): Likewise.
251
252 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
253
254 * ada-valprint.c (ada_val_print_1): When implicitly dereferencing
255 a reference type, pass the reference type directly to unpack_pointer.
256 * c-valprint.c (c_val_print): Likewise.
257 * f-valprint.c (f_val_print): Likewise.
258 * m2-valprint.c (print_variable_at_address, m2_val_print): Likewise.
259 * p-valprint.c (pascal_val_print): Likewise.
260
261 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
262
263 * eval.c (evaluate_subexp_standard): Use builtin_type_int8
264 to construct the EVAL_SKIP dummy return value.
265 * ada-lang.c (ada_evaluate_subexp): Likewise.
266 * jv-lang.c (evaluate_subexp_java): Likewise.
267 * m2-lang.c (evaluate_subexp_modula2): Likewise.
268 * scm-lang.c (evaluate_exp): Likewise.
269
270 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
271
272 * value.h (coerce_enum, coerce_number): Remove prototypes.
273 * value.c (coerce_enum, coerce_number): Remove.
274 * valarith.c (value_x_binop): Do not call coerce_enum.
275 (value_x_unop): Likewise.
276 (value_logical_not): Call coerce_array instead of coerce_number.
277
278 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
279
280 * ax-gdb.c: Include "language.h".
281 (gen_frame_args_address): Add GDBARCH parameter; use it
282 instead of current_gdbarch.
283 (gen_frame_locals_address): Likewise.
284 (gen_var_ref): Add GDBARCH parameter. Update calls to
285 gen_frame_args_address and gen_frame_locals_address. Use
286 pointer type from gdbarch.
287 (gen_usual_unary): Add EXP parameter. Use integer type
288 from exp->gdbarch.
289 (gen_usual_arithmetic): Likewise.
290 (gen_integral_promotions): Likewise.
291 (gen_add, gen_sub): Remove.
292 (gen_ptradd, gen_ptrsub, gen_ptrdiff): New functions.
293 (gen_logical_not): Use passed-in boolean result type
294 instead of builtin_type_int.
295 (gen_complement): Do not call gen_usual_unary or
296 gen_integral_promotions.
297 (gen_struct_ref): Call require_rvalue instead of gen_usual_unary.
298 (gen_repeat): Add EXP parameter. Update call to gen_expr.
299 Use builtin_type_int32 as internal range type.
300 (gen_sizeof): Add EXP and SIZE_TYPE parameters. Use SIZE_TYPE
301 as result type. Update call to gen_expr.
302 (gen_expr): Add EXP parameter. Update calls to gen_expr,
303 gen_repeat, gen_var_ref, gen_usual_unary, gen_usual_arithmetic,
304 and gen_integral_promotions. Call gen_ptradd, gen_ptrsub,
305 gen_ptrdiff, or gen_binop instead of gen_add or gen_sub.
306 Use exp->gdbarch instead of current_gdbarch.
307 Call language_bool_type to determine result type of UNOP_LOGICAL_NOT.
308
309 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
310
311 * eval.c (evaluate_subexp_standard): Add calls to binop_promote
312 and unop_promote before calling value_binop et. al.
313 * ada-lang.c (ada_evaluate_subexp): Add calls to binop_promote
314 and unop_promote before calling value_binop et. al.
315
316 * valarith.c (value_binop): Do not call binop_promote or unop_promote.
317 (value_pos): Do not call unop_promote.
318 (value_neg, value_complement): Likewise.
319
320 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
321
322 * value.h (unop_promote, binop_promote): Add prototypes.
323 * eval.c (unop_promote, binop_promote): New functions.
324 * valarith.c (unop_result_type, binop_result_type): Remove.
325 (value_binop): Call binop_promote or unop_promote.
326 Inline remaining parts of binop_result_type. Remove special
327 code to truncate integer values for unsigned operations.
328 (value_pos): Call unop_promote. Inline remaining parts of
329 unop_result_type.
330 (value_neg, value_complement): Likewise.
331
332 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
333
334 * value.h (value_add, value_sub): Remove.
335 (value_ptradd, value_ptrsub, value_ptrdiff): Add prototypes.
336 * valarith.c (value_add, value_sub): Remove.
337 (value_ptradd, value_ptrsub, value_ptrdiff): New functions.
338 (find_size_for_pointer_math): Add assertion. Update comment.
339 (value_binop): Update comment.
340
341 * eval.c (ptrmath_type_p): New function.
342 (evaluate_subexp_standard): Replace value_add and value_sub
343 by value_ptradd, value_ptrsub, value_ptrdiff or value_binop.
344 Use builtin_type_uint8 instead of builtin_type_char to hold
345 the increment for BINOP_{PRE,POST}{IN,DE}CREMENT operations.
346 * valarith.c (value_subscript): Replace value_add by
347 value_ptradd. Replace value_sub by value_binop.
348 * ada-lang.c (ada_value_ptr_subscript): Likewise.
349 (ada_tag_name_2): Replace value_add by value_ptradd.
350 (ada_evaluate_subexp): Replace value_add and value_sub by
351 value_binop.
352 * m2-lang.c (evaluate_subexp_modula2): Replace value_add
353 by value_ptradd.
354 * gnu-v2-abi.c (gnuv2_virtual_fn_field): Likewise.
355 * gnu-v3-abi.c (gnuv3_method_ptr_to_value): Likewise.
356
357 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
358
359 * eval.c (evaluate_subexp_for_sizeof): Use builtin_int type of
360 the expression architecture instead of builtin_type_int as the
361 sizeof return type.
362
363 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
364
365 * expression.h (enum exp_opcode): Document OP_COMPLEX to take
366 a type parameter as expression element.
367 * eval.c (evaluate_subexp_standard) [OP_COMPLEX]: Retrieve result
368 type as expression element.
369 * f-exp.y: Pass in type when buildin OP_COMPLEX expression.
370 * parse.c (operator_length_standard): Update length of OP_COMPLEX.
371
372 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
373
374 * language.h (struct language_arch_info): New members
375 bool_type_default and bool_type_symbol.
376 (lang_bool_type): Remove prototype.
377 (LA_BOOL_TYPE): Remove macro.
378 (language_bool_type): Add prototype.
379 * language.c (lang_bool_type): Remove.
380 (language_bool_type): New function.
381
382 * value.h (value_in): Change return value to int.
383 * value.c (value_in): Return int instead of struct value *.
384
385 * eval.c (evaluate_subexp_standard): Call language_bool_type instead
386 of using LA_BOOL_TYPE. Update call to value_in.
387 * ada-lang.c (ada_evaluate_subexp): Call language_bool_type instead
388 of using LA_BOOL_TYPE or builtin_type_int for boolean values.
389
390 * language.c (unknown_language_arch_info): Set bool_type_default member
391 of struct language_arch_info.
392 * ada-lang.c (ada_language_arch_info): Set bool_type_symbol and
393 bool_type_default members of struct language_arch_info.
394 * c-lang.c (c_language_arch_info): Set bool_type_default member
395 of struct language_arch_info.
396 (cplus_language_arch_info): Set bool_type_symbol and bool_type_default
397 members of struct language_arch_info.
398 * f-lang.c (f_language_arch_info): Set bool_type_symbol and
399 bool_type_default members of struct language_arch_info.
400 * jv-lang.c (java_language_arch_info): Set bool_type_symbol and
401 bool_type_default members of struct language_arch_info.
402 * m2-lang.c (m2_language_arch_info): Set bool_type_symbol and
403 bool_type_default members of struct language_arch_info.
404 * p-lang.c (p_language_arch_info): Set bool_type_symbol and
405 bool_type_default members of struct language_arch_info.
406
407 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
408
409 * jv-lang.c (enum java_primitive_types): New type.
410 (java_language_arch_info): New function.
411 (java_language): Use it instead of c_language_arch_info.
412
413 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
414
415 * value.h (value_bitstring_subscript): New prototype.
416 * valarith.h (value_bitstring_subscript): New function.
417 (value_subscript): No longer handle TYPE_CODE_BITSTRING.
418 * eval.c (evaluate_subexp_standard): Call value_bitstring_subscript
419 instead of value_subscript to handle TYPE_CODE_BITSTRING.
420
421 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
422
423 * expression.h (struct expression): New member GDBARCH.
424 * parse.c (parse_exp_in_context): Initialize it.
425 * parser-def.h (parse_gdbarch, parse_language): New macros.
426
427 * ada-exp.y (parse_type): New macro.
428 Replace builtin_type_ macros by using parse_type.
429 Replace current_language by parse_language.
430 * ada-lex.l (processInt): Replace current_gdbarch by parse_gdbarch.
431 Replace builtin_type_ macros.
432
433 * c-exp.y (parse_type): New macro.
434 Replace builtin_type_ macros by using parse_type.
435 (parse_number): Replace current_gdbarch by parse_gdbarch.
436 (yylex): Replace current_language by parse_language.
437
438 * f-exp.y (parse_type, parse_f_type): New macros.
439 Replace builtin_type_ macros by using parse_{f_,}type.
440 (parse_number): Replace current_gdbarch by parse_gdbarch.
441 (yylex): Replace current_language by parse_language.
442
443 * jv-exp.y (parse_type): New macro.
444 (parse_number): Replace builtin_type_ macros by using parse_type.
445
446 * m2-exp.y (parse_type, parse_m2_type): New macros.
447 Replace builtin_type_ macros by using parse_{m2_,}type.
448
449 * objc-exp.y (parse_type): New macro.
450 Replace builtin_type_ macros by using parse_type.
451 (parse_number): Replace current_gdbarch by parse_gdbarch.
452 (yylex): Replace current_language by parse_language.
453
454 * p-exp.y (parse_type): New macro.
455 Replace builtin_type_ macros by using parse_type.
456 (parse_number): Replace current_gdbarch by parse_gdbarch.
457 (yylex): Replace current_language by parse_language.
458
459 2008-09-11 Ulrich Weigand <uweigand@de.ibm.com>
460
461 * parser-defs.h (write_exp_msymbol): Remove TEXT_SYMBOL_TYPE
462 and DATA_SYMBOL_TYPE arguments.
463 * parse.c (write_exp_msymbol): Remove TEXT_SYMBOL_TYPE and
464 DATA_SYMBOL_TYPE arguments. Replace use of builtin_type_CORE_ADDR.
465 (write_dollar_variable): Update call.
466
467 * ada-exp.y (write_var_or_type): Update call.
468 * c-exp.y: Likewise.
469 * f-exp.y: Likewise.
470 * jv-exp.y: Likewise.
471 * m2-exp.y: Likewise.
472 * objc-exp.y: Likewise.
473 * p-exp.y: Likewise.
474
475 2008-09-10 Joel Brobecker <brobecker@adacore.com>
476
477 * ada-lang.c (ada_parent_type): Add handling of the case where
478 the _parent field is a pointer and/or has a parallel XVS type.
479 (ada_evaluate_subexp) [OP_VAR_VALUE]: When doing an
480 EVAL_AVOID_SIDE_EFFECTS evaluation of a tagged type, return
481 the type of the tag instead of doing forcing an EVAL_NORMAL
482 expression evaluation.
483
484 2008-09-10 Paul N. Hilfinger <hilfinger@adacore.com>
485 Joel Brobecker <brobecker@adacore.com>
486
487 * ada-lang.c (is_digits_suffix): New function.
488 (is_dot_digits_suffix): Remove.
489 (ada_lookup_symbol_list): Remove digits suffix from minimal symbols
490 before looking up in symbol table, and do not use wild matches on them.
491 (wild_match): Reimplement for speed and to allow matching of operator
492 symbols.
493 (is_valid_name_for_wild_match): Return zero for names that do not
494 follow the GNAT encoding.
495
496 (is_name_suffix): Fix typo in comment.
497 (to_record_with_fixed_variant_part): Ditto.
498
499 2008-09-10 Pedro Alves <pedro@codesourcery.com>
500
501 * Makefile.in (gnu-nat.o): New rule.
502
503 2008-09-10 Joel Brobecker <brobecker@adacore.com>
504
505 * ada-lang.c (ada_evaluate_subexp) [OP_ATR_SIZE]: Use
506 archecture-neutral builtin_type_int32 instead of builtin_type_int.
507
508 2008-09-10 Joel Brobecker <brobecker@adacore.com>
509
510 * ada-lang.c (ada_evaluate_subexp) [BINOP_ADD, BINOP_SUB]:
511 Add special handling for pointer types.
512
513 2008-09-10 Pedro Alves <pedro@codesourcery.com>
514
515 * inf-ttrace.c (inf_ttrace_follow_fork): Declare locals at the
516 right scope level.
517 (inf_ttrace_resume, inf_ttrace_wait): Typos.
518
519 2008-09-10 Ulrich Weigand <uweigand@de.ibm.com>
520
521 * ada-lang.c (ada_array_length): Use builtin_type_int32 instead
522 of builtin_type_int.
523 (ada_evaluate_subexp) [UNOP_IN_RANGE]: Use operand range type
524 instead of builtin_type_int.
525
526 2008-09-09 Pedro Alves <pedro@codesourcery.com>
527
528 * infrun.c (normal_stop): Run hook-stop last.
529
530 2008-09-09 Pedro Alves <pedro@codesourcery.com>
531
532 * gnu-nat.c (gnu_pid_to_exec_file): Delete.
533 (init_gnu_ops): Don't register it.
534
535 2008-09-09 Pedro Alves <pedro@codesourcery.com>
536
537 * gnu-nat.c (gnu_attach): Push target before fetching the list of
538 threads.
539
540 2008-09-08 Daniel Jacobowitz <dan@codesourcery.com>
541
542 * valops.c (value_cast_structs): Return NULL for failure.
543 (value_cast): Handle NULL from value_cast_structs.
544 (value_fetch_lazy): Call check_typedef. Remove unused variable.
545
546 2008-09-08 Pedro Alves <pedro@codesourcery.com>
547
548 * inferior.h (context_switch_to): Delete.
549 * infrun.c (context_switch): Don't save and load infrun state.
550 (context_switch_to): Delete.
551
552 * infcmd.c (proceed_thread_callback): Replace context_switch_to
553 calls by switch_to_thread calls.
554
555 * gdbthread.h (save_infrun_state, load_infrun_state): Delete.
556 * thread.c (main_thread_state, main_thread_executing): Delete.
557 (inferior_thread): Delete references to them.
558 (add_thread_silent): Fix case where we're adding a thread with the
559 same ptid as an exited thread. Remove references to
560 context-switching.
561 (load_infrun_state, save_infrun_state): Delete.
562 (thread_alive, is_thread_state, any_running, is_executing)
563 (set_executing): Remove the special handling for targets that
564 don't register any thread.
565 (restore_current_thread, thread_apply_all_command)
566 (do_captured_thread_select): Unconditionally call
567 switch_to_thread.
568
569 * mi/mi-main.c (mi_cmd_execute): Check for exited threads.
570 Call switch_to_thread instead of context_switch_to.
571
572 2008-09-08 Pedro Alves <pedro@codesourcery.com>
573
574 Remove global continuations in favour of a per-thread
575 continuations.
576
577 * gdbthread.h (struct thread_info): Add comments around
578 continuations and intermediate_continuations.
579 (save_infrun_state, load_infrun_state): Delete continuations and
580 intermediate_continuations arguments.
581 * infrun.c (context_switch): Don't context-switch the continuations.
582 * thread.c (clear_thread_inferior_resources): Discard all
583 continuations of the thread we're clearing.
584 (save_infrun_state, load_infrun_state): Delete continuations and
585 intermediate_continuations arguments, and the code referencing
586 them.
587 * utils.c: Include "gdbthread.h".
588 (cmd_continuation, intermediate_continuation): Delete.
589 (add_continuation): Add thread_info* argument. Install the
590 continuation on it.
591 (restore_thread_cleanup): New.
592 (do_all_continuations_ptid, do_all_continuations_thread_callback):
593 New.
594 (do_all_continuations): Reimplement.
595 (discard_all_continuations_thread_callback,
596 discard_all_continuations_thread): New.
597 (discard_all_continuations): Reimplement.
598 (add_intermediate_continuation): Add thread_info* argument.
599 Install the continuation on it.
600 (do_all_intermediate_continuations_thread_callback)
601 (do_all_intermediate_continuations_thread): New.
602 (do_all_intermediate_continuations): Reimplement.
603 (discard_all_intermediate_continuations_thread_callback): New.
604 (discard_all_intermediate_continuations_thread): New.
605 (discard_all_intermediate_continuations): Reimplement.
606
607 * breakpoint.c (until_break_command): Install the continuation on
608 the current thread.
609
610 * defs.h (cmd_continuation, intermediate_continuation): Delete.
611 (struct thread_info): Forward declare.
612 (add_continuation, add_intermediate_continuation): Add
613 thread_info* argument.
614 (do_all_continuations_thread, discard_all_continuations_thread)
615 (do_all_intermediate_continuations_thread)
616 (discard_all_intermediate_continuations_thread): Declare.
617 * inf-loop.c (inferior_event_handler): In non-stop only run
618 continuations on the thread that stopped. In all-stop, run
619 continuations on all threads.
620 * infcmd.c (step_once, finish_command): Adjust.
621
622 2008-09-08 Pedro Alves <pedro@codesourcery.com>
623
624 Remove the global stop_step in favour of a per-thread
625 stop_step.
626
627 * inferior.h (stop_step): Delete.
628
629 * gdbthread.h (struct thread_info): Add comments to stop_step.
630 (save_infrun_state, load_infrun_state): Remove stop_step argument.
631 * thread.c (load_infrun_state, save_infrun_state): Remove
632 stop_step argument, and references to it.
633
634 * infrun.c (clear_proceed_status): Clear stop_step.
635 (fetch_inferior_event): Adjust.
636 (context_switch): Don't context-switch stop_step.
637 (handle_inferior_event): Adjust.
638 (normal_stop): Adjust.
639 (save_inferior_status, restore_inferior_status): Adjust.
640
641 * infcmd.c (stop_step): Delete.
642 (step_1, step_1_continuation, step_once, until_next_command):
643 Adjust.
644
645 2008-09-08 Pedro Alves <pedro@codesourcery.com>
646
647 Remove the global step_multi in favour of a per-thread
648 step_multi.
649
650 * inferior.h (step_multi): Delete.
651 * gdbthread.h (struct thread_info): Add comments around
652 step_multi.
653 (save_infrun_state, load_infrun_state): Remove step_multi
654 parameter.
655 * thread.c (load_infrun_state, save_infrun_state): Remove
656 step_multi argument, and references to it.
657 * infcmd.c (step_multi): Delete.
658 (step_1): Adjust.
659 (step_1_continuation, until_next_command): Adjust.
660 * infrun.c (fetch_inferior_event): Adjust.
661 (context_switch): Don't context-switch step_multi.
662 (print_stop_reason, normal_stop): Adjust.
663
664 2008-09-08 Pedro Alves <pedro@codesourcery.com>
665
666 Remove the global stop_signal in favour of a per-thread
667 stop_signal.
668
669 * inferior.h (stop_signal): Delete.
670 * gdbthread.h (save_infrun_state, load_infrun_state): Remove
671 stop_signal argument.
672 * thread.c (load_infrun_state, save_infrun_state): Remove
673 stop_signal argument. Don't reference it.
674
675 * infcmd.c (stop_signal): Delete.
676 (program_info): Adjust.
677 * infrun.c (resume): Clear stop_signal.
678 (proceed): Adjust. Pass the last stop_signal to the thread we're
679 resuming.
680 (context_switch): Don't context-switch stop_signal.
681 (handle_inferior_event, keep_going): Adjust.
682 (save_inferior_status, restore_inferior_status): Adjust.
683
684 * fbsd-nat.c: Include "gdbthread.h".
685 (find_signalled_thread, find_stop_signal): New.
686 (fbsd_make_corefile_notes): Use it.
687 * fork-child.c (startup_inferior): Adjust.
688
689 * linux-nat.c (get_pending_status): Adjust.
690 (linux_nat_do_thread_registers): Adjust.
691 (find_signalled_thread, find_stop_signal): New.
692 (linux_nat_do_thread_registers): Add stop_signal parameter.
693 (struct linux_nat_corefile_thread_data): Add stop_signal member.
694 (linux_nat_corefile_thread_callback): Pass stop_signal.
695 (linux_nat_do_registers): Delete.
696 (linux_nat_make_corefile_notes): Use find_stop_signal. Assume
697 there's always a thread.
698
699 * procfs.c (find_signalled_thread, find_stop_signal): New.
700 (find_stop_signal): New.
701 (procfs_do_thread_registers): Add stop_signal parameter.
702 (struct procfs_corefile_thread_data): Add stop_signal member.
703 (procfs_corefile_thread_callback): Pass args->stop_signal.
704 (procfs_make_note_section): Find the last stop_signal.
705
706 * solib-irix.c: Include gdbthread.h.
707 (irix_solib_create_inferior_hook): Adjust.
708 * solib-osf.c: Include gdbthread.h.
709 (osf_solib_create_inferior_hook): Adjust.
710 * solib-sunos.c: Include gdbthread.h.
711 (sunos_solib_create_inferior_hook): Adjust.
712 * solib-svr4.c: Include gdbthread.h.
713 (svr4_solib_create_inferior_hook): Adjust.
714
715 * win32-nat.c (do_initial_win32_stuff): Adjust.
716
717 2008-09-08 Pedro Alves <pedro@codesourcery.com>
718
719 * gdbthread.h (struct thread_info): Add comments around
720 proceed_to_finish.
721 (save_infrun_state, load_infrun_state): Remove proceed_to_finish
722 argument.
723 * thread.c (load_infrun_state, save_infrun_state): Delete
724 proceed_to_finish argument and references to it.
725
726 * infcall.c (call_function_by_hand): Adjust.
727 * infcmd.c (finish_command): Adjust.
728 * infrun.c (proceed_to_finish): Delete.
729 (clear_proceed_status): Adjust.
730 (context_switch): Don't context-switch proceed_to_finish.
731 (normal_stop, save_inferior_status, restore_inferior_status):
732 Adjust.
733
734 2008-09-08 Pedro Alves <pedro@codesourcery.com>
735
736 * inferior.h (stop_bpstat): Delete.
737
738 * breakpoint.h (bpstat_do_actions): Remove bpstat* argument.
739
740 * breakpoint.c (bpstat_do_actions): Rename to ...
741 (bpstat_do_actions_1): ... this. Make static. Change return type
742 to int. Return true if a breakpoint proceeded.
743 (bpstat_do_actions): New, as wrapper around bpstat_do_actions_1.
744 (delete_breakpoint): Don't reference the global stop_bpstat; it's
745 gone.
746
747 * gdbthread.h (struct thread_info): Add stop_bpstat.
748 (save_infrun_state, load_infrun_state): Remove stop_bpstat
749 argument.
750 * thread.c (load_infrun_state, save_infrun_state): Remove
751 stop_bpstat argument, and the code referencing it.
752
753 * infcall.c: Include "gdbthread.h".
754 (call_function_by_hand): Adjust.
755 * exceptions.c: Include "gdbthread.h".
756 (throw_exception): Adjust.
757 * infcmd.c (stop_bpstat): Delete.
758 (continue_command): In all-stop, set the ignore count on the
759 thread that reported the stop. In non-stop, set it on the current
760 thread.
761 (finish_command_continuation): Adjust.
762 (program_info): Adjust.
763 * infrun.c (clear_proceed_status): Adjust.
764 (context_switch): Don't context-switch stop_bpstat.
765 (handle_inferior_event): Adjust.
766 (normal_stop): Adjust.
767 (save_inferior_status, restore_inferior_status): Adjust.
768
769 * inf-loop.c (inferior_event_handler): Remove parameter to
770 bpstat_do_actions call.
771 * top.c (command_loop): Remove parameter to bpstat_do_actions
772 call. Call it unconditionally.
773 * event-top.c (command_handler): Ditto.
774 * python/python.c (execute_gdb_command): Ditto.
775
776 2008-09-08 Pedro Alves <pedro@codesourcery.com>
777
778 * inferior.h (step_over_calls): Delete.
779
780 * gdbthread.h (save_infrun_state, load_infrun_state): Remove
781 step_over_calls argument.
782 * thread.c (save_infrun_state, load_infrun_state): Remove
783 step_over_calls argument. Adjust.
784
785 * infcmd.c (step_over_calls): Delete.
786 (step_1): Adjust.
787 * infrun.c (clear_proceed_status): Adjust.
788 (context_switch): Don't context-switch step_over_calls.
789 (handle_inferior_event, save_inferior_status)
790 (restore_inferior_status): Adjust.
791
792 2008-09-08 Pedro Alves <pedro@codesourcery.com>
793
794 Remove context switching in favour of accessing thread_info fields
795 directly.
796
797 * infrun.c (stepping_over_breakpoint, step_resume_breakpoint):
798 Delete.
799 (struct thread_stepping_state): Delete.
800 (gtss, tss): Delete.
801 (follow_inferior_reset_breakpoints, follow_exec)
802 (resume, clear_proceed_status): Adjust.
803 (prev_pc): Delete.
804 (proceed, start_remote, init_wait_for_inferior): Adjust.
805 (struct execution_control_state): Add event_thread member.
806 (delete_step_resume_breakpoint_callback)
807 (delete_step_thread_step_resume_breakpoint)
808 (delete_step_thread_step_resume_breakpoint_cleanup)
809 (delete_step_thread_step_resume_breakpoint): New.
810 (wait_for_inferior, init_execution_control_state): Use
811 delete_step_thread_step_resume_breakpoint_cleanup.
812 (wait_for_inferior): Set the event_thread.
813 (fetch_inferior_event): Ditto. Delete the step-resume breakpoint
814 with delete_step_thread_step_resume_breakpoint.
815 (init_thread_stepping_state): Change parameter type to
816 thread_info. Adjust.
817 (context_switch): Don't context switch prev_pc,
818 stepping_over_breakpoint, step_resume_breakpoint,
819 step_range_start, step_range_end, step_frame_id,
820 tss->stepping_over_breakpoint,
821 tss->stepping_through_solib_after_catch,
822 tss->stepping_through_solib_catchpoints, tss->current_line, or
823 tss->current_symtab.
824 (adjust_pc_after_break, handle_inferior_event)
825 (currently_stepping, step_into_function)
826 (insert_step_resume_breakpoint_at_sal)
827 (insert_longjmp_resume_breakpoint, keep_going): Adjust.
828 (clear_stepping_state): New.
829 (normal_stop): Adjust.
830 (save_inferior_status, restore_inferior_status): Adjust.
831
832 * gdbthread.h (struct thread_info): Comments describing the
833 members moved here. Add step_after_step_resume_breakpoint.
834 (delete_step_resume_breakpoint): Add thread_info argument.
835 (save_infrun_state, load_infrun_state): Remove prev_pc,
836 trap_expected, step_resume_breakpoint, step_range_start,
837 step_range_end, step_frame_id, another_trap,
838 stepping_through_solib_after_catch,
839 stepping_through_solib_catchpoints, current_line and
840 current_symtab function arguments.
841 (inferior_thread): Declare.
842
843 * thread.c (inferior_thread): New.
844 (delete_step_resume_breakpoint): Add a thread_info parameter and
845 rewrite.
846 (load_infrun_state, save_infrun_state): Remove prev_pc,
847 trap_expected, step_resume_breakpoint, step_range_start,
848 step_range_end, step_frame_id, stepping_over_breakpoint,
849 stepping_through_solib_after_catch,
850 stepping_through_solib_catchpoints, current_line and
851 current_symtab args. Remove code referencing them.
852
853 * infcmd.c (step_range_start, step_range_end, step_frame_id):
854 Delete.
855 (step_1, step_once, until_next_command): Adjust.
856
857 * inferior.h (step_range_start, step_range_end, step_frame_id):
858 Delete.
859
860 * linux-nat.c (linux_child_follow_fork): If following the child,
861 move the step state to it. Adjust.
862 * inf-ptrace.c (inf_ptrace_follow_fork): Ditto.
863 * inf-ttrace.c (inf_ttrace_follow_fork): Ditto.
864
865 2008-09-08 Pedro Alves <pedro@codesourcery.com>
866
867 * bsd-uthread.c (bsd_uthread_find_new_threads): Claim the main
868 thread.
869
870 2008-09-08 Pedro Alves <pedro@codesourcery.com>
871
872 * corelow.c (add_to_thread_list): If this is the first time we
873 hear about thread info, update inferior_ptid.
874 (core_open): Clear the thread list and set inferior_ptid before
875 acknowledging a new inferior. Find threads before fetching
876 register info. Give an upper target layer a chance to find and
877 claim new threads. Print core generation and stop signal info
878 after finding new threads.
879 (get_core_register_section): Look at the lwp member of
880 inferior_ptid for detecting if we have threads info, instead of
881 the pid member.
882 (core_pid_to_str): New.
883 (init_core_ops): Register core_pid_to_str.
884
885 2008-09-08 Pedro Alves <pedro@codesourcery.com>
886
887 * spu-linux-nat.c (spu_child_post_startup_inferior)
888 (spu_child_post_attach): Don't add the main thread here.
889
890 2008-09-08 Pedro Alves <pedro@codesourcery.com>
891
892 Use ptid_t.tid to store thread ids instead of ptid_t.pid.
893
894 * gnu-nat.c (inf_validate_procs): If this is the first time we're
895 seeing a thread id, extend the main thread's ptid. If we still
896 have pending execs, don't be verbose about new threads.
897 (gnu_wait, gnu_resume, gnu_attach, gnu_thread_alive)
898 (gnu_pid_to_str, cur_thread, sig_thread_cmd): Adjust.
899 * i386gnu-nat.c (gnu_fetch_registers, gnu_store_registers):
900 Adjust.
901
902 2008-09-08 Pedro Alves <pedro@codesourcery.com>
903
904 * procfs.c (to_attach): Create a procinfo for the current lwp.
905 Add it to gdb's thread list.
906 (procfs_fetch_registers, procfs_store_registers): Assume there's
907 always an lwp.
908 (procfs_wait): Don't add the main thread here.
909 (procfs_init_inferior): Create a procinfo for the main lwp here.
910 Change main thread's ptid with thread_change_ptid.
911 (procfs_notice_thread): Check for exited threads.
912 (procfs_corefile_thread_callback): Remove check for the main
913 process.
914 (procfs_make_note_section): Assume there is always a thread.
915
916 * sol-thread.c (sol_thread_attach): Clear sol_thread_active before
917 attaching. Change the main thread ptid with thread_change_ptid.
918 (sol_thread_detach): Clear sol_thread_active.
919 (sol_thread_wait): Check for exited threads.
920 (sol_thread_create_inferior): Clear sol_thread_active before
921 creating a new inferior. Change the main thread ptid with
922 thread_change_ptid.
923 (sol_thread_mourn_inferior): Clear sol_thread_active.
924 (sol_find_new_threads_callback): Check for exited threads.
925
926 2008-09-08 Pedro Alves <pedro@codesourcery.com>
927
928 * inf-ttrace.c (inf_ttrace_wait): On TTEVT_LWP_CREATE and
929 LWP_TERMINATE, resume the caller thread. On TTEVT_LWP_CREATE,
930 TTEVT_LWP_EXIT and TTEVT_LWP_TERMINATE, don't stop the whole
931 process, and return TARGET_WAITKIND_IGNORE.
932
933 2008-09-08 Pedro Alves <pedro@codesourcery.com>
934
935 * inf-ttrace.c: Include <signal.h>
936 (inf_ttrace_delete_dead_threads_callback): New.
937 (inf_ttrace_resume_lwp): New.
938 (inf_ttrace_resume_callback, inf_ttrace_resume): Rewrite. Don't
939 delete dying threads until they are really dead.
940 (inf_ttrace_wait): After stopping the whole process, delete any
941 dying thread that is really dead by now.
942 (inf_ttrace_thread_alive): Return 1.
943 (inf_ttrace_extra_thread_info): New.
944 (inf_ttrace_target): Register inf_ttrace_extra_thread_info.
945
946 2008-09-08 Pedro Alves <pedro@codesourcery.com>
947
948 * inf-ttrace.c (inf_ttrace_follow_fork): Register the main thread
949 of the child fork.
950 (inf_ttrace_attach): Add the main thread.
951 (inf_ttrace_resume_callback): Check for exited threads. Adjust
952 for always a thread.
953 (inf_ttrace_wait): Decorate the main thread's ptid with lwp info
954 using thread_change_ptid, and set its private data. Don't add the
955 main thread here.
956 (inf_ttrace_pid_to_str): Adjust.
957
958 2008-09-08 Pedro Alves <pedro@codesourcery.com>
959
960 * bsd-uthread.c (bsd_uthread_wait): Decorate the main thread with
961 thread_change_ptid. Check for exited threads.
962 (bsd_uthread_find_new_threads): Check for exited threads.
963
964 2008-09-08 Pedro Alves <pedro@codesourcery.com>
965
966 * inf-ptrace.c: Include "gdbthread.h".
967 (inf_ptrace_attach): Add the main thread here.
968 * linux-nat.c (linux_nat_attach): Don't add the main thread here.
969 Decorate the main thread id with the lwp id.
970
971 2008-09-08 Pedro Alves <pedro@codesourcery.com>
972
973 * linux-nat.c (linux_nat_wait): Update inferior_ptid's ptid with
974 thread_change_ptid. Don't add or mark the main thread as running
975 and executing here.
976 * fork-child.c (fork_inferior): Add the main thread here.
977
978 2008-09-08 Jerome Guitton <guitton@adacore.com>
979
980 * rs6000-tdep.c (rs6000_fetch_instruction)
981 (rs6000_skip_stack_check): New functions.
982 (skip_prologue): Skip stack check sequence.
983
984 2008-09-08 David Daney <ddaney@avtrex.com>
985
986 * dummy-frame.h (frame.h): Include it.
987 (struct frame_id): Remove declaration.
988
989 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
990
991 * spu-tdep.c (spu_push_dummy_code): New function.
992 (spu_gdbarch_init): Install it.
993
994 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
995
996 * gdbarch.sh (gdbarch_dump): Use core_addr_to_string_nz
997 instead of paddr_nz.
998 * gdbarch.c: Regenerate.
999
1000 * target.c (target_xfer_partial, debug_print_register): Use
1001 core_addr_to_string_nz instead of paddr_nz.
1002
1003 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1004
1005 * rs6000-tdep.c (rs6000_gdbarch_init): Setup displaced stepping
1006 *before* calling gdbarch_init_osabi.
1007 (rs6000_aix_init_osabi): Disable displaced stepping.
1008
1009 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1010
1011 * target.c (update_current_target): Do not inherit to_open
1012 or to_close.
1013 (pop_target): Call target_close on target_stack instead
1014 of current_target.
1015 (pop_all_targets_above): Likewise.
1016
1017 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1018
1019 * gnu-v3-abi.c (gnuv3_decode_method_ptr): New function.
1020 (gnuv3_print_method_ptr): Use it.
1021 (gnuv3_method_ptr_to_value): Likewise.
1022
1023 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1024
1025 * nto-tdep.h (struct nto_target_ops): Add gdbarch parameter to
1026 register_area callback function.
1027 * i386-nto-tdep.c (i386nto_register_area): Add gdbarch parameter.
1028 Use it instead of current_gdbarch.
1029 * nto-procfs.c (procfs_store_registers): Update call.
1030
1031 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1032
1033 * mips-tdep.c (deprecated_mips_set_processor_regs_hack): Use
1034 regcache architecture instead of current_gdbarch.
1035
1036 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1037
1038 * mep-tdep.c (struct mep_prologue): Add gdbarch member.
1039 (check_for_saved): Use it instead of current_gdbarch.
1040 (is_arg_spill): Add gdbarch paramter. Use it instead
1041 of current_gdbarch.
1042 (mep_analyze_prologue): Add gdbarch parameter. Pass it
1043 to is_arg_spill and check_for_saved.
1044 (mep_skip_prologue, mep_analyze_frame_prologue): Update calls.
1045
1046 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1047
1048 * hppa-tdep.c (internalize_unwinds): Use objfile architecture
1049 instead of current_gdbarch.
1050
1051 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1052
1053 * m68k-tdep.h (m68kbsd_fpreg_offset): Add gdbarch parameter.
1054 * m68kbsd-tdep.c (m68kbsd_fpreg_offset): Add gdbarch paramter.
1055 Use it instead of current_gdbarch.
1056 (m68kbsd_supply_fpregset): Update call.
1057 * m68kbsd-nat.c (m68kbsd_supply_fpregset): Likewise.
1058 (m68kbsd_collect_fpregset): Likewise.
1059
1060 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1061
1062 * cris-tdep.c (cris_version, cris_mode): Remove.
1063 (crisv32_single_step_through_delay): Use tdep->cris_mode.
1064 (cris_breakpoint_from_pc): Likewise.
1065 (cris_frame_unwind_cache): Use tdep->cris_version.
1066 (crisv32_scan_prologue): Likewise.
1067 (cris_spec_reg_applicable): Add gdbarch argument.
1068 Use tdep->cris_version.
1069 (cris_register_size, cris_special_register_name): Update calls.
1070 (cris_special_register_name): Add gdbarch argument.
1071 (cris_register_name, crisv32_register_name): Update calls.
1072
1073 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1074
1075 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Use info->arch
1076 instead of current_gdbarch.
1077
1078 * sh64-tdep.c (gdb_print_insn_sh64): Remove.
1079 (sh64_gdbarch_init): Install print_insn_sh64 directly.
1080 * sh-tdep.c (gdb_print_insn_sh): Remove.
1081 (sh_gdbarch_init): Install print_insn_sh directly.
1082
1083 * mips-tdep.c (gdb_print_insn_mips): Do not check mips_abi
1084 from current_gdbarch.
1085 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): New functions.
1086 (mips_gdbarch_init): Install them instead of gdb_print_insn_mips
1087 depending on mips_abi.
1088
1089 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1090
1091 * gdbarch.sh (addr_bits_remove): Change type to 'm'.
1092 (smash_text_address): Likewise.
1093 * gdbarch.c, gdbarch.h: Regenerate.
1094
1095 * arch-utils.c (core_addr_identity): Add gdbarch parameter.
1096 * arch-utils.h (core_addr_identity): Likewise.
1097 * arm-tdep.c (arm_addr_bits_remove): Likewise.
1098 (arm_smash_text_address): Likewise.
1099 * hppa-tdep.c (hppa_smash_text_address): Likewise.
1100 * m88k-tdep.c (m88k_addr_bits_remove): Likewise.
1101 * s390-tdep.c (s390_addr_bits_remove): Likewise.
1102
1103 * mips-tdep.c (mips_addr_bits_remove): Add gdbarch parameter.
1104 Use it instead of current_gdbarch.
1105
1106 * arm-tdep.c (arm_prologue_prev_register, arm_unwind_pc,
1107 arm_dwarf2_prev_register): Update calls.
1108 * m88k-tdep.c (m88k_unwind_pc): Update call.
1109
1110 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1111
1112 * dwarf2expr.h (dwarf2_read_address): Add gdbarch argument.
1113 * dwarf2expr.c (dwarf2_read_address): Add gdbarch argument.
1114 Call gdbarch_integer_to_address directly instead of converting
1115 to value and back. Update comment.
1116 (execute_stack_op): Update call site.
1117 * dwarf2loc.c (find_location_expression): Likewise.
1118 (locexpr_describe_location): Update
1119
1120 * dwarf2expr.h (struct dwarf_expr_context): Add gdbarch member.
1121 * dwarf2-frame.c (execute_stack_op): Initialize ctx->gdbarch.
1122 * dwarf2loc. (dwarf2_evaluate_loc_desc): Likewise.
1123 (dwarf2_loc_desc_needs_frame): Likewise.
1124
1125 2008-09-05 Ulrich Weigand <uweigand@de.ibm.com>
1126
1127 * breakpoint.h (struct bp_location): Change type of section
1128 member to "struct obj_section *".
1129 * tracepoint.h (struct tracepoint): Likewise.
1130 * symtab.h (struct general_symbol_info): Replace bfd_section
1131 member with obj_section.
1132 (struct symtab_and_line): Change type of section member to
1133 "struct obj_section *".
1134 (SYMBOL_BFD_SECTION): Remove macro, replace by ...
1135 (SYMBOL_OBJ_SECTION): ... this.
1136
1137 * minsym.c (prim_record_minimal_symbol_and_info): Record symbol
1138 section as obj_section instead of bfd_section.
1139
1140 * ada-lang.c (ada_decode_symbol): Use gsymbol->obj_section
1141 directly instead of looking of obj_section from bfd_section.
1142
1143 * objfiles.h (find_pc_sect_section): Remove.
1144 * objfiles.c (find_pc_sect_section): Remove.
1145 (find_pc_section): Inline find_pc_sect_section code.
1146
1147 * symfile.h (find_pc_overlay): Return struct obj_section *.
1148 (find_pc_mapped_section): Likewise.
1149 (section_is_overlay, section_is_mapped): Change type of section
1150 argument to struct obj_section *.
1151 (pc_in_mapped_range, pc_in_unmapped_range): Likewise.
1152 (overlay_mapped_address, overlay_unmapped_address): Likewise.
1153 (symbol_overlayed_address): Likewise.
1154 * symtab.h (symbol_overlayed_address): Likewise.
1155 * symfile.c (overlay_is_mapped): Remove.
1156 (section_is_mapped): Inline overlay_is_mapped code. Update.
1157 (overlay_invalidate_all): Update.
1158 (section_is_overlay): Change section argument to type
1159 "struct obj_section *". Use bfd_ methods.
1160 (pc_in_unmapped_range): Likewise. Handle relocated sections.
1161 (pc_in_mapped_range): Likewise. Handle relocated sections.
1162 (sections_overlap): Likewise.
1163 (overlay_unmapped_address): Likewise.
1164 (overlay_mapped_address): Likewise.
1165 (symbol_overlayed_address): Likewise.
1166 (find_pc_overlay): Return struct obj_section *.
1167 (find_pc_mapped_section): Likewise.
1168 (list_overlays_command): Update.
1169 (map_overlay_command, unmap_overlay_command): Update.
1170 (simple_overlay_update): Update.
1171
1172 * block.h (blockvector_for_pc_sect): Change section argument
1173 to type "struct obj_section *".
1174 (block_for_pc_sect): Likewise.
1175 * block.c (blockvector_for_pc_sect): Change section argument
1176 to type "struct obj_section *".
1177 (block_for_pc_sect): Likewise.
1178 * symtab.h (find_pc_sect_function, find_pc_sect_psymtab,
1179 find_pc_sect_symtab, find_pc_sect_psymbol, find_pc_sect_line,
1180 lookup_minimal_symbol_by_pc_section, find_function_start_pc): Likewise.
1181 (matching_bfd_sections): Rename to ...
1182 (matching_obj_sections): ... this. Update argument types.
1183 * blockframe.c (find_pc_sect_function): Likewise.
1184 * breakpoint.c (describe_other_breakpoints): Likewise.
1185 (breakpoint_has_pc, check_duplicates_for): Likewise.
1186 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Likewise.
1187 (lookup_minimal_symbol_by_pc_section): Likewise.
1188 * symtab.c (find_pc_sect_psymtab_closer): Likewise.
1189 (find_pc_sect_psymtab, find_pc_sect_psymbol, find_pc_sect_symtab,
1190 find_pc_sect_line, find_function_start_pc): Likewise.
1191 (matching_bfd_sections): Rename to ...
1192 (matching_obj_sections): ... this. Update argument types.
1193
1194 * blockframe.c (find_pc_partial_function): Update to section
1195 type changes. No longer call find_pc_sect_section.
1196 (cache_pc_function_section): Change to type "struct obj_section *".
1197 * breakpoint.c (resolve_sal_pc): Update to section type changes.
1198 * exec.c (xfer_memory): Likewise.
1199 * findvar.c (read_var_value): Likewise.
1200 * infcmd.c (jump_command): Likewise.
1201 * linespec.c (minsym_found): Likewise.
1202 * maint.c (maintenance_translate_address): Likewise.
1203 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Likewise.
1204 (lookup_solib_trampoline_symbol_by_pc): Likewise.
1205 * parse.c (write_exp_msymbol): Likewise.
1206 * printcmd.c (build_address_symbolic): Likewise.
1207 (address_info, sym_info): Likewise.
1208 * symmisc.c (dump_msymbols, print_symbol): Likewise.
1209 * symtab.c (fixup_section): Likewise.
1210 (fixup_symbol_section, fixup_psymbol_section): Likewise.
1211 (find_pc_line, find_function_start_sal): Likewise.
1212 * target.c (memory_xfer_partial): Likewise.
1213 * hppa-hpux-tdep.c (hppa64_hpux_in_solib_call_trampoline): Likewise.
1214 * spu-tdep.c (spu_overlay_update): Likewise.
1215
1216 2008-09-04 Doug Evans <dje@google.com>
1217
1218 * defs.h (plongest,pulongest): Renamed from paddr_u,paddr_d.
1219 Change argument of pulongest from CORE_ADDR to ULONGEST.
1220 All callers updated.
1221 * utils.c (plongest): Renamed from paddr_d.
1222 (pulongest): Renamed from paddr_u, change arg type to ULONGEST.
1223 * remote-mips.c (send_srec): Use paddr_nz instead of paddr_u in
1224 `CORE_ADDR addr' arg of error message.
1225
1226 2008-09-03 Angela Marie Thomas <angela@releasedominatrix.com>
1227
1228 * ser-tcp.c (ser_tcp_send_break): New function.
1229 (_initialize_ser_tcp): Use ser_tcp_send_break.
1230 * ser-tcp.h (ser_tcp_send_break): New prototype.
1231
1232 2008-09-03 Ulrich Weigand <uweigand@de.ibm.com>
1233
1234 * spu-tdep.c (spu_push_dummy_call): Update all stack pointer slots
1235 when allocating stack frame for inferior call.
1236
1237 2008-09-03 Ulrich Weigand <uweigand@de.ibm.com>
1238
1239 * spu-tdep.c (spu_frame_unwind_cache): Do not attempt to unwind
1240 SP or return address if we failed to find a valid frame.
1241
1242 2008-09-03 Aleksandar Ristovski <aristovski@qnx.com>
1243
1244 * breakpoint.c (breakpoint_init_inferior): Mark as not inserted only
1245 non-permanent breakpoints.
1246 (bpstat_stop_status): Change enable_state to bp_disabled only for
1247 non-permanent breakpoints.
1248 (bp_loc_is_permanent): New function.
1249 (create_breakpoint): Check if the location points to a permanent
1250 breakpoint and if it does, make breakpoint permanent.
1251 (update_breakpoint_locations): Make sure new locations of permanent
1252 breakpoints are properly initialized.
1253 * i386-tdep.c (i386_skip_permanent_breakpoint): New function.
1254 (i386_gdbarch_init): Set gdbarch_skip_permanent_breakpoint.
1255
1256 2008-09-02 Pedro Alves <pedro@codesourcery.com>
1257
1258 * breakpoint.c (insert_breakpoints, update_global_location_list):
1259 Check breakpoints_always_inserted_mode instead of
1260 always_inserted_mode directly.
1261
1262 2008-09-02 Andreas Schwab <schwab@suse.de>
1263
1264 * ia64-tdep.c (ia64_get_dyn_info_list): Use obj_section_addr.
1265
1266 2008-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
1267
1268 Stay compatible after the GCC PR fortran/29635 fix.
1269 * dwarf2read.c (process_die <DW_TAG_imported_module>)
1270 (process_die <DW_TAG_imported_module>): Do not assert anything about
1271 these unsupported tags.
1272
1273 2008-08-29 Tom Tromey <tromey@redhat.com>
1274
1275 * maint.c (_initialize_maint_cmds): Fix typo.
1276
1277 2008-08-29 Tom Tromey <tromey@redhat.com>
1278
1279 * dwarf2read.c (dwarf2_build_psymtabs_hard): Copy dirname on
1280 obstack.
1281
1282 2008-08-27 Ulrich Weigand <uweigand@de.ibm.com>
1283
1284 * remote.c: Include "gdb_stat.h".
1285
1286 2008-08-26 Ulrich Weigand <uweigand@de.ibm.com>
1287
1288 * dummy-frame.h (dummy_frame_pop): Add prototype.
1289 * dummy-frame.c: Include "observer.h".
1290 (dummy_frame_push): Do not check for stale frames.
1291 (dummy_frame_pop): New function.
1292 (cleanup_dummy_frames): New function.
1293 (_initialize_dummy_frame): Install it as inferior_created observer.
1294
1295 * frame.h (struct frame_id): Update comments.
1296 (frame_id_inner): Remove prototype.
1297 * frame.c (frame_id_inner): Make static. Add comments.
1298 (frame_find_by_id): Update frame_id_inner safety net check to avoid
1299 false positives for targets using non-contiguous stack ranges.
1300 (get_prev_frame_1): Update frame_id_inner safety net check.
1301 (frame_pop): Call dummy_frame_pop when popping a dummy frame.
1302
1303 * stack.c (return_command): Directly pop the selected frame.
1304 * infrun.c (handle_inferior_event): Remove dead code.
1305 * i386-tdep.c (i386_push_dummy_call): Update comment.
1306
1307 2008-08-26 Ulrich Weigand <uweigand@de.ibm.com>
1308
1309 * breakpoint.c (remove_breakpoint): Do not fail if unable to remove
1310 breakpoint from shared library.
1311
1312 2008-08-26 Ulrich Weigand <uweigand@de.ibm.com>
1313
1314 * solib-svr4.c (read_program_header): New function.
1315 (scan_dyntag_auxv): New function.
1316 (elf_locate_base): Use it if scan_dyntag fails.
1317 (find_program_interpreter): New function.
1318 (enable_break): Use it instead of .interp section.
1319
1320 2008-08-26 Ulrich Weigand <uweigand@de.ibm.com>
1321
1322 * remote.h (remote_filename_p, remote_bfd_open): Add prototypes.
1323 * remote.c (remote_bfd_iovec_open, remote_bfd_iovec_close,
1324 remote_bfd_iovec_pread, remote_bfd_iovec_stat, remote_filename_p,
1325 remote_bfd_open): New functions.
1326 (remote_hostio_send_command): Fail safely if remote connection
1327 is not set up.
1328
1329 * solist.h (solib_open): Remove prototype.
1330 (solib_bfd_open): Add prototype.
1331 * solib.c: Include "remote.h".
1332 (solib_open): Remove, replace by ...
1333 (solib_bfd_open): ... this new function. Handle remote BFDs.
1334 (solib_map_sections): Replace solib_open by solib_bfd_open.
1335 * solib-frv.c: Include "exceptions.h".
1336 (enable_break2): Replace solib_open by solib_bfd_open.
1337 * solib-svr4.c: Include "exceptions.h".
1338 (enable_break): Replace solib_open by solib_bfd_open.
1339
1340 * symfile.c: Include "remote.h".
1341 (build_id_verify): Handle remote BFDs.
1342 (separate_debug_file_exists): Use BFD to access file. Handle
1343 remote BFDs.
1344 (symfile_bfd_open): Handle remote BFDs.
1345 (reread_symbols): Handle remote BFDs.
1346
1347 * NEWS: Mention "remote:" argument prefix to "set sysroot".
1348
1349 2008-08-26 Ulrich Weigand <uweigand@de.ibm.com>
1350
1351 * gdbarch.sh (target_gdbarch): New global variable.
1352 (deprecated_current_gdbarch_select_hack): Set it.
1353 * gdbarch.c, gdbarch.h: Regenerate.
1354
1355 * arch-utils.c (gdbarch_update_p): Use target_gdbarch instead
1356 of current_gdbarch.
1357 * target-descriptions.c (target_find_description): Likewise.
1358 * arm-tdep.c (arm_update_current_architecture): Likewise.
1359 (show_fp_model, arm_show_abi, arm_show_fallback_mode,
1360 arm_show_force_mode): Likewise.
1361 * mips-tdep.c (show_mask_address, show_mipsfpu_command,
1362 show_mips_abi): Likewise.
1363 * mep-tdep.c (me_module_register_set, current_me_module): Likewise.
1364
1365 * target.c (target_translate_tls_address): Use target_gdbarch
1366 instead of current_gdbarch.
1367 * remote.c (struct packet_reg): Likewise.
1368 (get_remote_arch_state, packet_reg_from_regnum,
1369 packet_reg_from_pnum, remote_check_symbols, remote_wait,
1370 remote_address_masked, remote_insert_breakpoint,
1371 remote_insert_hw_breakpoint, remote_read_description): Likewise.
1372 * remote-m32r-sdi.c (m32r_resume, m32r_wait): Likewise.
1373 * remote-mips.c (mips_open, mips_common_breakpoint): Likewise.
1374 * cris-tdep.c (cris_can_use_hardware_watchpoint): Likewise.
1375
1376 * solib.c (solib_open, solib_map_sections, solib_read_symbols,
1377 solib_add, info_sharedlibrary_command, solib_address,
1378 solib_create_inferior_hook, in_solib_dynsym_resolve_code,
1379 solib_global_lookup): Likewise.
1380 * solib-frv.c (enable_break2, frv_relocate_main_executable): Likewise.
1381 * solib-irix.c (irix_current_sos, irix_open_symbol_file_object):
1382 Likewise.
1383 * solib-sunos.c (sunos_solib_create_inferior_hook): Likewise.
1384 * solib-svr4.c (exec_entry_point, enable_break, svr4_free_so,
1385 set_solib_svr4_fetch_link_map_offsets, svr4_fetch_link_map_offsets):
1386 Likewise.
1387 * nto-tdep.c (nto_find_and_open_solib, nto_init_solib_absolute_prefix,
1388 nto_truncate_ptr): Likewise.
1389 * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Likewise.
1390
1391 2008-08-26 Luis Machado <luisgpm@br.ibm.com>
1392
1393 * ppc-linux-tdep.c (ppc_linux_vsx_regset_sections) New structure.
1394 (ppc_linux_vmx_regset_sections): New structure.
1395 (ppc_linux_fp_regset_sections): New structure.
1396 (ppc_linux_init_abi): Select core-file regset based on target
1397 features.
1398
1399 2008-08-26 Ulrich Weigand <uweigand@de.ibm.com>
1400
1401 * target.c (debug_print_register): Use regcache_raw_collect
1402 instead of regcache_cooked_read. Only handle raw registers.
1403
1404 2008-08-25 Pedro Alves <pedro@codesourcery.com>
1405
1406 * cp-name-parser.y: Include config.h before system headers.
1407
1408 2008-08-25 Ulrich Weigand <uweigand@de.ibm.com>
1409
1410 * m88k-tdep.c: Update for unwinder changes.
1411
1412 2008-08-24 Tom Tromey <tromey@redhat.com>
1413
1414 * s390-tdep.c (s390_address_class_type_flags): Use
1415 TYPE_INSTANCE_FLAG_ADDRESS_CLASS_1.
1416 (s390_address_class_type_flags_to_name): Likewise.
1417 (s390_address_class_name_to_type_flags): Likewise.
1418
1419 2008-08-24 Tom Tromey <tromey@redhat.com>
1420
1421 * rs6000-tdep.c (rs6000_builtin_type_vec128): Don't use
1422 TYPE_FLAGS.
1423 * features/rs6000/powerpc-vsx32l.c
1424 (initialize_tdesc_powerpc_vsx32l): Update.
1425 * features/rs6000/powerpc-vsx32.c
1426 (initialize_tdesc_powerpc_vsx32): Update.
1427 * features/rs6000/powerpc-vsx64.c
1428 (initialize_tdesc_powerpc_vsx64): Update.
1429 * features/rs6000/powerpc-vsx64l.c
1430 (initialize_tdesc_powerpc_vsx64l): Update.
1431 * target-descriptions.c (maint_print_c_tdesc_cmd): Emit
1432 TYPE_VECTOR, not TYPE_FLAGS.
1433
1434 2008-08-24 Tom Tromey <tromey@redhat.com>
1435
1436 * xml-tdesc.c (tdesc_end_union): Update.
1437 * stabsread.c (define_symbol): Update.
1438 (read_type): Update.
1439 (read_struct_type): Update.
1440 (read_enum_type): Update.
1441 * spu-tdep.c (spu_builtin_type_vec128): Update.
1442 * sh-tdep.c (sh_push_dummy_call_fpu): Update.
1443 (sh_push_dummy_call_nofpu): Update.
1444 * mdebugread.c (parse_symbol): Update.
1445 (parse_symbol): Update.
1446 (parse_symbol): Update.
1447 (upgrade_type): Update.
1448 * jv-lang.c (java_lookup_class): Update.
1449 * iq2000-tdep.c (iq2000_pointer_to_address): Update.
1450 * i386-tdep.c (i386_mmx_type): Update.
1451 (i386_sse_type): Update.
1452 * gdbtypes.h (enum type_flag_value): New enum.
1453 (enum type_instance_flag_value): New enum.
1454 (TYPE_FLAG_UNSIGNED, TYPE_FLAG_NOSIGN, TYPE_FLAG_STUB,
1455 TYPE_FLAG_TARGET_STUB, TYPE_FLAG_STATIC, TYPE_FLAG_PROTOTYPED,
1456 TYPE_FLAG_INCOMPLETE, TYPE_FLAG_VARARGS, TYPE_FLAG_VECTOR,
1457 TYPE_FLAG_FIXED_INSTANCE, TYPE_FLAG_STUB_SUPPORTED,
1458 TYPE_FLAG_NOTTEXT): Now enum constants.
1459 (TYPE_FLAG_CONST, TYPE_FLAG_VOLATILE, TYPE_FLAG_CODE_SPACE,
1460 TYPE_FLAG_DATA_SPACE, TYPE_FLAG_ADDRESS_CLASS_1,
1461 TYPE_FLAG_ADDRESS_CLASS_2): Remove.
1462 (TYPE_INSTANCE_FLAG_CONST, TYPE_INSTANCE_FLAG_VOLATILE,
1463 TYPE_INSTANCE_FLAG_CODE_SPACE, TYPE_INSTANCE_FLAG_DATA_SPACE,
1464 TYPE_INSTANCE_FLAG_ADDRESS_CLASS_1,
1465 TYPE_INSTANCE_FLAG_ADDRESS_CLASS_2): New constants.
1466 (TYPE_UNSIGNED, TYPE_NOSIGN, TYPE_STUB, TYPE_TARGET_STUB,
1467 TYPE_STATIC, TYPE_PROTOTYPED, TYPE_INCOMPLETE, TYPE_VARARGS,
1468 TYPE_VECTOR, TYPE_FIXED_INSTANCE, TYPE_STUB_SUPPORTED,
1469 TYPE_NOTTEXT): Update.
1470 (TYPE_FLAG_ADDRESS_CLASS_ALL): Remove.
1471 (TYPE_INSTANCE_FLAG_ADDRESS_CLASS_ALL): New define.
1472 (TYPE_VOLATILE, TYPE_CODE_SPACE, TYPE_DATA_SPACE,
1473 TYPE_ADDRESS_CLASS_1, TYPE_ADDRESS_CLASS_2,
1474 TYPE_ADDRESS_CLASS_ALL): Update.
1475 (struct main_type) <flags>: Remove.
1476 <flag_unsigned, flag_nosign, flag_stub, flag_target_stub,
1477 flag_static, flag_prototyped, flag_incomplete, flag_varargs,
1478 flag_vector, flag_stub_supported, flag_nottext,
1479 flag_fixed_instance>: New fields.
1480 <nfields, vptr_fieldno>: Move earlier.
1481 (TYPE_FLAGS): Remove.
1482 * gdbtypes.c (make_pointer_type): Update.
1483 (address_space_name_to_int): Update.
1484 (address_space_int_to_name): Update.
1485 (make_type_with_address_space): Update.
1486 (make_cv_type): Update.
1487 (create_range_type): Update.
1488 (get_discrete_bounds): Update.
1489 (create_set_type): Update.
1490 (make_vector_type): Update.
1491 (smash_to_method_type): Update.
1492 (check_typedef): Update.
1493 (check_stub_method): Update.
1494 (init_type): Individually assign flag fields.
1495 (recursive_dump_type): Don't print entire TYPE_FLAGS field. Do
1496 print TYPE_FIXED_INSTANCE, TYPE_STUB_SUPPORTED, and TYPE_NOTTEXT.
1497 (copy_type_recursive): Copy the entire main type. Don't use
1498 TYPE_FLAGS.
1499 * features/rs6000/powerpc-altivec64l.c
1500 (initialize_tdesc_powerpc_altivec64l): Update.
1501 * features/rs6000/powerpc-altivec64.c
1502 (initialize_tdesc_powerpc_altivec64): Update.
1503 * features/rs6000/powerpc-altivec32l.c
1504 (initialize_tdesc_powerpc_altivec32l): Update.
1505 * features/rs6000/powerpc-altivec32.c
1506 (initialize_tdesc_powerpc_altivec32): Update.
1507 * features/rs6000/powerpc-7400.c (initialize_tdesc_powerpc_7400):
1508 Update.
1509 * features/arm-with-iwmmxt.c (initialize_tdesc_arm_with_iwmmxt):
1510 Update.
1511 * dwarf2read.c (read_structure_type): Update.
1512 (read_enumeration_type): Likewise.
1513 (process_enumeration_scope): Likewise.
1514 (read_tag_pointer_type): Likewise.
1515 (read_subroutine_type): Likewise.
1516 (read_subroutine_type): Likewise.
1517 (read_base_type): Likewise.
1518 * coffread.c (coff_read_enum_type): Update.
1519 * ada-valprint.c (adjust_type_signedness): Update.
1520 * ada-typeprint.c (print_record_field_types): Update.
1521 * ada-lang.c (packed_array_type): Update.
1522 (empty_record): Don't reset TYPE_FLAGS.
1523 (ada_template_to_fixed_record_type_1): Update.
1524 (ada_template_to_fixed_record_type_1): Likewise.
1525 (template_to_static_fixed_type): Likewise.
1526 (to_record_with_fixed_variant_part): Likewise.
1527 (to_fixed_record_type): Likewise.
1528 (to_fixed_array_type): Likewise.
1529 (to_static_fixed_type): Likewise.
1530
1531 2008-08-23 Jim Blandy <jimb@redhat.com>
1532
1533 PR macros/607:
1534 * symmisc.c (print_symbol_bcache_statistics): Include statistics
1535 for the macro bcache.
1536
1537 2008-08-23 Tom Tromey <tromey@redhat.com>
1538
1539 * macrotab.h (struct macro_definition) <kind>: Shrink to one bit.
1540 (argc): Now 31 bits.
1541
1542 2008-08-22 Tom Tromey <tromey@redhat.com>
1543
1544 * NEWS: Move macro entries back under "New commands".
1545
1546 2008-08-22 Ulrich Weigand <uweigand@de.ibm.com>
1547
1548 * breakpoint.c (create_overlay_event_breakpoint): Rename to ...
1549 (create_overlay_event_breakpoint_1): ... this. Add OBJFILE parameter.
1550 (create_overlay_event_breakpoint): Loop over all objfiles to install
1551 multiple instances of the overlay event breakpoint if present.
1552
1553 2008-08-22 Ulrich Weigand <uweigand@de.ibm.com>
1554
1555 * spu-tdep.c (spu_overlay_new_objfile): Only consider SPU objfiles.
1556 (info_spu_event_command): Command only supported on SPU architecture.
1557 (info_spu_signal_command): Likewise.
1558 (info_spu_mailbox_command): Likewise.
1559 (info_spu_dma_command): Likewise.
1560 (info_spu_proxydma_command): Likewise.
1561
1562 2008-08-22 Ulrich Weigand <uweigand@de.ibm.com>
1563
1564 * infrun.c (adjust_pc_after_break): Do not call get_thread_regcache
1565 if the thread has already exited.
1566
1567 2008-08-22 Pedro Alves <pedro@codesourcery.com>
1568
1569 * infrun.c (proceed): Move back setting previous_inferior_ptid
1570 from here ...
1571 (wait_for_inferior): ... to here.
1572 (fetch_inferior_event): ... and here.
1573
1574 2008-08-21 Ulrich Weigand <uweigand@de.ibm.com>
1575
1576 * gdbarch.sh: Include "regcache.h" into gdbarch.c.
1577 (deprecated_current_gdbarch_select_hack): Call registers_changed
1578 instead of reinit_frame_cache.
1579 * gdbarch.c: Regenerate.
1580
1581 2008-08-21 Ulrich Weigand <uweigand@de.ibm.com>
1582
1583 * elfread.c (elf_symtab_read): Do not relocate thread-local symbols.
1584
1585 2008-08-21 Daniel Jacobowitz <dan@codesourcery.com>
1586
1587 * xcoffread.c (SYMNAME_ALLOC): Correct syntax.
1588
1589 2008-08-21 Ulrich Weigand <uweigand@de.ibm.com>
1590
1591 * findvar.c (locate_var_value): Do not call get_frame_arch
1592 with a NULL frame argument.
1593
1594 2008-08-21 Ulrich Weigand <uweigand@de.ibm.com>
1595
1596 * frame.h (frame_map_regnum_to_name): Remove prototype.
1597 (frame_map_name_to_regnum): Remove prototype.
1598 * frame.c (frame_map_regnum_to_name): Remove.
1599 (frame_map_name_to_regnum): Remove.
1600 (frame_unwind_register_value): Use user_reg_map_regnum_to_name
1601 instead of frame_map_regnum_to_name.
1602 * ax-gdb.c: Include "user-regs.h".
1603 (gen_expr): Use user_reg_map_name_to_regnum instead of
1604 frame_map_name_to_regnum.
1605 * eval.c: Include "user-regs.h".
1606 (evaluate_subexp_standard): Use user_reg_map_name_to_regnum
1607 instead of frame_map_name_to_regnum.
1608 * infcmd.c (registers_info): Likewise.
1609 * parse.c: Include "user-regs.h".
1610 (write_dollar_variable): Use user_reg_map_name_to_regnum
1611 instead of frame_map_name_to_regnum.
1612 * tracepoint.c: Include "user-regs.h".
1613 (encode_actions): Use user_reg_map_name_to_regnum
1614 instead of frame_map_name_to_regnum.
1615 * valops.c: Include "user-regs.h".
1616 (value_fetch_lazy): Use user_reg_map_regnum_to_name instead
1617 of frame_map_regnum_to_name.
1618
1619 2008-08-21 Ulrich Weigand <uweigand@de.ibm.com>
1620
1621 * ppc-linux-tdep.c (ppc64_linux_convert_from_func_ptr_addr): Read
1622 and manually relocate .opd contents from BFD instead of reading
1623 them from target memory.
1624
1625 2008-08-21 Daniel Jacobowitz <dan@codesourcery.com>
1626
1627 * dwarf2read.c (processing_current_prefix): Delete static
1628 variable.
1629 (process_full_comp_unit): Do not set processing_current_prefix.
1630 (dwarf2_full_name): New function.
1631 (read_func_scope): Do not set processing_current_prefix. Use
1632 determine_prefix.
1633 (read_structure_type): Do not set processing_current_prefix. Remove
1634 unused inner cleanup.
1635 (process_structure_scope): Do not set processing_current_prefix.
1636 (read_enumeration_type): Use dwarf2_full_name.
1637 (determine_class_name): Return a const char *. Put the result
1638 on the objfile obstack. Use dwarf2_full_name.
1639 (read_namespace_type): New function.
1640 (read_namespace): Do not create the type here. Use
1641 determine_prefix.
1642 (read_typedef): Use dwarf2_full_name. Do not pass the name
1643 to init_type.
1644 (read_base_type): Do not pass the name to init_type. Handle
1645 TYPE_FLAG_NOSIGN.
1646 (read_unspecified_type): Do not pass the name to init_type.
1647 (new_symbol): Use dwarf2_full_name instead of
1648 processing_current_prefix.
1649 (read_type_die): Do not set processing_current_prefix. Handle
1650 DW_TAG_namespace.
1651 (determine_prefix): Handle specifications. Return the result
1652 on the objfile obstack. Handle unions correctly.
1653
1654 2008-08-21 Daniel Jacobowitz <dan@codesourcery.com>
1655
1656 * buildsym.c (add_symbol_to_list): Do not call
1657 cp_scan_for_anonymous_namespaces here.
1658 (finish_block): Do not call cp_set_block_scope here.
1659 * cp-namespace.c (processing_has_namespace_info)
1660 (processing_current_prefix): Delete.
1661 (cp_initialize_namespace): Do not initialize
1662 processing_has_namespace_info.
1663 (cp_scan_for_anonymous_namespaces): Use SYMBOL_DEMANGLED_NAME. Do
1664 not check processing_has_namespace_info.
1665 (cp_set_block_scope): Take prefix and namespace info flag as
1666 arguments. Honor namespaces regardless of a demangled name.
1667 * cp-support.h (processing_has_namespace_info)
1668 (processing_current_prefix): Delete declarations.
1669 (cp_set_block_scope): Update prototype.
1670 * dwarf2read.c (processing_has_namespace_info)
1671 (processing_current_prefix): New static variables.
1672 (read_file_scope): Initialize processing_has_namespace_info.
1673 (read_func_scope): Call cp_set_block_scope for C++.
1674 (new_symbol): Call cp_scan_for_anonymous_namespaces for C++.
1675 * symtab.c (symbol_demangled_name): Accept a const argument.
1676 * symtab.h (symbol_demangled_name): Update prototype.
1677
1678 2008-08-21 Daniel Jacobowitz <dan@codesourcery.com>
1679
1680 * ax-gdb.c (gen_var_ref): Use SYMBOL_LINKAGE_NAME.
1681 * blockframe.c (find_pc_partial_function): Likewise.
1682 * buildsym.c (find_symbol_in_list): Likewise.
1683 * c-valprint.c (c_val_print): Likewise.
1684 * coffread.c (patch_opaque_types, process_coff_symbol): Likewise.
1685 (coff_read_enum_type): Likewise. Use SYMBOL_SET_LINKAGE_NAME.
1686 * cp-support.c (cp_remove_params): Renamed from remove_params and
1687 made global.
1688 (overload_list_add_symbol): Update call to remove_params.
1689 * cp-support.h (cp_remove_params): Declare.
1690 * dwarf2read.c (process_enumeration_scope): Use SYMBOL_LINKAGE_NAME.
1691 (dwarf2_const_value): Use SYMBOL_PRINT_NAME.
1692 * expprint.c (dump_subexp_body_standard): Likewise.
1693 * f-valprint.c (info_common_command, there_is_a_visible_common_named):
1694 Use SYMBOL_LINKAGE_NAME to find symbols and SYMBOL_PRINT_NAME
1695 for messages.
1696 * findvar.c (read_var_value): Use SYMBOL_LINKAGE_NAME.
1697 * gnu-v2-abi.c (gnuv2_value_rtti_type): Likewise.
1698 * hppa-hpux-tdep.c (hppa32_hpux_in_solib_call_trampoline)
1699 (hppa_hpux_skip_trampoline_code): Use SYMBOL_LINKAGE_NAME to find
1700 symbols and SYMBOL_PRINT_NAME for messages.
1701 * jv-lang.c (add_class_symbol): Use SYMBOL_SET_LINKAGE_NAME.
1702 * linespec.c (decode_line_2): Use SYMBOL_LINKAGE_NAME.
1703 * mdebugread.c (parse_symbol): Use SYMBOL_LINKAGE_NAME and
1704 SYMBOL_SET_LINKAGE_NAME.
1705 (mylookup_symbol): Use SYMBOL_LINKAGE_NAME.
1706 * minsyms.c (add_minsym_to_demangled_hash_table): Use
1707 SYMBOL_SEARCH_NAME.
1708 (lookup_minimal_symbol): Use SYMBOL_LINKAGE_NAME or
1709 SYMBOL_MATCHES_SEARCH_NAME, depending on the pass.
1710 * objfiles.h (ALL_OBJFILE_MSYMBOLS): Use SYMBOL_LINKAGE_NAME.
1711 * printcmd.c (build_address_symbolic): Use SYMBOL_LINKAGE_NAME.
1712 (address_info): Use SYMBOL_PRINT_NAME for messages and
1713 SYMBOL_LINKAGE_NAME for lookups.
1714 * sol-thread.c (info_cb): Use SYMBOL_PRINT_NAME for messages.
1715 * stabsread.c (patch_block_stabs, define_symbol)
1716 (read_type, read_enum_type, common_block_end)
1717 (cleanup_undefined_types_1, scan_file_globals): Use
1718 SYMBOL_LINKAGE_NAME, SYMBOL_SET_LINKAGE_NAME, ALL_OBJFILE_MSYMBOLS,
1719 and SYMBOL_PRINT_NAME.
1720 * stack.c (print_frame_args): Use SYMBOL_LINKAGE_NAME.
1721 (print_frame, frame_info): Use SYMBOL_PRINT_NAME for output. Use
1722 cp_remove_params instead of cplus_demangle.
1723 (print_block_frame_labels, print_frame_arg_vars): Use
1724 SYMBOL_LINKAGE_NAME.
1725 * symmisc.c (dump_msymbols): Use ALL_OBJFILE_MSYMBOLS and
1726 SYMBOL_LINKAGE_NAME.
1727 (dump_symtab_1, print_symbol, print_partial_symbols)
1728 (maintenance_check_symtabs): Use SYMBOL_LINKAGE_NAME.
1729 * symtab.h (DEPRECATED_SYMBOL_NAME): Delete.
1730 (SYMBOL_SET_LINKAGE_NAME): New.
1731 (SYMBOL_SET_NAMES): Add a comment.
1732 * tracepoint.c (set_traceframe_context, validate_actionline)
1733 (collect_symbol, scope_info): Use SYMBOL_LINKAGE_NAME for
1734 lookups and SYMBOL_PRINT_NAME for output.
1735 * typeprint.c (typedef_print): Use SYMBOL_LINKAGE_NAME.
1736 * xcoffread.c (process_xcoff_symbol): Use SYMBOL_SET_LINKAGE_NAME.
1737
1738 2008-08-21 Pedro Alves <pedro@codesourcery.com>
1739
1740 * arm-tdep.c (arm_pc_is_thumb): Use obj_section_addr.
1741 * hppa-hpux-tdep.c (hppa_hpux_find_dummy_bpaddr): Likewise.
1742 * hppa-linux-tdep.c (hppa_linux_find_global_pointer): Use
1743 obj_section_addr and obj_section_endaddr.
1744 * hppa-tdep.c (hppa64_convert_code_addr_to_fptr): Likewise.
1745 * hppabsd-tdep.c (hppabsd_find_global_pointer): Likewise.
1746 * ia64-tdep.c (ia64_find_global_pointer): Likewise.
1747 (find_extant_func_descr): Likewise.
1748 * solib-frv.c (frv_relocate_main_executable): Use
1749 obj_section_addr.
1750 * xstormy16-tdep.c (xstormy16_find_jmp_table_entry): Use
1751 obj_section_addr and obj_section_endaddr.
1752
1753 2008-08-21 Paul N. Hilfinger <hilfinger@adacore.com>
1754
1755 * NEWS: Amplify last entry on boolean types in Ada.
1756
1757 2008-08-20 Daniel Jacobowitz <dan@codesourcery.com>
1758
1759 * dwarf2read.c (die_specification, dwarf2_extension, follow_die_ref):
1760 Make the dwarf2_cu * parameter output as well as input. Update it if
1761 we follow a reference to another CU.
1762 (read_func_scope, determine_class_name, namespace_name, dwarf2_attr)
1763 (die_type, die_containing_type): Update calls to changed functions.
1764 Use the returned CU along with the returned DIE.
1765 (read_namespace): Use dwarf2_attr instead of dwarf2_extension.
1766
1767 2008-08-20 Daniel Jacobowitz <dan@codesourcery.com>
1768
1769 * dwarf2read.c (queue_comp_unit): Take an objfile argument. Read
1770 in the DIEs here.
1771 (process_queue): Do not read in the DIEs here.
1772 (psymtab_to_symtab_1): Update call to queue_comp_unit.
1773 (read_full_die): Do not call queue_comp_unit from here.
1774 (maybe_queue_comp_unit): New function.
1775 (follow_die_ref): Use it.
1776
1777 2008-08-20 Daniel Jacobowitz <dan@codesourcery.com>
1778
1779 * dwarf2read.c (struct attribute): Move earlier.
1780 (struct die_info): Change attrs to a trailing array.
1781 (dwarf_alloc_die): Take the number of attributes. Allocate space
1782 for them.
1783 (read_full_die): Update call to dwarf_alloc_die. Do not manually
1784 allocate attributes.
1785
1786 2008-08-20 Daniel Jacobowitz <dan@codesourcery.com>
1787
1788 * dwarf2read.c (REF_HASH_SIZE): Delete.
1789 (struct dwarf2_cu): Replace die_ref_table with die_hash.
1790 (struct die_info): Remove next_ref.
1791 (store_in_ref_table): Remove offset argument. Rewrite to use
1792 htab_find_slot_with_hash.
1793 (die_hash, die_eq): New.
1794 (read_comp_unit): Allocate the die_hash.
1795 (read_die_and_children): Update call to store_die_ref.
1796 (follow_die_ref): Rewrite to use htab_find_with_hash.
1797
1798 2008-08-20 Daniel Jacobowitz <dan@codesourcery.com>
1799
1800 * dwarf2read.c (free_die_list, copy_die): Delete.
1801 (dwarf_alloc_die): Take a CU argument. Allocate the new DIE
1802 on the obstack.
1803 (read_full_die): Update call to dwarf_alloc_die. Allocate
1804 attributes on the CU obstack.
1805 (free_one_comp_unit): Do not call free_die_list.
1806
1807 2008-08-20 Daniel Jacobowitz <dan@codesourcery.com>
1808
1809 * dwarf2read.c (read_die_and_children): Ignore NULL DIEs.
1810 (read_die_and_siblings): Likewise. Do not add padding DIEs to the
1811 sibling list.
1812 (read_full_die): Do not allocate DIEs for abbrev 0.
1813 (follow_die_ref): Correct error message.
1814
1815 2008-08-20 Pedro Alves <pedro@codesourcery.com>
1816
1817 * linespec.c (symtab_from_filename): Also throw NOT_FOUND_ERROR if
1818 there are no symbols loaded, instead of throwing a generic error.
1819 (decode_variable): Likewise.
1820
1821 2008-08-20 Pedro Alves <pedro@codesourcery.com>
1822
1823 * objfiles.h (struct obj_section): Remove addr and endaddr fields.
1824 (obj_section_offset, obj_section_addr, obj_section_endaddr): New
1825 macros.
1826 * objfiles.c (add_to_objfile_sections): Don't set addr, endaddr
1827 and offset. Use size_t instead of unsigned long.
1828 (build_objfile_section_table): Use size_t instead of unsigned
1829 long.
1830 (objfile_relocate): Don't relocate s->addr and s->endaddr, they're
1831 gone.
1832 (find_pc_sect_section): Use obj_section_addr and
1833 obj_section_endaddr.
1834 * symfile.c (symfile.c): Remove code that maps sections
1835 offsets in "addr" to the object's sections.
1836 * blockframe.c (find_pc_partial_function): Use obj_section_endaddr.
1837 * gcore.c (gcore_create_callback): Use obj_section_addr and
1838 obj_section_endaddr.
1839 * maint.c (print_objfile_section_info): Likewise.
1840 * printcmd.c (sym_info): Use obj_section_addr and
1841 obj_section_endaddr.
1842 * symtab.c (fixup_section): Likewise.
1843
1844 2008-08-20 Mark Kettenis <kettenis@gnu.org>
1845
1846 * sparc-tdep.c: Make some comments catch up with reality.
1847
1848 2008-08-20 Vladimir Prus <vladimir@codesourcery.com>
1849
1850 * NEWS: Mention 'set target-async'
1851
1852 2008-08-19 Vladimir Prus <vladimir@codesourcery.com>
1853
1854 * infrun.c (resume): If the thread is placed to the deferred step
1855 queue, mark it as running.
1856
1857 2008-08-19 Vladimir Prus <vladimir@codesourcery.com>
1858
1859 Make sure target supports non-stop.
1860 * infcmd.c (run_command_1, attach_command): If non-stop mode
1861 is requested, verify the target supports it.
1862 * linux-nat.c (linux_nat_supports_non_stop): New.
1863 (linux_nat_add_target): Register the above.
1864 * target.c (find_default_supports_non_stop)
1865 (target_supports_non_stop): New.
1866 (init_dummy_target): Register find_default_supports_non_stop.
1867 * target.h (struct target_ops): New field to_supports_non_stop.
1868 (target_supports_non_stop): New.
1869
1870 2008-08-19 Pedro Alves <pedro@codesourcery.com>
1871 Vladimir Prus <vladimir@codesourcery.com>
1872
1873 * target.c (target_async_permitted, target_async_permitted_1)
1874 (set_maintenance_target_async_permitted)
1875 (show_maintenance_target_async_permitted): New.
1876 (initialize_targets): Register 'set target-async'.
1877 * target.h (target_async_permitted): Declare.
1878 * linux-nat.c (linux_nat_async_enabled)
1879 (linux_nat_async_permitted, set_maintenance_linux_async_permitted)
1880 (show_maintenance_linux_async_permitted): Remove.
1881 (sigchld_handler, linux_nat_is_async_p, linux_nat_can_async_p)
1882 (get_pending_events, linux_nat_async): Use target_async_permitted.
1883 (linux_nat_set_async_mode): Remove, moving the only used bits
1884 into...
1885 (linux_nat_setup_async): This.
1886 (_initialize_linux_nat): Do not register 'maint set linux-async'.
1887 Use linux_nat_setup_async.
1888 * remote.c (remote_async_permitted, remote_async_permitted_set)
1889 (set_maintenance_remote_async_permitted)
1890 (show_maintenance_remote_async_permitted): Remove.
1891 (remote_open_1, remote_terminal_inferior, remote_can_async_p)
1892 (remote_is_async_p): Use target_async_permitted.
1893 (_initialize_remote): Don't register 'main set remote-async'.
1894 * mi/mi-cmds.c (mi_cmds): Register -list-target-features.
1895 * mi/mi-cmds.h (mi_cmd_list_target_features): New.
1896 * mi/mi-main.c (mi_cmd_list_target_features): New.
1897
1898 2008-08-19 Vladimir Prus <vladimir@codesourcery.com>
1899
1900 * target.c (maybe_kill_then_attach)
1901 (maybe_kill_then_create_inferior): Remove.
1902 (update_current_target): Do not default to_attach,
1903 to_create_inferiour, to_is_async_p.
1904
1905 2008-08-19 Paul N. Hilfinger <hilfinger@adacore.com>
1906
1907 Changes for supporting boolean types in debugging data.
1908 * ada-lang.c (discrete_type_high_bound,discrete_type_low_bound): Change
1909 API to return LONGEST values rather than struct values.
1910 (ada_evaluate_subexp): Change to use new API of discrete_type_low_bound
1911 and discrete_type_high_bound.
1912 (to_fixed_range_type): Create a range type in cases where
1913 argument is base type and its limits are representable as ints.
1914 (ada_is_modular_type): Correct so that base type must be integral.
1915 * ada-lex.l (TRUEKEYWORD,FALSEKEYWORD): Make 'true' and 'false'
1916 keywords when they appear alone, since we are phasing out
1917 direct representation of these identifiers in debugging data.
1918 * ada-exp.y: Define 'true' and 'false' as primaries.
1919 (type_boolean): New function.
1920 (type_int,type_long,type_long_long,type_floattype_double)
1921 (type_long_double): Remove uses of current_gdbarch for consistency
1922 with type_boolean.
1923 (write_int): Change comment to indicate that it might write boolean
1924 constant as well.
1925 * ada-typeprint.c (ada_print_type): Print '(false, true)' for boolean
1926 type, since will no longer be represented as enumerated type in
1927 debugging data.
1928 * ada-valprint.c (print_optional_low_bound): Handle boolean case
1929 as well.
1930 * NEWS: Note support boolean types.
1931
1932 2008-08-18 Pedro Alves <pedro@codesourcery.com>
1933
1934 * bsd-uthread.c (bsd_uthread_close): New.
1935 (bsd_uthread_deactivate): Don't cleanup here, just unpush the
1936 target.
1937 (bsd_uthread_solib_loaded): Fix typo.
1938 (bsd_uthread_target): Register bsd_uthread_close.
1939
1940 2008-08-18 Pedro Alves <pedro@codesourcery.com>
1941
1942 * corelow.c (core_open): Assume there was no upper layer left
1943 behind from a previous inferior.
1944 * target.c (pop_all_targets): Rename to ...
1945 (pop_all_targets_above): ... this. Add a target stratum
1946 parameter. Use it instead of hardcoding the dummy_stratum.
1947 (pop_all_targets): New, defer to pop_all_targets_above.
1948 (target_preopen): Use pop_all_targets_above.
1949 * target.h (pop_all_targets_above): Declare.
1950
1951 2008-08-18 Pedro Alves <pedro@codesourcery.com>
1952
1953 * gdbthread.h (thread_change_ptid): Declare.
1954 * infrun.c (infrun_thread_ptid_changed): New.
1955 (_initialize_infrun): Attach infrun_thread_ptid_changed to the
1956 thread_ptid_changed observer.
1957 * regcache.c (regcache_thread_ptid_changed): New.
1958 (_initialize_regcache): Attach regcache_thread_ptid_changed to the
1959 thread_ptid_changed observer.
1960 * thread.c (thread_change_ptid): New.
1961
1962 2008-08-18 Tom Tromey <tromey@redhat.com>
1963
1964 * symfile.c (reread_symbols): Update.
1965 * solib-sunos.c (allocate_rt_common_objfile): Update.
1966 * objfiles.c (allocate_objfile): Update.
1967 * objfiles.h (struct objfile) <md, mmfd, deprecated_obj_private>:
1968 Remove.
1969
1970 2008-08-18 Tom Tromey <tromey@redhat.com>
1971
1972 * gdbtypes.c (copy_type_recursive): Allocate 'stored' on objfile's
1973 obstack.
1974
1975 2008-08-18 Daniel Jacobowitz <dan@codesourcery.com>
1976
1977 * rs6000-tdep.c (struct rs6000_framedata): Add gpr_mask, used_bl,
1978 lr_register.
1979 (rs6000_in_function_epilogue_p): Check for bctr.
1980 (skip_prologue): Initialize lr_register. Set lr_reg to a register
1981 number. Set gpr_mask and used_bl. Continue scanning while some
1982 expected registers are not saved. Set lr_register if LR is not
1983 stored.
1984 (rs6000_frame_cache): Handle gpr_mask and lr_register.
1985
1986 2008-08-17 Tom Tromey <tromey@redhat.com>
1987
1988 PR gdb/1535:
1989 * breakpoint.c (CATCH_PERMANENT, CATCH_TEMPORARY): New macros.
1990 (ep_find_event_name_end): Remove.
1991 (catch_fork_temporary, catch_vfork_temporary,
1992 catch_fork_permanent, catch_vfork_permanent): New constants.
1993 (catch_vfork, catch_fork): Remove.
1994 (catch_fork_command_1): Add 'command' argument. Remove
1995 'fork_kind' and 'tempflag'. Handle NULL 'arg'. Update switch for
1996 all cases.
1997 (catch_exec_command_1): Add 'command' argument; remove
1998 'tempflag'. Handle NULL 'arg'.
1999 (catch_load_command_1): Likewise.
2000 (catch_unload_command_1): Likewise.
2001 (catch_ada_exception_command): Likewise.
2002 (catch_assert_command): Likewise.
2003 (catch_catch_command): New function.
2004 (catch_throw_command): Likewise.
2005 (catch_command_1): Remove.
2006 (catch_command): Just call error.
2007 (tcatch_command): Likewise.
2008 (catch_cmdlist): New global.
2009 (tcatch_cmdlist): Likewise.
2010 (add_catch_command): New function.
2011 (_initialize_breakpoint): Create "catch" and "tcatch" as prefix
2012 commands. Create all catch sub-commands.
2013
2014 2008-08-17 Pedro Alves <pedro@codesourcery.com>
2015
2016 * gdbthread.h: Add comments.
2017 * stack.c (get_selected_block): Return 0 on an exited thread.
2018 * top.c (execute_command): Check for is_stopped, not !is_running.
2019 * event-top.c (command_handler): Likewise.
2020
2021 2008-08-16 Pedro Alves <pedro@codesourcery.com>
2022
2023 * mi/mi-main.c (mi_cmd_exec_next, mi_cmd_exec_next_instruction)
2024 (mi_cmd_exec_step, mi_cmd_exec_step_instruction)
2025 (mi_cmd_exec_finish): Remove "return".
2026
2027 2008-08-16 Pedro Alves <pedro@codesourcery.com>
2028
2029 * target.h (pop_all_targets): Declare.
2030 * target.c (pop_all_targets): New.
2031 * top.c (quit_target): Pop all targets instead of just closing the
2032 current.
2033
2034 2008-08-16 Vladimir Prus <vladimir@codesourcery.com>
2035 Thiago Jung Bauermann <bauerman@br.ibm.com>
2036
2037 * cli-script.c (read_next_line): Add parse_commands argument.
2038 (recurse_read_control_structure): Adapt to new read_next_line
2039 signature.
2040 (read_command_lines): Add parse_commands argument.
2041 (define_command): Adapt to new read_command_lines signature.
2042 (document_command): Likewise.
2043 * breakpoint.c (commands_command): Likewise.
2044 * defs.h (read_command_lines): Adjust function prototype.
2045
2046 2008-08-16 Paul N. Hilfinger <hilfinger@adacore.com>
2047
2048 * ada-lang.c (pos_atr): Account for the possibility that the
2049 argument may be a reference.
2050
2051 2008-08-16 Paul N. Hilfinger <hilfingr@adacore.com>
2052
2053 * xcoffread.c (scan_xcoff_symtab): Do not include global symbols
2054 ('F' format) for @FIX names generated by the loader, retaining only
2055 the minimal symbols (and no partial symbol tables) for these names.
2056 Fixes warning messages about symbols that are found in partial
2057 symbol tables, but not full symbol tables.
2058
2059 2008-08-16 Pedro Alves <pedro@codesourcery.com>
2060
2061 * infrun.c (fetch_inferior_event): Only call normal_stop if not
2062 stopping quietly.
2063
2064 2008-08-15 Luis Machado <luisgpm@br.ibm.com>
2065
2066 * rs6000-tdep: Include "features/rs6000/powerpc-vsx32.c".
2067 Include "features/rs6000/powerpc-vsx64.c".
2068 (ppc_supply_vsxregset): New function.
2069 (ppc_collect_vsxregset): New function.
2070 (IS_VSX_PSEUDOREG): New macro.
2071 (IS_EFP_PSEUDOREG): New macro.
2072 (vsx_register_p): New function.
2073 (ppc_vsx_support_p): New function.
2074 (rs6000_builtin_type_vec128): New function.
2075 (rs6000_register_name): Hide upper halves of vs0~vs31. Return
2076 correct names for VSX registers and EFPR registers.
2077 (rs6000_pseudo_register_type): Return correct types for VSX
2078 and EFPR registers.
2079 (rs6000_pseudo_register_reggroup_p): Return correct group for
2080 VSX and EFPR registers.
2081 (ppc_pseudo_register_read): Rename to dfp_pseudo_register_read.
2082 (ppc_pseudo_register_write): Rename to dfp_pseudo_register_write.
2083 (vsx_pseudo_register_read): New function.
2084 (vsx_pseudo_register_write): New function.
2085 (efpr_pseudo_register_read): New function.
2086 (efpr_pseudo_register_write): New function.
2087 (rs6000_pseudo_register_read): Call new VSX and EFPR read functions.
2088 (rs6000_pseudo_register_write): Call new VSX and EFPR write functions.
2089 (rs6000_gdbarch_init): Declare have_vsx.
2090 Initialize new upper half VSX registers.
2091 Initialize VSX-related and EFPR-related pseudo-registers variables.
2092 Adjust the number of pseudo registers accordingly.
2093
2094 * ppc-linux-nat.c: Define PTRACE_GETVSXREGS, PTRACE_SETVSXREGS
2095 and SIZEOF_VSRREGS.
2096 (gdb_vsxregset_t): New type.
2097 (have_ptrace_getsetvsxregs): New variable.
2098 (fetch_vsx_register): New function.
2099 (fetch_register): Handle VSX registers.
2100 (fetch_vsx_registers): New function.
2101 (fetch_ppc_registers): Handle VSX registers.
2102 (store_ppc_registers): Handle VSX registers.
2103 (store_vsx_register): New function.
2104 (store_register): Handle VSX registers.
2105 (store_vsx_registers): New function.
2106 (ppc_linux_read_description): Handle VSX-enabled inferiors.
2107 (gdb_vsxregset_t): New type.
2108 (supply_vsxregset): New function.
2109 (fill_vsxregset): New function.
2110
2111 * ppc-tdep.h (vsx_register_p): New prototype.
2112 (vsx_support_p): New prototype.
2113 (ppc_vsr0_regnum): New variable.
2114 (ppc_vsr0_upper_regnum): Likewise.
2115 (ppc_efpr0_regnum): Likewise.
2116 (ppc_builtin_type_vec128): New type.
2117 (ppc_num_vsrs): New constant.
2118 (ppc_num_vshrs): New constant.
2119 (ppc_num_efprs): Likewise.
2120 Define POWERPC_VEC_VSX PPC_VSR0_UPPER_REGNUM and PPC_VSR31_UPPER_REGNUM.
2121 (ppc_supply_vsxregset): New prototype.
2122 (ppc_collect_vsxregset): New prototype.
2123
2124 * ppc-linux-tdep.c: Include "features/rs6000/powerpc-vsx32l.c"
2125 Include "features/rs6000/powerpc-vsx64l.c".
2126 (_initialize_ppc_linux_tdep): Initialize VSX-enabled targets.
2127 (ppc_linux_regset_sections): Add new ".reg-ppc-vsx" field.
2128 (ppc32_linux_vsxregset): New 32-bit VSX-enabled regset.
2129 (ppc_linux_regset_from_core_section): Handle VSX core section.
2130 (ppc_linux_core_read_description): Support VSX-enabled core files.
2131
2132 * ppc-linux-tdep.h: Declare *tdesc_powerpc_vsx32l
2133 Declare tdesc_powerpc_vsx64l
2134
2135 * corelow.c (get_core_register_section): Support VSX-enabled
2136 core files.
2137
2138 * features/rs6000/power-vsx.xml: New VSX descriptions.
2139 * features/rs6000/powerpc-vsx32.xml: New file.
2140 * features/rs6000/powerpc-vsx32l.xml: New file.
2141 * features/rs6000/powerpc-vsx64.xml: New file.
2142 * features/rs6000/powerpc-vsx64l.xml: New file.
2143 * features/rs6000/powerpc-vsx32.c: New file (generated).
2144 * features/rs6000/powerpc-vsx32l.c: New file (generated).
2145 * features/rs6000/powerpc-vsx64.c: New file (generated).
2146 * features/rs6000/powerpc-vsx64l.c: New file (generated).
2147 * features/Makefile: Updated with new descriptions.
2148 * regformats/rs6000/powerpc-vsx32l.dat: New file (generated).
2149 * regformats/rs6000/powerpc-vsx64l.dat: New file (generated).
2150
2151 2008-08-15 Vladimir Prus <vladimir@codesourcery.com>
2152
2153 * ia64-linux.nat (_initialize_ia64_linux_nat): Don't
2154 call linux_target twice.
2155
2156 2008-08-14 Aleksandar Ristovski <aristovski@qnx.com>
2157
2158 * nto-tdep.c (lm_info): Updated struct lm_info definition from
2159 solib-svr4.c
2160 (LM_ADDR): Use l_addr if available; if not, use link map and set
2161 l_addr.
2162
2163 2008-08-14 Tom Tromey <tromey@redhat.com>
2164
2165 * macrocmd.c (macro_define_command): Check for NULL argument.
2166 (macro_undef_command): Likewise.
2167
2168 2008-08-14 Pedro Alves <pedro@codesourcery.com>
2169
2170 * infcmd.c (continue_1): Add an ERROR_NO_INFERIOR call.
2171
2172 2008-08-13 Pedro Alves <pedro@codesourcery.com>
2173
2174 * breakpoint.c (always_inserted_auto, always_inserted_on)
2175 (always_inserted_off, always_inserted_enums): New.
2176 (always_inserted_mode): Change type to char* and point to
2177 always_inserted_auto.
2178 (show_always_inserted_mode): In auto mode, also show the current
2179 effect of the option.
2180 (breakpoints_always_inserted_mode): Adjust for the new auto mode.
2181 (_initialize_breakpoint): Make the "set breakpoints
2182 always-inserted" command an enum command. Extend help to describe
2183 the auto mode.
2184
2185 2008-08-13 Ulrich Weigand <uweigand@de.ibm.com>
2186
2187 * spu-tdep.c (info_spu_dma_command): Respect TSQV (tag status
2188 query valid) bit. Ignore bits outside the condition field.
2189 (info_spu_proxydma_command): Ignore bits outside the field.
2190
2191 2008-08-12 Michael Snyder <msnyder@vmware.com>
2192
2193 * MAINTAINERS: Update my email address.
2194
2195 2008-08-12 Ulrich Weigand <uweigand@de.ibm.com>
2196
2197 * ppc-linux-nat.c (ppc_linux_get_hwcap): Really get AT_HWCAP.
2198
2199 2008-08-12 Pedro Alves <pedro@codesourcery.com>
2200
2201 Add no-ack mode to the remote protocol --- optionally stop ACKing
2202 packets and responses when we have a reliable communication
2203 medium.
2204
2205 Based on Apple's GDB, by Jason Molenda <jmolenda@apple.com>
2206
2207 * remote.c (struct remote_state): Add noack_mode field.
2208 (PACKET_QStartNoAckMode): New.
2209 (remote_start_remote): Don't any outstanding packet here.
2210 (remote_open_1): Clear noack_mode. Ack any outstanding packet
2211 here. Activate noack mode if requested.
2212 (remote_protocol_features): Add QStartNoAckMode.
2213 (remote_open_1):
2214 (putpkt_binary): Don't send ack in noack mode.
2215 (read_frame): Don't recompute the checksum in noack mode.
2216 (getpkt_sane): Skip sending ack if in noack mode.
2217 (_initialize_remote): Add set/show remote noack mode.
2218 * NEWS: Note the new features.
2219
2220 2008-08-11 Kevin Buettner <kevinb@redhat.com>
2221
2222 * rs6000-tdep.c (BL_MASK, BL_INSTRUCTION, BL_DISPLACEMENT_MASK):
2223 New macros.
2224 (rs6000_skip_main_prologue): New function.
2225 (rs6000_gdb_arch_init): Register rs6000_skip_main_prologue.
2226
2227 2008-08-11 Sandra Loosemore <sandra@codesourcery.com>
2228
2229 * MAINTAINERS (Write After Approval): Add self.
2230
2231 2008-08-11 Stan Shebs <stan@codesourcery.com>
2232
2233 ARM BE8 support.
2234 * disasm.c (gdb_disassemble_info): Set endian_code.
2235 * gdbarch.sh (gdbarch_info): New field byte_order_for_code.
2236 * gdbarch.h, gdbarch.c: Regenerate.
2237 * arch-utils.c (initialize_current_architecture): Set the
2238 default byte_order_for_code.
2239 (gdbarch_info_init): Ditto.
2240 (gdbarch_info_fill): Ditto.
2241 * arm-tdep.c (SWAP_INT, SWAP_SHORT): New macros.
2242 (thumb_analyze_prologue): Swap halfword if code endianness is
2243 different from general endianness.
2244 (arm_skip_prologue): Similarly.
2245 (arm_scan_prologue): Ditto.
2246 (thumb_get_next_pc): Ditto.
2247 (arm_get_next_pc): Ditto.
2248 (arm_gdbarch_init): Set byte_order_for_code from BE8 flag,
2249 choose correct endianness for breakpoints.
2250
2251 2008-08-10 Pedro Alves <pedro@codesourcery.com>
2252
2253 * bsd-kvm.c: Include "gdbthread.h".
2254 (bsd_kvm_ptid): New.
2255 (bsd_kvm_open): Add a main thread.
2256 (bsd_kvm_close): Delete it.
2257 (bsd_kvm_thread_alive): New.
2258 (bsd_kvm_pid_to_str): New.
2259 (bsd_kvm_add_target): Register bsd_kvm_thread_alive and
2260 bsd_kvm_pid_to_str.
2261 (bsd_kvm_add_target): Initialize bsd_kvm_ptid.
2262
2263 2008-08-09 Pedro Alves <pedro@codesourcery.com>
2264
2265 * buildsym.c (start_subfile): Properly cast sentinel in concat
2266 call.
2267 * cp-name-parser.y: Include "config.h".
2268 * xml-tdesc.c (fetch_xml_from_file): Properly cast sentinel in
2269 concat call.
2270 * gdb_select.h: Include sys/time.h if sys/select.h is not
2271 available.
2272
2273 2008-08-09 Pedro Alves <pedro@codesourcery.com>
2274
2275 * go32-nat.c: Include "gdbthread.h".
2276 (go32_stop, go32_kill_inferior): Delete the main thread.
2277 (go32_create_inferior): Add it.
2278 (go32_thread_alive, go32_pid_to_str): New.
2279 (init_go32_ops): Register go32_thread_alive and go32_pid_to_str.
2280
2281 2008-08-09 Pedro Alves <pedro@codesourcery.com>
2282
2283 * go32-nat.c (fetch_register, store_register): Pass the regcache
2284 gdbarch to i386_fp_regnum_p and i386_fpc_regnum_p.
2285 (go32_xfer_memory): Change type of myaddr parameter to gdb_byte.
2286 (struct seg_descr, struct seg_descr): pack the whole struct
2287 instead of each member individually.
2288
2289 2008-08-09 Andreas Schwab <schwab@suse.de>
2290
2291 * python/python.c (_initialize_python): Use unabbreviated commands
2292 in prefix name.
2293
2294 2008-08-09 Daniel Jacobowitz <dan@codesourcery.com>
2295
2296 * Makefile.in (stamp-h): Also create .deps.
2297
2298 2008-08-09 Tom Tromey <tromey@redhat.com>
2299
2300 * Makefile.in (generated_files): Add GNULIB_H.
2301
2302 2008-08-09 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
2303
2304 * solib-pa64.c (pa64_solib_create_inferior_hook): Don't set
2305 DT_HP_DEBUG_PRIVATE. Add warning if DT_HP_DEBUG_PRIVATE is not set.
2306 Revise comment.
2307 (pa64_current_sos): Remove map private warning warning.
2308 * solib-som.c: Include string.h and sys/utsname.h.
2309 (get_hpux_major_release): New function.
2310 (som_solib_create_inferior_hook): Read dynamic linker header. Warn
2311 about shared library private mapping on HP-UX 11 and later. Only force
2312 private mapping of shared libraries on HP-UX 10 and earlier.
2313 (link_map_start): Delete warning.
2314
2315 2008-08-09 Xuepeng Guo <xuepeng.guo@intel.com>
2316 H.J. Lu <hongjiu.lu@intel.com>
2317 Mark Kettenis <kettenis@gnu.org>
2318
2319 * amd64-tdep.c (amd64_frame_cache): Add saved_sp_reg.
2320 (amd64_init_frame_cache): Initialize saved_sp_reg.
2321 (amd64_analyze_stack_align): New.
2322 (amd64_analyze_prologue): Call it.
2323 (amd64_frame_cache): Use saved_sp_reg if it is invalid. Don't set
2324 %rip to 8 when halfway aligning the stack.
2325
2326 * amd64-tdep.h (amd64_regnum): Add AMD64_R9_REGNUM to
2327 AMD64_R14_REGNUM.
2328
2329 * i386-tdep.c (i386_frame_cache): Remove stack_align. Add
2330 saved_sp_reg.
2331 (i386_alloc_frame_cache): Remove stack_align. Initialize
2332 saved_sp_reg to -1.
2333 (i386_analyze_stack_align): Rewrite.
2334 (i386_frame_cache): Use saved_sp_reg if it is valid.
2335
2336 2008-08-09 Ulrich Weigand <uweigand@de.ibm.com>
2337
2338 * target.c: Include "solib.h".
2339 (target_pre_inferior): Call no_shared_libraries.
2340 * infcmd.c (run_command_1): Do not call objfile_purge_solibs
2341 or clear_solib.
2342 (attach_command): Do not call clear_solib.
2343
2344 2008-08-09 Mark Kettenis <kettenis@gnu.org>
2345
2346 * i386obsd-nat.c (i386obsd_supply_pcb): Supply the right bytes for
2347 the %eip register.
2348
2349 2008-08-08 Tom Tromey <tromey@redhat.com>
2350
2351 * Makefile.in (python.o): Remove dependencies. Use COMPILE and
2352 POSTCOMPILE.
2353 (python-utils.o): Likewise.
2354
2355 2008-08-08 Andreas Schwab <schwab@suse.de>
2356
2357 * corefile.c (_initialize_core): Remove spurious paren from set
2358 gnutarget doc string.
2359
2360 2008-08-08 Luis Machado <luisgpm@br.ibm.com>
2361
2362 * ppc-linux-nat.c: Include "auxv.h" and "elf/common.h".
2363 Define PPC_FEATURE_BOOKE.
2364 (ppc_linux_get_hwcap): New function.
2365 (ppc_linux_region_ok_for_hw_watchpoint): Handle PowerPC 440
2366 4-bytes alignment restrictions.
2367 (ppc_linux_insert_watchpoint): Handle PowerPC 440-specific
2368 positioning of the read/write flags.
2369 (ppc_linux_watchpoint_addr_within_range): Handle PowerPC 440
2370 4-bytes alignment.
2371
2372 2008-08-08 Pedro Alves <pedro@codesourcery.com>
2373
2374 Use ptid_t.tid to store thread ids instead of ptid_t.pid.
2375
2376 * win32-nat.c (win32_add_thread): Change thread argument type to
2377 ptid_t. Adjust.
2378 (win32_add_thread): Adjust.
2379 (win32_delete_thread): Change thread argument type to ptid_t.
2380 Adjust.
2381 (win32_fetch_inferior_registers, win32_store_inferior_registers)
2382 (win32_resume, get_win32_debug_event, get_win32_debug_event)
2383 (win32_wait, win32_pid_to_exec_file, win32_pid_to_str): Adjust.
2384 (init_win32_ops): Put to_magic last.
2385 (win32_win32_thread_alive): Adjust.
2386
2387 2008-08-08 Pedro Alves <pedro@codesourcery.com>
2388
2389 * remote-m32r-sdi.c (m32r_thread_alive, m32r_pid_to_str): New.
2390 (init_m32r_ops): Register m32r_thread_alive and m32r_pid_to_str.
2391
2392 2008-08-08 Pedro Alves <pedro@codesourcery.com>
2393
2394 * remote-m32r-sdi.c: Include "gdbthread.h".
2395 (remote_m32r_ptid): New.
2396 (m32r_close): Delete the main thread.
2397 (m32r_resume): Set inferior_ptid toA remote_m32r_ptid. Add the
2398 main thread.
2399 (m32r_kill, m32r_load, sdireset_command): Delete the main thread.
2400 (_initialize_remote_m32r): Initialize remote_m32r_ptid.
2401
2402 2008-08-07 Tom Tromey <tromey@redhat.com>
2403 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
2404
2405 * aclocal.m4, configure: Rebuild.
2406 * configure.in: Call ZW_CREATE_DEPDIR,
2407 ZW_PROG_COMPILER_DEPENDENCIES, AC_PROG_MAKE_SET.
2408 (MAKE, GMAKE): New substs.
2409 * acinclude.m4: Include depstand.m4.
2410 * Makefile.in (DEPMODE, DEPDIR, COMPILE.post, COMPILE.pre,
2411 COMPILE, POSTCOMPILE, depcomp): New variables.
2412 Remove all _h variables.
2413 Remove many .o targets.
2414 ($(srcdir)/copying.c): avoid backslash-newline after comment
2415 sign (@maintainer_mode_true@).
2416 (HFILES_NO_SRCDIR): Regenerate.
2417 (generated_files): New variable.
2418 (all_gdbtk_cflags): Likewise.
2419 (.c.o): Rewrote.
2420 (init.o, version.o, copying.o): Remove.
2421 (distclean): Remove DEPDIR.
2422 (test-cp-name-parser.o, hpux-thread.o, main.o, monitor.o,
2423 printcmd.o, procfs.o, v850ice.o): Rewrite.
2424 (cli-cmds.o, cli-decode.o, cli-dump.o, cli-interp.o, cli-logging.o,
2425 cli-script.o, cli-setshow.o, cli-utils.o): Likewise.
2426 (gdbtk.o, gdbtk-bp.o, gdbtk-cmds.o, gdbtk-hooks.o, gdbtk-interp.o,
2427 gdbtk-main.o, gdbtk-register.o, gdbtk-stack.o, gdbtk-varobj.o,
2428 gdbtk-wrapper.o): Likewise.
2429 (mi-cmd-break.o, mi-cmd-disas.o, mi-cmd-env.o, mi-cmd-file.o,
2430 mi-cmds.o, mi-cmd-stack.o, mi-cmd-target.o, mi-cmd-var.o,
2431 mi-console.o, mi-getopt.o, mi-interp.o, mi-main.o, mi-out.o,
2432 mi-parse.o, mi-symbol-cmds.o, mi-common.o, signals.o, tui.o,
2433 tui-command.o, tui-data.o, tui-disasm.o, tui-file.o, tui-hooks.o,
2434 tui-interp.o, tui-io.o, tui-layout.o, tui-main.o, tui-out.o,
2435 tui-regs.o, tui-source.o, tui-stack.o, tui-win.o, tui-windata.o,
2436 tui-wingeneral.o, tui-winsource.o): Likewise.
2437 (all_object_files): New variable.
2438 ($(all_object_files)): New target.
2439 Include dependency files, when using GNU Make.
2440
2441 2008-08-07 Ulrich Weigand <uweigand@de.ibm.com>
2442
2443 * spu-tdep.c (info_spu_dma_cmdlist): Only show entries with
2444 the valid bit set. Ensure display order respects partial
2445 order defined by dependency bits.
2446
2447 2008-08-06 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
2448
2449 * solib-pa64.c (read_dld_descriptor): Return zero if load map is not
2450 setup.
2451
2452 2008-08-06 Mark Kettenis <kettenis@gnu.org>
2453
2454 * i386obsd-nat.c (i386obsd_supply_pcb): Adjust for changes in
2455 OpenBSD 4.3.
2456
2457 2008-08-06 Vladimir Prus <vladimir@codesourcery.com>
2458 Tom Tromey <tromey@redhat.com>
2459 Thiago Jung Bauermann <bauerman@br.ibm.com>
2460 Doug Evans <dje@google.com>
2461
2462 * Makefile.in (SUBDIR_PYTHON_OBS, SUBDIR_PYTHON_SRCS,
2463 SUBDIR_PYTHON_DEPS, SUBDIR_PYTHON_LDFLAGS, SUBDIR_PYTHON_CFLAGS,
2464 PYTHON_CFLAGS): New.
2465 (python_h, python_internal_h): New.
2466 (cli-script.o): Depend on python.h
2467 (python.o, python-utils.o): New.
2468 * cli/cli-script.c (print_command_lines): Handle python_control.
2469 (execute_control_command): Handle python_control.
2470 (execute_control_command_untraced): New function.
2471 (while_command): Call execute_control_command_untraced.
2472 (if_command): Likewise.
2473 (get_command_line): Remove static attribute.
2474 (read_next_line): Handle "python".
2475 (recurse_read_control_structure): Handle python_control.
2476 (read_command_lines): Handle python_control.
2477 Include python.h.
2478 * cli/cli-script.h (get_command_line): Add prototype.
2479 (execute_control_command_untraced): Likewise.
2480 * configure.ac: Add --with-python.
2481 * defs.h (enum command_control_type) <python_control>: New
2482 constant.
2483 * python/python-internal.h: New file.
2484 * python/python.c: New file.
2485 * python/python.h: New file.
2486 * python/python-utils.c: New file.
2487 * NEWS: Mention Python scripting support and its new commands.
2488
2489 2008-08-06 Ulrich Weigand <uweigand@de.ibm.com>
2490
2491 * spu-tdep.c (spu_gdbarch_init): Call set_gdbarch_frame_red_zone_size.
2492
2493 2008-08-06 Phil Muldoon <pmuldoon@redhat.com>
2494
2495 * MAINTAINERS (Write After Approval): Add self.
2496
2497 2008-08-06 Phil Muldoon <pmuldoon@redhat.com>
2498
2499 * breakpoint.c (hw_breakpoint_used_count): Use breakpoint_enabled.
2500 (insert_breakpoint_locations): Likewise.
2501
2502 2008-08-05 Phil Muldoon <pmuldoon@redhat.com>
2503
2504 * breakpoint.c (create_longjmp_breakpoint): Remove unused struct
2505 breakpoint.
2506 (set_longjmp_breakpoint): Likewise.
2507
2508 2008-08-04 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
2509
2510 PR build/2490
2511 * solib-pa64.c: Only compile if both HAVE_ELF_HP_H and __LP64__ are
2512 defined.
2513
2514 2008-08-05 Tom Tromey <tromey@redhat.com>
2515
2516 * bcache.c (deprecated_bcache_added): Initialize obstack.
2517 (bcache_xmalloc): Don't initialize obstack.
2518 (bcache_xfree): Conditionally free obstack.
2519 (bcache_memory_used): Update.
2520
2521 2008-08-05 Tom Tromey <tromey@redhat.com>
2522
2523 * symfile.c (add_psymbol_to_bcache): Return a const pointer. Use
2524 bcache_full.
2525 (append_psymbol_to_list): Accept a const pointer.
2526 (add_psymbol_to_list): Fix const correctness.
2527 * bcache.h: (deprecated_bcache_added, deprecated_bcache): Remove.
2528 (bcache_full): Declare.
2529 * bcache.c (bcache_data, deprecated_bcache): Remove.
2530 (bcache): Use bcache_full.
2531 (bcache_full): Rename from deprecated_bcache_added. Change return
2532 type.
2533
2534 2008-08-04 Stan Shebs <stan@codesourcery.com>
2535
2536 * solib-svr4.c (BKPT_AT_SYMBOL): Remove, always defined.
2537 (bkpt_names): Remove SOLIB_BKPT_NAME, never defined.
2538 (enable_break): Remove test of BKPT_AT_SYMBOL.
2539
2540 2008-08-02 Keith Seitz <keiths@redhat.com>
2541
2542 * acinclude.m4: Include ../config/tcl.m4 to pick up
2543 standard Tcl configury bits.
2544 Remove all Tcl, Tk, Itcl, Itk, etc definitions.
2545 * configure.ac: Don't check if ../itcl exists when building
2546 gdbtk. It could be installed.
2547 Rewrite gdbtk configury to allow for using system-supplied
2548 Tcl and Tk. Gdbtk no longer requires build-time access to
2549 itcl and itk.
2550 * Makefile.in: Remove everything related to itcl and itk.
2551 Rewrite the Tcl bits for gdbtk to correspond to rewrite of
2552 configure.ac.
2553 Remove v850ice.o build rule.
2554 (ALL_TCL_CFLAGS): New convenience defintion. Change all
2555 gdbtk sources to use it.
2556 * configure: Regenerate.
2557
2558 2008-07-31 Stan Shebs <stan@codesourcery.com>
2559
2560 * coffread.c (coff_symtab_read): Remove FUNCTION_EPILOGUE_SIZE.
2561
2562 2008-07-30 Stan Shebs <stan@codesourcery.com>
2563
2564 * objfiles.c (TARGET_KEEP_SECTION): Remove.
2565 (add_to_objfile_sections): Remove use.
2566
2567 2008-07-29 Tom Tromey <tromey@redhat.com>
2568
2569 * cli/cli-decode.c (lookup_cmd_1): Use memcpy.
2570 (lookup_cmd_composition): Likewise.
2571
2572 2008-07-29 Tom Tromey <tromey@redhat.com>
2573
2574 * cli/cli-cmds.c (edit_command): Remove unused variables. Delete
2575 dead code. Fix indentation.
2576
2577 2008-07-29 Stan Shebs <stan@codesourcery.com>
2578
2579 * main.c (captured_main): Remove long-unused #if 0 blocks.
2580
2581 2008-07-28 Tom Tromey <tromey@redhat.com>
2582
2583 * annotate.h (deprecated_annotate_starting_hook): Remove.
2584 (deprecated_annotate_stopped_hook): Remove.
2585 (deprecated_annotate_exited_hook): Remove.
2586 * Makefile.in (annotate.o): Depend on observer_h.
2587 * top.c (deprecated_delete_breakpoint_hook): Remove.
2588 (deprecated_create_breakpoint_hook): Likewise.
2589 (deprecated_modify_breakpoint_hook): Likewise.
2590 * interps.c (clear_interpreter_hooks): Update for removed hooks.
2591 * breakpoint.c (mention): Don't call removed hook.
2592 (delete_breakpoint): Likewise.
2593 (disable_breakpoint): Likewise.
2594 (do_enable_breakpoint): Likewise.
2595 * annotate.c: Include observer.h.
2596 (breakpoint_changed): Change type of argument.
2597 (_initialize_annotate): Register observers.
2598 (deprecated_annotate_starting_hook): Remove.
2599 (deprecated_annotate_stopped_hook): Remove.
2600 (deprecated_annotate_exited_hook): Remove.
2601 (annotate_starting): Update for hook removal.
2602 (annotate_stopped): Likewise.
2603 (annotate_exited): Likewise.
2604 * defs.h (deprecated_delete_breakpoint_hook): Remove.
2605 (deprecated_create_breakpoint_hook): Likewise.
2606 (deprecated_modify_breakpoint_hook): Likewise.
2607
2608 2008-07-28 Tom Tromey <tromey@redhat.com>
2609
2610 * main.c (captured_main): Don't use BEFORE_MAIN_LOOP_HOOK.
2611
2612 2008-07-27 Daniel Jacobowitz <dan@codesourcery.com>
2613
2614 * configure.ac: Check for the GNU/Linux ptrace signature.
2615 * configure: Regenerated.
2616
2617 2008-07-27 Daniel Jacobowitz <dan@codesourcery.com>
2618
2619 * linux-nat.c (resume_callback): Add more debugging output.
2620 (linux_nat_has_pending_sigint): New function, based on
2621 linux_nat_has_pending.
2622 (set_ignore_sigint, maybe_clear_ignore_sigint): New functions.
2623 (stop_wait_callback): Remove flush_mask handling. Honor
2624 ignore_sigint. Call maybe_clear_ignore_sigint. Pass NULL
2625 to recursive calls.
2626 (linux_nat_has_pending, flush_callback): Remove.
2627 (linux_nat_filter_event): Check for ignore_sigint.
2628 (linux_nat_wait): Remove flush_mask support and call to
2629 flush_callback. Use set_ignore_sigint and maybe_clear_ignore_sigint.
2630 * linux-nat.h (struct lwp_info): Add ignore_sigint field.
2631
2632 2008-07-27 Daniel Jacobowitz <dan@codesourcery.com>
2633
2634 * linux-nat.c (count_events_callback, select_event_lwp_callback): Only
2635 report events from resumed threads.
2636
2637 2008-07-27 Daniel Jacobowitz <dan@codesourcery.com>
2638
2639 * mips-linux-tdep.c (mips_linux_syscall_next_pc): New function.
2640 (mips_linux_init_abi): Set tdep->syscall_next_pc.
2641 * mips-tdep.c (enum mips_fpu_type, struct gdbarch_tdep): Move to
2642 mips-tdep.h.
2643 (mips32_next_pc): Handle the syscall instruction.
2644 * mips-tdep.h (enum mips_fpu_type, struct gdbarch_tdep): New,
2645 from mips-tdep.c. Add syscall_next_pc to gdbarch_tdep.
2646
2647 2008-07-26 Tom Tromey <tromey@redhat.com>
2648
2649 PR gdb/1158:
2650 * valops.c (value_struct_elt): Treat function-valued field as a
2651 static method.
2652
2653 2008-07-26 Tom Tromey <tromey@redhat.com>
2654
2655 PR gdb/1136:
2656 * macroexp.c (get_punctuator) <punctuators>: Rearrange to put
2657 longer tokens first.
2658
2659 2008-07-26 Vladimir Prus <vladimir@codesourcery.com>
2660
2661 Kill cmd_async_ok.
2662 * cli/cli-decode.h (CMD_ASYNC_OK, set_cmd_async_ok)
2663 (get_cmd_async_ok): Remove.
2664 * cli/cli-decode.c (set_cmd_async_ok, get_cmd_async_ok): Remove.
2665 * cli/cli-cmds.c (init_cli_cmds): Don't use set_cmd_async_ok.
2666 * infcmd.c (_initialize_infcmd): Likewise.
2667 * thread.c (_initialize_thread): Likewise.
2668
2669 2008-07-25 Joseph Myers <joseph@codesourcery.com>
2670
2671 * mips-tdep.c (mips_n32n64_push_dummy_call): Handle passing
2672 128-bit long doubles in even-odd pairs of FPRs. Do not
2673 right-align float arguments for big-endian.
2674 (mips_n32n64_return_value): Apply return value convention for
2675 structs containing one or two floating-point values to soft-float
2676 as well as hard-float. Handle 128-bit long doubles in such
2677 structs.
2678 (mips_o32_push_dummy_call): Only skip one integer register for a
2679 float argument passed in an FPR.
2680
2681 2008-07-25 Tom Tromey <tromey@redhat.com>
2682
2683 * tui/tui-hooks.c: Include observer.h.
2684 (tui_event_default, tui_old_event_hooks, tui_event_hooks):
2685 Remove.
2686 (tui_bp_created_observer, tui_bp_deleted_observer,
2687 tui_bp_modified_observer): New globals.
2688 (tui_install_hooks): Use observers, not events.
2689 (tui_remove_hooks): Likewise.
2690 * mi/mi-cmd-break.c: Include observer.h, not gdb-events.h.
2691 (mi_breakpoint_observers_installed, mi_can_breakpoint_notify): New
2692 globals.
2693 (breakpoint_notify): Check mi_can_breakpoint_notify.
2694 (breakpoint_hooks): Remove.
2695 (mi_cmd_break_insert): Attach observers. Don't use events.
2696 * tracepoint.c: Include observer.h, not gdb-events.h.
2697 (tracepoint_operation, trace_pass_command): Notify observer.
2698 * interps.c: Don't include gdb-events.h.
2699 (clear_interpreter_hooks): Don't call clear_gdb_event_hooks.
2700 * gdbarch.c: Rebuild.
2701 * gdbarch.sh: Emit include for observer.h, not gdb-events.h.
2702 (deprecated_current_gdbarch_select_hack): Notify observer.
2703 * breakpoint.h: Don't include gdb-events.h.
2704 * breakpoint.c: Don't include gdb-events.h.
2705 (condition_command): Notify observer.
2706 (commands_command): Likewise.
2707 (commands_from_control_command): Likewise.
2708 (mention, delete_breakpoint, set_ignore_count): Likewise.
2709 (disable_breakpoint, do_enable_breakpoint): Likewise.
2710 * Makefile.in (gdb_events_h): Remove.
2711 (breakpoint_h): Update.
2712 (COMMON_OBS): Remove gdb-events.o.
2713 (gdb-events.o): Remove.
2714 (breakpoint.o, gdbarch.o, interps.o, tracepoint.o, gdbtk-bp.o,
2715 gdbtk-hooks.o, mi-cmd-break.o, tui-hooks.o): Update.
2716 * gdb-events.c: Remove.
2717 * gdb-events.h: Remove.
2718 * gdb-events.sh: Remove.
2719
2720 2008-07-24 Pedro Alves <pedro@codesourcery.com>
2721
2722 * remote.c (remote_threads_extra_info): Don't query the remote
2723 server about info on the internally added main thread.
2724
2725 2008-07-24 Aleksandar Ristovski <aristovski@qnx.com>
2726
2727 * nto-procfs.c (procfs_attach): Populate initial thread list.
2728 (procfs_wait): Return new pid, built from the inferior status.
2729
2730 2008-07-23 Thiago Jung Bauermann <bauerman@br.ibm.com>
2731
2732 * configure.ac (CONFIG_INITS): Delete long obsoleted variable.
2733 * configure: Regenerate.
2734
2735 2008-07-23 Aleksandar Ristovski <aristovski@qnx.com>
2736
2737 * nto-procfs.c (procfs_xfer_memory): Changed signature.
2738 (procfs_resume): Workaround for dereferencing type-punned pointer
2739 warning.
2740 * nto-tdep.c (nto_parse_redirection): Change signature to be const
2741 correct.
2742 * nto-tdep.h (nto_parse_redirection): Likewise.
2743
2744 2008-07-21 Stan Shebs <stan@codesourcery.com>
2745
2746 Scrub remnants of IN_SOLIB_DYNSYM_RESOLVE_CODE.
2747 * gdbarch.sh: Adjust comment to refer to
2748 in_solib_dynsym_resolve_code().
2749 * gdbarch.h, gdbarch.c: Update.
2750 * solib-osf.c: Ditto.
2751 * infrun.c: Ditto.
2752 (handle_inferior_event): Use in_solib_dynsym_resolve_code
2753 unconditionally.
2754 * config/mips/nm-irix5.h: Remove undef of
2755 IN_SOLIB_DYNSYM_RESOLVE_CODE.
2756
2757 2008-07-21 Tom Tromey <tromey@redhat.com>
2758
2759 * symfile.c (reread_symbols): Don't pass argument to observer.
2760 * exec.c (exec_file_attach): Don't pass argument to observer.
2761 * ada-lang.c (ada_executable_changed_observer): Remove argument.
2762 * symtab.c (symtab_observer_executable_changed): Remove argument.
2763 * observer.sh: Handle functions with no arguments.
2764
2765 2008-07-20 Sergei Poselenov <sposelenov@emcraft.com>
2766 Chris Demetriou <cgd@google.com>
2767
2768 * elfread.c (elf_symfile_segments): Fix the check that each loadable
2769 section fits within an ELF segment to handle ELF segments that hit
2770 the end of the address space.
2771
2772 2008-07-20 Chris Demetriou <cgd@google.com>
2773
2774 * MAINTAINERS (Write After Approval): Add self.
2775
2776 2008-07-18 Tom Tromey <tromey@redhat.com>
2777
2778 PR gdb/855:
2779 * NEWS: Add entry for macro commands.
2780 * Makefile.in (macrocmd.o): Add gdb_string.h.
2781 * macroscope.h (user_macro_scope): Declare.
2782 (default_macro_scope): Update documentation.
2783 (macro_user_macros): Declare.
2784 * c-lang.c (c_preprocess_and_parse): Always attempt macro lookup.
2785 Use user_macro_scope.
2786 (null_macro_lookup): Remove.
2787 * macrotab.h (macro_callback_fn): Declare.
2788 (macro_for_each): Likewise.
2789 (macro_allow_redefinitions): Likewise.
2790 * macrotab.c (foreach_macro): New function
2791 (macro_for_each): Likewise.
2792 (struct macro_table) <redef_ok>: New field.
2793 (macro_allow_redefinitions): New function.
2794 (new_macro_table): Update.
2795 (macro_define_function): Likewise.
2796 (macro_define_object): Likewise.
2797 * macroscope.c (user_macro_scope): New function.
2798 (default_macro_scope): Use it.
2799 (macro_user_macros): New global.
2800 (standard_macro_lookup): Look in macro_user_macros.
2801 (_initialize_macroscope): New function.
2802 * macroexp.h (macro_is_whitespace, macro_is_digit,
2803 macro_is_identifier_nondigit): Declare.
2804 * macroexp.c (macro_is_whitespace): Rename. No longer static.
2805 (macro_is_digit): Likewise.
2806 (macro_is_identifier_nondigit): Likewise.
2807 (get_identifier): Update.
2808 (get_pp_number): Likewise.
2809 (get_token): Likewise.
2810 * macrocmd.c (skip_ws): New function.
2811 (extract_identifier): Likewise.
2812 (free_macro_definition_ptr): Likewise.
2813 (user_macros): Remove.
2814 (macro_define_command): Implement.
2815 (_initialize_macrocmd): Update.
2816 (macro_undef_command): Implement.
2817 (print_one_macro): New function.
2818 (macro_list_command): Implement.
2819
2820 2008-07-18 Joseph Myers <joseph@codesourcery.com>
2821
2822 * configure.ac: Put old value of $LIBS after -lbfd -liberty $intl
2823 in BFD ELF check.
2824 * configure: Regenerate.
2825
2826 2008-07-17 Paul Pluzhnikov <ppluzhnikov@google.com>
2827
2828 * auxv.c (fprint_target_auxv): Stop at AT_NULL.
2829
2830 2008-07-15 Andreas Schwab <schwab@suse.de>
2831
2832 * valops.c (value_cast_pointers): Follow typedefs when checking
2833 result of coercion.
2834
2835 2008-07-15 Daniel Jacobowitz <dan@codesourcery.com>
2836
2837 * block.c (block_function): Renamed to ...
2838 (block_linkage_function): ... this. All callers changed.
2839 * block.h (block_function): Renamed to ...
2840 (block_linkage_function): ... this.
2841
2842 2008-07-15 Daniel Jacobowitz <dan@codesourcery.com>
2843
2844 * mn10300-tdep.c (set_reg_offsets): Use get_frame_register_unsigned.
2845
2846 2008-07-15 Daniel Jacobowitz <dan@codesourcery.com>
2847
2848 * frame.c (frame_sp_unwind): Delete.
2849 (get_frame_sp): Do not use it.
2850 * frame.h (frame_sp_unwind): Delete prototype.
2851
2852 2008-07-15 Daniel Jacobowitz <dan@codesourcery.com>
2853
2854 * ia64-tdep.c (ia64_dummy_id): Use get_frame_pc.
2855
2856 2008-07-15 Daniel Jacobowitz <dan@codesourcery.com>
2857
2858 * dwarf2-frame.c (dwarf2_frame_cache): Update comment.
2859 * frame.c (frame_unwind_address_in_block): Delete.
2860 (get_frame_address_in_block): Do not use it. Check the type
2861 of the next frame first.
2862 (frame_cleanup_after_sniffer): Update comment.
2863 * frame.h (frame_unwind_address_in_block): Delete prototype.
2864 * hppa-tdep.c (hppa_find_unwind_entry_in_block): Update comment.
2865
2866 2008-07-15 Daniel Jacobowitz <dan@codesourcery.com>
2867
2868 * frame.c (frame_func_unwind): Delete.
2869 (get_frame_func): Do not use it.
2870 * frame.h (frame_func_unwind): Delete prototype.
2871 * hppa-tdep.c (hppa_frame_cache): Update comment.
2872 * rs6000-tdep.c (rs6000_frame_cache): Update comment.
2873
2874 2008-07-14 Stan Shebs <stan@codesourcery.com>
2875
2876 * remote-sim.c (init_gdbsim_ops): Remove
2877 TARGET_REDEFINE_DEFAULT_OPS.
2878
2879 2008-07-15 Daniel Jacobowitz <dan@codesourcery.com>
2880
2881 * findvar.c (read_var_value): Remove unused variable.
2882
2883 2008-07-15 Luis Machado <luisgpm@br.ibm.com>
2884
2885 * infrun.c (handle_inferior_event): Tag threads as stopped
2886 before inserting breakpoints.
2887
2888 2008-07-15 Hui Zhu <teawater@gmail.com>
2889
2890 * MAINTAINERS: Added myself to section Write After Approval.
2891
2892 2008-07-14 Paul Pluzhnikov <ppluzhnikov@google.com>
2893
2894 PR gdb/2477
2895 * cp-abi.c (value_virtual_fn_field): Handle invalid pointers.
2896
2897 2008-07-14 Pedro Alves <pedro@codesourcery.com>
2898
2899 * i386-dicos-tdep.c (i386_dicos_frame_align): Delete.
2900 (i386_dicos_push_dummy_code): New.
2901 (i386_dicos_init_abi): Don't register i386_dicos_frame_align.
2902 Register i386_dicos_push_dummy_code.
2903
2904 2008-07-14 Markus Deuling <deuling@de.ibm.com>
2905
2906 * mips-tdep.c (fp_register_arg_p): Add gdbarch as paramter.
2907 (mips_n32n64_push_dummy_call, mips_o64_return_value)
2908 (mips_eabi_push_dummy_call): Update call to fp_register_arg_p.
2909
2910 (MIPS_FPU_TYPE): Add gdbarch as parameter and replace current_gdbarch.
2911 (fp_register_arg_p, mips_dump_tdep, show_mipsfpu_command)
2912 (mips_n32n64_fp_arg_chunk_p): Update caller.
2913
2914 (mips_n32n64_fp_arg_chunk_p): Add gdbarch as paramter.
2915 (mips_n32n64_push_dummy_call): Update caller.
2916
2917 (MIPS_LAST_ARG_REGNUM): Add gdbarch as parameter and replace
2918 current_gdbarch.
2919 (mips_eabi_push_dummy_call, mips_n32n64_push_dummy_call)
2920 (mips_o32_push_dummy_call, mips_o64_push_dummy_call): Update caller.
2921
2922
2923 (MIPS_LAST_FP_ARG_REGNUM): Add gdbarch as parameter and replace
2924 current_gdbarch.
2925 (mips_eabi_push_dummy_call, mips_o32_push_dummy_call)
2926 (mips_o64_push_dummy_call): Update caller.
2927
2928 (MIPS_EABI): Add gdbarch as parameter and replace current_gdbarch.
2929 (fp_register_arg_p, mips_dump_tdep): Update caller.
2930
2931 (set_reg_offset): Add gdbarch as parameter and replace current_gdbarch.
2932 (mips16_scan_prologue, mips32_scan_prologue): Update caller.
2933
2934 (reset_saved_regs): Make static. Add gdbarch as parameter. Replace
2935 current_gdbarch.
2936 (mips32_scan_prologue): Update caller.
2937
2938 (heuristic_proc_start): Add gdbarch as parameter. Replace
2939 current_gdbarch.
2940 (mips_insn16_frame_cache, mips_insn32_frame_cache): Update caller.
2941
2942 * mipsnbsd-nat.c (mipsnbsd_fetch_inferior_registers)
2943 (mipsnbsd_store_inferior_registers): Use get_regcache_arch to get at
2944 the current architecture. Update call to getregs_supplies.
2945 (getregs_supplies): Add gdbarch as parameter and replace
2946 current_gdbarch.
2947
2948 * mipsnbsd-tdep.c (mipsnbsd_get_longjmp_target): Use get_frame_arch to
2949 get at the current architecture. Update call to NBSD_MIPS_JB_OFFSET and
2950 NBSD_MIPS_JB_ELEMENT_SIZE.
2951 (NBSD_MIPS_JB_ELEMENT_SIZE, NBSD_MIPS_JB_OFFSET): Add gdbarch and
2952 replace current_gdbarch.
2953
2954 * remote-mips.c (mips_map_regno): Add gdbarch as parameter and replace
2955 current_gdbarch.
2956 (mips_fetch_registers, mips_store_registers): Update call
2957 to mips_map_regno.
2958 (mips_load): Use get_regcache_arch to get at the current_architecture
2959 and replace current_gdbarch.
2960
2961 2008-07-13 Pedro Alves <pedro@codesourcery.com>
2962
2963 * thread.c (restore_selected_frame): On fail to restore, select
2964 the innermost frame, and don't crash when warning the user.
2965
2966 2008-07-13 Hui Zhu <teawater@gmail.com>
2967
2968 * symtab.c (expand_line_sal): Fix a memory leak.
2969
2970 2008-07-13 Pedro Alves <pedro@codesourcery.com>
2971
2972 * utils.c (struct continuation): Define as inheriting struct
2973 cleanup.
2974 (add_continuation, do_all_continuations)
2975 (discard_all_continuations, add_intermediate_continuation)
2976 (do_all_intermediate_continuations)
2977 (discard_all_intermediate_continuations): Adjust.
2978
2979 2008-07-13 Vladimir Prus <vladimir@codesourcery.com>
2980
2981 Skip varobj in running threads.
2982 * mi/mi-cmd-var.c (mi_cmd_var_update): If varobj's
2983 thread is not stopped, skip the varobj.
2984 * Makefile.in: Update dependencies.
2985
2986 2008-07-13 Vladimir Prus <vladimir@codesourcery.com>
2987
2988 Enable all commands while inferiour is running
2989 * mi/mi-main.c (mi_cmd_execute): Don't check if
2990 inferiour is executing.
2991
2992 2008-07-13 Vladimir Prus <vladimir@codesourcery.com>
2993
2994 Allow all CLI command even if target is executing.
2995 * gdb/top.c (execute_command_1): Don't check if the inferiour
2996 is running.
2997
2998 2008-07-13 Vladimir Prus <vladimir@codesourcery.com>
2999
3000 * mi/mi-main.c (mi_cmd_execute): Remove unused variable.
3001 Fix printing of frame, when frame is wrong.
3002
3003 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
3004
3005 * spu-tdep.c (spu_frame_unwind_cache): Do not error if
3006 backchain is unreadable.
3007
3008 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
3009
3010 * spu-linux-nat.c: Include "gdbthread.h".
3011 (spu_child_post_startup_inferior): Register main thread.
3012 (spu_child_post_attach): Likewise.
3013 * Makefile.in (spu-linux-nat.o): Update dependencies.
3014
3015 2008-07-12 Pedro Alves <pedro@codesourcery.com>
3016
3017 Rewrite continuations internals on top of cleanups and plug
3018 continuation arguments leaks.
3019
3020 * defs.h (struct continuation): Make it opaque.
3021 (add_continuation, add_intermediate_continuation): Drop the int
3022 argument of the continuation hook argument. Add
3023 continuation_free_args argument.
3024 (do_all_continuations, do_all_intermediate_continuations): Drop
3025 the error_p argument.
3026
3027 * utils.c (add_continuation): Drop the int argument of the
3028 continuation hook argument. Add continuation_free_args argument.
3029 Reimplement on top of cleanups.
3030 (do_all_continuations): Drop error argument. Reimplement on top
3031 of cleanups.
3032 (discard_all_continuations): Reimplement on top of cleanups.
3033 (add_intermediate_continuation): Drop the int argument of the
3034 continuation hook argument. Add continuation_free_args argument.
3035 Reimplement on top of cleanups.
3036 (do_all_intermediate_continuations): Drop error argument.
3037 Reimplement on top of cleanups.
3038 (discard_all_intermediate_continuations): Reimplement on top of
3039 cleanups.
3040
3041 * breakpoint.c (until_break_command_continuation): Drop error
3042 argument. Add xfree as continuation argument deleter.
3043
3044 * inf-loop.c (inferior_event_handler): On error, discard all
3045 continuations. Adjust to new do_all_intermediate_continuations
3046 and do_all_continuations interfaces.
3047
3048 * infcmd.c (step_1_continuation): Drop error_p argument. Adjust.
3049 Pass xfree as continuation argument deleter.
3050 (finish_command_continuation): Drop error_p argument. Adjust.
3051 (finish_command_continuation_free_arg): New.
3052 (finish_command): Pass finish_command_continuation_free_arg as
3053 continuation argument deleter. Adjust to new do_all_continuations
3054 interfaces.
3055 (attach_command_continuation): Drop error_p argument.
3056 (attach_command_continuation_free_args): New.
3057 (attach_command): Pass attach_command_continuation_free_args as
3058 continuation argument deleter.
3059
3060 * interps.c (interp_set): Adjust to new do_all_continuations
3061 interfaces.
3062
3063 * event-top.c (stdin_event_handler): In error, also discard the
3064 intermediate continuations.
3065
3066 2008-07-12 Pedro Alves <pedro@codesourcery.com>
3067
3068 Replace struct continuation_args by void* and per command structs.
3069
3070 * top.c (execute_command): Remove unused arg1 and arg2 locals.
3071
3072 * breakpoint.c (struct until_break_command_continuation_args):
3073 New.
3074 (until_break_command_continuation): Take a void* instead of a
3075 continuations_arg. Adjust.
3076 (until_break_command): Adjust to use struct
3077 until_break_command_continuation_args instead of struct
3078 continuation_arg.
3079
3080 * infcmd.c (struct step_1_continuation_args): New.
3081 (step_1_continuation): Take a void* instead of a
3082 continuations_arg. Adjust to use struct step_1_continuation_args.
3083 (step_once): Adjust to use struct step_1_continuation_args.
3084
3085 (struct finish_command_continuation_args): New.
3086 (finish_command_continuation): Take a void* instead of a
3087 continuations_arg. Adjust to use struct
3088 finish_command_continuation_args.
3089 (finish_command): Adjust to use struct
3090 finish_command_continuation_args.
3091 (struct attach_command_continuation_args): New.
3092 (attach_command_continuation): Take a void* instead of a
3093 continuations_arg. Adjust to use struct
3094 attach_command_continuation_args.
3095 (attach_command): Adjust to use struct
3096 attach_command_continuation_args.
3097
3098 * defs.h (struct continuation_arg): Delete.
3099 (struct continuation): Replace the struct continuation_arg*
3100 parameter of continuation_hook by a void*. Replace "arg_list"
3101 member by a new "args" member with void* type.
3102 (add_continuation, add_intermediate_continuation): Replace struct
3103 continuation_arg type usages by void* usages.
3104
3105 * utils.c (add_continuation, do_all_continuations)
3106 (add_intermediate_continuation)
3107 (do_all_intermediate_continuations): Replace struct
3108 continuation_arg type usages by void* usages. Pass "args" instead
3109 of "arg_list".
3110
3111 2008-07-12 Pedro Alves <pedro@codesourcery.com>
3112
3113 * infrun.c (struct thread_stepping_state): Delete sal member.
3114 (init_thread_stepping_state): Add local sal. Use it instead of
3115 tss->sal.
3116 (handle_inferior_event): New local stop_pc_sal. Use it instead of
3117 tss->sal.
3118 (step_into_function): Add local stop_func_sal. Use it instead of
3119 tss->sal.
3120
3121 2008-07-12 Vladimir Prus <vladimir@codesourcery.com>
3122
3123 Implement -exec-continue/-exec-interrupt --all.
3124 * infcmd.c (continue_1): New, extracted from
3125 (continue_command): ...here.
3126 (interrupt_target_1): New, extracted from
3127 (interrupt_target_command): ...here.
3128 * inferior.h (continue_1, interrupt_target_1): New.
3129 * mi/mi-main.c (mi_cmd_exec_continue)
3130 (mi_cmd_exec_interrupt): Handle --all.
3131
3132 2008-07-12 Vladimir Prus <vladimir@codesourcery.com>
3133
3134 Implement --thread and --frame.
3135 * gdbthread.h (find_thread_id): Declare.
3136 * thread.c (find_thread_id): Make non-static.
3137 * mi/mi-main.c (mi_cmd_execute): Switch to the right
3138 thread and frame, if necessary.
3139 * mi/mi-parse.c (mi_parse): Handle --thread and --frame.
3140 * mi/mi-parse.h (strcut mi_parse): New fields thread and frame.
3141
3142 2008-07-12 Vladimir Prus <vladimir@codesourcery.com>
3143
3144 * infrun.c (resume): Discard cleanups on early exit path.
3145
3146 2008-07-12 Vladimir Prus <vladimir@codesourcery.com>
3147
3148 * infrun.c (normal_stop): For MI, report which threads
3149 were stopped.
3150
3151 2008-07-12 Vladimir Prus <vladimir@codesourcery.com>
3152
3153 Report thread state in -thread-info output.
3154 * thread.c (print_thread_info): Add new field "state".
3155
3156 2008-07-11 Pedro Alves <pedro@codesourcery.com>
3157
3158 * infrun.c (handle_inferior_event): Also ignore a
3159 TARGET_SIGNAL_TRAP on a STOP_QUIETLY_NO_SIGSTOP.
3160
3161 2008-07-11 Tom Tromey <tromey@redhat.com>
3162
3163 * completer.c (complete_line_internal): New function, from
3164 complete_line. Add 'for_help' parameter.
3165 (complete_line): Use it.
3166 (command_completer): Move later. Rewrite.
3167
3168 2008-07-11 Pedro Alves <pedro@codesourcery.com>
3169
3170 * thread.c (thread_apply_command): Move making the cleanup out of
3171 the loop.
3172
3173 2008-07-11 Pedro Alves <pedro@codesourcery.com>
3174
3175 Exited threads.
3176
3177 * thread.c (enum thread_state): New.
3178 (thread_state main_thread_running): Delete, in favor of...
3179 (thread_state main_thread_state): ... this. Update throughout.
3180 (clear_thread_inferior_resources): New, split from free_thread.
3181 (free_thread): Call clear_thread_inferior_resources.
3182 (init_thread_list): Set main thread to stopped state.
3183 (add_thread_silent): Take care of PTID reuses.
3184 (delete_thread): If deleting inferior_ptid or a thread with
3185 refcount > 0, mark it as exited, but still keep it in the list.
3186 Only notify of thread exits, if we haven't done so yet.
3187 (iterate_over_threads): Make it safe to delete threads while
3188 iterating over them.
3189 (do_captured_list_thread_ids): Don't account for exited threads.
3190 (thread_alive): Check for the THREAD_EXITED state, and don't set
3191 ptid to -1 on exited threads.
3192 (set_running): Update to account for extra possible states.
3193 (is_thread_state): New.
3194 (is_stopped, is_exited): New.
3195 (is_running): Implement in terms of is_thread_state.
3196 (any_running): Update.
3197 (print_thread_info): Update. Account for exited threads. Don't
3198 warn about missed frame restoring here, its done in the cleanup.
3199 (switch_to_thread): Don't read from a thread that has gone.
3200 (restore_current_thread): In non-stop mode, do a full context
3201 switch.
3202 (restore_selected_frame): Add a frame_level argument. Rewrite.
3203 (struct current_thread_cleanup): Add selected_frame_level and
3204 was_stopped members.
3205 (do_restore_current_thread_cleanup): Check if thread was stopped
3206 and still is, and if the target has registers, stack and memory
3207 before restoring the selected frame. Don't delete the cleanup
3208 argument here.
3209 (restore_current_thread_cleanup_dtor): New.
3210 (make_cleanup_restore_current_thread): Remove all arguments.
3211 Rewrite.
3212 (thread_apply_all_command): Update. Prune threads.
3213 (thread_apply_command): Update.
3214 (thread_command): Account for currently selected exited thread.
3215 (do_captured_thread_select): Check for a running thread. Prune
3216 threads.
3217 (_initialize_thread): Make "info threads", "thread", "thread
3218 apply", and "thread apply all" appliable without a selected thread.
3219 * gdbthread.h (struct thread_info): Replace running_ by state_.
3220 Add refcount.
3221 (is_exited, is_stopped): Declare.
3222 (make_cleanup_restore_current_thread): Remove all arguments.
3223 * infrun.c: Include "event-top.h".
3224 (fetch_inferior_event): In non-stop mode, restore selected thread
3225 and frame after handling the event and running breakpoint
3226 commands. Display GDB prompt if needed.
3227 (normal_stop): In non-stop mode, don't print thread switching
3228 notice.
3229 * cli/cli-decode.c (set_cmd_no_selected_thread_ok)
3230 (get_cmd_no_selected_thread_ok): New.
3231 * cli/cli-decode.h (CMD_NO_SELECTED_THREAD_OK): New.
3232 (set_cmd_no_selected_thread_ok, get_cmd_no_selected_thread_ok):
3233 Declare.
3234 * cli/cli-cmds.c: Set "pwd", "help", "info", "show" as
3235 no-selected-thread ok.
3236 * top.c (execute_command): Check for non no-selected-thread-ok
3237 commands.
3238 * linux-nat.c (struct saved_ptids, threads_to_delete)
3239 (record_dead_thread, prune_lwps): Delete.
3240 (exit_lwp): Unconditionally delete thread.
3241 (linux_nat_resume): Remove prune_lwps call.
3242 * infcmd.c (proceed_thread_callback): Check if !is_stopped instead
3243 of is_running. Adjust to make_cleanup_restore_current_thread
3244 interface change.
3245 * mi/mi-main.c (mi_cmd_execute): Only allow a few commands if the
3246 selected thread has exited.
3247 * inf-loop.c (inferior_event_handler): Don't display the prompt
3248 here.
3249 * varobj.c (c_value_of_root): Update.
3250 * defs.h (make_cleanup_dtor): Declare.
3251 * utils.c (make_cleanup_dtor): New.
3252
3253 * Makefile.in (infrun.o): Depend on $(event_top_h).
3254
3255 2008-07-11 Pedro Alves <pedro@codesourcery.com>
3256
3257 Add "continue -a" and "interrupt -a" options for non-stop mode.
3258
3259 * infcmd.c (proceed_thread_callback, do_context_switch_to): New.
3260 (continue_command): Add "-a" option.
3261 (interrupt_target_command): Add "-a" option.
3262 (_initialize_infcmd): Add extend help of continue and interrupt
3263 command to mention the new "-a" option. Mark "continue" async ok.
3264
3265 2008-07-10 Doug Evans <dje@google.com>
3266
3267 Add "set print symbol-loading on|off".
3268 * NEWS: Document new option.
3269 * symfile.h (print_symbol_loading): Declare.
3270 * symfile.c (print_symbol_loading): New global.
3271 (symbol_file_add_with_addrs_or_offsets): Only print "Reading symbols
3272 from ..." if print_symbol_loading.
3273 (_initialize_symfile): Add set/show print symbol-loading.
3274 * solib.c (solib_read_symbols): Only print "Loaded symbols for ..."
3275 if print_symbol_loading.
3276
3277 2008-07-10 Pedro Alves <pedro@codesourcery.com>
3278
3279 Non-stop linux native.
3280
3281 * linux-nat.c (linux_test_for_tracefork): Block events while we're
3282 here.
3283 (get_pending_status): Implement non-stop mode.
3284 (linux_nat_detach): Stop threads before detaching.
3285 (linux_nat_resume): In non-stop mode, always resume only a single
3286 PTID.
3287 (linux_handle_extended_wait): On a clone event, in non-stop mode,
3288 add new lwp to GDB's thread table, and mark as running, executing
3289 and stopped appropriately.
3290 (linux_nat_filter_event): Don't assume there are other running
3291 threads when a thread exits.
3292 (linux_nat_wait): Mark the main thread as running and executing.
3293 In non-stop mode, don't stop all lwps.
3294 (linux_nat_kill): Stop lwps before killing them.
3295 (linux_nat_thread_alive): Use signal 0 to detect if a thread is
3296 alive.
3297 (send_sigint_callback): New.
3298 (linux_nat_stop): New.
3299 (linux_nat_add_target): Set to_stop to linux_nat_stop.
3300
3301 * linux-nat.h (thread_db_attach_lwp): Declare.
3302
3303 * linux-thread-db.c (thread_get_info_callback): Check for new
3304 threads if we have none.
3305 (thread_from_lwp, enable_thread_event): Set proc_handle.pid to the
3306 stopped lwp. Check for new threads if we have none.
3307 (thread_db_attach_lwp): New.
3308 (thread_db_init): Set proc_handle.pid to inferior_ptid.
3309 (check_event): Set proc_handle.pid to the stopped lwp.
3310 (thread_db_find_new_threads): Set proc_handle.pid to any stopped
3311 lwp available, bail out if there is none.
3312
3313 * linux-fork.c (linux_fork_killall): Use SIGKILL instead of
3314 PTRACE_KILL.
3315
3316 2008-07-10 Kevin Buettner <kevinb@redhat.com>
3317
3318 * rs6000-tdep.c (ppc_displaced_step_fixup): Change type of
3319 `current_pc' from CORE_ADDR to ULONGEST.
3320
3321 * remote-sim.c (gdbsim_cntrl_c): Pass remote_sim_ptid to
3322 gdbsim_stop().
3323
3324 2008-07-10 Jan Kratochvil <jan.kratochvil@redhat.com>
3325
3326 * NEWS (New commands): Mention "set disable-randomization".
3327 * configure.ac: Add check for HAVE_PERSONALITY and
3328 HAVE_DECL_ADDR_NO_RANDOMIZE.
3329 * configure, config.in: Regenerate.
3330 * linux-nat.c [HAVE_PERSONALITY]: New include <sys/personality.h>.
3331 [HAVE_PERSONALITY] [!HAVE_DECL_ADDR_NO_RANDOMIZE]: Set
3332 ADDR_NO_RANDOMIZE.
3333 (disable_randomization, show_disable_randomization)
3334 (set_disable_randomization): New.
3335 (linux_nat_create_inferior) [HAVE_PERSONALITY]: New variables
3336 PERSONALITY_ORIG and PERSONALITY_SET. Disable randomization upon the
3337 variable DISABLE_RANDOMIZATION.
3338 (_initialize_linux_nat): Call ADD_SETSHOW_BOOLEAN_CMD for the variable
3339 DISABLE_RANDOMIZATION.
3340
3341 2008-07-09 Pedro Alves <pedro@codesourcery.com>
3342
3343 Adjust all targets to new target_stop interface.
3344
3345 * gnu-nat.c (gnu_stop): Add ptid argument.
3346 * go32-nat.c (go32_stop): Add ptid argument.
3347 (go32_create_inferior): Pass inferior_ptid to go32_stop.
3348 * hpux-thread.c (hpux_thread_stop): Add ptid argument.
3349 * monitor.c (monitor_stop): Add ptid argument.
3350 (monitor_open): Pass inferior_ptid to monitor_stop.
3351 (monitor_interrupt): Pass inferior_ptid to target_stop.
3352 (monitor_stop): Add ptid argument.
3353 * nto-procfs.c (nto_interrupt): Pass inferior_ptid to target_stop.
3354 (procfs_create_inferior): Add ptid argument.
3355 * procfs.c (procfs_stop): Add ptid argument.
3356 * remote-m32r-sdi.c (m32r_stop): Add ptid argument.
3357 * remote-sim.c (gdbsim_stop): Add ptid argument.
3358 * sol-thread.c (sol_thread_stop): Add ptid argument.
3359 * win32-nat.c (win32_stop): Add ptid argument.
3360
3361 2008-07-09 Pedro Alves <pedro@codesourcery.com>
3362
3363 Non-stop inferior control.
3364
3365 * infrun.c (resume): In non-stop mode, always resume just one
3366 thread.
3367 (proceed): Don't call prepare_to_proceed in non-stop mode.
3368 (fetch_inferior_event): In non-stop mode, switch context before
3369 handling the event.
3370 (error_is_running, ensure_not_running): New.
3371 (handle_inferior_event): In non-stop mode: Mark only the event
3372 thread as stopped. Require that the target module manages adding
3373 threads to the thread list. Assert that there isn't a
3374 deferred_step_ptid set. Don't switch to infwait_thread_hop_state.
3375 (normal_stop): Only mark not-running if inferior hasn't exited.
3376 In non-stop mode, only mark the event thread.
3377
3378 * thread.c:Include "cli/cli-decode.h".
3379 (print_thread_info): Don't read from a running thread.
3380 Output "(running)" if thread is running.
3381 (switch_to_thread): Don't read stop_pc if thread is executing.
3382 (do_restore_current_thread_cleanup): Don't write to a running
3383 thread.
3384 (thread_apply_all_command): Don't read from a running thread. In
3385 non-stop mode, do a full context-switch instead of just switching
3386 threads.
3387 (thread_apply_command): In non-stop mode, do a full context-switch
3388 instead of just switching threads.
3389 (do_captured_thread_select): Likewise. Inform user if selected
3390 thread is running.
3391 (_initialize_thread): Mark "info threads" and "thread" and
3392 async_ok.
3393
3394 * inf-loop.c (inferior_event_handler): In non-stop mode, don't
3395 unregister the target from the event loop.
3396
3397 * infcmd.c (continue_command, step_1, jump_command)
3398 (signal_command): Ensure the selected thread isn't running.
3399 (interrupt_target_command): In non-stop mode, interrupt only the
3400 selected thread.
3401
3402 * inferior.h (error_is_running, ensure_not_running): Declare.
3403
3404 * target.h (struct target_ops): Add ptid argument to the to_stop
3405 member.
3406 (target_stop): Add ptid_t argument.
3407
3408 * target.c (update_current_target): Add ptid argument to to_stop's
3409 type.
3410 (debug_to_stop): Add ptid_t argument.
3411 (debug_to_rcmd): Set to_stop_ptid.
3412
3413 * remote.c (remote_stop): Add ptid_t argument.
3414 (async_remote_interrupt): Add inferior_ptid to target_stop.
3415 * inf-ptrace.c (inf_ptrace_stop): Add ptid argument.
3416
3417 * Makefile.in (thread.o): Depend on $(cli_decode_h).
3418
3419 2008-07-09 Pedro Alves <pedro@codesourcery.com>
3420
3421 Don't rely on ecs->wait_for_more.
3422
3423 * infrun.c (proceed): Clear the stepping state, set
3424 previous_inferior_ptid and clear infwait state.
3425 (wait_for_inferior): Don't clear the stepping state, set
3426 previous_inferior_ptid, or clear the infwait state here.
3427 (fetch_inferior_event): Don't clear the stepping state, set
3428 previous_inferior_ptid, or clear the infwait state here. Don't
3429 condition on wait_for_more.
3430
3431 2008-07-09 Pedro Alves <pedro@codesourcery.com>
3432
3433 Refactor infrun a bit.
3434
3435 * infrun.c (currently_stepping): Take a struct
3436 thread_stepping_state instead of an execution_control_state.
3437 (struct thread_stepping_state): New, split from
3438 execution_control_state.
3439 (gtss, tss): New globals.
3440 (proceed): Clear the stepping state, set previous_inferior_ptid
3441 and clear infwait state.
3442 (init_wait_for_inferior): Clear the stepping state,
3443 previous_inferior_ptid and infwait state.
3444 (waiton_ptid, infwait_state): New, split from
3445 execution_control_state.
3446 (struct execution_control_state): Members that persist through
3447 events moved out to either struct thred_stepping_state or made
3448 global. Deleted unneeded wp, saved_inferior_ptid, tmpstatus.
3449 (wait_for_inferior, fetch_inferior_event): Use local
3450 execution_control_state. Update to execution_control_state split.
3451 (init_execution_control_state): Adjust.
3452 (init_thread_stepping_state): New, extracted from
3453 init_execution_control_state.
3454 (context_switch): Take a ptid instead of an
3455 execution_control_state.
3456 (context_switch_to): Adjust.
3457 (adjust_pc_after_break): Adjust.
3458 (init_infwait_state): New.
3459 (handle_inferior_event): Adjust.
3460
3461 2008-07-09 Pedro Alves <pedro@codesourcery.com>
3462 Vladimir Prus <vladimir@codesourcery.com>
3463
3464 Per-thread commands.
3465
3466 * gdbthread.h: Remove unneeded forward declarations.
3467 Include "inferior.h".
3468 (struct thread_info): Add continuations,
3469 intermediate_continuations, proceed_to_finish, step_over_calls,
3470 stop_step, step_multi and stop_signal members.
3471 (save_infrun_state): Add continuations,
3472 intermediate_continuations, proceed_to_finish, step_over_calls,
3473 stop_step, step_multi, stop_signal and stop_bpstat parameters.
3474 (load_infrun_state): Add continuations,
3475 intermediate_continuations, proceed_to_finish, step_over_calls,
3476 stop_step, step_multi, stop_signal and stop_bpstat parameters.
3477
3478 * thread.c (load_infrun_state): In non-stop mode, load
3479 continuations, intermediate_continuations, proceed_to_finish,
3480 step_over_calls, stop_step, step_multi and stop_signal.
3481 (save_infrun_state): Store continuations,
3482 intermediate_continuations, proceed_to_finish, step_over_calls,
3483 stop_step, step_multi, stop_signal and stop_bpstat.
3484 (save_infrun_state): Store continuations,
3485 intermediate_continuations, proceed_to_finish, step_over_calls,
3486 stop_step, step_multi, stop_signal and stop_bpstat.
3487 (free_thread): Clear The thread's stop_bpstat.
3488
3489 * inferior.h (context_switch_to): Declare.
3490
3491 * infrun.c (ecss): New global.
3492 (context_switch): Context switch continuations,
3493 intermediate_continuations, proceed_to_finish, step_over_calls,
3494 stop_step, step_multi, stop_signal and stop_bpstat.
3495 (wait_for_inferior): Use global ecss.
3496 (async_ecss, async_ecs): Delete.
3497 (fetch_inferior_event): Use global ecss.
3498 (context_switch_to): New.
3499
3500 * top.c (execute_command): In non-stop, only check if the current
3501 thread is running, in all-stop, check if there's any thread
3502 running.
3503
3504 * breakpoint.c (bpstat_remove_breakpoint): New.
3505 (bpstat_remove_breakpoint_callback): New.
3506 (delete_breakpoint): Clear the stop_bpstats of all threads.
3507
3508 * mi/mi-main.c (mi_cmd_execute): In non-stop, only check if the
3509 current thread is running, in all-stop, check if there's any
3510 thread running.
3511
3512 * Makefile.in (gdbthread_h): Depend on $(inferior_h).
3513
3514 2008-07-09 Pedro Alves <pedro@codesourcery.com>
3515
3516 Add non_stop global.
3517
3518 * inferior.h (non_stop): Declare.
3519 * infrun.c (non_stop, non_stop_1): New.
3520 (set_non_stop, show_non_stop): New.
3521 (_initialize_infrun): Add "set/show non-stop" command.
3522
3523 2008-07-09 Pedro Alves <pedro@codesourcery.com>
3524
3525 Adjust fork/vfork/exec to pass ptids around.
3526
3527 * target.h (struct target_waitstatus): Store related_pid as a ptid.
3528 (inferior_has_forked, inferior_has_vforked, inferior_has_execd):
3529 Take a ptid_t.
3530 * breakpoint.h (struct breakpoint): Change forked_inferior_pid
3531 type to ptid.
3532 * breakpoint.c (print_it_typical, bpstat_check_location)
3533 (print_one_breakpoint_location, set_raw_breakpoint_without_location)
3534 (create_fork_vfork_event_catchpoint): Adjust.
3535 * infrun.c (fork_event): Change parent_pid and child_pid types to
3536 ptid.
3537 (follow_exec, inferior_has_forked, inferior_has_vforked)
3538 (inferior_has_execd): Take a ptid_t and don't trim it.
3539 * linux-thread-db.c (thread_db_wait): Don't trim the returned ptid.
3540 * linux-nat.c (linux_child_follow_fork): Adjust.
3541 * inf-ptrace.c (inf_ptrace_wait): Adjust.
3542 * inf-ttrace.c (inf_ttrace_wait): Adjust.
3543 * win32-nat.c (get_win32_debug_event): Don't set related_pid.
3544
3545 2008-07-09 Pedro Alves <pedro@codesourcery.com>
3546
3547 Add "executing" property to threads.
3548
3549 * inferior.h (target_executing): Delete.
3550 * gdbthread.h (struct thread_info): Add executing_ field.
3551 (set_executing, is_executing): New.
3552 * thread.c (main_thread_executing): New.
3553 (init_thread_list): Clear it and also main_thread_running.
3554 (is_running): Return false if target has no execution.
3555 (any_running, is_executing, set_executing): New.
3556
3557 * top.c: Include "gdbthread.h".
3558 (target_executing): Delete.
3559 (execute_command): Replace target_executing check by any_running.
3560 * event-top.c: Include "gdbthread.h".
3561 (display_gdb_prompt, command_handler): Replace target_executing by
3562 is_running.
3563 * inf-loop.c: Include "gdbthread.h". Don't mark as not executing
3564 here. Replace target_executing by is_running.
3565 * infrun.c (handle_inferior_event): Mark all threads as
3566 not-executing.
3567 * linux-nat.c (linux_nat_resume): Don't mark thread as executing
3568 here.
3569 * stack.c (get_selected_block): Return null if inferior is
3570 executing.
3571 * target.c (target_resume): Mark resumed ptid as executing.
3572 * breakpoint.c (until_break_command): Replace target_executing
3573 check by is_executing.
3574 * remote.c (remote_async_resume): Don't mark inferior as executing
3575 here.
3576 * mi/mi-interp.c (mi_cmd_interpreter_exec): Replace target_executing
3577 by any_running.
3578
3579 * mi/mi-main.c (mi_cmd_exec_interrupt, mi_cmd_execute)
3580 (mi_execute_async_cli_command): Replace target_executing by
3581 is_running.
3582
3583 * frame.c (get_current_frame): Error out if the current thread is
3584 executing.
3585 (has_stack_frames): New.
3586 (get_selected_frame, deprecated_safe_get_selected_frame): Check
3587 has_stack_frames.
3588
3589 * Makefile.in (event-top.o, frame.o, inf-loop.o, top.o): Depend on
3590 $(gdbthread_h).
3591
3592 2008-07-09 Pedro Alves <pedro@codesourcery.com>
3593
3594 * symfile.c (load_command): Reopen the exec file and reread
3595 symbols before anything else.
3596
3597 2008-07-09 Pedro Alves <pedro@codesourcery.com>
3598
3599 * remote-sim.c: Include gdbthread.h.
3600 (remote_sim_ptid): New global.
3601 (gdbsim_create_inferior): Silently add the main task to GDB's
3602 thread list.
3603 (gdbsim_close, gdbsim_mourn_inferior): Silently delete the main
3604 task from GDB's thread list.
3605 (gdbsim_resume): Adjust to use remote_sim_ptid.
3606 (gdbsim_thread_alive, gdbsim_pid_to_str): New.
3607 (init_gdbsim_ops): Register gdbsim_thread_alive and
3608 gdbsim_pid_to_str.
3609 (_initialize_remote_sim): Initialize remote_sim_ptid.
3610 * Makefile.in (remote-sim.o): Depend on $(gdbthread_h).
3611
3612 2008-07-09 Pedro Alves <pedro@codesourcery.com>
3613
3614 * monitor (monitor_ptid): New global.
3615 (monitor_open): Silently add the main task to GDB's thread list.
3616 (monitor_close, monitor_mourn_inferior): Silently delete the main
3617 task from GDB's thread list.
3618 (monitor_thread_alive, monitor_pid_to_str): New.
3619 (init_base_monitor_ops): Register monitor_thread_alive and
3620 monitor_pid_to_str.
3621 (_initialize_remote_monitors): Initialize monitor_ptid.
3622
3623 * gdbthread.h (delete_thread_silent): Declare.
3624 * thread.c (delete_thread): Rename to ...
3625 (delete_thread_1): ... this. Add "silent" parameter. If silent,
3626 don't do exit notifications.
3627 (delete_thread, delete_thread_silent): New, as wrappers to
3628 delete_thread_1.
3629
3630 2008-07-08 Pedro Alves <pedro@codesourcery.com>
3631
3632 * breakpoint.c (update_global_location_list): Add boolean
3633 "should_insert" argument. Only insert locations if caller told it
3634 too.
3635 (update_global_location_list_nothrow): Add boolean "should_insert"
3636 argument. Pass it to update_global_location_list.
3637 (insert_breakpoints, create_longjmp_breakpoint)
3638 (create_overlay_event_breakpoint, enable_overlay_breakpoints)
3639 (create_thread_event_breakpoint, create_solib_event_breakpoint)
3640 (create_fork_vfork_event_catchpoint, create_exec_event_catchpoint)
3641 (enable_watchpoints_after_interactive_call_stop)
3642 (set_momentary_breakpoint, create_breakpoints)
3643 (break_command_really, watch_command_1)
3644 (create_ada_exception_breakpoint, update_breakpoint_locations)
3645 (do_enable_breakpoint, enable_command): Pass true to
3646 update_global_location_list.
3647 (bpstat_stop_status, disable_overlay_breakpoints)
3648 (disable_watchpoints_before_interactive_call_start)
3649 (delete_breakpoint, disable_breakpoint, disable_command): Pass
3650 false to update_global_location_list.
3651 (update_breakpoints_after_exec): Don't temporarily disable
3652 always-inserted mode.
3653
3654 2008-07-08 Pedro Alves <pedro@codesourcery.com>
3655
3656 * breakpoint.c (mark_breakpoints_out): Make public.
3657 (update_breakpoints_after_exec): Don't call mark_breakpoints_out
3658 here. Update comment.
3659 * breakpoint.h (mark_breakpoints_out): Declare.
3660
3661 * linux-nat.c (linux_handle_extended_wait): On
3662 TARGET_WAITKIND_EXECD, call mark_breakpoints_out.
3663 * inf-ttrace.c (inf_ttrace_wait): Likewise.
3664
3665 2008-07-08 Pedro Alves <pedro@codesourcery.com>
3666
3667 * infrun.c (follow_exec): Reset shared libraries before adding the
3668 main exec file.
3669
3670 2008-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
3671
3672 * breakpoint.c (bpstat_copy): Call RELEASE_VALUE on the new OLD_VAL.
3673
3674 2008-07-07 Pedro Alves <pedro@codesourcery.com>
3675
3676 * i386-dicos-tdep.c: Include "inferior.h".
3677 (i386_dicos_frame_align): New.
3678 (i386_dicos_init_abi): Register i386_dicos_frame_align. Set call
3679 dummy location ON_STACK.
3680 * Makefile.in (i386-dicos-tdep.o): Depend on $(inferior_h).
3681
3682 2008-07-07 Joel Brobecker <brobecker@adacore.com>
3683
3684 * gstdint.h: New file.
3685
3686 2008-07-05 Vladimir Prus <vladimir@codesourcery.com>
3687
3688 * mi/mi-interp.c (mi_on_resume): Don't try to report
3689 resumed thread it the thread list is empty.
3690
3691 2008-07-05 Pierre Muller <muller@ics.u-strasbg.fr>
3692
3693 * cli/cli-decode.c (add_setshow_optional_filename_cmd): Set
3694 completer for set to filename_completer.
3695
3696 NEWS: Mention it.
3697
3698 2008-07-04 Vladimir Prus <vladimir@codesourcery.com>
3699
3700 Implement -target-attach.
3701 * mi/mi-cmds.c (mi_cmds): Forward -target-attach to CLI attach.
3702
3703 2008-06-21 Hui Zhu <teawater@gmail.com>
3704
3705 * target-descriptions.c (maint_print_c_tdesc_cmd): Fix a memory leak.
3706
3707 2008-07-03 Pedro Alves <pedro@codesourcery.com>
3708
3709 * config/i386/nm-cygwin.h (ATTACH_NO_WAIT): Delete.
3710 * config/i386/nm-i386gnu.h (ATTACH_NO_WAIT): Delete.
3711
3712 * target.h (struct target_ops): Add to_attach_no_wait member.
3713 (target_attach_no_wait): New.
3714 * target.c (update_current_target): Inherit to_attach_no_wait.
3715
3716 * infcmd.c: Replace ATTACH_NO_WAIT compile time check by
3717 target_attach_no_wait runtime check.
3718
3719 * gnu-nat.c (init_gnu_ops): Set to_attach_no_wait in gnu_ops.
3720 * win32-nat.c (init_win32_ops): Set to_attach_no_wait in
3721 win32_ops.
3722
3723 2008-07-03 Pedro Alves <pedro@codesourcery.com>
3724
3725 * i386-tdep.c (i386_displaced_step_fixup): Condition log printing
3726 on debug_displaced being set.
3727
3728 2008-06-30 Daniel Jacobowitz <dan@codesourcery.com>
3729
3730 * frame.c (get_prev_frame_1): Call frame_unwind_find_by_frame
3731 directly instead of get_frame_id.
3732
3733 2008-06-30 Luis Machado <luisgpm@br.ibm.com>
3734
3735 * rs6000-tdep.c (ppc_displaced_step_fixup): New function.
3736 (deal_with_atomic_sequence): Update BC masks.
3737 (rs6000_gdbarch_init): Init displaced stepping infra-structure.
3738 Define BRANCH_MASK, B_INSN, BC_INSN, BXL_INSN, BP_MASK and BP_INSN.
3739
3740 2008-06-30 Daniel Jacobowitz <dan@codesourcery.com>
3741
3742 * cris-tdep.c (crisv32_single_step_through_delay): Get this frame's
3743 register, not the previous frame's.
3744
3745 2008-06-30 Luis Machado <luisgpm@br.ibm.com>
3746
3747 * source.c (select_source_symtab): Make sure we skip namespace
3748 symtabs when showing cpp source code.
3749
3750 2008-06-30 Hans-Peter Nilsson <hp@axis.com>
3751
3752 * MAINTAINERS (Authorized committers): Fix my email address.
3753
3754 2008-06-28 Vladimir Prus <vladimir@codesourcery.com>
3755
3756 * mi/mi-cmds.c (mi_cmds): Route -exec-run, -exec-until,
3757 -target-download and -target-select via CLI, so that
3758 the quoting rules are the same as they were (unfortunately)
3759 in all prior gdb releases.
3760 * mi/mi-cmds.h (mi_cmd_exec_run, mi_cmd_exec_until)
3761 (mi_cmd_target_download, mi_cmd_target_select): Remove.
3762 * mi/mi-main.c (mi_cmd_exec_run, mi_cmd_exec_until)
3763 (mi_cmd_target_download, mi_cmd_target_select): Remove.
3764 (mi_cmd_execute): Set current_token even for commands
3765 routed via CLI.
3766
3767 2008-06-28 Ulrich Weigand <uweigand@de.ibm.com>
3768
3769 * alphafbsd-tdep.c: Update for unwinder changes.
3770 * alpha-linux-tdep.c: Likewise.
3771 * alphanbsd-tdep.c: Likewise.
3772 * alphaobsd-tdep.c: Likewise.
3773 * avr-tdep.c: Likewise.
3774 * cris-tdep.c: Likewise.
3775 * frv-linux-tdep.c: Likewise.
3776 * frv-tdep.c: Likewise.
3777 * h8300-tdep.c: Likewise.
3778 * hppa-linux-tdep.c: Likewise.
3779 * iq2000-tdep.c: Likewise.
3780 * m32c-tdep.c: Likewise.
3781 * m32r-linux-tdep.c: Likewise.
3782 * m32r-tdep.c: Likewise.
3783 * m68hc11-tdep.c: Likewise.
3784 * mep-tdep.c: Likewise.
3785 * mn10300-tdep.c: Likewise.
3786 * mt-tdep.c: Likewise.
3787 * score-tdep.c: Likewise.
3788 * sh64-tdep.c: Likewise.
3789 * sh-tdep.c: Likewise.
3790 * sparc64fbsd-tdep.c: Likewise.
3791 * sparc64nbsd-tdep.c: Likewise.
3792 * sparc64obsd-tdep.c: Likewise.
3793 * v850-tdep.c: Likewise.
3794 * vaxobsd-tdep.c: Likewise.
3795 * vax-tdep.c: Likewise.
3796 * xstormy16-tdep.c: Likewise.
3797
3798 2008-06-28 Vladimir Prus <vladimir@codesourcery.com>
3799
3800 * mi/mi-main.c (enum captured_mi_execute_command_actions)
3801 (captured_mi_execute_command_args): Remove.
3802 (captured_mi_execute_command): Cast the closure to mi_parse
3803 pointer, not to captured_mi_execute_command_args, and don't
3804 set the action field thereof.
3805 (mi_execute_command): Pass struct mi_parse, not
3806 captured_mi_execute_command_args to captured_mi_execute_command.
3807 (mi_execute_command): Remove (dead) code for suppressing
3808 printing prompt.
3809
3810 2008-06-28 Pedro Alves <pedro@codesourcery.com>
3811
3812 * linux-nat.c (enum sigchld_state): New.
3813 (linux_nat_async_events_state): Renamed from
3814 linux_nat_async_events_enabled.
3815 (linux_nat_event_pipe_push, my_waitpid): Adjust.
3816 (sigchld_default_action): New.
3817 (lin_lwp_attach_lwp): Adjust. Call linux_nat_async_events
3818 unconditionally.
3819 (linux_nat_create_inferior): Set events state to sigchld_default
3820 state.
3821 (linux_nat_resume): Adjust.
3822 (linux_nat_wait): Call linux_nat_async_events unconditionally.
3823 (sigchld_handler): Adjust.
3824 (linux_nat_async_mask): Don't set SIGCHLD actions here.
3825 (get_pending_events): Adjust.
3826 (linux_nat_async_events): Rewrite to handle enum sigchld_state
3827 instead of a boolean.
3828 (linux_nat_async): Adjust.
3829 (_initialize_linux_nat): Capture default SIGCHLD action into
3830 sigchld_default_action.
3831
3832 2008-06-28 Vladimir Prus <vladimir@codesourcery.com>
3833
3834 * breakpoint.c (moribund_locations): New.
3835 (bpstat_stop_status): Process moribund locations.
3836 (update_global_location_list): Add removed
3837 locations to moribund_locations.
3838 (breakpoint_retire_moribund): New.
3839 * breakpoint.h (struct bp_location): New field
3840 events_till_retirement.
3841 (breakpoint_retire_moribund): Declare.
3842 * thread.c (thread_count): New.
3843 * infrun.c (handle_inferior_event): Call
3844 breakpoint_retire_moribund.
3845 * gdbthread.h (thread_count): Declare.
3846
3847 2008-06-27 Joseph Myers <joseph@codesourcery.com>
3848
3849 * dfp.c (decimal_convert): Call match_endianness before and after
3850 conversion.
3851
3852 2008-06-27 Jonathan Larmour <jifl@eCosCentric.com>
3853
3854 * remote.c (remote_insert_breakpoint): Ensure that if Z0
3855 unsupported and we fall back to memory_insert_breakpoint, we
3856 use the unmodified requested address.
3857
3858 2008-06-27 Joel Brobecker <brobecker@adacore.com>
3859
3860 * dwarf2read.c (read_attribute_value): Issue a complaint when
3861 adjusting size attribute values of 0xffffffff as zero.
3862
3863 2008-06-27 Joseph Myers <joseph@codesourcery.com>
3864
3865 * i386-tdep.c (i386_16_byte_align_p): New.
3866 (i386_push_dummy_call): Determine stack space required for
3867 arguments going forwards allowing for 16-byte alignment, then push
3868 arguments going forwards.
3869
3870 2008-06-27 Pedro Alves <pedro@codesourcery.com>
3871
3872 * infrun.c (start_remote): Don't clear thread list here.
3873 * monitor.c (monitor_open): Include "gdbthread.h". Clear thread
3874 list here.
3875 * remote.c (record_currthread): Upgrade the main thread and its
3876 entry in the thread list if this is the first time we hear about
3877 threads.
3878 (remote_thread_alive): Consider magic_null_ptid or a ptid without
3879 a tid member always alive.
3880 (remote_find_new_threads): Don't update the main thread here.
3881 (remote_start_remote): Clear thread list here. Always add the
3882 main thread.
3883 (extended_remote_attach_1): Add the main thread here.
3884 (extended_remote_mourn_1): Re-add the main thread here.
3885 (extended_remote_create_inferior_1): Add a main thread.
3886
3887 * Makefile.in (monitor.o): Depend on $(gdbthread_h).
3888
3889 2008-06-27 Pedro Alves <pedro@codesourcery.com>
3890
3891 Use ptid_t.tid to store thread ids instead of ptid_t.pid.
3892
3893 * remote.c (magic_null_ptid, not_sent_ptid, any_thread_ptid): New
3894 globals.
3895 (general_thread, continue_thread): Change type to ptid_t.
3896 (record_currthread): Take a ptid_t parameter instead of an
3897 integer.
3898 (MAGIC_NULL_PID): Delete.
3899 (set_thread): Take a ptid_t parameter and adjust.
3900 (set_general_thread, set_continue_thread): New.
3901 (remote_thread_alive, remote_newthread_step)
3902 (remote_current_thread, remote_find_new_threads)
3903 (remote_threads_info, remote_start_remote, remote_vcont_resume)
3904 (remote_resume_1, remote_wait, extended_remote_create_inferior_1)
3905 (threadalive_test, remote_pid_to_str)
3906 (remote_get_thread_local_address): Adjust.
3907 (_initialize_remote): Initialize magic_null_ptid, not_sent_ptid
3908 and any_thread_ptid.
3909
3910 2008-06-26 Jan Kratochvil <jan.kratochvil@redhat.com>
3911
3912 * configure.ac (--enable-tui): AC_MSG_ERROR for explicit --enable-tui.
3913 * configure: Regenerated.
3914
3915 2008-06-26 Joel Brobecker <brobecker@adacore.com>
3916
3917 * dwarf2read.c (read_attribute_value): Treat size attribute
3918 values of 0xffffffff as if the attribute value was zero.
3919
3920 2008-06-26 Vladimir Prus <vladimir@codesourcery.com>
3921
3922 * linux-nat.c: Add description of overall logic.
3923
3924 2008-06-26 Daniel Jacobowitz <dan@codesourcery.com>
3925
3926 * Makefile.in (GNULIB_H): Use GNULIB_STDINT_H.
3927 (gdb_stdint_h, gdb_stdint.h, stamp-int): Delete. Remove
3928 all dependencies on $(gdb_stdint_h).
3929 (distclean): Do not delete gdb_stdint.h.
3930 * acinclude.m4: Do not use stdint.m4.
3931 * configure.ac: Set GNULIB_STDINT_H. Remove tests for stdint.h,
3932 uintptr_t, and gdb_stdint.h.
3933 * defs.h: Include <stdint.h>.
3934 * gdb_thread_db.h: Assume stdint.h is already included.
3935 * breakpoint.c, findcmd.c, hppa-tdep.c, inf-ptrace.c, proc-service.c,
3936 rs6000-nat.c, spu-linux-nat.c, target.c, win32-nat.c: Do not
3937 include gdb_stdint.h.
3938 * configure, config.in: Regenerate.
3939
3940 2008-06-26 Joseph Myers <joseph@codesourcery.com>
3941
3942 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Handle passing
3943 decimal floating-point values in GPRs for soft-float.
3944 (do_ppc_sysv_return_value): Handle returning decimal
3945 floating-point values in GPRs for soft-float.
3946
3947 2008-06-26 Vladimir Prus <vladimir@codesourcery.com>
3948
3949 * target.c (target_read_until_error): New.
3950 * target.h (target_read_until_error): Declare.
3951 * mi/mi-main.c (mi_cmd_data_read_memory): Use
3952 target_read_until_error.
3953
3954 2008-06-25 Jan Kratochvil <jan.kratochvil@redhat.com>
3955
3956 Fix a memory leak found by Hui Zhu <teawater@gmail.com>.
3957 * c-exp.y (parse_number): Move the S and SAVED_CHAR initialization
3958 after the DECFLOAT detection to fix a memory leak. Remove the
3959 redundant NUM initialization. Protect the DECFLOAT detection memory
3960 access before the P block. Restore the P memory content for the
3961 DECFLOAT detection.
3962
3963 2008-06-25 Vladimir Prus <vladimir@codesourcery.com>
3964
3965 Kill the return value for all MI command functions.
3966 * mi/mi-cmds.h (enum mi_cmd_result): Remove.
3967 (mi_cmd_argv_ftype): Change return type to void.
3968
3969 * mi/mi-main.c: Adjust all function that implement
3970 MI commands to return nothing.
3971 (struct captured_mi_execute_command_actions):
3972 Remove the rc field.
3973 (mi_cmd_execute): Return nothing.
3974 (mi_execute_async_cli_command): Return nothing.
3975 (mi_cmd_exec_interrupt): Don't print ^done here.
3976 (mi_cmd_target_select): Don't print ^connected here.
3977 (captured_mi_execute_command): Don't check for MI_CMD_DONE.
3978 Special-case -target-select and output ^connected, not ^done.
3979
3980 * mi/mi-cmd-break.c: Adjust.
3981 * mi/mi-cmd-disas.c: Adjust.
3982 * mi/mi-cmd-env.c: Adjust.
3983 * mi/mi-cmd-file.c: Adjust.
3984 * mi/mi-cmd-stack.c: Adjust.
3985 * mi/mi-cmd-target.c: Adjust.
3986 * mi/mi-cmd-var.c: Adjust.
3987 * mi/mi-interp.c: Adjust.
3988 * mi/mi-symbol-cmds.c: Adjust.
3989
3990 2008-06-25 Vladimir Prus <vladimir@codesourcery.com>
3991
3992 Emit ^running via observer.
3993 * mi/mi-interp.c (mi_cmd_interpreter_exec): Do no print
3994 ^running here.
3995 (mi_on_resume): Print ^running if not previously output.
3996 * mi/mi-main.c (running_result_record_printed): New.
3997 (captured_mi_execute_command): Reset
3998 running_result_record_printed. Use running_result_record_printed
3999 to decide if we should skip ^done.
4000 (mi_execute_async_cli_command): Don't print ^running here.
4001 * mi/mi-main.h (current_token, running_result_record_printed):
4002 Declare.
4003
4004 2008-06-24 Michael Snyder <msnyder@specifix.com>
4005
4006 * infrun.c (_initialize_infrun): White space and typo fix.
4007
4008 2008-06-23 Christopher Faylor <me.gdb.changelog@cgf.cx>
4009
4010 * win32-nat.c (safe_symbol_file_add_stub): Remove unused variable.
4011 (do_initial_win32_stuff): Fix problem with inability to set breakpoints
4012 when first loading DLL with "dll" command.
4013
4014 2008-06-19 Pierre Muller <muller@ics.u-strasbg.fr>
4015
4016 * gnu-nat.c (proc_string): Use capital T for "Thread".
4017
4018 2008-06-19 Pierre Muller <muller@ics.u-strasbg.fr>
4019
4020 * win32-nat.c (win32_pid_to_str): Use capital T for "Thread".
4021
4022 2008-06-18 Joel Brobecker <brobecker@adacore.com>
4023
4024 * solib-osf.c (osf_solib_create_inferior_hook): Do nothing if
4025 the target cannot run.
4026
4027 2008-06-18 Joel Brobecker <brobecker@adacore.com>
4028
4029 * solib-osf.c (osf_solib_create_inferior_hook): Do nothing if
4030 we're attaching to a running process.
4031
4032 2008-06-18 Pierre Muller <muller@ics.u-strasbg.fr>
4033
4034 * win32-nat.c (handle_load_dll): Give dll name and load address
4035 if debug_events is on.
4036 (handle_unload_dll): Likewise.
4037
4038 2008-06-14 Vladimir Prus <vladimir@codesourcery.com>
4039
4040 Don't suppress *running when doing finish.
4041 * infcall.c (call_function_by_hand): Set both
4042 suppress_resume_observer and suppress_stop_observer.
4043 * infcmd.c (suppress_run_stop_observers): Split into...
4044 (suppress_resume_observer, suppress_stop_observer): ...those.
4045 (finish_command_continuation): Clear suppress_stop_observer.
4046 (finish_command): Set suppress_stop_observer.
4047 * inferior.h (suppress_run_stop_observers): Split into...
4048 (suppress_resume_observer, suppress_stop_observer): ...those.
4049 * infrun.c (normal_stop): Check for suppress_stop_observer.
4050 * thread.c (set_running): Check for suppress_resume_observer.
4051
4052 2008-06-12 Pedro Alves <pedro_alves@portugalmail.pt>
4053 Pierre Muller <muller@ics.u-strasbg.fr>
4054
4055 * gdbarch.sh (gdbarch_skip_main_prologue): New.
4056 * gdbarch.h, gdbarch.c: Regenerate.
4057 * i386-tdep.h (i386_skip_main_prologue): Declare.
4058 * i386-tdep.c (i386_skip_main_prologue): New.
4059 * i386-cygwin-tdep.c (i386_cygwin_init_abi): Register
4060 i386_skip_main_prologue as gdbarch_skip_main_prologue gdbarch callback.
4061 * symtab.c (find_function_start_sal): When pc points at the "main"
4062 function, call gdbarch_skip_main_prologue.
4063
4064 2008-06-11 Daniel Jacobowitz <dan@codesourcery.com>
4065
4066 * value.c (value_primitive_field): Fetch lazy register values.
4067
4068 2008-06-11 Pedro Alves <pedro@codesourcery.com>
4069
4070 * NEWS: Mention support removal of undocumented S AA p PID stop
4071 reply packet.
4072
4073 * remote.c (remote_wait): Remove undocumented S AA p PID support.
4074
4075 2008-06-10 Stan Shebs <stan@codesourcery.com>
4076
4077 * MAINTAINERS: Update my affiliation and address.
4078
4079 2008-06-10 Andreas Schwab <schwab@suse.de>
4080
4081 * top.c (print_gdb_version): Don't print final newline.
4082
4083 2008-06-10 Vladimir Prus <vladimir@codesourcery.com>
4084
4085 Implement *running.
4086 * Makefile.in: Update dependencies.
4087 * gdbthread.h (struct thread_info): New field
4088 running_.
4089 (set_running, is_running): New.
4090 * thread.c (set_running, is_running): New.
4091 * inferior.h (suppress_normal_stop_observer): Rename to...
4092 (suppress_run_stop_observers): ..this.
4093 * infcmd.c (suppress_normal_stop_observer): Rename to...
4094 (suppress_run_stop_observers): ..this.
4095 (finish_command_continuation, finish_command): Adjust.
4096 * infcall.c (call_function_by_hand): Adjust.
4097 * infrun.c (normal_stop): Call set_running.
4098 * target.c (target_resume): New. Call set_running.
4099 * target.h (target_resume): Convert from macro to
4100 a function.
4101
4102 * mi/mi-interp.c (mi_on_resume): New.
4103 (mi_interpreter_init): Register mi_on_resume.
4104
4105 2008-06-10 Vladimir Prus <vladimir@codesourcery.com>
4106
4107 Use observers to report stop events in MI.
4108 * mi/mi-interp.c (mi_on_normal_stop): New.
4109 (mi_interpreter_init): Register mi_on_normal_stop.
4110 (mi_interpreter_exec_continuation): Remove.
4111 (mi_cmd_interpreter_exec): Don't register the above.
4112 * mi/mi-main.c (captured_mi_execute_command): Don't care
4113 about sync_execution.
4114 (mi_execute_async_cli_command): Don't install continuation. Don't
4115 print *stopped.
4116 (mi_exec_async_cli_cmd_continuation): Remove.
4117
4118 2008-06-10 Vladimir Prus <vladimir@codesourcery.com>
4119
4120 Suppress normal stop observer when it's problematic.
4121 * inferior.h (suppress_normal_stop_observer): New.
4122 * infcall.c (call_function_by_hand): Disable stop events when
4123 doing function calls.
4124 * infmcd.c (suppress_normal_stop_observer): New.
4125 (finish_command_continuation): Call normal_stop observer
4126 explicitly.
4127 (finish_command): Disable stop events inside proceed.
4128 * infrun.c (normal_stop): Don't call normal stop observer if
4129 suppressed of if multi-step is in progress.
4130
4131 2008-06-10 Vladimir Prus <vladimir@codesourcery.com>
4132
4133 Remove stale code.
4134 * infrun.c (finish_command): Don't pass cleanup
4135 to continuation.
4136 (finish_command_continuation): Don't grab cleanup from
4137 the passed data, as we don't use, and cannot, use it anyway.
4138
4139 2008-06-10 Vladimir Prus <vladimir@codesourcery.com>
4140
4141 Introduce common cleanup for restoring integers.
4142 * defs.h (make_cleanup_restore_integer): New declaration.
4143 (struct cleanup): New field free_arg.
4144 (make_my_cleanup_2): New.
4145 * utils.c (restore_integer_closure, restore_integer)
4146 (make_cleanup_restore_integer): New.
4147 (make_my_cleanup): Initialize the free_arg field and
4148 renamed to make_my_cleanup_2.
4149 (do_my_cleanups): Call free_arg.
4150 (discard_cleanups): Call free_arg.
4151 * breakpoint.c (restore_always_inserted_mode): Remove.
4152 (update_breakpoints_after_exec): Use make_cleanup_restore_integer.
4153
4154 2008-06-09 Doug Evans <dje@google.com>
4155
4156 * remote.c (remote_wait): Include beginning of malformed packet
4157 in error output.
4158
4159 2008-06-09 Tom Tromey <tromey@redhat.com>
4160
4161 * completer.c (complete_line): Don't special-case
4162 expression_completer.
4163 (expression_completer): Only pass last word to
4164 location_completer.
4165 * c-exp.y (yylex): Check 'token', not 'operator'.
4166
4167 2008-06-09 Daniel Jacobowitz <dan@codesourcery.com>
4168
4169 * configure.ac (build_warnings): Add -Wno-format for mingw.
4170 * configure: Regenerated.
4171
4172 2008-06-07 Daniel Jacobowitz <dan@codesourcery.com>
4173
4174 * NEWS: Make indentation consistent. Move exec tracing entry out
4175 of remote packet list.
4176
4177 2008-06-06 Tom Tromey <tromey@redhat.com>
4178
4179 * value.h (evaluate_subexpression_type, extract_field_op):
4180 Declare.
4181 * printcmd.c (_initialize_printcmd): Use expression_completer for
4182 'p', 'inspect', 'call'.
4183 * parser-defs.h (parse_field_expression): Declare.
4184 * parse.c: Include exceptions.h.
4185 (in_parse_field, expout_last_struct): New globals.
4186 (mark_struct_expression): New function.
4187 (prefixify_expression): Return int.
4188 (prefixify_subexp): Return int. Use expout_last_struct.
4189 (parse_exp_1): Update.
4190 (parse_exp_in_context): Add 'out_subexp' argument. Handle
4191 in_parse_field.
4192 (parse_field_expression): New function.
4193 * expression.h (parse_field_expression): Declare.
4194 (in_parse_field): Likewise.
4195 * eval.c (evaluate_subexpression_type): New function.
4196 (extract_field_op): Likewise.
4197 * completer.h (expression_completer): Declare.
4198 * completer.c (expression_completer): New function.
4199 (count_struct_fields, add_struct_fields): New functions.
4200 * c-exp.y (yyparse): Redefine.
4201 (COMPLETE): New token.
4202 (exp): New productions.
4203 (saw_name_at_eof, last_was_structop): New globals.
4204 (yylex): Return COMPLETE when needed. Recognize in_parse_field.
4205 (c_parse): New function.
4206 * breakpoint.c (_initialize_breakpoint): Use expression_completer
4207 for watch, awatch, and rwatch.
4208 * Makefile.in (parse.o): Depend on exceptions_h.
4209
4210 2008-06-06 Paul Pluzhnikov <ppluzhnikov@google.com>
4211
4212 PR gdb/1147
4213 * gdb/valopts.c (find_overload_match): Handle references
4214 to pointers.
4215
4216 2008-06-06 Paul N. Hilfinger <hilfinger@adacore.com>
4217
4218 * ada-lang.c (ada_value_assign): Correct big-endian case to take into
4219 account the bitsize of the 'from' operand.
4220
4221 2008-06-06 Pedro Alves <pedro@codesourcery.com>
4222
4223 * annotate.h (annotate_thread_changed): Declare.
4224
4225 2008-06-06 Nick Roberts <nickrob@snap.net.nz>
4226
4227 * annotate.c (annotate_thread_changed): New function.
4228 * thread.c (thread_command) : Use it.
4229 * infrun.c (normal_stop): Use it.
4230
4231 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
4232 Nathan Sidwell <nathan@codesourcery.com>
4233 Joseph Myers <joseph@codesourcery.com>
4234
4235 * acinclude.m4: Include ../config/acx.m4.
4236 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
4237 * configure, config.in: Regenerate.
4238 * main.c (print_gdb_help): Use REPORT_BUGS_TO for bug-reporting
4239 address.
4240 * top.c (print_gdb_version): Use PKGVERSION and REPORT_BUGS_TO.
4241
4242 2008-06-05 Pedro Alves <pedro@codesourcery.com>
4243
4244 Replace 'target async' by 'maintenance set remote-async' and
4245 'target remote' combination.
4246
4247 * remote.c (remote_async_wait): Merge into remote_wait, and
4248 remove.
4249 (remote_async_permitted, remote_async_permitted_set): New
4250 variables.
4251 (set_maintenance_remote_async_permitted)
4252 (show_maintenance_remote_async_permitted): New functions.
4253 (remote_async_ops, extended_async_remote_ops): Delete.
4254 (remote_async_open, extended_remote_async_open): Delete.
4255 (remote_open_1): Drop async_p parameter. Update callers. Replace
4256 async_p with remote_async_permitted checks.
4257 (extended_async_remote_attach): Delete.
4258 (remote_resume, remote_async_resume): Merge and leave remote_resume.
4259 (remote_async_terminal_inferior): Rename to...
4260 (remote_terminal_inferior): ... this, and add
4261 remote_async_termitted check.
4262 (remote_async_terminal_ours): Rename to...
4263 (remote_terminal_ours): ... this, and add remote_async_termitted
4264 check.
4265 (remote_wait, remote_async_wait): Merge and leave remote_wait
4266 only.
4267 (remote_kill, remote_async_kill): Merge and leave remote_kill
4268 only.
4269 (remote_async_mourn, extended_async_remote_mourn): Delete.
4270 (extended_remote_create_inferior_1): Drop async_p parameter.
4271 Update callers. Always use extended_remote_ops.
4272 (extended_remote_async_create_inferior): Delete.
4273 (remote_return_zero): Delete.
4274 (init_remote_ops): Register remote_can_async_p, remote_async,
4275 remote_async_mask, remote_terminal_inferior and
4276 remote_terminal_ours.
4277 (remote_can_async_p, remote_is_async_p): Check for
4278 remote_async_permitted.
4279 (init_remote_async_ops, init_extended_async_remote_ops): Remove.
4280 (set_remote_cmd): Don't add async and extended-async targets.
4281 (_initialize_remote): Add set/show remote-async maintenance
4282 commands.
4283
4284 2008-06-05 Pedro Alves <pedro@codesourcery.com>
4285
4286 * remote.c (kill_kludge): Delete.
4287 (remote_wait, remote_async_wait): Don't set it.
4288 (remote_kill, remote_async_kill): Don't do anything with it.
4289
4290 2008-06-05 Pedro Alves <pedro@codesourcery.com>
4291
4292 * linux-thread-db.c (thread_db_wait): Don't trim event ptid.
4293
4294 2008-06-05 Aleksandar Ristovski <aristovski@qnx.com>
4295
4296 * bcache.c (bcache_data): Call deprecated_bcache_added function.
4297 (deprecated_bcache_added): New function name. Body of function
4298 bcache_data is used here with the addition of 'added' argument.
4299 * bcache.h (deprecated_bcache_added): New function.
4300 * symfile.c (add_psymbol_to_bcache): New helper function, takes part of
4301 work from add_psymbol_to_list - initialises partial symbol and stashes
4302 it in objfile's cache.
4303 (append_psymbol_to_list): New helper function, takes other part of
4304 work from add_psymbol_to_list - adds partial symbol to the given list.
4305 (add_psymbol_to_list): Call helper functions instead of doing work
4306 here. If adding to global list, do not duplicate partial symbols in the
4307 partial symtab.
4308
4309 2008-06-05 Aleksandar Ristovski <aristovski@qnx.com>
4310
4311 * breakpoint.c (print_exception_catchpoint): Put 'exception' back to
4312 'exception caught|thrown' message.
4313
4314 2008-06-05 Jan Kratochvil <jan.kratochvil@redhat.com>
4315
4316 * Makefile.in: Update dependencies.
4317 * dwarf2expr.c: New include "gdb_assert.h".
4318 (new_dwarf_expr_context): Initialize MAX_RECURSION_DEPTH.
4319 (dwarf_expr_eval): Sanity check the RECURSION_DEPTH count.
4320 (execute_stack_op): Error out on too large RECURSION_DEPTH.
4321 Increase/decrease RECURSION_DEPTH around the function.
4322
4323 2008-06-05 Daniel Jacobowitz <dan@codesourcery.com>
4324
4325 * remote.c (get_offsets): Handle a single segment.
4326 * symfile.c (symfile_map_offsets_to_segments): Allow more bases
4327 than segments.
4328
4329 2008-06-03 Daniel Jacobowitz <dan@codesourcery.com>
4330
4331 * solib-svr4.c (struct lm_info): Add lm_addr.
4332 (main_lm_addr): New.
4333 (svr4_default_sos): Set lm_addr.
4334 (svr4_current_sos): Set lm_addr and main_lm_addr.
4335 (svr4_fetch_objfile_link_map): Rewrite.
4336 (svr4_clear_solib): Clear main_lm_addr.
4337
4338 2008-06-03 Michael Snyder <msnyder@redhat.com>
4339 Joseph Myers <joseph@codesourcery.com>
4340
4341 * mips-tdep.c (mips_eabi_return_value): Replace stub that always
4342 returned RETURN_VALUE_STRUCT_CONVENTION with a real function.
4343
4344 2008-06-02 Roman Zippel <zippel@linux-m68k.org>
4345
4346 * m68klinux-tdep.c (m68k_linux_pc_in_sigtramp): Fix incorrect test.
4347
4348 2008-06-02 Roman Zippel <zippel@linux-m68k.org>
4349
4350 * m68k-tdep.c (m68k_analyze_prologue): Fix length of lea insn.
4351
4352 2008-06-01 Joel Brobecker <brobecker@adacore.com>
4353
4354 * rs6000-aix-tdep.c (rs6000_convert_from_func_ptr_addr): Do not
4355 treat pointers in data space as function descriptors if the
4356 target address is also in the data space.
4357
4358 2008-05-30 Joel Brobecker <brobecker@adacore.com>
4359
4360 * alpha-tdep.c (alpha_heuristic_frame_unwind_cache): Set
4361 the trad-frame register value for the SP register.
4362
4363 2008-05-29 Mark Kettenis <kettenis@gnu.org>
4364
4365 * sparcnbsd-tdep.c, sparcobsd-tdep.c: Update for unwinder changes.
4366
4367 2008-05-28 Joel Brobecker <brobecker@adacore.com>
4368
4369 * ia64-tdep.c (ia64_convert_from_func_ptr_addr): Improve the heuristic
4370 that identifies function descriptors outside of the .opd section.
4371
4372 2008-05-28 Aleksandar Ristovski <aristovski@qnx.com>
4373
4374 * breakpoint.c (print_exception_catchpoint): In CLI add 'Temporary' for
4375 temporary catchpoints. In MI add missing fields 'reason', 'disp',
4376 'bkptno'.
4377 (print_mention_exception_catchpoint): Add 'Temporary' for temporary
4378 catchpoints.
4379 (handle_gnu_v3_exceptions): Use tempflag.
4380
4381 2008-05-28 Vladimir Prus <vladimir@codesourcery.com>
4382
4383 Refactor varobj_update interface.
4384 * varobj.c (varobj_update): Report changes as vector. Also
4385 return not just a list of varobj, but a list of special structures
4386 that tell what exactly has changed.
4387 * varobj.h (enum varobj_update_error): Rename to
4388 varobj_scope_status.
4389 (struct varobj_update_result_t): New.
4390 (varobj_update): Adjust prototype.
4391 * mi/mi-cmd-var.c: Adjust for changes.
4392
4393 2008-05-28 Vladimir Prus <vladimir@codesourcery.com>
4394
4395 * varobj.c (varobj_update): Fix comment typo.
4396 Fix indentation.
4397
4398 2008-05-26 Joel Brobecker <brobecker@adacore.com>
4399
4400 Set the symtab field of symbols read from ECOFF debugging entries.
4401 * mdebugread.c (add_symbol): Add new parameter symtab.
4402 (parse_symbol): Update calls to add_symbol throughout.
4403
4404 2008-05-27 Andreas Schwab <schwab@suse.de>
4405
4406 * symtab.h (enum address_class): Remove LOC_REGPARM and
4407 LOC_COMPUTED_ARG.
4408 (struct symbol): Add is_argument.
4409 (SYMBOL_IS_ARGUMENT): Define.
4410
4411 * ada-lang.c (ada_add_block_symbols): Use SYMBOL_IS_ARGUMENT.
4412 * buildsym.c (finish_block): Likewise.
4413 * stack.c (print_frame_args, print_block_frame_locals)
4414 (print_frame_arg_vars): Likewise.
4415 * symtab.c (lookup_block_symbol): Likewise.
4416 * tracepoint.c (add_local_symbols): Likewise.
4417 * mi/mi-cmd-stack.c (list_args_or_locals): Likewise.
4418
4419 * coffread.c (process_coff_symbol): Set SYMBOL_IS_ARGUMENT.
4420 * dwarf2read.c (new_symbol): Likewise.
4421 * mdebugread.c (parse_symbol): Likewise.
4422 * stabsread.c (define_symbol): Likewise.
4423
4424 * ada-exp.y (select_possible_type_sym): Don't handle LOC_REGPARM
4425 and LOC_COMPUTED_ARG.
4426 * ada-lang.c (resolve_subexp, symtab_for_sym): Likewise.
4427 * ax-gdb.c (gen_var_ref): Likewise.
4428 * eval.c (evaluate_subexp_for_address): Likewise.
4429 * findvar.c (symbol_read_needs_frame, read_var_value): Likewise.
4430 * m2-exp.y (yylex): Likewise.
4431 * printcmd.c (address_info): Likewise.
4432 * symmisc.c (print_symbol, print_partial_symbols): Likewise.
4433 * tracepoint.c (collect_symbol, scope_info): Likewise.
4434
4435 2008-05-24 Carlos Eduardo Seo <cseo@linux.vnet.ibm.com>
4436
4437 * gdbarch.sh: Added new gdbarch struct
4438 core_regset_sections.
4439 * gdbarch.c: Refreshed.
4440 * gdbarch.h: Refreshed.
4441 * regset.h (core_regset_section): Declared.
4442 * linux-nat.c (linux_nat_do_thread_registers): Added
4443 support for the new gdbarch struct core_regset_sections.
4444 * utils.c (host_address_to_string): New function.
4445 * defs.h (host_address_to_string): New prototype.
4446 * i386-linux-tdep.c (i386_regset_rections): New register
4447 sections list for i386.
4448 (i386_linux_init_abi): Initialized new gdbarch struct
4449 core_regset_sections.
4450 * Makefile.in: Updated to reflect dependency changes.
4451 * ppc-linux-tdep.c (ppc_regset_sections): Register
4452 sections list for ppc.
4453 (ppc_linux_init_abi): Initialized new gdbarch struct
4454 core_regset_sections
4455
4456 2008-05-24 Andreas Schwab <schwab@suse.de>
4457
4458 * linespec.c (decode_objc): Save current language around call to
4459 get_selected_block.
4460
4461 2008-05-23 Joel Brobecker <brobecker@adacore.com>
4462
4463 * valprint.h (get_array_bounds): Renames get_array_low_bound.
4464 * valprint.c (get_array_bounds): Renames get_array_low_bound.
4465 Return the proper bound value if the array index type is an
4466 enumerated type. Compute the high bound if requested.
4467 (val_print_array_elements): Handle the case when the array
4468 element has a null size.
4469 * ada-valprint.c (print_optional_low_bound): Add handling
4470 for empty arrays or arrays of zero-size elements.
4471 (ada_val_print_array): New function, extracted out from
4472 ada_val_print_1 case TYPE_CODE_ARRAY, and enhanced to
4473 handle empty arrays and arrays of zero-size elements.
4474 (ada_val_print_1)[case TYPE_CODE_ARRAY]: Replace extracted-out
4475 code by call to ada_val_print_array.
4476 (ada_value_print): Remove handling of null array. The handling
4477 was incomplete and is now better handled by ada_val_print_array.
4478
4479 2008-05-23 Markus Deuling <deuling@de.ibm.com>
4480
4481 * annotate.c (annotate_source, annotate_frame_begin): Replace
4482 deprecated_print_address_numeric with paddress.
4483 * cli/cli-cmds.c (list_command, edit_command): Likewise.
4484 * tui/tui-stack.c (tui_make_status_line): Likewise.
4485
4486 * defs.h (deprecated_print_address_numeric): Remove.
4487 * printcmd.c (deprecated_print_address_numeric): Remove.
4488 * maint.c (maint_print_section_info): Fix comment.
4489
4490 2008-05-23 Markus Deuling <deuling@de.ibm.com>
4491
4492 * valprint.c (print_hex_chars, print_octal_chars, print_decimal_chars,
4493 print_binary_chars, print_char_chars): Add byte_order parameter and
4494 replace gdbarch_byte_order.
4495 (print_decimal_chars): Replace START_P, NOT_END_P and NEXT_P by their
4496 expressions and remove them. Remove unused TWO_TO_FOURTH.
4497 (val_print_type_code_int): Introduce gdbarch_byte_order to get at the
4498 endianness. Update call to print_hex_chars.
4499 * valprint.h (print_hex_chars, print_octal_chars, print_decimal_chars,
4500 print_binary_chars, print_char_chars): Add byte_order parameter.
4501 * printcmd.c (print_scalar_formatted): Introduce gdbarch_byte_order to
4502 get at the endianness. Update print_*_char calls to use byte_order.
4503
4504 2008-05-22 Ulrich Weigand <uweigand@de.ibm.com>
4505
4506 * symtab.h (struct symbol): Make "aux_value" member a void pointer
4507 instead of a union.
4508 (SYMBOL_LOCATION_BATON): Update.
4509
4510 2008-05-22 Ulrich Weigand <uweigand@de.ibm.com>
4511
4512 * symtab.h (enum address_class): Remove LOC_BASEREG and
4513 LOC_BASEREG_ARG.
4514 (struct symbol): Remove "basereg" member of "aux_value" union.
4515 (SYMBOL_BASEREG): Remove.
4516
4517 * ada-exp.y (select_possible_type_sym): Do not handle LOC_BASEREG
4518 or LOC_BASEREG_ARG.
4519 * ada-lang.c (resolve_subexp, symtab_for_sym): Likewise.
4520 (ada_add_block_symbols): Likewise.
4521 * ax-gdb.c (gen_var_ref): Likewise.
4522 * buildsym.c (finish_block): Likewise.
4523 * findvar.c (symbol_read_needs_frame, read_var_value): Likewise.
4524 * m2-exp.y (yylex): Likewise.
4525 * mi/mi-cmd-stack.c (list_args_or_locals): Likewise.
4526 * printcmd.c (address_info): Likewise.
4527 * stack.c (print_frame_args, print_block_frame_locals): Likewise.
4528 (print_frame_arg_vars): Likewise.
4529 * symmisc.c (print_symbol): Likewise.
4530 * symtab.c (lookup_block_symbol): Likewise.
4531 * tracepoint.c (collect_symbol, add_local_symbols): Likewise.
4532 (scope_info): Likewise.
4533
4534 2008-05-22 Ulrich Weigand <uweigand@de.ibm.com>
4535
4536 * symtab.h (enum address_class): Remove LOC_LOCAL_ARG.
4537
4538 * ada-exp.y (select_possible_type_sym): Do not handle LOC_LOCAL_ARG.
4539 * ada-lang.c (resolve_subexp, symtab_for_sym): Likewise.
4540 (ada_add_block_symbols): Likewise.
4541 * ax-gdb.c (gen_var_ref): Likewise.
4542 * buildsyms.c (finish_block): Likewise.
4543 * findvar.c (symbol_read_needs_frame, read_var_value): Likewise.
4544 * m2-exp.y (yylex): Likewise.
4545 * mi/mi-cmd-stack.c (list_args_or_locals): Likewise.
4546 * printcmd.c (address_info): Likewise.
4547 * stack.c (print_frame_args, print_frame_arg_vars): Likewise.
4548 * symmisc.c (print_symbol, print_partial_symbols): Likewise.
4549 * symtab.c (lookup_block_symbol): Likewise.
4550 * tracepoint.c (collect_symbol, add_local_symbols): Likewise.
4551 (scope_info): Likewise.
4552
4553 2008-05-22 Ulrich Weigand <uweigand@de.ibm.com>
4554
4555 * symtab.h (enum address_class): Remove LOC_INDIRECT and
4556 LOC_HP_THREAD_LOCAL_STATIC.
4557
4558 * findvar.c (symbol_read_needs_frame, read_var_value): Do not
4559 handle LOC_INDIRECT or LOC_HP_THREAD_LOCAL_STATIC.
4560 (read_var_value): Likewise.
4561 * buildsym.c (finish_block): Likewise.
4562 * objfiles.c (objfile_relocate): Likewise.
4563 * printcmd.c (address_info): Likewise.
4564 * symmisc.c (print_symbol, print_partial_symbols): Likewise.
4565 * tracepoint.c (scope_info): Likewise.
4566
4567 2008-05-21 Markus Deuling <deuling@de.ibm.com>
4568 Maxim Grigoriev <maxim2405@gmail.com>
4569
4570 * xtensa-tdep.c (xtensa_read_register): Remove.
4571 (xtensa_frame_cache): Get rid of xtensa_read_register. Pass extra
4572 argument litbase to call0_frame_cache().
4573 (call0_track_op, call0_analyze_prologue)
4574 (call0_frame_cache): Use extra argument litbase.
4575
4576 2008-05-21 Joel Brobecker <brobecker@adacore.com>
4577
4578 * infcmd.c (_initialize_infcmd): Add new "fin" alias for "finish".
4579
4580 2008-05-21 Ulrich Weigand <uweigand@de.ibm.com>
4581
4582 * frame.h (SIZEOF_FRAME_SAVED_REGS): Remove.
4583
4584 2008-05-21 Ulrich Weigand <uweigand@de.ibm.com>
4585
4586 * alpha-mdebug-tdep.c: Include "trad-frame.h".
4587 (struct alpha_mdebug_unwind_cache): Change type of SAVED_REGS to
4588 struct trad_frame_saved_reg *.
4589 (alpha_mdebug_frame_unwind_cache): Allocate SAVED_REGS using
4590 trad_frame_alloc_saved_regs. Update accesses. Record previous
4591 value of SP as being vfp.
4592 (alpha_mdebug_frame_prev_register): Use trad_frame_get_prev_register.
4593 * Makefile.in (alpha-mdebug-tdep.o): Update dependencies.
4594
4595 2008-05-21 Markus Deuling <deuling@de.ibm.com>
4596
4597 * score-tdep.c (score_print_insn): Get the current endianess from
4598 disassemble_info instead of gdbarch_byte_order.
4599
4600 2008-05-21 Pedro Alves <pedro@codesourcery.com>
4601
4602 * frame.c (get_prev_frame_1): Build frame id before setting
4603 this_frame->prev_p, not after.
4604
4605 2008-05-21 Nick Roberts <nickrob@snap.net.nz>
4606
4607 * annotate.c (annotate_new_thread): New function for new-thread
4608 annotation.
4609 * annotate.h: (annotate_new_thread): New extern.
4610 * thread.c (add_thread_with_info): Use it.
4611 * Makefile.in (thread.o): Add dependency on annotate.h.
4612
4613 2008-05-20 Joel Brobecker <brobecker@adacore.com>
4614
4615 * win32-nat.c (win32_wait): Block the control-c event while
4616 waiting for a debug event.
4617
4618 2008-05-19 Pedro Alves <pedro@codesourcery.com>
4619
4620 * symtab.h (lookup_symbol_in_language): Update comment.
4621 * symtab.c (lookup_symbol_aux_block): Update comment.
4622 * ada-lang.c (ada_lookup_symbol_list): Update comment.
4623
4624 2008-05-19 Ulrich Weigand <uweigand@de.ibm.com>
4625
4626 * symtab.h (lookup_symbol_in_language): Remove SYMTAB parameter.
4627 (lookup_symbol): Likewise.
4628 * symtab.c (lookup_symbol_in_language): Remove SYMTAB parameter.
4629 (lookup_symbol): Likewise.
4630 (search_symbols): Update.
4631
4632 * linespec.c (find_methods, collect_methods): Update.
4633 (add_matching_methods, add_constructors): Update.
4634 (decode_compound, decode_dollar, decode_variable): Update.
4635 (lookup_prefix_sym): Update.
4636
4637 (symbol_found): Remove SYM_SYMTAB parameter.
4638 Use SYMBOL_SYMTAB (sym) instead.
4639
4640 * gdbtypes.c (lookup_typename): Update.
4641 (lookup_struct, lookup_union, lookup_enum): Update.
4642 (lookup_template_type): Update.
4643 (check_typedef): Update.
4644 * language.c (lang_bool_type): Update.
4645 * mdebugread.c (parse_procedure): Update.
4646 * mi/mi-cmd-stack.c (list_args_or_locals): Update.
4647 * parse.c (write_dollar_variable): Update.
4648 * printcmd.c (address_info): Update.
4649 * source.c (select_source_symtab): Update.
4650 * stack.c (print_frame_args, print_frame_arg_vars): Update.
4651 * valops.c (find_function_in_inferior): Update.
4652 (value_struct_elt_for_reference): Update.
4653 * value.c (value_static_field, value_fn_field): Update.
4654
4655 * alpha-mdebug-tdep.c (find_proc_desc): Update.
4656 * arm-tdep.c (arm_skip_prologue): Update.
4657 * mt-tdep.c (mt_skip_prologue): Update.
4658 * xstormy16-tdep.c (xstormy16_skip_prologue): Update.
4659
4660 * ada-lang.h (struct ada_symbol_info): Remove SYMTAB member.
4661 * ada-lang.c (ada_add_block_symbols): Remove SYMTAB parameter.
4662 (add_defn_to_vec): Likewise.
4663 (ada_add_block_symbols): Likewise.
4664 (lookup_cached_symbol, cache_symbol): Likewise.
4665 (standard_lookup): Update.
4666 (ada_lookup_symbol_list): Update.
4667
4668 * c-valprint.c (c_val_print): Update.
4669 * cp-support.c (cp_lookup_rtti_type): Update.
4670 * jv-lang.c (java_lookup_class, get_java_object_type): Update.
4671 * objc-lang.c (lookup_struct_typedef, find_imps): Update.
4672 * p-valprint.c (pascal_val_print): Update.
4673 * scm-lang.c (scm_lookup_name): Update.
4674
4675 * c-exp.y: Update.
4676 * f-exp.y: Update.
4677 * jv-exp.y: Update.
4678 * m2-exp.y: Update.
4679 * objc-exp.y: Update.
4680 * p-exp.y: Update.
4681
4682 2008-05-19 Ulrich Weigand <uweigand@de.ibm.com>
4683
4684 * language.h (struct language_defn): Remove SYMTAB parameter from
4685 la_lookup_symbol_nonlocal callback function pointer.
4686
4687 * ada-lang.h (ada_lookup_encoded_symbol): Remove SYMTAB parameter.
4688 (ada_lookup_encoded_symbol): Likewise.
4689 * ada-lang.c (ada_lookup_encoded_symbol): Remove SYMTAB parameter.
4690 Always call fixup_symbol_section.
4691 (ada_lookup_symbol): Remove SYMTAB parameter.
4692 (ada_lookup_symbol_nonlocal): Likewise.
4693 * ada-exp.y (write_object_renaming): Update.
4694 (find_primitive_type): Likewise.
4695
4696 * cp-support.h (cp_lookup_symbol_nonlocal): Remove SYMTAB parameter.
4697 (cp_lookup_symbol_namespace): Likewise.
4698 * cp-namespace.c (lookup_namespace_scope): Remove SYMTAB parameter.
4699 (lookup_symbol_file): Likewise.
4700 (lookup_possible_namespace_symbol): Likewise.
4701 (cp_lookup_symbol_nonlocal): Likewise.
4702 (cp_lookup_symbol_namespace): Likewise.
4703 (cp_lookup_nested_type): Update.
4704
4705 * scm-valprint.c (scm_inferior_print): Update.
4706 * valops.c (value_maybe_namespace_elt): Update.
4707
4708 * solist.h (struct target_so_ops): Remove SYMTAB parameter from
4709 lookup_lib_global_symbol callback function pointer.
4710 (solib_global_lookup): Remove SYMTAB parameter.
4711 * solib.c (solib_global_lookup): Remove SYMTAB parameter.
4712 * solib-svr4.c (elf_lookup_lib_symbol): Likewise.
4713
4714 * symtab.h (basic_lookup_symbol_nonlocal): Remove SYMTAB parameter.
4715 (lookup_symbol_static): Likewise.
4716 (lookup_symbol_global): Likewise.
4717 (lookup_symbol_aux_block): Likewise.
4718 (lookup_global_symbol_from_objfile): Likewise.
4719 * symtab.c (lookup_symbol_aux): Remove SYMTAB parameter.
4720 (lookup_symbol_aux_local): Likewise.
4721 (lookup_symbol_aux_block): Likewise.
4722 (lookup_symbol_aux_symtabs): Likewise.
4723 (lookup_symbol_aux_psymtabs): Likewise.
4724 (lookup_global_symbol_from_objfile): Likewise.
4725 (basic_lookup_symbol_nonlocal): Likewise.
4726 (lookup_symbol_static): Likewise.
4727 (lookup_symbol_global): Likewise.
4728
4729 (lookup_symbol_in_language): Do not pass SYMTAB to lookup_symbol_aux.
4730
4731 2008-05-17 Pedro Alves <pedro@codesourcery.com>
4732
4733 * remote.c (init_extended_remote_ops): Fix typo.
4734
4735 2008-05-16 Pedro Alves <pedro@codesourcery.com>
4736
4737 * NEWS: Mention new DICOS x86 target configuration.
4738
4739 2008-05-16 Pedro Alves <pedro@codesourcery.com>
4740 Ulrich Weigand <uweigand@de.ibm.com>
4741
4742 * minsyms.c (lookup_minimal_symbol_by_pc_name): New function.
4743 * symtab.h (lookup_minimal_symbol_by_pc_name): Add prototype.
4744
4745 * symtab.c (fixup_section): Remove prototype. Add ADDR parameter;
4746 use it instead of ginfo->value.address. Look up minimal symbol by
4747 address and name. Assume OBJFILE is non-NULL.
4748 (fixup_symbol_section): Ensure we always have an objfile to look
4749 into. Extract and pass to fixup_section the symbol's address that
4750 will match the minimal symbol's address.
4751 (fixup_psymbol_section): Likewise.
4752
4753 (find_pc_sect_psymtab): Fall back to non-addrmap case when debugging
4754 overlays and the addrmap returned the wrong section.
4755
4756 * dwarf2read.c (var_decode_location): Set SYMBOL_CLASS before
4757 calling fixup_symbol_section.
4758
4759 2008-05-16 Ulrich Weigand <uweigand@de.ibm.com>
4760
4761 * minsyms.c: Include "target.h".
4762 (find_solib_trampoline_target): Handle minimal symbols pointing
4763 to function descriptors as well.
4764 * Makefile.in (minsyms.o): Update dependencies.
4765
4766 * ppc-linux-tdep.c (ppc64_standard_linkage): Rename to ...
4767 (ppc64_standard_linkage1): ... this. Fix optional instructions.
4768 (PPC64_STANDARD_LINKAGE_LEN): Rename to ...
4769 (PPC64_STANDARD_LINKAGE1_LEN): ... this.
4770 (ppc64_standard_linkage2, ppc64_standard_linkage3): New.
4771 (PPC64_STANDARD_LINKAGE2_LEN, PPC64_STANDARD_LINKAGE3_LEN): New.
4772 (ppc64_standard_linkage_target): Rename to ...
4773 (ppc64_standard_linkage1_target): ... this.
4774 (ppc64_standard_linkage2_target, ppc64_standard_linkage3_target): New.
4775 (ppc64_skip_trampoline_code): Support three variants of standard
4776 linkage stubs. Call find_solib_trampoline_target to handle
4777 glink stubs.
4778
4779 2008-05-16 Ulrich Weigand <uweigand@de.ibm.com>
4780
4781 * ppc-linux-tdep.c (ppc_linux_init_abi): Do not install
4782 ppc64_sysv_abi_adjust_breakpoint_address.
4783 * ppc-sysv-tdep.c (ppc64_sysv_abi_adjust_breakpoint_address): Remove.
4784 * ppc-tdep.h (ppc64_sysv_abi_adjust_breakpoint_address): Remove.
4785
4786 2008-05-16 Ulrich Weigand <uweigand@de.ibm.com>
4787
4788 * ppc-linux-tdep.c (ppc_linux_skip_trampoline_code): Remove.
4789 (ppc_linux_init_abi): Install find_solib_trampoline_target instead
4790 of ppc_linux_skip_trampoline_code.
4791
4792 2008-05-15 Daniel Jacobowitz <dan@codesourcery.com>
4793
4794 * gdbarch.sh: Delete dwarf_reg_to_regnum.
4795 * gdbarch.c, gdbarch.h: Regenerated.
4796 * amd64-tdep.c, arm-tdep.c, h8300-tdep.c, hppa-linux-tdep.c,
4797 hppa-tdep.c, i386-tdep.c, m32c-tdep.c, m68k-tdep.c, mips-tdep.c,
4798 s390-tdep.c, xtensa-tdep.c: Do not set dwarf_reg_to_regnum.
4799
4800 2008-05-15 Pedro Alves <pedro@codesourcery.com>
4801
4802 * linux-nat.c (trap_ptid): Delete.
4803 (linux_nat_detach, linux_nat_wait, linux_nat_mourn_inferior):
4804 Adjust.
4805 * linux-thread-db.c (thread_db_wait): Adjust.
4806
4807 2008-05-15 Joel Brobecker <brobecker@adacore.com>
4808
4809 * linespec.c (decode_line_1): Fix a couple of comments.
4810
4811 2008-05-15 Alan Modra <amodra@bigpond.net.au>
4812
4813 * dbxread.c: Formatting.
4814 (INTERNALIZE_SYMBOL): Init n_other.
4815 (set_namestring): Take pointer to nlist arg rather than struct
4816 copy. Update all callers.
4817
4818 2008-05-15 Andreas Schwab <schwab@suse.de>
4819
4820 * Makefile.in (dwarf2loc.o): Remove $(addrmap_h).
4821 (dwarf2read.o): Add $(addrmap_h).
4822
4823 2008-05-14 Ulrich Weigand <uweigand@de.ibm.com>
4824
4825 * ppc-linux-tdep.c (ppc_linux_convert_from_func_ptr_addr): Rename ...
4826 (ppc64_linux_convert_from_func_ptr_addr): ... to this. No longer try
4827 to handle ppc32 PLT entries.
4828 (ppc_linux_init_abi): Install ppc64_linux_convert_from_func_ptr_addr
4829 only on ppc64.
4830
4831 2008-05-14 Daniel Jacobowitz <dan@codesourcery.com>
4832
4833 * elfread.c (elf_symtab_read): Create trampolines for @plt symbols.
4834 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Renamed from
4835 lookup_minimal_symbol_by_pc_section. Prefer trampolines if requested.
4836 (lookup_minimal_symbol_by_pc_section): Use
4837 lookup_minimal_symbol_by_pc_section_1.
4838 (lookup_solib_trampoline_symbol_by_pc): Likewise.
4839
4840 2008-05-13 Joel Brobecker <brobecker@adacore.com>
4841
4842 * findcmd.c: Add #include "gdb_stdint.h".
4843 * Makefile.in (findcmd.o): Update dependencies.
4844
4845 2008-05-11 David S. Miller <davem@davemloft.net>
4846
4847 * sparc-linux-tdep.c (sparc32_linux_init_abi): Remove
4848 long double size override, Linux does use 128-bit now.
4849
4850 * sparc-linux-tdep.c (PSR_SYSCALL): Define.
4851 (sparc_linux_write_pc): New function.
4852 (sparc32_linux_init_abi): Register it.
4853 * sparc64-linux-tdep.c (TSTATE_SYSCALL): Define.
4854 (sparc64_linux_write_pc): New function.
4855 (sparc64_linux_init_abi): Register it.
4856
4857 * sparc-linux-tdep.c, sparc64-linux-tdep.c: Use
4858 dwarf2_append_unwinders(), not dwarf2_frame_sniffer.
4859
4860 2008-05-11 Ulrich Weigand <uweigand@de.ibm.com>
4861
4862 * rs6000-tdep.c (rs6000_gdbarch_init): Set up info.target_desc
4863 and info.tdep_info before calling gdbarch_init_osabi.
4864
4865 2008-05-09 Joel Brobecker <brobecker@adacore.com>
4866
4867 * ada-lang.c (ada_evaluate_subexp) [BINOP_ASSIGN]: Do not force
4868 the type of the right hand side of the assignment to the type
4869 of the left hand side if the left hand side is a convenience
4870 variable.
4871
4872 2008-05-09 Ulrich Weigand <uweigand@de.ibm.com>
4873
4874 * NEWS: Mention gdbserver bi-arch capability.
4875
4876 2008-05-09 Doug Evans <dje@google.com>
4877
4878 New "find" command.
4879 * NEWS: Document find command and qSearch:memory packet.
4880 * Makefile.in (SFILES): Add findcmd.c.
4881 (COMMON_OBJS): Add findcmd.o.
4882 (findcmd.o): New rule.
4883 * findcmd.c: New file.
4884 * target.h (target_ops): New member to_search_memory.
4885 (simple_search_memory): Declare.
4886 (target_search_memory): Declare.
4887 * target.c (simple_search_memory): New fn.
4888 (target_search_memory): New fn.
4889 * remote.c (PACKET_qSearch_memory): New packet kind.
4890 (remote_search_memory): New fn.
4891 (init_remote_ops): Init to_search_memory.
4892 (init_extended_remote_ops): Ditto.
4893 (_initialize_remote): Add qSearch:memory packet config command.
4894
4895 2008-05-09 Eli Zaretskii <eliz@gnu.org>
4896
4897 * thread.c (_initialize_thread): Don't use commas and periods in
4898 first line of doc string of "set/show print thread-events".
4899
4900 2008-05-08 Joel Brobecker <brobecker@adacore.com>
4901
4902 * alpha-mdebug-tdep.c, alpha-osf1-tdep.c, alpha-tdep.c:
4903 Update for unwinder changes.
4904
4905 2008-05-08 Joel Brobecker <brobecker@adacore.com>
4906
4907 * frame.c (get_frame_base_address, get_frame_locals_address)
4908 (get_frame_args_address): Pass the correct frame when calling
4909 frame_base_find_by_frame.
4910
4911 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
4912
4913 * remote.c (extended_remote_attach_1): Call target_find_description.
4914
4915 2008-05-08 Daniel Jacobowitz <dan@codesourcery.com>
4916
4917 * remote.c (extended_remote_create_inferior_1): Clean up
4918 before marking the target running.
4919
4920 2008-05-08 Joel Brobecker <brobecker@adacore.com>
4921
4922 * hppa-tdep.h, hppa-tdep.c, hppa-hpux-tdep.c: Update for unwinder
4923 changes.
4924
4925 2008-05-07 Joel Brobecker <brobecker@adacore.com>
4926
4927 * sparc-tdep.c, sparc-tdep.h, sparc-sol2-tdep.c, sparc64-tdep.c,
4928 sparc64-sol2-tdep.c: Update for unwinder changes.
4929
4930 2008-05-07 Daniel Jacobowitz <dan@codesourcery.com>
4931
4932 * cp-support.c (mangled_name_to_comp): Initialize storage.
4933 (unqualified_name_from_comp): Likewise.
4934
4935 2008-05-07 Jie Zhang <jie.zhang@analog.com>
4936
4937 * remote.c (remote_insert_breakpoint): Call get_remote_state
4938 after gdbarch_breakpoint_from_pc is called.
4939 (remote_insert_hw_breakpoint): Likewise.
4940
4941 2008-05-06 Joel Brobecker <brobecker@adacore.com>
4942
4943 * valprint.c (val_print): Add new language parameter and use it
4944 instead of using the current_language. Update calls to val_print
4945 throughout.
4946 (common_val_print): Add new langauge parameter and pass it to
4947 val_print.
4948 * value.h (struct language_defn): Add opaque declaration.
4949 (val_print, common_val_print): Update declarations.
4950 * stack.c (print_frame_args): Update call to common_val_print
4951 using the appropriate language.
4952 * mi/mi-cmd-stack.c (list_args_or_locals): Likewise.
4953 * c-valprint, f-valprint.c, m2-valprint.c, mt-tdep.c, infcmd.c,
4954 mi/mi-main.c, jv-valprint.c, ada-valprint.c, varobj.c, p-valprint.c,
4955 scm-valprint.c, cp-valprint.c, sh64-tdep.c, printcmd.c:
4956 #include "language.h" if necessary.
4957 Update calls to val_print and common_val_print.
4958 * Makefile.in (mt-tdep.o, sh64-tdep.o, mi-cmds.o, mi-main.o):
4959 Update dependencies.
4960
4961 2008-05-06 Joel Brobecker <brobecker@adacore.com>
4962
4963 * ia64-tdep.c (ia64_convert_from_func_ptr_addr): Treat addresses
4964 pointing inside a non-executable section as function descriptors.
4965
4966 2008-05-06 Pedro Alves <pedro@codesourcery.com>
4967
4968 * inf-loop.c (inferior_event_handler): Run all continuations and
4969 print any language change before running the breakpoint commands.
4970
4971 2008-05-06 Joel Brobecker <brobecker@adacore.com>
4972
4973 * frame-unwind.c (frame_unwind_got_bytes): New function.
4974 * frame-unwind.h (frame_unwind_got_bytes): Add declaration.
4975 * libunwind-frame.h, libunwind-frame.c, ia64-tdep.c: Update
4976 for unwinder changes.
4977
4978 2008-05-05 Doug Evans <dje@google.com>
4979
4980 * NEWS: Mention new /m modifier for disassemble command.
4981 * cli/cli-cmds.c (print_disassembly): New function.
4982 (disassemble_current_function): New function
4983 (disassemble_command): Recognize /m modifier, print mixed
4984 source+assembly.
4985 (init_cli_cmds): Update disassemble help text.
4986
4987 2008-05-05 Maxim Grigoriev <maxim2405@gmail.com>
4988
4989 * xtensa-tdep.c: Update for unwinder changes.
4990
4991 2008-05-05 Andreas Schwab <schwab@suse.de>
4992
4993 Update m68k port for unwinder changes.
4994 * m68k-tdep.c (m68k_frame_cache): Expect this_frame.
4995 (m68k_frame_this_id, m68k_frame_prev_register): Update signature.
4996 (m68k_frame_unwind): Use default_frame_sniffer.
4997 (m68k_frame_sniffer): Remove.
4998 (m68k_frame_base_address): Expect this_frame.
4999 (m68k_dummy_id): Renamed from m68k_unwind_dummy_id. Expect
5000 this_frame.
5001 (m68k_gdbarch_init): Use set_gdbarch_dummy_id,
5002 dwarf2_append_unwinders, and frame_unwind_append_unwinder.
5003 * m68klinux-tdep.c (m68k_linux_pc_in_sigtramp): Expect frame_info
5004 parameter instead of pc value.
5005 (m68k_linux_get_sigtramp_info, m68k_linux_sigtramp_frame_cache):
5006 Expect this_frame.
5007 (m68k_linux_sigtramp_frame_this_id)
5008 (m68k_linux_sigtramp_frame_prev_register)
5009 (m68k_linux_sigtramp_frame_sniffer): Update signature.
5010 (m68k_linux_sigtramp_frame_unwind): Use
5011 m68k_linux_sigtramp_frame_sniffer.
5012 (m68k_linux_init_abi): Use frame_unwind_append_unwinder.
5013
5014 * m68klinux-nat.c (store_register): Fix typo.
5015
5016 2008-05-05 Pedro Alves <pedro@codesourcery.com>
5017
5018 * infcmd.c (step_1): Put thread id on the stack to avoid possible
5019 NULL dereferencing.
5020
5021 2008-05-05 Luis Machado <luisgpm@br.ibm.com>
5022
5023 * symfile.c (reread_symbols): Update objfile's entry point.
5024
5025 2008-05-05 Aleksandar Ristovski <aristovski@qnx.com>
5026 Joel Brobecker <brobecker@adacore.com>
5027
5028 * ada-lang.c: Update throughout to use symbol_matches_domain
5029 instead of matching the symbol domain explictly.
5030 * dwarf2read.c (add_partial_symbol): Do not add new psym for
5031 STRUCT_DOMAIN. Make sure you recognize c++ struct and java and ada
5032 class as typedefs. See lookup_partial_symbol function.
5033 (new_symbol): Similar to add_partial_symbol, do not create
5034 symbol for the typedef. See lookup_block_symbol.
5035 * symtab.c (symbol_matches_domain): New function, takes care
5036 of dual meaning of STRUCT_DOMAIN symbol for c++, ada and java.
5037 (lookup_partial_symbol): Use symbol_matches_domain to see if the
5038 found psym domain matches the given domain.
5039 (lookup_block_symbol): Likewise.
5040
5041 2008-05-05 Vladimir Prus <vladimir@codesourcery.com>
5042
5043 * top.c (command_line_handler_continuation): Remove.
5044 (execute_command): Do not install the above.
5045
5046 2008-05-05 Vladimir Prus <vladimir@codesourcery.com>
5047
5048 * inf-loop.c (inferior_event_handler): Call bpstat_do_action,
5049 and catch all exceptions from it.
5050 * top.c (command_line_handler_continuation): Don't
5051 call bpstat_do_action here.
5052
5053 2008-05-04 Daniel Jacobowitz <dan@codesourcery.com>
5054
5055 * dwarf2read.c (struct dwarf2_cu): Add type_hash.
5056 (struct die_info): Remove type.
5057 (read_type_die, read_typedef, read_base_type, read_subrange_type)
5058 (read_structure_type, read_enumeration_type, read_array_type)
5059 (read_tag_pointer_type, read_tag_ptr_to_member_type)
5060 (read_tag_reference_type, read_tag_const_type, read_tag_volatile_type)
5061 (read_tag_string_type, read_subroutine_type, read_set_type)
5062 (read_unspecified_type): Delete prototypes. Remove check for
5063 already-loaded type. Return the new type.
5064 (set_die_type): Return the new type.
5065 (reset_die_and_siblings_types): Delete.
5066 (load_comp_unit, load_full_comp_unit): Set type_hash.
5067 (process_queue): Remove call to reset_die_and_siblings_types.
5068 (process_die): Do not read most types here. Use read_type_die
5069 for others.
5070 (read_func_scope, dwarf2_add_member_fn): Use read_type_die.
5071 (quirk_gcc_member_function_pointer): Return the new type.
5072 (process_structure_scope, process_enumeration_scope): Use
5073 get_die_type and read the DIE's type.
5074 (read_full_die): Do not initialize die->type.
5075 (tag_type_to_type): Use read_type_die.
5076 (read_type_die): Check for already defined types. Return the
5077 type.
5078 (determine_prefix): Use get_die_type.
5079 (set_die_type): Return the type.
5080 (get_die_type): Take a CU argument. Check for no type_hash.
5081
5082 2008-05-04 Daniel Jacobowitz <dan@codesourcery.com>
5083
5084 * dwarf2read.c (dwarf2_ranges_read, read_partial_die): Initialize
5085 locals.
5086
5087 2008-05-04 Pedro Alves <pedro@codesourcery.com>
5088
5089 * breakpoint.c (update_breakpoints_after_exec): Delete bp_longjmp
5090 and bp_longjmp_resume breakpoints.
5091 (breakpoint_address_is_meaningful): Claim bp_longjmp_resume as
5092 meaningful.
5093 (create_longjmp_breakpoint): Don't create bp_longjmp_resume
5094 breakpoints. Create bp_longjmp breakpoints as momentary
5095 breakpoints.
5096 (enable_longjmp_breakpoint): Delete.
5097 (set_longjmp_breakpoint): New.
5098 (disable_longjmp_breakpoint): Delete.
5099 (delete_longjmp_breakpoint): New.
5100 (set_longjmp_resume_breakpoint): Delete.
5101 (set_momentary_breakpoint_at_pc): New.
5102 (breakpoint_re_set_one): Don't delete bp_longjmp and
5103 bp_longjmp_resume breakpoints.
5104 (breakpoint_re_set): Don't create longjmp and longjmp-resume
5105 breakpoints.
5106
5107 * infrun.c (step_resume_breakpoint): Add comment.
5108 (struct execution_control_state): Delete handling_longjmp member.
5109 (init_execution_control_state). Don't clear handling_longjmp.
5110 (context_switch): Don't context switch handling_longjmp.
5111 (handle_inferior_event): If handling a bp_longjmp breakpoint,
5112 create a bp_longjmp_resume breakpoint, and set it as current
5113 step_resume_breakpoint, then step over the longjmp breakpoint. If
5114 handling a bp_longjmp_resume breakpoint, don't delete the longjmp
5115 breakpoint, delete the longjmp-resume breakpoint, and stop
5116 stepping.
5117 (currently_stepping): Remove handling_longjmp from expression.
5118 (insert_step_resume_breakpoint_at_sal): Update comment.
5119 (insert_longjmp_resume_breakpoint): New.
5120
5121 * breakpoint.h (set_momentary_breakpoint_at_pc): Declare.
5122 (enable_longjmp_breakpoint, disable_longjmp_breakpoint): Delete
5123 declarations.
5124 (set_longjmp_breakpoint, delete_longjmp_breakpoint): Declare.
5125 (set_longjmp_resume_breakpoint): Delete declaration.
5126
5127 * gdbthread.h (save_infrun_state): Remove handling_longjmp
5128 parameter.
5129 (load_infrun_state): Delete *handling_longjmp parameter.
5130 * thread.c (save_infrun_state): Remove handling_longjmp parameter.
5131 Update body.
5132 (load_infrun_state): Delete *handling_longjmp parameter. Update
5133 body.
5134
5135 * infcmd.c (disable_longjmp_breakpoint_cleanup): Delete.
5136 (delete_longjmp_breakpoint_cleanup): New.
5137 (step_1): Call set_longjmp_breakpoint instead of
5138 enable_longjmp_breakpoint. Use delete_longjmp_breakpoint_cleanup
5139 instead of disable_longjmp_breakpoint_cleanup when making cleanup.
5140 (step_1_continuation): Pass thread id in the continuation args to
5141 step_once.
5142 (step_once): Add thread parameter. Pass thread id the the
5143 continuation.
5144
5145 2008-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5146
5147 Set CU BASE_ADDRESS already from partial DIEs.
5148 * dwarf2read.c (read_partial_die): New variables BASE_ADDRESS and
5149 BASE_ADDRESS_TYPE. Set these variables from DW_AT_LOW_PC and
5150 DW_AT_ENTRY_PC. Set CU->HEADER.BASE_KNOWN and CU->HEADER.BASE_ADDRESS
5151 from these variables if it was still unset.
5152
5153 * Makefile.in: Update dependencies.
5154 * dwarf2read.c: Include "addrmap.h"
5155 (struct dwarf2_cu): New fields RANGES_OFFSET and HAS_RANGES_OFFSET.
5156 (dwarf2_ranges_read): New prototype.
5157 (dwarf2_build_psymtabs_hard): Initialize and prepare PSYMTABS_ADDRMAP.
5158 Add discontiguous range to PSYMTABS_ADDRMAP by DWARF2_RANGES_READ on
5159 HAS_RANGES_OFFSET, otherwise add there the contiguous range.
5160 (dwarf2_ranges_read): New parameter RANGES_PST, update the function
5161 comment for it. Add the found ranges to RANGES_PST. New variable
5162 BASEADDR, initialize it the common way.
5163 (dwarf2_get_pc_bounds): Update the caller for the new parameter.
5164 (read_partial_die): `DW_AT_ranges' now only sets RANGES_OFFSET and
5165 HAS_RANGES_OFFSET for the later processing.
5166 * objfiles.h (struct objfile): New field PSYMTABS_ADDRMAP.
5167 * symtab.c: Include "addrmap.h"
5168 (find_pc_sect_psymtab): Support reading the field PSYMTABS_ADDRMAP.
5169 Move the psymtab locator into ...
5170 (find_pc_sect_psymtab_closer): ... a new function.
5171
5172 2008-05-04 Ulrich Weigand <uweigand@de.ibm.com>
5173
5174 * arch-utils.c (gdbarch_update_p): Use default values for
5175 info.abfd and info.target_desc if they are NULL.
5176 (gdbarch_from_bfd): Remove assertion.
5177 (set_gdbarch_from_file): Call gdbarch_find_by_info directly,
5178 using the current target description.
5179 (gdbarch_info_fill): Do not use default values for info->abfd
5180 and info->target_desc.
5181
5182 2008-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5183
5184 * symfile.c (reread_symbols): Reload EXEC_BFD on its change.
5185
5186 2008-05-04 Ulrich Weigand <uweigand@de.ibm.com>
5187
5188 * inferior.h (read_pc_pid, write_pc_pid): Remove.
5189 * regcache.h (regcache_read_pc, regcache_write_pc): Add prototypes.
5190
5191 * regcache.c (read_pc_pid): Remove, replace by ...
5192 (regcache_read_pc): ... this function.
5193 (write_pc_pid): Remove, replace by ...
5194 (regcache_write_pc): ... this function.
5195 (read_pc, write_pc): Update.
5196
5197 * infrun.c (displaced_step_prepare): Replace read_pc_pid and
5198 write_pc_pid by regcache_read_pc and regcache_write_pc.
5199 (displaced_step_fixup): Likewise.
5200 (resume): Likewise. Use regcache arch instead of current_gdbarch.
5201 (prepare_to_proceed): Likewise.
5202 (proceed): Likewise.
5203 (adjust_pc_after_break): Likewise.
5204 (handle_inferior_event): Likewise.
5205
5206 * linux-nat.c (cancel_breakpoint): Likewise.
5207 * linux-thread-db.c (check_event): Likewise.
5208 * aix-thread.c (aix_thread_wait): Likewise.
5209 * tracepoint.c (trace_dump_command): Likewise.
5210
5211 2008-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5212
5213 * dwarf2loc.c (dwarf_expr_frame_base): Error out on missing
5214 SYMBOL_LOCATION_BATON.
5215
5216 2008-05-04 Vladimir Prus <vladimir@codesourcery.com>
5217
5218 * target.h (struct target_ops): New field to_auxv_parse.
5219 * auxv.c (default_auxv_parse): New, renamed from previous
5220 target_auxv_parse.
5221 (target_auxv_parse): Try to call target method. Fallback to
5222 default_auxv_parse if not found.
5223 * procfs.c (procfs_auxv_parse): New.
5224 (init_procfs_ops): On Solaris, in 64-bit mode, install
5225 procfs_auxv_parse.
5226
5227 2008-05-03 Adam Nemet <anemet@caviumnetworks.com>
5228
5229 * symfile.c (add_symbol_file_command): Use paddress rather than
5230 hex_string to print the address.
5231
5232 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
5233
5234 * rs6000-tdep.c (rs6000_frame_this_id): If info->base is 0,
5235 return the null frame ID to terminate the backtrace.
5236
5237 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
5238
5239 * rs6000-tdep.c: Do not include "rs6000-tdep.h".
5240 (rs6000_find_toc_address_hook): Move to rs6000-aix-tdep.c.
5241 (SIG_FRAME_PC_OFFSET): Likewise.
5242 (SIG_FRAME_LR_OFFSET): Likewise.
5243 (SIG_FRAME_FP_OFFSET): Likewise.
5244 (rs6000_push_dummy_call): Likewise.
5245 (rs6000_return_value): Likewise.
5246 (rs6000_convert_from_func_ptr_addr): Likewise.
5247 (branch_dest, rs6000_software_single_step): Likewise.
5248 (deal_with_atomic_sequence): Rename to ...
5249 (ppc_deal_with_atomic_sequence): ... this. Adapt all callers.
5250 Do not call branch_dest; inline required parts of that function.
5251 (rs6000_skip_trampoline_code): Replace DEPRECATED_SYMBOL_NAME
5252 with SYMBOL_LINKAGE_NAME.
5253 (struct reg, regsize): Delete.
5254 (read_memory_addr): Delete; inline into callers.
5255 (rs6000_skip_prologue): Move after skip_prologue.
5256 (skip_prologue): Remove prototype.
5257 (rs6000_gdbarch_init): Remove sysv_abi variable; perform all
5258 initialization as if this variable were true. Do not install
5259 ppc64_sysv_abi_adjust_breakpoint_address.
5260
5261 * rs6000-aix-tdep.c: Include "gdb_assert.h", "gdbtypes.h",
5262 "gdbcore.h", "target.h", "value.h", "infcall.h", "objfiles.h",
5263 and "breakpoint.h".
5264 (rs6000_find_toc_address_hook): Move here from rs6000-tdep.c.
5265 (SIG_FRAME_PC_OFFSET): Likewise.
5266 (SIG_FRAME_LR_OFFSET): Likewise.
5267 (SIG_FRAME_FP_OFFSET): Likewise.
5268 (rs6000_push_dummy_call): Likewise.
5269 (rs6000_return_value): Likewise.
5270 (rs6000_convert_from_func_ptr_addr): Likewise.
5271 (branch_dest, rs6000_software_single_step): Likewise. Replace
5272 tdep->text_segment_base by AIX_TEXT_SEGMENT_BASE.
5273 (rs6000_aix_init_osabi): Install rs6000_push_dummy_call,
5274 rs6000_return_value, and rs6000_convert_from_func_ptr_addr.
5275 Call set_gdbarch_long_double_bit and set_gdbarch_frame_red_zone_size.
5276 Set tdep->lr_frame_offset. Do not set tdep->text_segment_base.
5277
5278 * rs6000-tdep.h (rs6000_software_single_step): Remove prototype.
5279 (AIX_TEXT_SEGMENT_BASE): New macro.
5280 * rs6000-nat.c (exec_one_dummy_insn): Replace tdep->text_segment_base
5281 by AIX_TEXT_SEGMENT_BASE.
5282
5283 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Add prototype.
5284 (struct gdbarch_tdep): Remove text_segment_base member.
5285 * ppc-linux-tdep.c (ppc_linux_init_abi): On 64-bit, install
5286 ppc64_sysv_abi_adjust_breakpoint_address.
5287
5288 * Makefile.in (rs6000-tdep.o): Update dependencies.
5289 (rs6000-aix-tdep.o): Likewise.
5290
5291 2008-05-03 Luis Machado <luisgpm@br.ibm.com>
5292 Thiago Jung Bauermann <bauerman@br.ibm.com>
5293
5294 * cli/cli-decode.c (lookup_cmd_1): Fix indentation.
5295 * doublest.c (convert_typed_floating): Fix typo in comment.
5296 * dwarf2-frame.c (dwarf2_frame_cache): Likewise.
5297 * frame-unwind.h (frame_sniffer_ftype): Likewise.
5298 * frame.c (frame_unwind_address_in_block): Likewise.
5299 * ppc-sysv-tdep.c (ppc64_sysv_abi_push_dummy_call): Likewise.
5300 * symtab.h (struct symbol): Likewise.
5301 * tramp-frame.h (struct trad_frame_cache): Likewise.
5302 * value.c (allocate_repeat_value): Likewise.
5303
5304 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
5305
5306 * infrun.c (handle_inferior_event): Do not insert breakpoints at
5307 TARGET_WAITKIND_LOADED events during startup (i.e. in the shell).
5308
5309 2008-05-03 Pedro Alves <pedro@codesourcery.com>
5310
5311 * parse.c (parse_exp_in_context): Don't override
5312 expression_context_pc if get_selected_block returned a valid
5313 block.
5314
5315 2008-05-03 Daniel Jacobowitz <dan@codesourcery.com>
5316
5317 * alpha-tdep.h (ALPHA_REGISTER_BYTES): Delete.
5318 * arm-tdep.h (STATUS_REGISTER_SIZE): Delete.
5319 * breakpoint.c (args_for_catchpoint_enable, current_exception_event):
5320 Delete.
5321 * c-typeprint.c (c_type_print_base): Delete handling of template
5322 instantiations.
5323 * cp-support.h (METHOD_PTR_IS_VIRTUAL, METHOD_PTR_FROM_VOFFSET)
5324 (METHOD_PTR_TO_VOFFSET): Delete.
5325 * defs.h (QUIT_FIXME): Delete.
5326 * f-lang.h (DEFAULT_DOTMAIN_NAME_IN_MF77, DEFAULT_MAIN_NAME_IN_MF77)
5327 (DEFAULT_DOTMAIN_NAME_IN_XLF_BUGGY, DEFAULT_DOTMAIN_NAME_IN_XLF): Delete.
5328 * gdbtypes.h (struct cplus_struct_type): Delete is_inlined,
5329 ninstantiations, and instantiations.
5330 (TYPE_INSTANTIATIONS, TYPE_NINSTANTIATIONS, TYPE_INSTANTIATION)
5331 (TYPE_FN_FIELD_INLINED): Delete.
5332 * srec.h (SREC_BINARY): Delete.
5333 * symtab.c (symbol_init_demangled_name): Delete.
5334 * symtab.h (SYMBOL_INIT_DEMANGLED_NAME, symbol_init_demangled_name)
5335 (SYMBOL_OBJFILE, struct exception_event_record, CURRENT_EXCEPTION_KIND)
5336 (CURRENT_EXCEPTION_CATCH_SAL, CURRENT_EXCEPTION_CATCH_LINE)
5337 (CURRENT_EXCEPTION_CATCH_FILE, CURRENT_EXCEPTION_CATCH_PC)
5338 (CURRENT_EXCEPTION_THROW_SAL, CURRENT_EXCEPTION_THROW_LINE)
5339 (CURRENT_EXCEPTION_THROW_FILE, CURRENT_EXCEPTION_THROW_PC): Delete.
5340 * target.h (enum thread_control_capabilities): Delete tc_switch.
5341 (target_can_switch_threads): Delete.
5342
5343 2008-05-03 Daniel Jacobowitz <dan@codesourcery.com>
5344
5345 * Makefile.in (objfiles.o): Update.
5346 * exec.c (exec_set_section_address): Support p->addr != 0.
5347 * objfiles.c (objfile_relocate): Update exec_ops section
5348 addresses.
5349 * symfile.c (place_section): Move exec_set_section_address call...
5350 (default_symfile_offsets): ...to here.
5351
5352 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
5353
5354 * Makefile.in (ppc_linux_tdep_h): New macro.
5355 (powerpc_32l_c, powerpc_altivec32_c, powerpc_altivec32l_c): Likewise.
5356 (powerpc_64l_c, powerpc_altivec64_c, powerpc_altivec64l_c): Likewise.
5357 (powerpc_e500l_c): Likewise.
5358 (ppc-linux-nat.o): Update dependencies.
5359 (ppc-linux-tdep.o): Update dependencies.
5360 (rs6000-tdep.o): Update dependencies.
5361
5362 * ppc-tdep.h (ppc_linux_memory_remove_breakpoint): Remove.
5363 (ppc_linux_svr4_fetch_link_map_offsets): Remove.
5364 (ppc_linux_gregset, ppc_linux_fpregset): Move to ppc-linux-tdep.h
5365 (ppc_supply_reg, ppc_collect_reg): Add prototypes.
5366 (tdesc_powerpc_e500): Remove.
5367
5368 * rs6000.c: Include "features/rs6000/powerpc-altivec32.c"
5369 and "features/rs6000/powerpc-altivec64.c".
5370 (ppc_supply_reg, ppc_collect_reg): Make global.
5371 (variants): Use tdesc_powerpc_32 for "powerpc" and
5372 tdesc_powerpc_altivec64 for "powerpc64".
5373 (_initialize_rs6000_tdep): Initialize AltiVec descriptions.
5374
5375 * ppc-linux-tdep.h: New file.
5376
5377 * ppc-linux-tdep.c: Include "ppc-linux-tdep.c".
5378 Include "features/rs6000/powerpc-32l.c".
5379 Include "features/rs6000/powerpc-altivec32l.c".
5380 Include "features/rs6000/powerpc-64l.c".
5381 Include "features/rs6000/powerpc-altivec64l.c".
5382 Include "features/rs6000/powerpc-e500l.c".
5383 (ppc_linux_supply_gregset): New function.
5384 (ppc_linux_collect_gregset): Handle orig_r3 and trap registers.
5385 (ppc32_linux_gregset): Use ppc_linux_supply_gregset.
5386 (ppc64_linux_gregset): Likewise.
5387 (ppc_linux_sigtramp_cache): Handle orig_r3 and trap registers.
5388 (ppc_linux_trap_reg_p): New function.
5389 (ppc_linux_write_pc): New function.
5390 (ppc_linux_core_read_description): New function.
5391 (ppc_linux_init_abi): Install ppc_linux_write_pc and
5392 ppc_linux_core_read_description. Install orig_r3 and trap
5393 registers if present in the target description.
5394 (_initialize_ppc_linux_tdep): Initialize Linux target descriptions.
5395
5396 * ppc-linux-nat.c: Include "ppc-linux-tdep.h".
5397 (PT_ORIG_R3, PT_TRAP): Define if necessary.
5398 (ppc_register_u_addr): Handle orig_r3 and trap registers.
5399 (fetch_ppc_registers): Likewise.
5400 (store_ppc_registers): Likewise.
5401 (store_register): Likewise.
5402 (ppc_linux_read_description): Check whether AltiVec is supported.
5403 Check whether inferior is 32-bit or 64-bit. Return the appropriate
5404 Linux target description.
5405
5406 * features/Makefile (WHICH): Use rs6000/powerpc-32l and
5407 rs6000/powerpc-altivec32l instead of rs6000/powerpc-32.
5408 Use rs6000/powerpc-64l and rs6000/powerpc-altivec64l instead
5409 of rs6000/powerpc-64. Use rs6000/powerpc-e500l instead of
5410 rs6000/powerpc-e500. Update -expedite variables accordingly.
5411
5412 * features/rs6000/power-spe.xml: Use regnum 73 for "acc".
5413 * features/rs6000/powerpc-32.xml: Do not include power-altivec.xml.
5414 * features/rs6000/powerpc-64.xml: Do not include power-altivec.xml.
5415 * features/rs6000/powerpc-e500.c: Regenerate.
5416 * features/rs6000/powerpc-32.c: Regenerate.
5417 * features/rs6000/powerpc-64.c: Regenerate.
5418
5419 * features/rs6000/power-linux.xml: New file.
5420 * features/rs6000/power64-linux.xml: New file.
5421 * features/rs6000/powerpc-32l.xml: New file.
5422 * features/rs6000/powerpc-altivec32l.xml: New file.
5423 * features/rs6000/powerpc-64l.xml: New file.
5424 * features/rs6000/powerpc-altivec64l.xml: New file.
5425 * features/rs6000/powerpc-e500l.xml: New file.
5426 * features/rs6000/powerpc-32l.c: New (generated) file.
5427 * features/rs6000/powerpc-altivec32l.c: New (generated) file.
5428 * features/rs6000/powerpc-64l.c: New (generated) file.
5429 * features/rs6000/powerpc-altivec64l.c: New (generated) file.
5430 * features/rs6000/powerpc-e500l.xml: New (generated) file.
5431
5432 * regformats/reg-ppc.dat: Remove.
5433 * regformats/reg-ppc64.dat: Remove.
5434 * regformats/rs6000/powerpc-32.dat: Remove.
5435 * regformats/rs6000/powerpc-64.dat: Remove.
5436 * regformats/rs6000/powerpc-e500.dat: Remove.
5437 * regformats/rs6000/powerpc-32l.dat: New (generated) file.
5438 * regformats/rs6000/powerpc-altivec32l.dat: New (generated) file.
5439 * regformats/rs6000/powerpc-64l.dat: New (generated) file.
5440 * regformats/rs6000/powerpc-altivec64l.dat: New (generated) file.
5441 * regformats/rs6000/powerpc-e500l.dat: New (generated) file.
5442
5443 2008-05-03 Pedro Alves <pedro@codesourcery.com>
5444
5445 * thread.c (delete_thread): Call observer_notify_thread_exit.
5446 * mi/mi-interp.c (mi_interpreter_init): Register mi_thread_exit as
5447 thread_exit observer.
5448 (mi_thread_exit): New.
5449
5450 2008-05-03 Thiago Jung Bauermann <bauerman@br.ibm.com>
5451
5452 * breakpoint.c (create_exception_catchpoint): Remove prototype
5453 for already deleted function.
5454 * breakpoint.h (ep_is_exception_catchpoint): Likewise.
5455 * frame.h (show_stack_frame): Remove prototype.
5456 * stack.c (show_stack_frame): Remove empty, unused function.
5457 * source.c (symtab_to_fullname, print_source_lines): Small fix
5458 in comment.
5459 * value.c (show_values): Update comments to mention "show values"
5460 command instead of "info history".
5461
5462 2008-05-02 Ulrich Weigand <uweigand@de.ibm.com>
5463
5464 * linespec.c: Include "target.h".
5465 (minsym_found): Handle minimal symbols pointing to function
5466 descriptors. Use find_function_start_pc.
5467 * minsyms.c (msymbol_objfile): New function.
5468 * parse.c (write_exp_msymbol): Handle minimal symbols pointing
5469 to function descriptors.
5470 * symtab.c (fixup_section): Only use minimal symbol at the same
5471 address to determine section of a symbol.
5472 (find_function_start_pc): New function.
5473 (find_function_start_sal): Use it.
5474 * symtab.h (msymbol_objfile): Add prototype.
5475 (find_function_start_pc): Likewise.
5476 * value.c: Include "objfiles.h".
5477 (value_fn_field): Handle minimal symbols pointing to function
5478 descriptors.
5479 * Makefile.in (linespec.o): Update dependencies.
5480 (value.o): Likewise.
5481
5482 2008-05-02 Joel Brobecker <brobecker@adacore.com>
5483
5484 * ada-lang.c (unwrap_value): Handle the case where the "F" field
5485 inside a PAD type is a bitfield.
5486
5487 2008-05-02 Ulrich Weigand <uweigand@de.ibm.com>
5488
5489 * ppc-sysv-tdep.c (ppc64_sysv_abi_push_dummy_call): Handle
5490 TYPE_CODE_BOOL and TYPE_CODE_CHAR the same as TYPE_CODE_INT.
5491 Handle TYPE_CODE_REF the same as TYPE_CODE_PTR.
5492 Handle TYPE_CODE_METHOD the same as TYPE_CODE_FUNC.
5493 Allow typedefs when checking for function pointer arguments.
5494 Right-align small structs passed on the stack.
5495 (ppc64_sysv_abi_return_value): Handle TYPE_CODE_BOOL and
5496 TYPE_CODE_CHAR the same as TYPE_CODE_INT.
5497 Handle TYPE_CODE_REF the same as TYPE_CODE_PTR.
5498
5499 2008-05-02 Daniel Jacobowitz <dan@codesourcery.com>
5500
5501 * Makefile.in (arm-tdep.o): Update.
5502 * arm-tdep.c (arm_objfile_data_key, struct arm_mapping_symbol)
5503 (struct arm_per_objfile, arm_compare_mapping_symbols): New.
5504 (arm_pc_is_thumb): Use mapping symbols.
5505 (arm_objfile_data_cleanup, arm_record_special_symbol): New.
5506 (arm_gdbarch_init): Call set_gdbarch_record_special_symbol.
5507 (_initialize_arm_tdep): Initialize arm_objfile_data_key.
5508 * elfread.c (elf_symtab_read): Use gdbarch_record_special_symbol.
5509 * gdbarch.sh: Add record_special_symbol.
5510 * gdbarch.c, gdbarch.h: Regenerated.
5511 * objfiles.c (struct objfile_data): Add cleanup member.
5512 (register_objfile_data_with_cleanup): New function, from
5513 register_objfile_data.
5514 (register_objfile_data): Use it.
5515 (objfile_free_data): Call clear_objfile_data.
5516 (clear_objfile_data): Call cleanup functions.
5517 * objfiles.h (register_objfile_data_with_cleanup): Declare.
5518
5519 2008-05-02 Daniel Jacobowitz <dan@codesourcery.com>
5520
5521 * objfiles.c (init_entry_point_info): Handle shared libraries.
5522
5523 2008-05-02 Daniel Jacobowitz <dan@codesourcery.com>
5524
5525 * arm-tdep.c (arm_prologue_this_id): Compare pc, not func, to
5526 lowest_pc.
5527
5528 2008-05-02 Jim Blandy <jimb@codesourcery.com>
5529 Pedro Alves <pedro@codesourcery.com>
5530
5531 Implement displaced stepping.
5532
5533 * gdbarch.sh (max_insn_length): New 'variable'.
5534 (displaced_step_copy, displaced_step_fixup)
5535 (displaced_step_free_closure, displaced_step_location): New
5536 functions.
5537 (struct displaced_step_closure): Add forward declaration.
5538 * gdbarch.c, gdbarch.h: Regenerated.
5539
5540 * arch-utils.c: #include "objfiles.h".
5541 (simple_displaced_step_copy_insn)
5542 (simple_displaced_step_free_closure)
5543 (displaced_step_at_entry_point): New functions.
5544 * arch-utils.h (simple_displaced_step_copy_insn)
5545 (simple_displaced_step_free_closure)
5546 (displaced_step_at_entry_point): New prototypes.
5547
5548 * i386-tdep.c (I386_MAX_INSN_LEN): Rename to...
5549 (I386_MAX_MATCHED_INSN_LEN): ... this.
5550 (i386_absolute_jmp_p, i386_absolute_call_p)
5551 (i386_ret_p, i386_call_p, i386_breakpoint_p, i386_syscall_p)
5552 (i386_displaced_step_fixup): New functions.
5553 (struct i386_insn, i386_match_insn): Update.
5554 (i386_gdbarch_init): Set gdbarch_max_insn_length.
5555 * i386-tdep.h (I386_MAX_INSN_LEN): New.
5556 (i386_displaced_step_fixup): New prototype.
5557 * i386-linux-tdep.c (i386_linux_init_abi): Include "arch-utils.h".
5558 Register gdbarch_displaced_step_copy,
5559 gdbarch_displaced_step_fixup, gdbarch_displaced_step_free_closure,
5560 and gdbarch_displaced_step_location functions.
5561
5562 * infrun.c (debug_displaced): New variable.
5563 (show_debug_displaced): New function.
5564 (struct displaced_step_request): New struct.
5565 (displaced_step_request_queue, displaced_step_ptid)
5566 (displaced_step_gdbarch, displaced_step_closure)
5567 (displaced_step_original, displaced_step_copy)
5568 (displaced_step_saved_copy, can_use_displaced_stepping): New
5569 variables.
5570 (show_can_use_displaced_stepping, use_displaced_stepping)
5571 (displaced_step_clear, cleanup_displaced_step_closure)
5572 (displaced_step_dump_bytes, displaced_step_prepare)
5573 (displaced_step_clear_cleanup, write_memory_ptid)
5574 (displaced_step_fixup): New functions.
5575 (resume): Call displaced_step_prepare.
5576 (proceed): Call read_pc once, and remember the value. If using
5577 displaced stepping, don't remove breakpoints.
5578 (handle_inferior_event): Call displaced_step_fixup. Add some
5579 debugging output. When we try to step over a breakpoint, but get
5580 a signal to deliver to the thread instead, ensure the step-resume
5581 breakpoint is actually inserted. If a thread hop is needed, and
5582 displaced stepping is enabled, don't remove breakpoints.
5583 (init_wait_for_inferior): Call displaced_step_clear.
5584 (_initialize_infrun): Add "set debug displaced" command. Add
5585 "maint set can-use-displaced-stepping" command. Clear
5586 displaced_step_ptid.
5587 * inferior.h (debug_displaced): Declare variable.
5588 (displaced_step_dump_bytes): Declare function.
5589
5590 * Makefile.in (arch-utils.o, i386-linux-tdep.o): Update
5591 dependencies.
5592
5593 2008-05-02 Daniel Jacobowitz <dan@codesourcery.com>
5594
5595 * arm-tdep.c (arm_mode_strings, arm_fallback_mode_string)
5596 (arm_force_mode_string, arm_show_fallback_mode)
5597 (arm_show_force_mode): New.
5598 (arm_pc_is_thumb): Honor fallback-mode and force-mode. Use
5599 arm_frame_is_thumb.
5600 (_initialize_arm_tdep): Add "set arm fallback-mode"
5601 and "set arm force-mode".
5602 * NEWS: Document new commands.
5603
5604 2008-05-02 Andrew Stubbs <andrew.stubbs@st.com>
5605
5606 * main.h (batch_silent): Declare.
5607 * event-top.c: Include main.h.
5608 (gdb_setup_readline): Remove extern batch_silent declaration.
5609 * infrun.c (normal_stop): Don't print source location when running in
5610 --batch-silent mode.
5611 * Makefile.in (event-top.o): Add main.h dependency.
5612
5613 2008-05-02 Andreas Schwab <schwab@suse.de>
5614
5615 * target.h (struct target_ops): Add
5616 to_watchpoint_addr_within_range.
5617 (target_watchpoint_addr_within_range): New function.
5618 * target.c (update_current_target): Inherit
5619 to_watchpoint_addr_within_range, defaulting to
5620 default_watchpoint_addr_within_range.
5621 (default_watchpoint_addr_within_range): New function.
5622 (debug_to_watchpoint_addr_within_range): New function.
5623 (setup_target_debug): Set to_watchpoint_addr_within_range.
5624 * ppc-linux-nat.c (ppc_linux_watchpoint_addr_within_range):
5625 New function.
5626 (_initialize_ppc_linux_nat): Set to_watchpoint_addr_within_range.
5627 * breakpoint.c (watchpoints_triggered): Use
5628 target_watchpoint_addr_within_range.
5629
5630 2008-05-01 Pedro Alves <pedro@codesourcery.com>
5631
5632 * configure.tgt: Add i[34567]86-*-dicos* and x86_64-*-dicos*.
5633 (i[34567]86-*-dicos*, x86_64-*-dicos*):
5634 Set gdb_osabi to GDB_OSABI_DICOS.
5635
5636 * defs.h (enum gdb_osabi): Add GDB_OSABI_DICOS.
5637 * osabi.c (gdb_osabi_name): Add "DICOS".
5638
5639 * i386-dicos-tdep.c: New file.
5640
5641 * Makefile.in (ALL_TARGET_OBS): Add i386-dicos-tdep.o.
5642 (ALLDEPFILES): Add i386-dicos-tdep.c.
5643 (i386-dicos-tdep.o): New rule.
5644
5645 2008-05-01 Pedro Alves <pedro@codesourcery.com>
5646
5647 * linux-nat.c (linux_nat_switch_fork): Reinit GDB's thread list
5648 and register the fork's PTID as a thread.
5649
5650 2008-05-01 Aleksandar Ristovski <aristovski@qnx.com>
5651
5652 PR gdb/1665
5653 * breakpoint.c (create_breakpoint): Add breakpoint_ops argument and
5654 assign its value to the breakpoint created.
5655 (create_breakpoints): Add breakpoint_ops argument and pass it
5656 to create_breakpoint call.
5657 (break_command_really): Add breakpoint_ops argument and pass/assign
5658 appropriately.
5659 (break_command_1): Pass NULL as ops argument.
5660 (set_breakpoint): Pass NULL as ops argument.
5661 (print_one_exception_catchpoint): Print <PENDING> if no loc available.
5662 (handle_gnu_v3_exceptions): Call generic breakpoint code to insert
5663 catch and throw catchpoints.
5664
5665 2008-05-01 Aleksandar Ristovski <aristovski@qnx.com>
5666
5667 PR gdb/2343
5668 * corelow.c (core_open): Use gdbarch_target_signal_from_host to
5669 translate signal numeric value from the target to GDB's enum
5670 target_signal.
5671 * gdbarch.c, gdbarch.h: Regenerated.
5672 * gdbarch.sh: Added two new functions target_signal_from_host and
5673 target_signal_to_host.
5674 * target.h (default_target_signal_from_host,
5675 default_target_signal_to_host): New functions - declarations.
5676 * signals/signals.c (struct gdbarch): New declaration.
5677 (default_target_signal_to_host, default_target_signal_from_host): New
5678 functions.
5679
5680 2008-05-01 Daniel Jacobowitz <dan@codesourcery.com>
5681 Pedro Alves <pedro@codesourcery.com>
5682
5683 Based on work by Jan Kratochvil <jan.kratochvil@redhat.com> and Jeff
5684 Johnston <jjohnstn@redhat.com>.
5685
5686 * NEWS: Mention attach to stopped process fix.
5687 * infcmd.c (detach_command, disconnect_command): Discard the thread
5688 list.
5689 * infrun.c (handle_inferior_event): Do not ignore non-SIGSTOP while
5690 attaching. Use signal_stop_state.
5691 (signal_stop_state): Check stop_soon.
5692 * linux-nat.c (kill_lwp): Declare earlier.
5693 (pid_is_stopped, linux_nat_post_attach_wait): New.
5694 (lin_lwp_attach_lwp): Use linux_nat_post_attach_wait. Update
5695 comments.
5696 (linux_nat_attach): Use linux_nat_post_attach_wait.
5697 (detach_callback, linux_nat_detach): Improve handling for signalled
5698 processes.
5699 (linux_nat_pid_to_str): Always print out the LWP ID if it differs
5700 from the process ID.
5701 * Makefile.in (infcmd.o): Update.
5702
5703 2008-05-01 Daniel Jacobowitz <dan@codesourcery.com>
5704
5705 * arm-linux-tdep.h (ARM_CPSR_REGNUM): Delete definition.
5706 * arm-tdep.c (arm_frame_is_thumb): New.
5707 (arm_pc_is_thumb): Clarify comment.
5708 (thumb_analyze_prologue): Remove PC special case.
5709 (thumb_scan_prologue): Take a block_addr argument. Use it for
5710 find_pc_partial_function. Remove unused variables.
5711 (arm_scan_prologue): Use arm_frame_is_thumb. Use the block address
5712 for find_pc_partial_function. Remove PC special case.
5713 (arm_prologue_prev_register): Add special handling for PC and CPSR.
5714 (arm_dwarf2_prev_register, arm_dwarf2_frame_init_reg): New.
5715 (arm_get_next_pc): Use arm_frame_is_thumb.
5716 (arm_write_pc): Use CPSR_T instead of 0x20.
5717 (arm_gdbarch_init): Call dwarf2_frame_set_init_reg.
5718 * arm-tdep.h (enum gdb_regnum): Add ARM_CPSR_REGNUM.
5719 (CPSR_T): Define.
5720 * dwarf2-frame.c (dwarf2_frame_prev_register): Handle
5721 DWARF2_FRAME_REG_FN.
5722 * dwarf2-frame.h (enum dwarf2_frame_reg_rule): Add
5723 DWARF2_FRAME_REG_FN.
5724 (struct dwarf2_frame_state_reg): Add FN to loc union.
5725
5726 2008-05-01 Nick Roberts <nickrob@snap.net.nz>
5727
5728 * exec.c (print_section_info): Add missing '\n'.
5729
5730 2008-05-01 Vladimir Prus <vladimir@codesourcery.com>
5731
5732 * thread.c (add_thread): Move observer call to ...
5733 (add_thread_silent): ... here.
5734
5735 2008-04-30 Ulrich Weigand <uweigand@de.ibm.com>
5736
5737 * rs6000-tdep.c: Update for unwinder changes.
5738 * ppcobsd-tdep.c: Likewise.
5739
5740 2008-04-30 Ulrich Weigand <uweigand@de.ibm.com>
5741
5742 * s390-tdep.c: Update for unwinder changes.
5743
5744 2008-04-30 Ulrich Weigand <uweigand@de.ibm.com>
5745
5746 * spu-tdep.c: Update for unwinder changes.
5747
5748 2008-04-30 Daniel Jacobowitz <dan@codesourcery.com>
5749
5750 * hppanbsd-tdep.c, m68kbsd-tdep.c, mn10300-linux-tdep.c,
5751 ppc-linux-tdep.c, ppcnbsd-tdep.c, sparc-linux-tdep.c,
5752 sparc64-linux-tdep.c: Update for unwinder changes.
5753
5754 2008-04-30 Daniel Jacobowitz <dan@codesourcery.com>
5755
5756 * mipsnbsd-tdep.c, mips64obsd-tdep.c, mips-linux-tdep.c: Update
5757 for unwinder changes.
5758 * mips-tdep.c: Likewise.
5759 (mips_stub_frame_cache): Unwind the ABI stack pointer, not the
5760 raw one.
5761
5762 2008-04-30 Daniel Jacobowitz <dan@codesourcery.com>
5763
5764 * arm-linux-tdep.c, arm-tdep.c, armobsd-tdep.c: Update for
5765 unwinder changes.
5766
5767 2008-04-30 Daniel Jacobowitz <dan@codesourcery.com>
5768
5769 Update i386 and amd64 ports for unwinder changes.
5770
5771 * amd64-tdep.c (amd64_frame_cache): Expect this_frame.
5772 (amd64_frame_this_id, amd64_frame_prev_register): Update signature.
5773 (amd64_frame_unwind): Use default_frame_sniffer.
5774 (amd64_frame_sniffer): Delete.
5775 (amd64_sigtramp_frame_cache): Expect this_frame.
5776 (amd64_sigtramp_frame_this_id, amd64_sigtramp_frame_prev_register)
5777 (amd64_sigtramp_frame_sniffer): Update signature.
5778 (amd64_sigtramp_frame_unwind): Add amd64_sigtramp_frame_sniffer.
5779 (amd64_frame_base_address): Expect this_frame.
5780 (amd64_dummy_id): Renamed from amd64_unwind_dummy_id. Expect
5781 this_frame.
5782 (amd64_init_abi): Use set_gdbarch_dummy_id and
5783 frame_unwind_append_unwinder.
5784 * i386-tdep.c (i386_frame_cache): Expect this_frame.
5785 (i386_frame_this_id, i386_frame_prev_register): Update signature.
5786 (i386_frame_unwind): Use default_frame_sniffer.
5787 (i386_frame_sniffer): Delete.
5788 (i386_sigtramp_frame_cache): Expect this_frame.
5789 (i386_sigtramp_frame_this_id, i386_sigtramp_frame_prev_register)
5790 (i386_sigtramp_frame_sniffer): Update signature.
5791 (i386_sigtramp_frame_unwind): Use i386_sigtramp_frame_sniffer.
5792 (i386_frame_base_address): Update signature.
5793 (i386_dummy_id): Rename from i386_unwind_dummy_id. Expect this_frame.
5794 (i386_push_dummy_call): Update comment.
5795 (i386_sigtramp_p, i386_svr4_sigtramp_p, i386_svr4_sigcontext_addr):
5796 Expect this_frame.
5797 (i386_gdbarch_init): Use set_gdbarch_dummy_id, dwarf2_append_unwinders,
5798 and frame_unwind_append_unwinder.
5799 * amd64-linux-tdep.c, amd64-sol2-tdep.c, amd64fbsd-tdep.c,
5800 amd64nbsd-tdep.c, amd64obsd-tdep.c, i386-linux-tdep.c,
5801 i386-nto-tdep.c, i386bsd-tdep.c, i386-sol2-tdep.c, i386obsd-tdep.c,
5802 i386nbsd-tdep.c: Update for unwinder changes.
5803
5804 2008-04-30 Daniel Jacobowitz <dan@codesourcery.com>
5805
5806 * trad-frame.c (struct trad_frame_cache): Rename next_frame to this_frame.
5807 (trad_frame_cache_zalloc, trad_frame_alloc_saved_regs): Expect
5808 this_frame.
5809 (trad_frame_get_prev_register, trad_frame_get_register): Update signature.
5810 * trad-frame.h (trad_frame_cache_zalloc, trad_frame_get_register)
5811 (trad_frame_alloc_saved_regs, trad_frame_get_prev_register): Update
5812 signature.
5813 * tramp-frame.c (tramp_frame_cache, tramp_frame_start): Expect
5814 this_frame.
5815 (tramp_frame_this_id, tramp_frame_prev_register, tramp_frame_sniffer):
5816 Update signature.
5817 * tramp-frame.h (struct tramp_frame): Update signature of init.
5818 * Makefile.in (trad-frame.o): Update.
5819
5820 2008-04-30 Daniel Jacobowitz <dan@codesourcery.com>
5821
5822 * dwarf2-frame.c (read_reg): Expect this_frame in the baton.
5823 (execute_stack_op): Put this_frame in the baton.
5824 (execute_cfa_program): Take this_frame.
5825 (struct dwarf2_frame_ops): Update comment for signal_frame_p.
5826 (dwarf2_frame_default_init_reg, dwarf2_frame_init_reg)
5827 (dwarf2_frame_signal_frame_p, dwarf2_frame_cache)
5828 (dwarf2_frame_this_id): Adjust to work on this_frame.
5829 (dwarf2_signal_frame_this_id): Delete.
5830 (dwarf2_frame_prev_register): Update signature. Use new frame
5831 unwind methods.
5832 (dwarf2_frame_sniffer): Update signature. Expect this_frame.
5833 (dwarf2_frame_unwind, dwarf2_signal_frame_unwind): Add
5834 dwarf2_frame_sniffer.
5835 (dwarf2_append_unwinders): New.
5836 (dwarf2_frame_base_address, dwarf2_frame_base_sniffer): Expect
5837 this_frame.
5838 * sparc-tdep.c (sparc32_dwarf2_struct_return_p)
5839 (sparc32_dwarf2_frame_init_reg): Expect this_frame.
5840 * cris-tdep.c (cris_dwarf2_frame_init_reg): Likewise.
5841 * rs6000-tdep.c (ppc_dwarf2_frame_init_reg): Likewise.
5842 * s390-tdep.c (s390_dwarf2_frame_init_reg): Likewise.
5843 * sh-tdep.c (sh_dwarf2_frame_init_reg): Likewise.
5844 * sparc64-tdep.c (sparc64_dwarf2_frame_init_reg): Likewise.
5845 * dwarf2-frame.h (dwarf2_frame_sniffer): Delete declaration.
5846 (dwarf2_append_unwinders): Declare.
5847 (dwarf2_frame_base_sniffer): Update declaration.
5848 * i386-linux-tdep.c (i386_linux_dwarf_signal_frame_p): Expect
5849 this_frame.
5850
5851 2008-04-30 Daniel Jacobowitz <dan@codesourcery.com>
5852
5853 Convert frame unwinders to use the current frame and
5854 "struct value".
5855
5856 * frame.c (frame_debug): Make global.
5857 (get_frame_id): Pass this frame to unwinder routines.
5858 (frame_pc_unwind): Remove unused unwind->prev_pc support.
5859 (do_frame_register_read): Do not discard the return value of
5860 frame_register_read.
5861 (frame_register_unwind): Remove debug messages. Use
5862 frame_unwind_register_value.
5863 (frame_unwind_register_value, get_frame_register_value): New
5864 functions.
5865 (create_new_frame, get_frame_base_address, get_frame_locals_address)
5866 (get_frame_args_address, get_frame_type): Pass this frame to
5867 unwinder routines.
5868 (frame_cleanup_after_sniffer, frame_prepare_for_sniffer): New
5869 functions.
5870 * frame.h: Update comments.
5871 (frame_debug, frame_unwind_register_value, get_frame_register_value)
5872 (frame_prepare_for_sniffer): Declare.
5873 * frame-unwind.h: Update comments and parameter names.
5874 (default_frame_sniffer): Declare.
5875 (frame_prev_register_ftype): Return a struct value *.
5876 (struct frame_unwind): Remove prev_pc member.
5877 (frame_unwind_sniffer_ftype, frame_unwind_append_sniffer): Delete.
5878 (frame_unwind_append_unwinder, frame_unwind_got_optimized)
5879 (frame_unwind_got_register, frame_unwind_got_memory)
5880 (frame_unwind_got_constant, frame_unwind_got_address): Declare.
5881 * frame-base.h: Update comments and parameter names.
5882 * valops.c (value_fetch_lazy): Use get_frame_register_value. Iterate
5883 if necessary. Add debugging output.
5884 * sentinel-frame.c (sentinel_frame_prev_register)
5885 (sentinel_frame_this_id): Update for new signature.
5886 (sentinel_frame_prev_pc): Delete.
5887 (sentinel_frame_unwinder): Remove prev_pc.
5888 * ia64-tdep.c (ia64_libunwind_frame_unwind): Do not initialize
5889 prev_pc.
5890 * libunwind-frame.c (libunwind_frame_unwind): Likewise.
5891 * frame-unwind.c (struct frame_unwind_table_entry): Remove sniffer.
5892 (frame_unwind_append_sniffer): Delete.
5893 (frame_unwind_append_unwinder): New function.
5894 (frame_unwind_find_by_frame): Take this frame. Only use sniffers
5895 from unwinders. Use frame_prepare_for_sniffer.
5896 (default_frame_sniffer, frame_unwind_got_optimized)
5897 (frame_unwind_got_register, frame_unwind_got_memory)
5898 (frame_unwind_got_constant, frame_unwind_got_address): New functions.
5899 * dummy-frame.c (dummy_frame_sniffer): Use gdbarch_dummy_id.
5900 (dummy_frame_prev_register, dummy_frame_this_id): Update for new
5901 signature.
5902 * gdbarch.sh: Replace unwind_dummy_id with dummy_id.
5903 * gdbarch.c, gdbarch.c: Regenerated.
5904 * frame-base.c (default_frame_base_address)
5905 (default_frame_locals_address, default_frame_args_address): Update
5906 for new signature.
5907 (frame_base_find_by_frame): Pass this frame to unwinder routines.
5908 * infcall.c (call_function_by_hand): Update comments.
5909 * Makefile.in (frame-unwind.o): Update dependencies.
5910
5911 2008-04-30 Daniel Jacobowitz <dan@codesourcery.com>
5912
5913 * ada-lang.c (ada_value_primitive_packed_val): Only check
5914 value_lazy for memory lvals.
5915 * findvar.c (value_of_register_lazy): New function.
5916 (locate_var_value): Only check value_lazy for memory lvals.
5917 * valarith.c (value_subscripted_rvalue): Likewise.
5918 * valops.c (value_fetch_lazy): Handle both memory and register
5919 lvals.
5920 (search_struct_field, value_slice): Only check value_lazy for memory
5921 lvals.
5922 * value.c (struct value): Update comment for lazy.
5923 (value_primitive_field): Only check value_lazy for memory lvals.
5924 * value.h (value_lazy): Update comment.
5925 (value_of_register_lazy): Declare.
5926
5927 2008-04-30 Daniel Jacobowitz <dan@codesourcery.com>
5928
5929 * corefile.c (reopen_exec_file): Close any open files.
5930
5931 2008-04-29 Joel Brobecker <brobecker@adacore.com>
5932
5933 * ia64-tdep.c (ia64_memory_remove_breakpoint): Set
5934 show_memory_breakpoints to 1 while reading the instruction bundle.
5935
5936 2008-04-29 Joel Brobecker <brobecker@adacore.com>
5937
5938 * gdbarch.sh: Document the return_value method. Explain that
5939 the FUNCTYPE parameter might be NULL.
5940 * gdbarch.h: Regenerated.
5941 * sparc-tdep.c (sparc32_push_dummy_code): Do not pass the function
5942 type when calling using_struct_return, as this is unnecessary
5943 on this target.
5944
5945 2008-04-28 Joel Brobecker <brobecker@adacore.com>
5946
5947 * terminal.h (create_tty_session): Fix return type.
5948
5949 2008-04-26 Vladimir Prus <vladimir@codesourcery.com>
5950
5951 * mi/mi-interp.c (mi_new_thread): Quote the thread id.
5952
5953 2008-04-26 Joel Brobecker <brobecker@adacore.com>
5954
5955 * breakpoint.c (condition_command, commands_from_control_command)
5956 (break_command_really): Minor reformatting.
5957
5958 2008-04-25 Pedro Alves <pedro@codesourcery.com>
5959
5960 * dwarf2read.c (dwarf2_const_value): Handle DW_FORM_strp.
5961
5962 2008-04-25 Pedro Alves <pedro@codesourcery.com>
5963
5964 * amd64-tdep.c (amd64_get_longjmp_target): New.
5965 (amd64_init_abi): Register amd64_get_longjmp_target as
5966 gdbarch_get_longjmp_target callback.
5967 * i386-tdep.c (i386_get_longjmp_target): Remove 64-bit handling.
5968
5969 2008-04-25 Pedro Alves <pedro@codesourcery.com>
5970
5971 * breakpoint.h (enum bpstat_what_main_action): Delete
5972 BPSTAT_WHAT_CLEAR_LONGJMP_RESUME_SINGLE.
5973
5974 * breakpoint.c (clrs): Delete.
5975 (bpstat_what): Update table.
5976
5977 * infrun.c (handle_inferior_event): Remove
5978 BPSTAT_WHAT_CLEAR_LONGJMP_RESUME_SINGLE handling.
5979
5980 2008-04-24 Vladimir Prus <vladimir@codesourcery.com>
5981
5982 * mi/mi-cmds.h (mi_cmd_args_ftype): Remove.
5983 Adjust all prototypes using mi_cmd_args_ftype to use
5984 mi_cmd_argv_ftype.
5985 (struct mi_cmd): Remove the args_func field.
5986 * mi/mi-cmds.c: Don't provide value for the args_func field.
5987 * mi/mi-main.c (mi_execute_async_cli_command)
5988 (mi_cmd_exec_run, mi_cmd_exec_next, mi_cmd_exec_next_instruction)
5989 (mi_cmd_exec_step, mi_cmd_exec_step_instruction)
5990 (mi_cmd_exec_finish, mi_cmd_exec_until, mi_cmd_exec_return)
5991 (mi_cmd_exec_continue, mi_cmd_exec_interrupt)
5992 (mi_cmd_target_download): Adjust.
5993 (mi_cmd_target_select): Adjust. Pass 0 for from_tty parameter.
5994 (mi_cmd_execute): Do not check for args_func.
5995 (mi_execute_async_cli_command): Adjust.
5996 * mi/mi-parse.c: Don't check for args_func.
5997
5998 2008-04-24 Vladimir Prus <vladimir@codesourcery.com>
5999
6000 * breakpoint.c (bpstat_check_location)
6001 (bpstat_check_watchpoint, bpstat_check_breakpoint_conditions):
6002 New, extracted from bpstat_stop_status.
6003 (bpstat_stop_status): Use the above.
6004
6005 2008-04-24 Vladimir Prus <vladimir@codesourcery.com>
6006
6007 * mi/mi-main.c (last_async_command): Rename to current_token.
6008 (previous_async_command): Remove.
6009 (mi_cmd_gdb_exit): Adjust.
6010 (mi_cmd_exec_interrupt): Don't dance with previous_async_command.
6011 (mi_cmd_target_select): Adjust.
6012 (mi_cmd_execute): Don't set previous_async_command. Free token
6013 here even in async mode.
6014 (mi_execute_async_cli_command): Adjust.
6015 (mi_exec_async_cli_cmd_continuation): Adjust. Do not free the
6016 token.
6017 (mi_load_progress): Adjust.
6018
6019 2008-04-24 Vladimir Prus <vladimir@codesourcery.com>
6020
6021 * infcmd.c (step_1_continuation): Always disable longjmp
6022 breakpoint if we're not going to do another step.
6023
6024 2008-04-24 Vladimir Prus <vladimir@codesourcery.com>
6025
6026 exec_cleanup murder.
6027 * breakpoint.c (until_break_command_continuation): Add
6028 the 'error' parameter. Directly delete the breakoint as
6029 opposed to running cleanups.
6030 (until_break_command): Install continuation only
6031 after starting the target. Don't use exec cleanups,
6032 use ordinary cleanups. Discard cleanups is successfully
6033 started the target in async mode.
6034 (make_cleanup_delete_breakpoint): Remove.
6035 * breakpoint.h (make_cleanup_delete_breakpoint): Remove
6036 declaration.
6037 * defs.h (do_exec_cleanups, make_exec_cleanup): Remove
6038 declarations.
6039 (struct continations): Add the 'error' parameter to the
6040 continuation_hook field.
6041 (add_continuation, do_all_continuations)
6042 (add_intermediate_continuation)
6043 (do_all_intermediate_continuations): Add the 'error' parameter.
6044 * exceptions.c (throw_exception): Don't call do_exec_cleanups.
6045 * inf-loop.c (inferior_event_handler): Instead of calling
6046 discard_all_continuations, use do_all_continuations with 1 as
6047 'error' parameter. Pass 0 as 'error' parameter in existing uses
6048 of discard_all_continuations.
6049 * infcmd.c (step_1): Do not use exec cleanup. For async case, discard
6050 cleanups.
6051 (step_once): Install continuation only after resuming the target.
6052 (step_1_continuation): Disable longjmp breakpoint on error.
6053 (finish_command_continuation): Add the error parameter. Delete
6054 the finish breakpoint directly, do not use cleanups.
6055 (finish_command): Do not use exec_cleanups. Always setup
6056 continuation. For sync case, immediately run them.
6057 (attach_command_continuation): Add the error parameter.
6058 * infrun.c (fetch_inferior_event): Do not use exec cleanups to
6059 remove step_resume_breakpoint -- adjust delete it directly.
6060 * interps.c (interp_set): Adjust call to do_all_continations.
6061 * mi/mi-interp.c (mi_interpreter_exec_continuation): Do not
6062 do exec cleanups.
6063 * mi/mi-main.c (mi_cmd_target_select): Do not do exec
6064 cleanups.
6065 (mi_cmd_execute): Do not use exec_cleanup.
6066 (mi_execute_async_cli_command): Simplify the string concatenation
6067 logic. Do no use exec cleanup.
6068 (mi_exec_async_cli_cmd_continuation): New parameter error.
6069 Free last_async_command.
6070 * top.c (command_line_handler_continuation): New parameter error.
6071 * utils.c (exec_cleanup_chain, make_exec_cleanup)
6072 (do_exec_cleanups): Remove.
6073 (add_continuation, do_all_continations)
6074 (add_intermediate_continuation)
6075 (do_all_intermediate_continuations): New parameter error.
6076
6077 2008-04-24 Vladimir Prus <vladimir@codesourcery.com>
6078
6079 * breakpoint.h (bp_location_p): New typedef.
6080 Register a vector of bp_location_p.
6081 * breakpoint.c (always_inserted_mode)
6082 (show_always_inserted_mode): New.
6083 (unlink_locations_from_global_list): Remove.
6084 (update_global_location_list)
6085 (update_global_location_list_nothrow): New.
6086 (update_watchpoint): Don't free locations.
6087 (should_insert_location): New.
6088 (insert_bp_location): Use should_insert_location.
6089 (insert_breakpoint_locations): Copied from
6090 insert_breakpoints.
6091 (insert_breakpoint): Use insert_breakpoint_locations.
6092 (bpstat_stop_status): Call update_global_location_list
6093 when disabling breakpoint.
6094 (allocate_bp_location): Don't add to bp_location_chain.
6095 (set_raw_breakpoint)
6096 (create_longjmp_breakpoint, enable_longjmp_breakpoint)
6097 (disable_longjmp_breakpoint, create_overlay_event_breakpoint)
6098 (enable_overlay_breakpoints, disable_overlay_breakpoints)
6099 (set_longjmp_resume_breakpoint)
6100 (enable_watchpoints_after_interactive_call_stop)
6101 (disable_watchpoints_before_interactive_call_start)
6102 (create_internal_breakpoint)
6103 (create_fork_vfork_event_catchpoint)
6104 (create_exec_event_catchpoint, set_momentary_breakpoint)
6105 (create_breakpoints, break_command_1, watch_command_1)
6106 (create_exception_catchpoint)
6107 (handle_gnu_v3_exceptions)
6108 (disable_breakpoint, breakpoint_re_set_one)
6109 (create_thread_event_breakpoint, create_solib_event_breakpoint)
6110 (create_ada_exception_breakpoint): : Don't call check_duplicates.
6111 Call update_global_location_list.
6112 (delete_breakpoint): Don't remove locations and don't
6113 try to reinsert them. Call update_global_location_list.
6114 (update_breakpoint_locations): Likewise.
6115 (restore_always_inserted_mode): New.
6116 (update_breakpoints_after_exec): Temporary disable
6117 always inserted mode.
6118 * Makefile.in: Update dependencies.
6119
6120 * infrun.c (proceed): Remove breakpoints while stepping
6121 over breakpoint.
6122 (handle_inferior_event): Don't remove or insert
6123 breakpoints.
6124 * linux-fork.c (checkpoint_command): Remove breakpoints
6125 before fork and insert after.
6126 (linux_fork_context): Remove breakpoints before switch
6127 and insert after.
6128 * target.c (target_disconnect, target_detach): Remove
6129 breakpoints from target.
6130
6131
6132 2008-04-24 Vladimir Prus <vladimir@codesourcery.com>
6133
6134 * breakpoint.c (print_one_breakpoint_location): In MI
6135 mode, report the location string the breakpoint was
6136 originally created with.
6137
6138 2008-04-23 Maxim Grigoriev <maxim2405@gmail.com>
6139
6140 * Makefile.in (xtensa-tdep.o): Update dependencies.
6141 * configure.tgt (xtensa*): Update dependencies.
6142 * xtensa-tdep.c (arreg_number): Renamed from areg_number.
6143 Local variable areg renamed to arreg.
6144 (areg_number): New function.
6145 (xtensa_pseudo_register_read, xtensa_pseudo_register_write)
6146 (xtensa_extract_return_value, xtensa_store_return_value): areg_number
6147 replaced by arreg_number.
6148 (xtensa_windowed_frame_cache, struct xtensa_frame_cache): New comments.
6149 (xtensa_alloc_frame_cache): Initialize cache->wd.ws.
6150 (xtensa_scan_prologue): New function.
6151 (xtensa_frame_cache): New local fp_regnum. Handle separately the case,
6152 when ENTRY instraction hasn't been executed yet. Get the frame pointer
6153 value based on prologue analysis. Fix the bugs preventing WS and
6154 AR4-AR7/A11 registers from getting right values for intermediate frames,
6155 whose registers have been already spilled.
6156 (xtensa_frame_prev_register): Fix WS register value. Use are_number
6157 and arreg_number appropriately.
6158 (xtensa_gdbarch_init): Set solib_svr4_fetch_link_map_offsets to
6159 svr4_ilp32_fetch_link_map_offsets.
6160
6161 2008-04-23 Andrew Stubbs <andrew.stubbs@st.com>
6162
6163 * printcmd.c: Define USE_PRINTF_I64 and PRINTF_HAS_LONG_LONG on MinGW.
6164 (printf_command): Convert %lld to %I64d when USE_PRINTF_I64 set.
6165
6166 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
6167
6168 * acinclude.m4: Add override.m4.
6169 * configure: Regenerate.
6170
6171 2008-04-22 Jan Kratochvil <jan.kratochvil@redhat.com>
6172
6173 * ada-lang.c (get_selections): Variable PROMPT made non-const and
6174 initialized with a trailing space now. Use PROMPT_ARG of
6175 COMMAND_LINE_INPUT instead of printing it ourselves.
6176
6177 2008-04-22 Joel Brobecker <brobecker@adacore.com>
6178
6179 * NEWS: Document support for 64-bit core file.
6180
6181 2008-04-22 Corinna Vinschen <vinschen@redhat.com>
6182
6183 * NEWS: Add information on calling convention and new SH CLI options.
6184
6185 * sh-tdep.c (sh_cc_gcc): New static string.
6186 (sh_cc_renesas): Ditto.
6187 (sh_cc_enum): New static string array.
6188 (sh_active_calling_convention): New static string pointer denoting
6189 active user chosen ABI.
6190 (sh_is_renesas_calling_convention): New function to return function
6191 specific ABI, or user choice if necessary.
6192 (sh_use_struct_convention): Rename first argument and turn around its
6193 meaning. Check for renesas ABI and return accordingly.
6194 (sh_use_struct_convention_nofpu): New function.
6195 (sh_next_flt_argreg): Get function type as third parameter. Check
6196 for renesas ABI and choose floating registers accordingly.
6197 (sh_push_dummy_call_fpu): Check for ABI and choose argument slot and
6198 struct return slot accordingly.
6199 (sh_push_dummy_call_nofpu): Ditto.
6200 (sh_return_value_nofpu): Call sh_use_struct_convention_nofpu from here.
6201 Evaluate ABI and give to sh_use_struct_convention_nofpu.
6202 (sh_return_value_fpu): Evaluate ABI and give to
6203 sh_use_struct_convention.
6204 (show_sh_command): New function.
6205 (set_sh_command): Ditto.
6206 (_initialize_sh_tdep): Initialize `set/show sh calling-convention
6207 CLI command.
6208
6209 * gdbarch.sh (return_value): Add func_type argument.
6210 * gdbarch.c: Regenerate.
6211 * gdbarch.h: Ditto.
6212 * eval.c (evaluate_subexp_standard): Rename local variable value_type to
6213 val_type so as not to collide with value_type function. Call
6214 using_struct_return with additional function type argument.
6215 * infcall.c (call_function_by_hand): Call using_struct_return and
6216 gdbarch_return_value with additional function type argument.
6217 * infcmd.c (print_return_value): Take addition func_type argument.
6218 Call gdbarch_return_value with additional function type argument.
6219 (finish_command_continuation): Call print_return_value with additional
6220 function type argument.
6221 (finish_command): Ditto.
6222 * sparc-tdep.c (sparc32_push_dummy_code): Call using_struct_return with
6223 additional function type argument.
6224 * stack.c (return_command): Call using_struct_return and
6225 gdbarch_return_value with additional function type argument.
6226 * value.c (using_struct_return): Take additional function type argument.
6227 * value.h (using_struct_return): Accommodate declaration.
6228 * alpha-tdep.c (alpha_return_value): Add func_type argument.
6229 * amd64-tdep.c (amd64_return_value): Ditto.
6230 * arm-tdep.c (arm_return_value): Ditto.
6231 * avr-tdep.c (avr_return_value): Ditto.
6232 * cris-tdep.c (cris_return_value): Ditto.
6233 * frv-tdep.c (frv_return_value): Ditto.
6234 * h8300-tdep.c (h8300_return_value): Ditto.
6235 (h8300h_return_value): Ditto.
6236 * hppa-tdep.c (hppa32_return_value): Ditto.
6237 (hppa64_return_value): Ditto.
6238 * i386-tdep.c (i386_return_value): Ditto.
6239 * ia64-tdep.c (ia64_return_value): Ditto.
6240 * iq2000-tdep.c (iq2000_return_value): Ditto.
6241 * m32c-tdep.c (m32c_return_value): Ditto.
6242 * m32r-tdep.c (m32r_return_value): Ditto.
6243 * m68hc11-tdep.c (m68hc11_return_value): Ditto.
6244 * m68k-tdep.c (m68k_return_value): Ditto.
6245 (m68k_svr4_return_value): Ditto.
6246 * m88k-tdep.c (m88k_return_value): Ditto.
6247 * mep-tdep.c (mep_return_value): Ditto.
6248 * mips-tdep.c (mips_eabi_return_value): Ditto.
6249 (mips_n32n64_return_value): Ditto.
6250 (mips_o32_return_value): Ditto.
6251 (mips_o64_return_value): Ditto.
6252 * mn10300-tdep.c (mn10300_return_value): Ditto.
6253 * mt-tdep.c (mt_return_value): Ditto.
6254 * ppc-linux-tdep.c (ppc_linux_return_value): Ditto.
6255 * ppc-sysv-tdep.c (ppc_sysv_abi_return_value): Ditto.
6256 (ppc_sysv_abi_broken_return_value): Ditto.
6257 (ppc64_sysv_abi_return_value): Ditto.
6258 * ppc-tdep.h (ppc_sysv_abi_return_value): Ditto.
6259 (ppc_sysv_abi_broken_return_value): Ditto.
6260 (ppc64_sysv_abi_return_value): Ditto.
6261 * ppcnbsd-tdep.c (ppcnbsd_return_value): Ditto.
6262 * rs6000-tdep.c (rs6000_return_value): Ditto.
6263 * s390-tdep.c (s390_return_value): Ditto.
6264 * score-tdep.c (score_return_value): Ditto.
6265 * sh-tdep.c (sh_return_value_nofpu): Ditto.
6266 (sh_return_value_fpu): Ditto.
6267 * sh64-tdep.c (sh64_return_value): Ditto.
6268 * sparc-tdep.c (sparc32_return_value): Ditto.
6269 * sparc64-tdep.c (sparc64_return_value): Ditto.
6270 * spu-tdep.c (spu_return_value): Ditto.
6271 * v850-tdep.c (v850_return_value): Ditto.
6272 * vax-tdep.c (vax_return_value): Ditto.
6273 * xstormy16-tdep.c (xstormy16_return_value): Ditto.
6274 * xtensa-tdep.c (xtensa_return_value): Ditto.
6275
6276 * gdbtypes.h (struct type): Add calling_convention member.
6277 * dwarf2read.c (read_subroutine_type): Add calling convention read
6278 from DW_AT_calling_convention attribute to function type.
6279
6280 2008-04-22 Markus Deuling <deuling@de.ibm.com>
6281
6282 * eval.c (evaluate_subexp_standard): Use value_subscripted_rvalue for
6283 multi_f77_subscript to support values from registers.
6284 * valarith.c (value_subscripted_rvalue): Remove prototype and static.
6285 * value.h (value_subscripted_rvalue): Add prototype.
6286
6287 * f-typeprint.c (f_type_print_base): Add support for TYPE_CODE_UNION.
6288 Fix output.
6289 * f-valprint.c (f_val_print): Likewise.
6290
6291 2008-04-21 Craig Silverstein <csilvers@google.com>
6292
6293 * dwarf2read.c (zlib_decompress_section): Define abfd in the
6294 !HAVE_ZLIB_H case.
6295
6296 2008-04-21 Pedro Alves <pedro@codesourcery.com>
6297
6298 * symfile.c (syms_from_objfile): Don't warn if lowest loadable
6299 section is not a code section.
6300
6301 2008-04-19 Craig Silverstein <csilvers@google.com>
6302
6303 * NEWS: Add information on compressed debug sections.
6304
6305 2008-04-19 Vladimir Prus <vladimir@codesourcery.com>
6306
6307 * mi/mi-cmd-var.c (varobj_update_one): Print new
6308 value for variable objects that changed type.
6309
6310 2008-04-19 Vladimir Prus <vladimir@codesourcery.com>
6311
6312 * varobj.c (varobj_invalidate): Don't touch floating
6313 varobjs.
6314
6315 2008-04-19 Mark Kettenis <kettenis@gnu.org>
6316
6317 * symtab.c: (multiple_symbols_modes, multiple_symbols_ask)
6318 (multiple_symbols_cancel): Remove extra const.
6319 * symtab.h: Likewise.
6320
6321 2008-04-19 Nick Roberts <nickrob@snap.net.nz>
6322
6323 * interps.c (top_level_interpreter): Rename static variable...
6324 (top_level_interpreter_ptr): ...to this.
6325 (top_level_interpreter): New function.
6326
6327 * interps.h: New extern for top_level_interpreter.
6328
6329 * linespec.c: Include interps.h and mi/mi-cmds.h.
6330 (decode_line_2): When using MI, always set all breakpoints in menu.
6331
6332 * Makefile.in (linespec.o, mi-interp.o): Add dependencies.
6333
6334 2008-04-18 Craig Silverstein <csilvers@google.com>
6335
6336 * configure.ac (AC_SEARCH_LIBS): Add check for zlib.
6337 * config.in, configure: Regenerate.
6338 * dwarf2read.c: Include zlib.h if present.
6339 Modified *_SECTION macros.
6340 (section_is_p): New.
6341 (dwarf2_locate_sections): Use section_is_p instead of strcmp
6342 (dwarf2_resize_section): New.
6343 to determine whether a given section has a given name.
6344 (zlib_decompress_section): New.
6345 (dwarf2_read_section): Read the compressed section if present
6346 in the binary.
6347 * MAINTAINERS: Added myself to section Write After Approval.
6348
6349 2008-04-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
6350
6351 * defs.h (exec_set_section_offsets): Remove prototype.
6352 * exec.c (exec_set_section_offsets): Remove function.
6353
6354 2008-04-18 Joel Brobecker <brobecker@adacore.com>
6355
6356 * stabsread.c (cleanup_undefined_types_1): Add instance flags check
6357 in the search for the matching symbol.
6358
6359 2008-04-17 Marc Khouzam <marc.khouzam@ericsson.com>
6360
6361 * breakpoint.c (update_watchpoint): Always reparse
6362 condition.
6363
6364 2008-04-17 Joel Brobecker <brobecker@adacore.com>
6365
6366 * breakpoint.c (print_one_breakpoint_location): Make sure to print
6367 the breakpoint address only once.
6368
6369 2008-04-17 Dennis Roberts <dennis.roberts@sunquestinfo.com>
6370
6371 * rs6000-tdep.c (rs6000_gdbarch_init): Use the BFD architecture,
6372 rather than a hard-coded architecture, for xcoff executables.
6373
6374 2008-04-17 Doug Evans <dje@google.com>
6375
6376 * buildsym.c (watch_main_source_file_lossage): New fn.
6377 (end_symtab): Call it.
6378
6379 * source.c (find_and_open_source): Add some comments clarifying
6380 handling of FULLNAME argument. Make static. Remove pointless
6381 xstrdup/xfree.
6382
6383 2008-04-17 Pedro Alves <pedro@codesourcery.com>
6384
6385 * inf-loop.c (inferior_event_handler): Also run the intermediate
6386 continuations in the INF_EXEC_COMPLETE case.
6387
6388 2008-04-16 Tom Tromey <tromey@redhat.com>
6389
6390 * cli/cli-decode.h (CMD_ASYNC_OK): New define.
6391 (set_cmd_async_ok, get_cmd_async_ok): Declare.
6392 * cli/cli-decode.c (set_cmd_async_ok): New function.
6393 (get_cmd_async_ok): New function.
6394 * cli/cli-cmds.c (init_cli_cmds): Mark "pwd", "help", "info", and
6395 "show" as async-ok.
6396 * top.c (execute_command): Use get_cmd_async_ok.
6397 * infcmd.c: Include cli/cli-decode.h.
6398 (_initialize_infcmd): Mark "interrupt" as async-ok.
6399 * Makefile.in (infcmd.o): Depend on cli_decode_h.
6400
6401 2008-04-16 Daniel Jacobowitz <dan@codesourcery.com>
6402
6403 PR gdb/2445
6404 * exec.c: Correct "arch-utils.h" include.
6405
6406 2008-04-15 Aleksandar Ristovski <aristovski@qnx.com>
6407
6408 PR gdb/2424
6409 * infrun.c (normal_stop) Move breakpoint_auto_delete further down
6410 to allow printing to 'see' real reason of stop. This fixes PR 2424.
6411 * breakpoint.c (bpdisp_texst): New function. The function takes over
6412 the role of bpstats static array in print_one_breakpoint_location.
6413 (print_it_typical): Print "Temporary breakpoint" instead
6414 of just "Breakpoint" when breakpoint is, well, temporary. For mi-like
6415 protocols, print disp field.
6416 (print_one_breakpoint_location): Removed bpdisps static definition.
6417 Call new bpstat_text function to get value for 'disp' field.
6418 (mention): Print "Temporary breakpoint" instead of just "Breakpoint".
6419
6420 2008-04-15 Daniel Jacobowitz <dan@codesourcery.com>
6421
6422 * gnulib/Makefile.am, gnulib/m4/gnulib-cache.m4,
6423 gnulib/aux/link-warning.h, gnulib/extra/link-warning.h: Adjust
6424 by rerunning gnulib-tool with --aux-dir=gnulib/extra.
6425 * gnulib/Makefile.in: Regenerate.
6426
6427 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
6428
6429 * Makefile.in (GNULIB_H): New. Trigger all-lib.
6430 (defs_h): Use $(GNULIB_H).
6431 (all-lib): Depend on gnulib/Makefile.
6432 (gnulib/Makefile): Regenerate gnulib/Makefile and gnulib/.deps.
6433 * config.in, gnulib/Makefile.in: Regenerated.
6434
6435 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
6436
6437 * Makefile.in (LIBGNU, INCGNU): Define.
6438 (INTERNAL_CFLAGS_BASE): Add INCGNU.
6439 (INTERNAL_LIBS, CLIBS, CDEPS): Add LIBGNU.
6440 (CLEANDIRS): New.
6441 ($(LIBGNU), all-lib): New rules.
6442 (clean, distclean, do-maintainer-clean): Use CLEANDIRS.
6443 * configure.ac: Use gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE.
6444 Simplify AC_CONFIG_AUX_DIR. Generate gnulib/Makefile.
6445 * gnulib: New directory, from gnulib-tool.
6446 * configure, aclocal.m4: Regenerated.
6447
6448 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
6449
6450 * linux-thread-db.c (have_threads_callback): Check thread->private.
6451
6452 2008-04-13 Nick Roberts <nickrob@snap.net.nz>
6453 Vladimir Prus <vladimir@codesourcery.com>
6454
6455 Fix @-varobjs.
6456 * varobj.c (value_of_root): Update the expression for
6457 floating varobjs.
6458 * mi/mi-cmd-var.c (varobj_update_one): If type has changed,
6459 report that.
6460
6461 2008-04-09 Marc Khouzam <marc.khouzam@ericsson.com>
6462
6463 * mi/mi-cmd-var.c: Include "mi-getopt.h".
6464 (mi_parse_format): New. Factored out from mi_cmd_var_set_format.
6465 (mi_cmd_var_set_format): Use new mi_parse_format.
6466 (mi_cmd_var_evaluate_expression): Support for -f option to specify
6467 format.
6468 * Makefile.in (mi-cmd-var.o): Update dependencies.
6469
6470 * varobj.h (varobj_get_formatted_value): Declare.
6471 * varobj.c (my_value_of_variable): Added format parameter.
6472 (cplus_value_of_variable): Likewise.
6473 (java_value_of_variable): Likewise.
6474 (c_value_of_variable): Likewise. Evaluate expression based
6475 on format parameter.
6476 (struct language_specific): Add format parameter to function member
6477 *value_of_variable.
6478 (varobj_get_formatted_value): New.
6479 (varobj_get_value): Added format parameter to method call.
6480
6481 2008-04-08 Joel Brobecker <brobecker@adacore.com>
6482
6483 * stabsread.c (cleanup_undefined_types_noname): Manually set the
6484 instance flags of the undefined type before calling replace_type.
6485
6486 2008-04-08 Vladimir Prus <vladimir@codesourcery.com>
6487
6488 * target.h (enum strata): Remove the download_stratum.
6489
6490 2008-04-07 Doug Evans <dje@google.com>
6491
6492 * buildsym.h (last_source_file): Add dwarf info to comment.
6493 (last_source_start_addr): Ditto.
6494
6495 2008-04-07 Pedro Alves <pedro@codesourcery.com>
6496
6497 * alphanbsd-tdep.c: Include "target.h".
6498 * mn10300-tdep.c: Include "target.h".
6499 * Makefile.in (alphanbsd-tdep.o, mn10300-tdep.o): Update.
6500
6501 2008-04-06 Vladimir Prus <vladimir@codesourcery.com>
6502
6503 Fix breakpoint condition that use member variables.
6504 * valops.c (check_field): Remove.
6505 (check_field_in): Rename to check_field.
6506 (value_of_this): Use la_name_of_this.
6507 * value.h (check_field): Adjust prototype.
6508
6509 * language.h (la_value_of_this): Rename to la_name_of_this.
6510 * language.c (unknown_language_defn): Specify "this" for
6511 name_of_this.
6512 (auto_language_defn): Likewise.
6513 (local_language_defn): Likewise.
6514 * ada-lang.c (ada_language_defn): Adjust comment.
6515 * c-lang.c (c_language_defn): Adjust comment.
6516 (cplus_language_defn): Specify "this" for name_of_this.
6517 (asm_language_defn): Adjust comment.
6518 (minimal_language_defn): Adjust comment.
6519 * f-lang.c (f_language_defn): Specify NULL for name_of_this.
6520 * jv-lang.c (java_language_defn): Specify "this" for name_of_this.
6521 * m2-lang.c (m2_language_defn): Specify "this" for name_of_this.
6522 * objc-lang.c (objc_language_defn): Specify "self" for
6523 name_of_this.
6524 * p-lang.c (pascal_language_defn): Specify "this" for
6525 name_of_this.
6526 * scm-lang.c (scm_language_defn): Specify NULL for name_of_this.
6527
6528 * symtab.c (lookup_symbol_aux): Lookup "this" in the
6529 proper scope, and check for field in type of "this", without
6530 trying to create a value.
6531
6532 2008-04-04 Pedro Alves <pedro@codesourcery.com>
6533
6534 * mi/mi-cmds.h (enum mi_cmd_result): Delete MI_CMD_ERROR.
6535 (mi_error_message): Delete declaration.
6536 * mi/mi-interp.c (mi_cmd_interpreter_exec): Call error instead of
6537 returning MI_CMD_ERROR.
6538 * mi/mi-main.c (mi_error_message): Delete.
6539 (mi_cmd_exec_interrupt):
6540 (mi_cmd_thread_select, mi_cmd_thread_list_ids)
6541 (mi_cmd_thread_info): Call error instead of returning
6542 MI_CMD_ERROR.
6543 (mi_cmd_data_list_register_values): Call error instead of
6544 returning MI_CMD_ERROR. Adapt to new get_register interface.
6545 (get_register): Change return typo to void. Call error instead of
6546 returning MI_CMD_ERROR.
6547 (mi_cmd_data_write_register_values): Call error instead of
6548 returning MI_CMD_ERROR.
6549 (mi_cmd_list_features): Return MI_CMD_DONE.
6550 (captured_mi_execute_command): Remove MI_CMD_ERROR handling.
6551 (mi_execute_command): Always print exceptions with -error.
6552
6553 2008-04-04 Joel Brobecker <brobecker@adacore.com>
6554
6555 * NEWS: Mention new commands set/show multiple-symbols.
6556
6557 2008-04-03 Joel Brobecker <brobecker@adacore.com>
6558
6559 * symtab.c (multiple_symbols_ask, multiple_symbols_all)
6560 (multiple_symbols_cancel): New constants.
6561 (multiple_symbols_modes, multiple_symbols_mode): New static globals.
6562 (multiple_symbols_select_mode): New function.
6563 (_initialize_symtab): Add new set/show multiple-symbols commands.
6564 * symtab.h (multiple_symbols_ask, multiple_symbols_all)
6565 (multiple_symbols_cancel, multiple_symbols_select_mode): Declare.
6566 * ada-lang.c (user_select_syms): Add handling of new multiple-symbols
6567 setting.
6568 * linespec.c (decode_line_2): Likewise.
6569
6570 2008-04-03 Doug Evans <dje@sebabeach.org>
6571
6572 * symtab.h (enum free_code): Delete free_contents, unused.
6573 * symmisc.c (free_symtab_block): Delete.
6574 (free_symtab, case free_code): Delete.
6575
6576 2008-04-01 Aleksandar Ristovski <aristovski@qnx.com>
6577
6578 * valops.c (value_cast_structs): New function. Cast related
6579 STRUCT types up/down and return cast value. The body of this
6580 function comes mostly from value_cast_pointers.
6581 (value_cast_pointers): Code for actual cast STRUCT-STRUCT moved
6582 to value_cast_structs. Now value_cast_pointers needs only create
6583 appropriate reference after using value_cast_structs for actual
6584 casting.
6585 (value_cast): Handle references.
6586
6587 2008-04-01 Marc Khouzam <marc.khouzam@ericsson.com>
6588
6589 * MAINTAINERS: Added myself to section Write After Approval.
6590
6591 2008-03-30 Daniel Jacobowitz <dan@codesourcery.com>
6592
6593 * ia64-tdep.c (examine_prologue): Correct array access.
6594
6595 2008-03-28 Aleksandar Ristovski <aristovski@qnx.com>
6596
6597 * cp-support.c (first_component_command): Return if no arguments.
6598
6599 2008-03-28 Carlos O'Donell <carlos@codesourcery.com>
6600
6601 * ser-mingw.c (ser_windows_open): Open requested name.
6602
6603 2008-03-28 Aleksandar Ristovski <aristovski@qnx.com>
6604
6605 * MAINTAINERS: Added myself.
6606
6607 2008-03-28 Pedro Alves <pedro@codesourcery.com>
6608
6609 * target.c (find_default_run_target): Allow a NULL `do_mesg'
6610 parameter. If it is NULL, don't call error.
6611 (find_default_can_async_p, find_default_is_async_p): Pass NULL as
6612 `do_mesg' parameter to find_default_run_target. If no target was
6613 found, return 0.
6614
6615 2008-03-28 Daniel Jacobowitz <dan@codesourcery.com>
6616
6617 * mips-linux-tdep.c: Update N32/N64 signal frame comments.
6618 (N64_SIGCONTEXT_LO, N64_SIGCONTEXT_PC, N64_SIGCONTEXT_FPCSR): Update.
6619 (N64_SIGCONTEXT_FIR, N64_SIGCONTEXT_CAUSE, N64_SIGCONTEXT_BADVADDR):
6620 Delete.
6621 (mips_linux_n32n64_sigframe_init): Do not record cause or badvaddr.
6622
6623 2008-03-27 Joel Brobecker <brobecker@adacore.com>
6624
6625 GDB 6.8 released.
6626
6627 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
6628
6629 * features/Makefile (%.dat): Set xmltarget to the base filename
6630 of the XML source, without subdirectory.
6631 * regformats/rs6000/powerpc-32.dat: Regenerate.
6632 * regformats/rs6000/powerpc-64.dat: Regenerate.
6633 * regformats/rs6000/powerpc-e500.dat: Regenerate.
6634
6635 2008-03-27 Markus Deuling <deuling@de.ibm.com>
6636
6637 * xcoffread.c (scan_xcoff_symtab): Replace current_gdbarch by
6638 objfile arch.
6639
6640 2008-03-27 Nick Roberts <nickrob@snap.net.nz>
6641
6642 * mi/mi-main.c (enum captured_mi_execute_command_actions):
6643 Spell suppress in EXECUTE_COMMAND_SUPPRESS_PROMPT correctly.
6644
6645 2008-03-26 Ulrich Weigand <uweigand@de.ibm.com>
6646
6647 * objfiles.h (struct objfile): New GDBARCH member.
6648 (get_objfile_arch): Add prototype.
6649 * objfiles.c: Include "arch-utils.h".
6650 (allocate_objfile): Look up gdbarch associated with bfd.
6651 (get_objfile_arch): New function.
6652 * Makefile (objfiles.o): Update dependencies.
6653
6654 * dwarf2-frame.c (decode_frame_entry_1): Replace current_gdbarch
6655 by objfile arch.
6656 * dwarf2loc.c (dwarf_expr_read_reg): Replace current_gdbarch
6657 by frame arch.
6658 (locexpr_describe_location): Replace current_gdbarch by
6659 objfile arch.
6660 * dwarf2read.c (die_type): Replace current_gdbarch by objfile arch.
6661 (dwarf2_add_field): Likewise.
6662 (read_tag_pointer_type): Likewise.
6663 (read_base_type): Likewise.
6664 (new_symbol): Likewise.
6665
6666 * coffread.c (decode_type): Add OBJFILE argument. Update callers.
6667 (decode_base_type, decode_function_type): Likewise.
6668 (coff_read_struct_type, coff_read_enum_type): Likewise.
6669 (coff_symtab_read): Replace current_gdbarch by objfile arch.
6670 (decode_base_type): Likewise.
6671 (coff_read_enum_type): Likewise.
6672 (coff_read_struct_type): Replace current_objfile by OBJFILE argument.
6673 (coff_read_enum_type): Likewise.
6674
6675 * dbxread.c (read_dbx_symtab): Replace current_gdbarch by objfile arch.
6676 (end_psymtab): Likewise.
6677 (process_one_symbol): Likewise.
6678
6679 * mdebugread.c (parse_symbol): Replace current_gdbarch by objfile arch.
6680 (parse_procedure): Likewise.
6681 (parse_partial_symbols): Likewise.
6682
6683 * somread.c (som_symtab_read): Replace current_gdbarch by objfile arch.
6684
6685 * stabsread.c (define_symbol): Replace current_gdbarch by objfile arch.
6686 Replace static pcc_promotion_type and pcc_unsigned_promotion_type by
6687 built-in types.
6688 (read_range_type): Replace current_gdbarch by objfile arch. Replace
6689 static range_index_type by built-in type.
6690 (read_one_struct_field): Replace current_gdbarch by objfile arch.
6691 (read_enum_type): Likewise.
6692
6693 * xcoffread.c (read_xcoff_symtab): Replace current_gdbarch by
6694 objfile arch.
6695
6696 2008-03-26 Vladimir Prus <vladimir@codesourcery.com>
6697
6698 * varobj.h (varobj_floating_p): Declare.
6699 * varobj.c (varobj_floating_p): New.
6700 * mi/mi-cmd-var.c (mi_cmd_var_update): When passed
6701 '@' as the name, update all floating varobjs.
6702
6703 2008-03-26 Vladimir Prus <vladimir@codesourcery.com>
6704
6705 * varobj.c (struct varobj_root): Rename use_selected_frame to
6706 floating, and clarify the meaning.
6707 (varobj_create, varobj_update, new_root_variable): Adjust.
6708 (value_of_root): Don't use type_changed as in variable,
6709 adjust comment.
6710 (c_value_of_root): Adjust.
6711
6712 2008-03-25 Pedro Alves <pedro@codesourcery.com>
6713
6714 * linux-nat.c (linux_nat_attach): Add the pid we attached to, to
6715 gdb's thread list.
6716 (linux_nat_wait): Add main lwp to gdb's thread list.
6717 * linux-thread-db.c (find_new_threads_callback): Also attach to
6718 already listed threads which thread_db didn't know about yet.
6719
6720 2008-03-25 Pedro Alves <pedro@codesourcery.com>
6721
6722 * linux-nat.c (drain_queued_events): Fix comment typo.
6723 (linux_nat_attach): In async mode, don't rely on storing a pending
6724 status. Instead place the wait status on the pipe.
6725 (linux_nat_resume): Remove unreacheable shortcut code in async
6726 mode.
6727 (stop_wait_callback): In async mode, don't store pending status.
6728 Instead, cancel breakpoints or resend the signal appropriatelly.
6729 (cancel_breakpoint): New, refactored from
6730 cancel_breakpoints_callback.
6731 (cancel_breakpoints_callback): Call cancel_breakpoint.
6732 (pipe_to_local_event_queue): Remove special token processing.
6733 (linux_nat_wait): Issue an internal error if a pending status is
6734 found in async mode.
6735
6736 2008-03-24 Daniel Jacobowitz <dan@codesourcery.com>
6737
6738 * inflow.c (gdb_has_a_terminal): Guard access to our_process_group.
6739
6740 2008-03-24 Nick Roberts <nickrob@snap.net.nz>
6741 Vladimir Prus <vladimir@codesourcery.com>
6742
6743 * varobj.c (struct varobj_root): New component thread_id.
6744 (varobj_get_thread_id, check_scope): New functions.
6745 (c_value_of_root): Use check_scope. Switch to the
6746 proper thread if necessary.
6747
6748 * varobj.h (varobj_get_thread_id): New extern.
6749
6750 * mi/mi-cmd-var.c (print_varobj): Add thread-id field.
6751
6752 2008-03-23 Daniel Jacobowitz <dan@codesourcery.com>
6753
6754 PR gdb/544
6755 * top.c: Revert 2008-03-21 changes.
6756
6757 2008-03-23 Vladimir Prus <vladimir@codesourcery.com>
6758
6759 * thread.c (make_cleanup_restore_current_thread): Make it
6760 globally visible.
6761 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
6762 * varobj.c (varobj_update): Don't save/restore frame.
6763 (c_value_of_root): Save/restore thread and frame here,
6764 using make_cleanup_restore_current_thread.
6765 * Makefile.in: Update dependecies.
6766
6767 2008-03-23 Vladimir Prus <vladimir@codesourcery.com>
6768
6769 * varobj.c (struct varobj_root): Clarify
6770 comment on the frame field.
6771 (varobj_create): Don't set frame if we have no
6772 block.
6773
6774 2008-03-21 Daniel Jacobowitz <dan@codesourcery.com>
6775
6776 PR gdb/544
6777 Suggested by Jan Kratochvil:
6778 * top.c (gdb_rl_operate_and_get_next_completion): Call
6779 rl_redisplay_function.
6780 (gdb_rl_redisplay): New.
6781 (init_main): Set rl_redisplay_function.
6782
6783 2008-03-21 Thomas Mittelstaedt <T.Mittelstaedt@cadenas.de> (tiny change)
6784
6785 * aix-thread.c (pdc_read_regs): Fix compiler warning.
6786 (pdc_write_regs, aix_thread_resume, fetch_regs_kernel_thread)
6787 (store_regs_kernel_thread): Likewise.
6788
6789 2008-03-21 Pedro Alves <pedro@codesourcery.com>
6790
6791 Linux native async support.
6792
6793 * target.h (struct target_ops): Delete to_async_mask_value and add
6794 to_async_mask.
6795 (target_is_async_p, target_async): Formatting.
6796 (target_async_mask_value): Delete.
6797 (target_async_mask): Delete function declaration, and add new
6798 target macro with the same name.
6799
6800 * target.c (update_current_target): Replace to_async_mask_value by
6801 to_async_mask. Default to_async_mask to return_one.
6802 (target_async_mask): Delete.
6803 (find_default_can_async_p, find_default_is_async_p): New.
6804 (init_dummy_target): register find_default_can_async_p and
6805 find_default_is_async_p on the dummy target.
6806
6807 * linux-nat.c: Include inf-loop.h, event-loop.h and event-top.h.
6808 (debug_linux_nat_async): New global.
6809 (show_debug_linux_nat_async): New function.
6810 (linux_nat_async_enabled, linux_nat_async_mask_value)
6811 (linux_nat_event_pipe, linux_nat_num_queued_events)
6812 (linux_nat_async_events_enabled): New globals.
6813 (struct waitpid_result): New struct.
6814 (waitpid_queue): New global.
6815 (queued_waitpid, push_waitpid, drain_queued_events): New.
6816 (my_waitpid): Call queued_waitpid.
6817 (linux_child_follow_fork): Disable async events during the call.
6818 (blocked_mask): Delete.
6819 (sync_sigchld_action, async_sigchld_action): New globals.
6820 (lin_lwp_attach_lwp): In sync mode, don't reblock SIGCHLD. In
6821 async mode, block events during the call.
6822 (linux_nat_create_inferior): New.
6823 (linux_nat_attach): In sync mode, restore the mask states. In
6824 async mode, wake the event loop immediatelly.
6825 (detach_callback): Drain all queued events of the lwp we're
6826 detaching from.
6827 (linux_nat_detach): Block async mode, and drain events of the main
6828 process.
6829 (linux_nat_resume): If in async mode, mask async events during the
6830 call. If short circuiting, force event loop to wake up. If
6831 resuming, set target_executing, and register target events in the
6832 event loop.
6833 (pipe_to_local_event_queue, local_event_queue_to_pipe): New.
6834 (linux_nat_wait): In async mode, block events during the call.
6835 Only enable/disable passing SIGINT to the inferior in sync mode.
6836 Get events from local waitpid queue. If no interesting events was
6837 found, return to events loop. Reregister target events in the
6838 event loop on exit. In sync mode, no need to reblock SIGCHLD.
6839 (linux_nat_kill): Disable events on entry.
6840 (linux_nat_mourn_inferior): In sync mode, don't restore the masks
6841 here. Detach async mode from the event loop if there are no more
6842 forks available, otherwise leave it on.
6843 (sigchld_handler): Assure this is called only in sync mode.
6844 (linux_async_permitted, linux_async_permitted_1): New globals.
6845 (set_maintenance_linux_async_permitted)
6846 (show_maintenance_linux_async_permitted): New functions.
6847 (linux_nat_is_async_p, linux_nat_can_async_p)
6848 (linux_nat_async_mask): New.
6849 (linux_nat_event_pipe_pop, linux_nat_event_pipe_push): New.
6850 (get_pending_events, async_sigchld_handler): New.
6851 (linux_nat_async_events): New.
6852 (async_terminal_is_ours): New global.
6853 (linux_nat_terminal_inferior, linux_nat_terminal_ours): New.
6854 (async_client_callback, async_client_context): New.
6855 (linux_nat_async_file_handler, linux_nat_async)
6856 (linux_nat_disable_async, linux_nat_enable_async): New.
6857 (linux_nat_add_target): Register linux_nat_create_inferior,
6858 linux_nat_can_async_p, linux_nat_is_async_p, linux_nat_async,
6859 linux_nat_async_mask, linux_nat_terminal_inferior and
6860 linux_nat_terminal_ours.
6861 (_initialize_linux_nat): Remove local action variable, and update
6862 code that used it to use sync_sigchld_action. Add new
6863 "lin-lwp-async" debug set/show command. Put the "lin-lwp" debug
6864 set/show command in the maintenance class. Add new "linux-async"
6865 maintenance set/show command. Block SIGCHLD by default. Setup
6866 async_sichld_action, and sync_sigchld_action. Install the default
6867 async mode.
6868 (lin_thread_get_thread_signals): Use a local sigset_t for blocking
6869 the cancel signals.
6870
6871 * linux-thread-db.c (re_check_for_thread_db): New.
6872 (clear_lwpid_callback): Handle TARGET_WAITKIND_IGNORE.
6873 (thread_db_can_async_p, thread_db_is_async_p, thread_db_async)
6874 (thread_db_async_mask): New.
6875 (init_thread_db_ops): Register thread_db_can_async_p,
6876 thread_db_is_async_p, thread_db_async and thread_db_async_mask.
6877
6878 * remote.c (remote_async_mask_value): New.
6879 (remote_return_zero): New.
6880 (init_remote_ops): Register remote_return_zero as callbacks of
6881 to_can_async_p and to_is_async_p.
6882 (remote_can_async_p, remote_is_async_p, remote_async): Update to
6883 use remote_async_mask_value.
6884 (remote_async_mask): New.
6885 (init_remote_async_ops): Remove to_async_mask_value setting and
6886 register remote_async_mask as to_async_mask callback in
6887 remote_async_ops.
6888
6889 * Makefile.in (linux-nat.o): Update.
6890
6891 2008-03-21 Daniel Jacobowitz <dan@codesourcery.com>
6892
6893 * gdbthread.h (add_thread_with_info): New.
6894 * linux-thread-db.c: Add some documentation.
6895 (GET_LWP, GET_PID, GET_THREAD, is_lwp, is_thread, BUILD_LWP): Delete.
6896 (struct private_thread_info): Remove th_valid and ti_valid.
6897 Replace ti with tid.
6898 (thread_get_info_callback): Do not add TID to the new ptid. Do
6899 not cache th or ti.
6900 (thread_db_map_id2thr, lwp_from_thread): Delete functions.
6901 (thread_from_lwp): Assert that the LWP is set. Do not add TID to the
6902 new PTID.
6903 (attach_thread): Handle an already-existing thread. Use
6904 add_thread_with_info. Cache the th and tid.
6905 (detach_thread): Verify that private was set. Remove verbose
6906 argument and printing. Update caller.
6907 (thread_db_detach): Do not adjust inferior_ptid.
6908 (clear_lwpid_callback, thread_db_resume, thread_db_kill): Delete.
6909 (check_event, find_new_threads_callback): Do not add TID to the new PTID.
6910 (thread_db_wait): Do not use lwp_from_thread.
6911 (thread_db_pid_to_str): Use the cached TID.
6912 (thread_db_extra_thread_info): Check that private is set.
6913 (same_ptid_callback): Delete.
6914 (thread_db_get_thread_local_address): Do not use it or check
6915 is_thread. Check that private is set. Assume that the thread
6916 handle is already cached.
6917 (init_thread_db_ops): Remove to_resume and to_kill.
6918 * thread.c (add_thread_with_info): New.
6919 (add_thread): Use it.
6920 * linux-nat.c (find_thread_from_lwp): Delete.
6921 (exit_lwp): Do not use it. Check print_thread_events. Print before
6922 deleting the thread.
6923 (GET_PID, GET_LWP, BUILD_LWP, is_lwp): Move to...
6924 * linux-nat.h (GET_PID, GET_LWP, BUILD_LWP, is_lwp): ...here.
6925 * inf-ttrace.c (inf_ttrace_wait): Use print_thread_events and
6926 printf_unfiltered for thread exits.
6927 * procfs.c (procfs_wait): Likewise.
6928
6929 2008-03-21 Chris Demetriou <cgd@google.com>
6930
6931 * symtab.c (rbreak_command): Quote symbol name before passing
6932 it to break_command.
6933
6934 2008-03-21 Daniel Jacobowitz <dan@codesourcery.com>
6935
6936 * eval.c (evaluate_subexp_for_address): Clarify error message.
6937 Use value_must_coerce_to_target.
6938 * infcall.c (value_arg_coerce): Call value_coerce_to_target.
6939 * valops.c (value_assign): Call value_coerce_to_target when
6940 assigning to anything but internalvars. Leave GDB-side arrays
6941 as arrays when assigning to internalvars.
6942 (value_must_coerce_to_target, value_coerce_to_target): New.
6943 (value_coerce_array, value_addr): Call value_coerce_to_target.
6944 (value_array): Create the array in GDB's memory instead of
6945 the inferior's.
6946 * value.h (value_must_coerce_to_target, value_coerce_to_target):
6947 Declare.
6948
6949 2008-03-21 Daniel Jacobowitz <dan@codesourcery.com>
6950
6951 * top.c (quit_confirm): Warn that we will kill the program.
6952
6953 2008-03-19 Pedro Alves <pedro@codesourcery.com>
6954
6955 * inflow.c (terminal_ours_1): Guard access to
6956 inferior_process_group with #ifdef PROCESS_GROUP_TYPE.
6957
6958 2008-03-18 Ulrich Weigand <uweigand@de.ibm.com>
6959 Jim Blandy <jimb@codesourcery.com>
6960 Daniel Jacobowitz <drow@false.org>
6961
6962 * dwarf2expr.h (struct dwarf_expr_context): Add ADDR_SIZE member.
6963 (dwarf2_read_address): Update prototype.
6964
6965 * dwarf2expr.c (unsigned_address_type): Add ADDR_SIZE parameter.
6966 (signed_address_type): Likewise.
6967 (dwarf2_read_address): Replace BYTES_READ parameter with ADDR_SIZE.
6968 (execute_stack_op): Update calls to unsigned_address_type,
6969 signed_address_type and dwarf2_read_address. Fix implementation
6970 of DW_OP_deref_size.
6971
6972 * dwarf2loc.h (dwarf2_per_cu_objfile): Add prototype.
6973 (dwarf2_per_cu_addr_size): Likewise.
6974 (struct dwarf2_locexpr_baton): Replace OBJFILE with PER_CU.
6975 (struct dwarf2_loclist_baton): Likewise.
6976
6977 * dwarf2loc.c (find_location_expression): Update calls to
6978 dwarf2_read_address. Use dwarf2_per_cu_objfile and
6979 dwarf2_per_cu_addr_size to retrieve PER_CU parameters.
6980 (locexpr_describe_location): Likewise.
6981 (dwarf2_evaluate_loc_desc): Replace OBJFILE with PER_CU parameter.
6982 Set ctx->addr_size to dwarf2_per_cu_addr_size (per_cu).
6983 (dwarf2_loc_desc_needs_frame): Add PER_CU parameter. Set ctx->addr_size
6984 to dwarf2_per_cu_addr_size (per_cu).
6985 (locexpr_read_variable): Update dwarf2_evaluate_loc_desc call.
6986 (loclist_read_variable): Likewise.
6987 (locexpr_read_needs_frame): Update dwarf2_loc_desc_needs_frame call.
6988
6989 * dwarf2read.c (dwarf2_symbol_mark_computed): Set baton->per_cu
6990 instead of baton->objfile.
6991 (dwarf2_per_cu_obfile): New function.
6992 (dwarf2_per_cu_addr_size): Likewise.
6993
6994 * dwarf2-frame.c (struct comp_unit): Move higher.
6995 (struct dwarf2_cie): Add UNIT and ADDR_SIZE members.
6996 (execute_stack_op): Add ADDR_SIZE parameter; set ctx->addr_size.
6997 (execute_cfa_program): Add FDE parameter. Replace EH_FRAME_P
6998 parameter by using fde->eh_frame_p. Use read_encoded_value
6999 to implement DW_CFA_set_loc.
7000 (struct dwarf2_frame_cache): Add ADDR_SIZE member.
7001 (dwarf2_frame_cache): Set cache->addr_size. Update calls to
7002 execute_stack_op and execute_cfa_program.
7003 (dwarf2_frame_prev_register): Update calls to execute_stack_op.
7004 (size_of_encoded_value): Remove.
7005 (read_encoded_value): Add PTR_LEN and FUNC_BASE parameters.
7006 Remove call to size_of_encoded_value. Implement DW_EH_PE_funcrel.
7007 (add_cie): Set cie->unit backlink.
7008 (decode_frame_entry_1): Set cie->addr_size. Update calls to
7009 read_encoded_value.
7010 (dwarf2_build_frame_info): Allocate UNIT on objfile obstack.
7011
7012 2008-03-17 Markus Deuling <deuling@de.ibm.com>
7013
7014 * i386-tdep.c (i386_print_insn): Remove unnecessary call to
7015 gdbarch_bfd_arch_info.
7016
7017 2008-03-17 Joel Brobecker <brobecker@adacore.com>
7018
7019 * aix-thread.c (pdc_read_regs): Minor reformatting.
7020
7021 2008-03-17 Vladimir Prus <vladimir@codesourcery.com>
7022
7023 * thread.c (print_thread_info): Don't insist
7024 on having current thread if there are no
7025 threads at all.
7026
7027 2008-03-17 Pedro Alves <pedro@codesourcery.com>
7028
7029 * infcmd.c (attach_command_post_wait)
7030 (attach_command_continuation): New.
7031 (attach_command): Support background async execution, and async
7032 execution in synchronous mode.
7033
7034 2008-03-17 Daniel Jacobowitz <dan@codesourcery.com>
7035
7036 * stack.c (print_stack_frame, print_frame): Use RETURN_MASK_ERROR.
7037 * symmisc.c (dump_symtab_1): Likewise.
7038 * wrapper.c (gdb_value_struct_elt): Likewise.
7039
7040 2008-03-17 Pedro Alves <pedro@codesourcery.com>
7041
7042 * linux-nat.c (linux_nat_filter_event): Fix comment typo.
7043
7044 2008-03-17 Pedro Alves <pedro@codesourcery.com>
7045
7046 * linux-nat.c (linux_nat_filter_event): New, refactored from
7047 linux_nat_wait.
7048 (linux_nat_wait): Call linux_nat_filter_event.
7049
7050 2008-03-17 Ulrich Weigand <uweigand@de.ibm.com>
7051
7052 * top.c (execute_command): Fix uninitialized variable error.
7053
7054 2008-03-16 Nick Hudson <nick.hudson@dsl.pipex.com>
7055
7056 * Makefile.in (amd64nbsd-nat.o): New dependency.
7057 * amd64nbsd-nat.c: Include "nbsd-nat.h".
7058 (_initialize_amd64nbsd_nat): Update target vector to use
7059 nbsd_pid_to_exec_file.
7060 * config/i386/nbsd64.mh (NATDEPFILES): Add nbsd-nat.o.
7061
7062 2008-03-15 Vladimir Prus <vladimir@codesourcery.com>
7063
7064 Remove ignoring leading exec events code.
7065 * fork-child.c (startup_inferior): Do not set
7066 inferior_ignoring_leading_exec_events.
7067 * inf-child.c (inf_child_reported_exec_events_per_exec_call): Remove.
7068 (inf_child_target): Do not set to_reported_exec_events_per_exec_call.
7069 * infrun.c (inferior_ignoring_leading_exec_events): Remove.
7070 (handle_inferior_event): Remove code for ignoring leading exec
7071 events.
7072 * target.c (update_current_target): Do not inherit, or default,
7073 to_reported_exec_events_per_exec_call.
7074 (debug_to_reported_exec_events_per_exec_call): Remove.
7075 (setup_target_debug): Do not set to_reported_exec_events_per_exec_call.
7076 * target.h (target_reported_exec_events_per_exec_call): Remove.
7077 (struct target): Remove the to_reported_exec_events_per_exec_call
7078 field.
7079
7080 2008-03-15 Vladimir Prus <vladimir@codesourcery.com>
7081
7082 Implement -thread-info.
7083 * gdbthread.h (print_thread_info): Declare.
7084
7085 * thread.c (print_thread_info): New, extracted
7086 from info_threads_command and adjusted to
7087 work for CLI and MI.
7088 (info_threads_command): Use print_thread_info.
7089 * Makefile.in: Update dependencies.
7090
7091 * mi/mi-cmds.c (mi_cmds): Specify a handler
7092 for -thread-info.
7093 * mi/mi-cmds.h (mi_cmd_thread_info): Declare.
7094 * mi/mi-main.c (mi_cmd_thread_info): New.
7095 (mi_cmd_list_features): Include 'thread-info'.
7096
7097 2008-03-14 Kevin Buettner <kevinb@redhat.com>
7098
7099 * mips-tdep.c (mips32_scan_prologue): Use the ABI register size
7100 to decide whether to match instruction patterns using "sw" and "sd".
7101
7102 2008-03-14 Pedro Alves <pedro@codesourcery.com>
7103
7104 * infcmd.c (jump_command): Postpone disabling stdin until after
7105 the possible query.
7106
7107 2008-03-14 Pedro Alves <pedro@codesourcery.com>
7108
7109 * inflow.c (gdb_getpgrp): New.
7110 (gdb_has_a_terminal): Use get_getpgrp.
7111 (terminal_ours_1): If attach_flag is set, don't refetch
7112 inferior_process_group.
7113
7114 2008-03-14 Pedro Alves <pedro@codesourcery.com>
7115
7116 * features/library-list.dtd: Allow "section" elements as children
7117 of "library". Add "section" element and describe its attributes.
7118
7119 * solib-target.c (struct lm_info): Add section_bases member.
7120 (library_list_start_segment): Error out if seen a section element.
7121 (library_list_start_section): New.
7122 (library_list_end_library): New.
7123 (solib_target_free_library_list): Free section_bases.
7124 (section_attributes): New.
7125 (library_children): Make "segment" optional. Add "section" child.
7126 (library_list_children): Register library_list_end_library.
7127 (solib_target_relocate_section_addresses): Handle section bases.
7128
7129 * NEWS: Mention new qXfer:libraries:read section offsets support.
7130
7131 2008-03-14 Vladimir Prus <vladimir@codesourcery.com>
7132
7133 * defs.h (do_exec_error_cleanups, discard_exec_error_cleanups)
7134 (make_exec_error_cleanup): Remove declarations.
7135 * utils.c (exec_error_cleanup_chain): Remove.
7136 (do_exec_error_cleanups, discard_exec_error_cleanups)
7137 (make_exec_error_cleanup): Remove.
7138 * event-loop.c (start_event_loop): Adjust call to
7139 async_enable_stdin.
7140 * event-top.c (async_enable_stdin): Remove the paramater dummy.
7141 (async_disable_stdin): Don't register async_enable_stdin via
7142 cleanup.
7143 * inf-loop.c (inferior_event_handler): Don't
7144 call do_exec_error_cleanups. Call async_enable_stdin instead.
7145 * event-loop.c (start_event_loop): Adjust call to
7146 async_enable_stdin.
7147 * tui/tui-interp.c (tui_command_loop): Adjust call to
7148 async_enable_stdin.
7149
7150 2008-03-14 Vladimir Prus <vladimir@codesourcery.com>
7151
7152 Async mode fixes.
7153 * Makefile.in (infcmd.o, inf-loop.o): Update dependencies.
7154 * breakpoint.c (bpstat_do_actions): In async mode,
7155 don't jump to top expecting stop_bpstat to be already
7156 updated.
7157 * event-loop.c (start_event_loop): Call async_enable_stdin
7158 on exception.
7159 * event-top.c (async_enable_stdin): Do nothing if sync_execution
7160 is not set.
7161 (command_handler): Do not setup continuation here.
7162 (command_line_handler_continuation): Move to...
7163 * top.c (command_line_handler_continuation): ... here.
7164 (execute_command): In async mode, register continuation.
7165 Don't check frame's language in running in async mode.
7166 * exceptions.c (throw_exception): Don't do exec_error_cleanups.
7167 * inf-loop.c (complete_execution): Inline into...
7168 (inferior_event_handler): ... here. Clear target_executing before
7169 doing any cleanups. Don't try to show prompt if the target was
7170 resumed.
7171 * infcmd.c (signal_command): Add support for async mode.
7172 (finish_command): Only add continuation if the target was
7173 successfully resumed.
7174 * remote.c (init_async_opts): Register to_get_thread_local_address
7175 handler.
7176 * mi/mi-interp.c (mi_cmd_interpreter_exec): Don't mess
7177 with sync_execution.
7178 * tui/tui-interp.c (tui_command_loop): Call async_enable_stdin
7179 on exception.
7180
7181 2008-03-14 Daniel Jacobowitz <dan@codesourcery.com>
7182
7183 * corefile.c (reopen_exec_file): Use exec_bfd_mtime.
7184 * exec.c (exec_bfd_mtime): Define.
7185 (exec_close): Clear it.
7186 (exec_file_attach): Set it.
7187 * gdbcore.h (exec_bfd_mtime): Declare.
7188 * source.c (find_source_lines): Do not use bfd_get_mtime.
7189
7190 2008-03-14 Vladimir Prus <vladimir@codesourcery.com>
7191
7192 * top.c (simplified_command_loop): Remove.
7193
7194 2008-03-14 Vladimir Prus <vladimir@codesourcery.com>
7195
7196 Remove unused remote.c hooks.
7197 * remote.c (deprecated_target_resume_hook)
7198 (deprecated_target_wait_loop_hook): Remove.
7199 (remote_resume): Do not call deprecated_target_resume_hook.
7200 (remote_wait): Do not call deprecated_target_wait_loop_hook.
7201 (remote_async_wait): Likewise.
7202
7203 2008-03-14 Vladimir Prus <vladimir@codesourcery.com>
7204
7205 Implement MI notification for new threads.
7206 * doc/observer.texi (new_thread): Document.
7207 * observer.sh: Forward declare struct thread_info.
7208 * thread.c (add_thread): Notify observer.
7209
7210 * interps.h (interp_init_ftype): New parameter
7211 top_level.
7212 (interp_set): Likewise.
7213 (top_level_interpreter_data): Declare.
7214 * interps.c (interp_set): New parameter top_level.
7215 Pass it to interpreter's init function. Remember
7216 top level interpreter.
7217 (interpreter_exec_cmd): Adjust.
7218 (top_level_interpreter_data): New.
7219 * main.c (captured_main): Pass 1 for top_level
7220 parameter of interp_set.
7221 * cli/cli-interp.c (cli_interpreter_init): New
7222 parameter top_level.
7223 * tui/tui-interp.c (tui_init): New parameter top_level.
7224
7225 * mi/mi-interp.c (mi_new_thread): New.
7226 (mi_interpreter_init): If top level, register
7227 observer for new threads.
7228
7229 * Makefile.in (mi-interp.o, thread.o): Update dependencies.
7230
7231 2008-03-14 Pedro Alves <pedro@codesourcery.com>
7232
7233 * top.c (execute_command): Disable break and stop
7234 commands in async mode.
7235
7236 2008-03-14 Pedro Alves <pedro@codesourcery.com>
7237
7238 revert:
7239 2008-03-14 Pedro Alves <pedro@codesourcery.com>
7240 * inf-loop.c (inferior_event_handler): Don't include remote.h.
7241 Call target_stop in the INF_QUIT_REQ case.
7242 * Makefile.in (inf-loop.o): Update.
7243
7244 2008-03-14 Pedro Alves <pedro@codesourcery.com>
7245
7246 * inf-loop.c (inferior_event_handler): Don't include remote.h.
7247 Call target_stop in the INF_QUIT_REQ case.
7248 * Makefile.in (inf-loop.o): Update.
7249
7250 2008-03-14 Pedro Alves <pedro@codesourcery.com>
7251
7252 * top.c (execute_command): Enable break, info and interrupt
7253 commands in async mode.
7254
7255 2008-03-13 Vladimir Prus <vladimir@codesourcery.com>
7256 Daniel Jacobowitz <dan@codesourcery.com>
7257
7258 * breakpoint.h (breakpoint_restore_shadows): New
7259 declaration.
7260 * breakpoint.c (breakpoint_restore_shadows): New.
7261 (read_memory_nobpt): Delete.
7262 * gdbcore.h (read_memory_nobpt): Delete declaration.
7263 * target.c (memory_xfer_partial): Call
7264 breakpoint_restore_shadows.
7265 (restore_show_memory_breakpoints)
7266 (make_show_memory_beakpoints_cleanup): New.
7267 (show_memory_breakpoints): New.
7268 * target.h (make_show_memory_beakpoints_cleanup): Declare.
7269 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint):
7270 Make sure we see memory breakpoints when checking if
7271 breakpoint is still there.
7272 * alpha-tdep.c, alphanbsd-tdep.c, frame.c, frv-tdep.c,
7273 hppa-linux-tdep.c, hppa-tdep.c, i386-linux-nat.c, i386-tdep.c,
7274 m68klinux-tdep.c, mips-tdep.c, mn10300-tdep.c, s390-tdep.c,
7275 sparc-tdep.c: Use target_read_memory instead of read_memory_nobpt.
7276
7277 2008-03-12 Pedro Alves <pedro@codesourcery.com>
7278
7279 * thread.c (add_thread): Use printf_unfiltered to print.
7280
7281 2008-03-12 Joel Brobecker <brobecker@gnat.com>
7282
7283 * sol-thread.c: Replace use of TM_I386SOL2_H by an expression
7284 that is true only on x86-solaris and x86_64-solaris.
7285 * procfs.c: Likewise. Move procfs_find_LDT_entry up together
7286 with proc_get_LDT_entry.
7287
7288 2008-03-12 Thiago Jung Bauermann <bauerman@br.ibm.com>
7289
7290 * configure.ac (AC_CHECK_FUNCS): Add check for setsid.
7291 * config.in, configure: Regenerate.
7292 * fork-child.c (fork_inferior): Call create_tty_session.
7293 * inflow.c (new_tty): Set controlling terminal with TIOCSCTTY.
7294 (create_tty_session): New function.
7295 * terminal.h: Declare create_tty_session.
7296
7297 2008-03-12 Alan Modra <amodra@bigpond.net.au>
7298
7299 PR 5900
7300 * elfread.c (elf_symtab_read): Make shndx an unsigned int.
7301 * mipsread.c: Include elf/internal.h.
7302 (read_alphacoff_dynamic_symtab): Map external reserved sym_shndx
7303 to internal range.
7304
7305 2008-03-11 Markus Deuling <deuling@de.ibm.com>
7306
7307 * win32-nat.c (do_win32_fetch_inferior_registers): Use get_regcache_arch
7308 to get at the current architecture and at the target specific vector.
7309 Add target specific vector to I387_FISEG_REGNUM and I387_FOP_REGNUM and
7310 remove define of I387_ST0_REGNUM.
7311
7312 * amd64-tdep.c (I387_ST0_REGNUM): Remove define.
7313
7314 (amd64_supply_fxsave, amd64_collect_fxsave): Use get_regcache_arch to
7315 get at the current architecture
7316 (I387_FISEG_REGNUM, I387_FOSEG_REGNUM): Add target specific vector as
7317 parameter.
7318
7319 * i386-tdep.c: Remove various define's and undef's of I387_ST0_REGNUM,
7320 I387_NUM_XMM_REGS and I387_MM0_REGNUM.
7321
7322 (I387_NUM_XMM_REGS, I387_XMM0_REGNUM, I387_MXCSR_REGNUM,
7323 I387_ST0_REGNUM, I387_FCTRL_REGNUM, I387_MM0_REGNUM,
7324 (I387_FSTAT_REGNUM): Add target specific vector as parameter.
7325
7326 (i386_register_name, i386_dbx_reg_to_regnum): Use gdbarch_tdep to get
7327 at the target specific vector.
7328
7329 (i386_get_longjmp_target): Use get_frame_arch to get at the current
7330 architecture. Use gdbarch_tdep to get at the target specific vector.
7331
7332 (i386_fp_regnum_p, i386_fpc_regnum_p): Add gdbarch as parameter and
7333 update caller. Use gdbarch_tdep to get at the target specific vector.
7334
7335 (i386_register_to_value: Use get_frame_arch to get at the current
7336 architecture.
7337
7338 * i386-tdep.h (i386_fp_regnum_p, i386_fpc_regnum_p): Add gdbarch as
7339 parameter.
7340
7341 * i387-tdep.c (I387_FCTRL_REGNUM, I387_FSTAT_REGNUM, I387_FTAG_REGNUM,
7342 I387_FISEG_REGNUM, I387_FIOFF_REGNUM, I387_FOSEG_REGNUM
7343 I387_FOOFF_REGNUM, I387_FOP_REGNUM, I387_ST0_REGNUM, FSAVE_ADDR,
7344 FXSAVE_ADDR, I387_XMM0_REGNUM): Add target specific vector as parameter.
7345
7346 (I387_ST0_REGNUM, I387_NUM_XMM_REGS): Remove various define's and
7347 undef's.
7348
7349 (i387_convert_register_p, i387_register_to_value,
7350 i387_value_to_register): Update call for i386_fp_regnum_p.
7351
7352 * i387-tdep.h: Remove comment.
7353 (I387_ST0_REGNUM, I387_NUM_XMM_REGS, I387_MM0_REGNUM): Add define.
7354 (I387_FCTRL_REGNUM, I387_FSTAT_REGNUM, I387_FTAG_REGNUM,
7355 I387_FISEG_REGNUM, I387_FIOFF_REGNUM, I387_FOSEG_REGNUM,
7356 I387_FOOFF_REGNUM, I387_FOP_REGNUM, I387_XMM0_REGNUM,
7357 I387_MXCSR_REGNUM): Add target specific vector as parameter.
7358
7359 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
7360
7361 * Makefile.in (fork-child.o): Update.
7362 * NEWS: Document "set exec-wrapper" and the gdbserver --wrapper
7363 argument. Gather all gdbserver features together.
7364 * fork-child.c (exec_wrapper): New variable.
7365 (fork_inferior): Use it.
7366 (startup_inferior): Skip an extra trap if using "set exec-wrapper".
7367 (unset_exec_wrapper_command, _initialize_fork_child): New.
7368
7369 2008-03-10 Hidetaka Takano <hidetaka.takano@glb.toshiba.co.jp>
7370
7371 * source.c (directory_command): Modify the determination of
7372 condition of terminal "from_tty".
7373
7374 2008-03-10 Matt Rice <ratmice@gmail.com>
7375
7376 * dwarf2read.c (set_cu_language): Add DW_LANG_ObjC.
7377
7378 2008-03-10 Hidetaka Takano <hidetaka.takano@glb.toshiba.co.jp>
7379
7380 * spu-tdep.c (info_spu_event_command): Insert a '\0' to the end
7381 of the data passing to strtoulst function.
7382 (info_spu_signal_command): Likewise.
7383
7384 2008-03-08 Vladimir Prus <vladimir@codesourcery.com>
7385
7386 * mi/mi-interp.c (mi_command_loop): Remove
7387 commented-out code.
7388
7389 2008-03-07 Joel Brobecker <brobecker@adacore.com>
7390
7391 * remote.c (extended_remote_attach_1): Make local variable pid an int
7392 instead of a pid_t.
7393
7394 2008-03-07 Joel Brobecker <brobecker@adacore.com>
7395
7396 * solib-svr4.c (svr4_same_1): New function, originally extracted
7397 from svr4_same and expanded to handle the sparc64 case.
7398 (svr4_same): Move up and reimplement using svr4_same_1.
7399 (enable_break): Use svr4_same_1 to do shared library name comparisons.
7400
7401 2008-03-07 Ramana Radhakrishnan <ramana.r@gmail.com>
7402
7403 * MAINTAINERS: Move self to Paper trail.
7404
7405 2008-03-05 Daniel Jacobowitz <dan@codesourcery.com>
7406
7407 * Makefile.in (mingw-hdep.o, posix-hdep.o, remote-fileio.o): Update.
7408 * event-loop.c (call_async_signal_handler): New.
7409 * event-loop.h (call_async_signal_handler)
7410 (gdb_call_async_signal_handler): Declare.
7411 (mark_async_signal_handler): Add comments.
7412 * event-top.c (handle_sigint): Use gdb_call_async_signal_handler.
7413 * mingw-hdep.c (sigint_event, sigint_handler): New.
7414 (gdb_select): Use them. Wait for the readline signal handler
7415 to finish.
7416 (gdb_call_async_signal_handler, _initialize_mingw_hdep): New functions.
7417 * posix-hdep.c (gdb_call_async_signal_handler): New function.
7418 * remote-fileio.c (sigint_fileio_token, async_remote_fileio_interrupt):
7419 New.
7420 (remote_fileio_ctrl_c_signal_handler): Use
7421 gdb_call_async_signal_handler.
7422 (initialize_remote_fileio): Initialize sigint_fileio_token.
7423 * remote.c (initialize_sigint_signal_handler, handle_remote_sigint): Do
7424 not initialize tokens here.
7425 (handle_remote_sigint_twice): Likewise. Reinstall
7426 handle_remote_sigint.
7427 (async_remote_interrupt_twice): Just call interrupt_query.
7428 (cleanup_sigint_signal_handler): Do not delete tokens.
7429 (remote_interrupt, remote_interrupt_twice): Use
7430 gdb_call_async_signal_handler.
7431 (interrupt_query): Reinstall the default signal handler.
7432 (_initialize_remote): Initialize tokens here.
7433
7434 2008-03-04 Joel Brobecker <brobecker@adacore.com>
7435
7436 * features/rs6000/power-core.xml, features/rs6000/power64-core.xml,
7437 features/rs6000/powerpc-601.xml, features/rs6000/rs6000.xml:
7438 Change the type of the lr register to code_ptr.
7439 * features/rs6000/powerpc-32.c, features/rs6000/powerpc-403.c,
7440 features/rs6000/powerpc-403gc.c, features/rs6000/powerpc-505.c,
7441 features/rs6000/powerpc-601.c, features/rs6000/powerpc-602.c,
7442 features/rs6000/powerpc-603.c, features/rs6000/powerpc-604.c,
7443 features/rs6000/powerpc-64.c, features/rs6000/powerpc-7400.c,
7444 features/rs6000/powerpc-750.c, features/rs6000/powerpc-860.c,
7445 features/rs6000/powerpc-e500.c, features/rs6000/rs6000.c: Regenerate.
7446
7447 2008-03-03 James E. Wilson <wilson@tuliptree.org>
7448
7449 * MAINTAINERS: Update my email address.
7450
7451 2008-03-03 Keith Seitz <keiths@redhat.com>
7452
7453 From Dave Murphy <davem@devkitpro.org>:
7454 * configure.ac: Set tcl configdir to win under mingw.
7455 * configure: Regenerate.
7456
7457 2008-03-03 Daniel Jacobowitz <dan@codesourcery.com>
7458
7459 * breakpoint.c (fetch_watchpoint_value): New function.
7460 (update_watchpoint): Set and clear val_valid. Use
7461 fetch_watchpoint_value. Handle unreadable values on the
7462 value chain. Correct check for user-requested array watchpoints.
7463 (breakpoint_init_inferior): Clear val_valid.
7464 (watchpoint_value_print): New function.
7465 (print_it_typical): Use it. Do not free or clear old_val. Print
7466 watchpoints even if old_val == NULL.
7467 (watchpoint_check): Use fetch_watchpoint_value. Check for values
7468 becoming readable or unreadable.
7469 (watch_command_1): Use fetch_watchpoint_value. Set val_valid.
7470 (do_enable_watchpoint): Likewise.
7471 * breakpoint.h (struct breakpoint): Update comment for val. Add
7472 val_valid.
7473 * NEWS: Mention watchpoints on inaccessible memory.
7474
7475 2007-02-29 Daniel Jacobowitz <dan@codesourcery.com>
7476
7477 * Makefile.in (i386-nat.o): Update.
7478 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Call
7479 i386_use_watchpoints.
7480 * i386-linux-nat.c (_initialize_i386_linux_nat): Call
7481 i386_use_watchpoints.
7482 * i386-nat.c (i386_stopped_data_address): Take two arguments.
7483 (i386_stopped_by_watchpoint): Update call.
7484 (i386_can_use_hw_breakpoint, i386_use_watchpoints): New.
7485 * config/i386/nm-i386.h: Conditionalize definitions on
7486 ! I386_WATCHPOINTS_IN_TARGET_VECTOR.
7487 (i386_use_watchpoints): Declare.
7488 (i386_stopped_data_address): Update.
7489 * config/i386/nm-linux.h (I386_WATCHPOINTS_IN_TARGET_VECTOR): Define.
7490 * config/i386/nm-linux64.h (I386_WATCHPOINTS_IN_TARGET_VECTOR): Define.
7491
7492 2008-02-29 Joel Brobecker <brobecker@adacore.com>
7493
7494 GDB 6.8 branch created (branch timestamp: 2008-02-26 10:00 UTC)
7495 * version.in: Bump version to 6.8.50.20080229-cvs.
7496
7497 2008-02-28 Markus Deuling <deuling@de.ibm.com>
7498
7499 * f-typeprint.c (f_print_type): Handle NULL pointer in VARSTRING
7500 properly.
7501
7502 2008-02-28 Tom Tromey <tromey@redhat.com>
7503
7504 * infcmd.c (notice_args_read): Print result of get_inferior_args.
7505
7506 2008-02-28 Daniel Jacobowitz <dan@codesourcery.com>
7507
7508 * infcmd.c (kill_if_already_running): Make static. Use
7509 target_require_runnable.
7510 * target.c (target_require_runnable): New.
7511 * target.h (target_require_runnable): Declare.
7512
7513 2008-02-28 Daniel Jacobowitz <dan@codesourcery.com>
7514
7515 * frame.c (reinit_frame_cache): Only annotate if frames were
7516 previously valid.
7517
7518 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
7519
7520 * regformats/reg-ppc.dat: Rename "ps" to "msr".
7521 * regformats/reg-ppc64.dat: Likewise.
7522
7523 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
7524
7525 * features/Makefile (%.dat): Emit xmltarget statement.
7526
7527 * regformats/regdat.sh: Support xmltarget and xmlarch statments.
7528 Generate code to set gdbserver_xmltarget in init_registers_${name}.
7529
7530 * regformats/arm-with-iwmmxt.dat: Regenerate.
7531 * regformats/mips64-linux.dat: Regenerate.
7532 * regformats/mips-linux.dat: Regenerate.
7533 * regformats/rs6000/powerpc-32.dat: Regenerate.
7534 * regformats/rs6000/powerpc-64.dat: Regenerate.
7535 * regformats/rs6000/powerpc-e500.dat: Regenerate.
7536
7537 * regformats/reg-arm.dat: Add xmlarch statement.
7538 * regformats/reg-i386.dat: Likewise.
7539 * regformats/reg-i386-linux.dat: Likewise.
7540 * regformats/reg-x86-64-linux.dat: Likewise.
7541 * regformats/reg-spu.dat: Likewise.
7542
7543 2008-02-27 Daniel Jacobowitz <dan@codesourcery.com>
7544
7545 * remote.c (remote_wait, remote_async_wait): Stop if we receive
7546 an error.
7547
7548 2008-02-27 Daniel Jacobowitz <dan@codesourcery.com>
7549
7550 * utils.c (debug_timestamp): New.
7551 (vfprintf_unfiltered): Print timestamps if requested.
7552 (show_debug_timestamp): New.
7553 (initialize_utils): Register "set debug timestamp".
7554 * NEWS: Mention "set debug timestamp". Add GDB 6.8 section.
7555
7556 2008-02-27 Joel Brobecker <brobecker@adacore.com>
7557
7558 * breakpoint.c (skip_prologue_sal): New function.
7559 (resolve_sal_pc): Adjust SAL past prologue if the SAL was
7560 computed from a line number.
7561
7562 2008-02-27 Joel Brobecker <brobecker@adacore.com>
7563
7564 * features/rs6000/power-core.xml, features/rs6000/power64-core.xml
7565 features/rs6000/powerpc-601.xml, features/rs6000/rs6000.xml:
7566 Set PC register type to "code_ptr".
7567 * features/rs6000/powerpc-32.c, features/rs6000/powerpc-403.c,
7568 features/rs6000/powerpc-403gc.c, features/rs6000/powerpc-505.c,
7569 features/rs6000/powerpc-601.c, features/rs6000/powerpc-602.c,
7570 features/rs6000/powerpc-603.c, features/rs6000/powerpc-604.c,
7571 features/rs6000/powerpc-64.c, features/rs6000/powerpc-7400.c,
7572 features/rs6000/powerpc-750.c, features/rs6000/powerpc-860.c,
7573 features/rs6000/powerpc-e500.c, features/rs6000/rs6000.c:
7574 Regenerate.
7575
7576 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
7577
7578 * regformats/regdat.sh: Rename init_registers function in
7579 generated file to init_registers_${name}.
7580
7581 * regformats/reg-crisv32.dat: Set "name" to crisv32.
7582 * regformats/reg-ppc64.dat: Set "name" to ppc64.
7583 * regformats/reg-s390x.dat: Set "name" to s390x.
7584
7585 2008-02-26 Greg Law <glaw@undo-software.com>
7586
7587 * regcache.c (registers_changed): Call reinit_frame_cache.
7588
7589 2008-02-26 Daniel Jacobowitz <dan@codesourcery.com>
7590
7591 * configure.tgt (sh-*-linux*): Match sh*. Add glibc-tdep.o.
7592 * sh-linux-tdep.c (sh_linux_init_abi): Use glibc_skip_solib_resolver
7593 and svr4_fetch_objfile_link_map.
7594 * Makefile.in (sh-linux-tdep.o): Update.
7595
7596 2008-02-26 Thiago Jung Bauermann <bauerman@br.ibm.com>
7597
7598 * amd64-tdep.c (amd64_classify): Add support for decimal float
7599 types.
7600 * i386-tdep.c (i386_return_value): Make 128-bit decimal float
7601 use the struct return convention.
7602
7603 2008-02-26 Nick Roberts <nickrob@snap.net.nz>
7604
7605 * breakpoint.c (print_one_breakpoint_location): Revert Enb field
7606 to old format. Discard breakpoint address if shared library is
7607 unloaded.
7608 (breakpoint_1): Adjust formatting of table header accordingly.
7609
7610 2008-02-25 Vladimir Prus <vladimir@codesourcery.com>
7611
7612 * remote.c (remote_get_threadlist): If the response
7613 is empty, don't try to parse it.
7614
7615 2008-02-23 Vladimir Prus <vladimir@codesourcery.com>
7616
7617 Unbreak 'target async'.
7618 * serial.c (serial_async): Set the
7619 handler function before enabling async
7620 mode.
7621
7622 2008-02-22 Daniel Jacobowitz <dan@codesourcery.com>
7623
7624 * solib-svr4.c (enable_break): Convert r_brk to a code address.
7625
7626 2008-02-21 Pedro Alves <pedro@codesourcery.com>
7627
7628 * remote.c (extended_remote_attach_1): Set attach_flag.
7629 (extended_remote_create_inferior_1): Clear attach_flag.
7630
7631 2008-02-20 Daniel Jacobowitz <dan@codesourcery.com>
7632
7633 * mipsnbsd-tdep.c (mipsnbsd_ilp32_fetch_link_map_offsets): Set
7634 r_brk_offset.
7635 (mipsnbsd_lp64_fetch_link_map_offsets): Likewise.
7636 * solib-svr4.c (solib_svr4_r_brk): New.
7637 (open_symbol_file_object, svr4_current_sos): Always check the
7638 debug base.
7639 (svr4_fetch_objfile_link_map): Do not set debug_base.
7640 (enable_break): Use r_brk if it is set.
7641 (svr4_ilp32_fetch_link_map_offsets): Set r_brk_offset.
7642 (svr4_lp64_fetch_link_map_offsets): Likewise.
7643 * solib-svr4.h (struct link_map_offsets): Add r_brk_offset.
7644
7645 2008-02-20 Markus Deuling <deuling@de.ibm.com>
7646 Mark Kettenis <kettenis@gnu.org>
7647
7648 * alpha-tdep.c (alpha_heuristic_unwind_cache): Replace saved_regs by
7649 trad_frame_saved_reg.
7650 (trad-frame.h): New include.
7651
7652 (alpha_heuristic_frame_unwind_cache): Use trad_frame_alloc_saved_regs
7653 instead of frame_obstack_zalloc.
7654 (alpha_heuristic_frame_prev_register): Use trad_frame_get_prev_register.
7655
7656 * Makefile.in (alpha-tdep.o): Add dependency to trad_frame_h.
7657
7658 2008-02-20 Markus Deuling <deuling@de.ibm.com>
7659
7660 * rs6000-tdep.c (gdb_print_insn_powerpc): Get the current endianess
7661 from disassemble_info instead of gdbarch_byte_order.
7662
7663 * mips-tdep.c (gdb_print_insn_mips): Likewise.
7664 * arm-tdep.c (gdb_print_insn_arm): Likewise.
7665
7666 2008-02-20 Markus Deuling <deuling@de.ibm.com>
7667
7668 * gdbarch.sh (memory_insert_breakpoint, memory_remove_breakpoint): Add
7669 gdbarch as parameter.
7670
7671 * gdbarch.{c,h}: Regenerate.
7672
7673 * ppc-tdep.h (ppc_linux_memory_remove_breakpoint): Add gdbarch as
7674 parameter.
7675 * mem-break.c (default_memory_insert_breakpoint)
7676 (default_memory_remove_breakpoint): Likewise.
7677 * target.h (default_memory_remove_breakpoint)
7678 (default_memory_insert_breakpoint): Likewise.
7679
7680 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Add gdbarch as
7681 parameter. Replace current_gdbarch by gdbarch.
7682 * m32r-tdep.c (m32r_memory_insert_breakpoint)
7683 (m32r_memory_remove_breakpoint): Likewise.
7684
7685 2008-02-19 Daniel Jacobowitz <dan@codesourcery.com>
7686
7687 * MAINTAINERS: Add Vladimir Prus as MI maintainer.
7688
7689 2008-02-19 Joel Brobecker <brobecker@adacore.com>
7690
7691 * NEWS: Add entry describing Add support improvements.
7692
7693 2008-02-18 Markus Deuling <deuling@de.ibm.com>
7694
7695 * m68klinux-nat.c (getfpregs_supplies): Replace gdbarch_fp0_regnum by
7696 M68K_FP0_REGNUM.
7697
7698 2008-02-18 Markus Deuling <deuling@de.ibm.com>
7699
7700 * sentinel-frame.c (sentinel_frame_prev_register): Do not call
7701 register_offset_hack anymore.
7702
7703 * regcache.{c,h} (register_offset_hack): Remove.
7704
7705 2008-02-18 Markus Deuling <deuling@de.ibm.com>
7706
7707 * hppa-tdep.h (find_global_pointer): Add gdbarch as parameter.
7708
7709 * hppa-hpux-tdep.c (hppa32_hpux_find_global_pointer): Likewise. Replace
7710 current_gdbarch by gdbarch.
7711 (hppa64_hpux_find_global_pointer): Likewise.
7712 * hppa-tdep.c (hppa_find_global_pointer): Likewise.
7713 (hppa32_push_dummy_call, hppa64_push_dummy_call): Update call for
7714 find_global_pointer.
7715
7716 * hppabsd-tdep.c (hppabsd_find_global_pointer): Add gdbarch as
7717 parameter.
7718 * hppa-linux-tdep.c (hppa_linux_find_global_pointer): Likewise.
7719
7720 * hppa-linux-nat.c (hppa_linux_register_addr): Use ARRAY_SIZE instead
7721 of gdbarch_num_regs.
7722
7723 * hppa-hpux-tdep.c (hppa_hpux_sr_for_addr): Add gdbarch as parameter and
7724 replace current_gdbarch by gdbarch.
7725 (hppa_hpux_push_dummy_code): Update call for hppa_hpux_sr_for_addr.
7726
7727 2008-02-18 Markus Deuling <deuling@de.ibm.com>
7728
7729 * rs6000-nat.c (exec_one_dummy_insn, regmap): Add gdbarch as parameter
7730 and replace current_gdbarch by gdbarch.
7731
7732 (store_register): Update call for exec_one_dummy_insn.
7733 (fetch_register, store_register): Update call of regmap.
7734
7735 * ppcnbsd-nat.c (getregs_supplies, getfpregs_supplies): Add gdbarch as
7736 parameter and replace current_gdbarch by gdbarch.
7737
7738 (ppcnbsd_store_inferior_registers): Use get_regcache_arch to get at
7739 the current architecture. Update call for getregs_supplies and
7740 getfpregs_supplies.
7741 (ppcnbsd_fetch_inferior_registers): Likewise.
7742
7743 * ppcobsd-nat.c (getfpregs_supplies): Add gdbarch as parameter and
7744 replace current_gdbarch by gdbarch.
7745 (ppcobsd_fetch_registers, ppcobsd_store_registers): Use
7746 get_regcache_arch to get at the current architecture. Update call for
7747 getfpregs_supplies.
7748
7749 2008-02-18 Markus Deuling <deuling@de.ibm.com>
7750
7751 * arch-utils.c (gdbarch_from_bfd): Remove unnecessary {old,new}_gdbarch
7752 variables.
7753
7754 2008-02-15 Markus Deuling <deuling@de.ibm.com>
7755
7756 * mips-linux-tdep.c (mips_linux_init_abi): Remove internal error.
7757
7758 2008-02-14 Vladimir Prus <vladimir@codesourcery.com>
7759
7760 * NEWS: Mention pending breakpints in MI.
7761
7762 2008-02-14 Markus Deuling <deuling@de.ibm.com>
7763
7764 * Makefile.in (ALL_TARGET_OBS): Remove dependency to xtensa-linux-nat.o.
7765
7766 2008-02-13 Markus Deuling <deuling@de.ibm.com>
7767
7768 Add script to build and test GDB using enable-targets=all.
7769
7770 * gdb_buildall.sh: New file.
7771
7772 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
7773
7774 * NEWS (New native configurations): Xtensa GNU/Linux.
7775 (New targets): Xtensa GNU/Linux.
7776 * Makefile.in (ALL_TARGET_OBS): Add xtensa-linux-nat.o and
7777 xtensa-linux-tdep.o
7778 (ALLDEPFILES): Add xtensa-linux-tdep.c and xtensa-linux-nat.c
7779 (xtensa-linux-nat.o, xtensa-linux-tdep.o): New dependencies.
7780 * configure.tgt (xtensa*-*-linux*): New entry.
7781 * xtensa-config.c (xtensa_tdep): New variable.
7782 (xtensa_config_byte_order, xtensa_config_tdep): Removed.
7783 (rmap): Change format based on new macro XTREG.
7784 (XTENSA_CONFIG_INSTANTIATE): Use new macro defined in xtensa-tdep.h.
7785 * xtensa-linux-nat.c: New.
7786 * xtensa-linux-tdep.c: New.
7787 * xtensa-xtregs.c: New.
7788 * xtensa-tdep.h (xtensa_elf_gregset_t): Update.
7789 (XTENSA_ELF_NGREG, XTREG, XTREG_END, XTENSA_GDBARCH_TDEP_INSTANTIATE)
7790 (XCHAL_NUM_CONTEXTS, XCHAL_HAVE_EXCEPTIONS): New macros.
7791 (xtensa_register_t): New field coprocessor.
7792 (XTENSA_REGISTER_FLAGS_PRIVILEGED): Name spelling corrected.
7793 * xtensa-tdep.c (xtensa_config_tdep, xtensa_config_byte_order): Removed.
7794 (xtensa_pseudo_register_read, xtensa_pseudo_register_write):
7795 Update to handle privileged registers.
7796 (xtensa_supply_gregset) Remove exccause and excvaddr registers.
7797 (xtensa_push_dummy_call): Set windowstart register correctly.
7798 (call0_analyze_prologue): Initialize xtensa_default_isa.
7799 (xtensa_derive_tdep): New.
7800 (xtensa_gdbarch_init): Get rid of xtensa_config_byte_order and
7801 xtensa_config_tdep, use XCHAL_HAVE_BE and xtensa_tdep instead.
7802 Call xtensa_derive_tdep().
7803 * config/xtensa/linux.mh: New.
7804 * regformats/reg-xtensa.dat: New.
7805
7806 2008-02-09 Aleksandar Ristovski <aristovski@qnx.com> (tiny change)
7807
7808 * corelow.c (core_open): Use IS_ABSOLUTE_PATH.
7809 (filenames.h): New include.
7810 * Makefile.in (corelow.o): Add dependency for filenames.h.
7811
7812 2008-02-08 Doug Evans <dje@google.com>
7813
7814 * source.c (find_and_open_source): Always rewrite absolute filenames.
7815
7816 2008-02-07 Doug Evans <dje@google.com>
7817
7818 * breakpoint.c: #include "hashtab.h".
7819 (ambiguous_names_p): New fn.
7820 (update_breakpoint_locations): When restoring bp enable status, don't
7821 compare function names if any functions have same name.
7822 * Makefile.in (breakpoint.o): Add hashtab.h dependency.
7823
7824 2008-02-07 Joel Brobecker <brobecker@adacore.com>
7825
7826 * ada-lang.c (symbol_completion_add): Make SV parameter a VEC**
7827 instead of just a VEC*. Update use of SV.
7828 (ada_make_symbol_completion_list): Update symbol_completion_add calls.
7829
7830 2007-02-07 Joel Brobecker <brobecker@adacore.com>
7831
7832 * NEWS: Put all new commands since gdb-6.7 together.
7833
7834 2007-02-07 Joel Brobecker <brobecker@adacore.com>
7835
7836 * ada-lang.c: #include "vec.h".
7837 (struct string_vector, new_string_vector, string_vector_append):
7838 Delete.
7839 (char_ptr): New typedef.
7840 (DEF_VEC_P (char_ptr)): New VEC type.
7841 (symbol_completion_add): Update profile to take the new VEC type
7842 instead of the old string_vector structure. Update code accordingly.
7843 (ada_make_symbol_completion_list): Use the new VEC type instead of
7844 the old string_vector structure, and update the code accordingly.
7845 * Makefile.in (ada-lang.o): Add dependency on vec.h.
7846
7847 2008-02-06 Pierre Muller <muller@ics.u-strasbg.fr>
7848
7849 * p-exp.y: Set current_type in missing places.
7850 (leftdiv_is_integer): New static variable.
7851 Typecast right operand of BINOP_DIV to long_double if both operands
7852 are integers.
7853
7854 2008-02-06 Maciej W. Rozycki <macro@mips.com>
7855
7856 * remote-mips.c (set_breakpoint): Rename to...
7857 (mips_set_breakpoint): ... this.
7858 (clear_breakpoint): Rename to...
7859 (mips_clear_breakpoint): ... this.
7860 (common_breakpoint): Rename to...
7861 (mips_common_breakpoint): ... this.
7862 (check_lsi_error): Rename to...
7863 (mips_check_lsi_error): ... this.
7864
7865 2007-02-05 Joel Brobecker <brobecker@adacore.com>
7866
7867 * language.h (struct language_defn): Add new field
7868 la_make_symbol_completion_list.
7869 * symtab.c (default_make_symbol_completion_list): Renames
7870 make_symbol_completion_list.
7871 (make_symbol_completion_list): New function.
7872 * symtab.h (default_make_symbol_completion_list): Add declaration.
7873 * langauge.c (unknown_language): Set la_make_symbol_completion_list.
7874 (auto_language, local_language): Likewise.
7875 * objc-lang.c (objc_language_defn): Likewise.
7876 * scm-lang.c (scm_language_defn): Likewise.
7877 * m2-lang.c (m2_language_defn): Likewise.
7878 * f-lang.c (f_language_defn): Likewise.
7879 * jv-lang.c (java_language_defn): Likewise.
7880 * p-lang.c (pascal_language_defn): Likewise.
7881 * c-lang.c (c_language_defn, cplus_language_defn, asm_language_defn)
7882 (minimal_language_defn): Likewise.
7883 * ada-lang.c (struct string_vector): New structure.
7884 (new_string_vector, string_vector_append, ada_unqualified_name)
7885 (add_angle_brackets, symbol_completion_match, symbol_completion_add)
7886 (ada_make_symbol_completion_list): New functions.
7887 (ada_language_defn): Set la_make_symbol_completion_list.
7888 * ada-lang.h (ada_make_symbol_completion_list): Remove declaration,
7889 this function is static.
7890
7891 2008-02-05 Kevin Buettner <kevinb@redhat.com>
7892
7893 * mn10300-tdep.c (mn10300_push_dummy_call): Adjust stack pointer
7894 to account for call site optimizations.
7895
7896 2008-02-05 Andrzej Zaborowski <balrogg@gmail.com>
7897
7898 * tracepoint.c (read_actions): Handle end-of-text indicator
7899 in action list properly. (Committed by Jim Blandy)
7900
7901 2008-02-05 Jim Blandy <jimb@red-bean.com>
7902
7903 * ax-gdb.c (gen_expr): Yield ordinary error if asked to trace a
7904 pseudoregister, not an internal error.
7905 Reported by: Andrzej Zaborowski
7906
7907 2008-02-04 Vladimir Prus <vladimir@codesourcery.com>
7908
7909 * varobj.c (c_value_of_variable): Use xstrdup.
7910
7911 2008-02-04 Vladimir Prus <vladimir@codesourcery.com>
7912
7913 Update stored rendition of varobj value when format changes.
7914 * varobj.c (varobj_set_display_format): Recomputed
7915 print_value.
7916 (c_value_of_variable): Return print_value.
7917
7918 2008-02-03 Doug Evans <dje@google.com>
7919
7920 * eval.c (evaluate_subexp_standard): Fix type of result of mixed
7921 integer/float division operations when EVAL_AVOID_SIDE_EFFECTS.
7922 * valops.c (value_one): New function.
7923 * value.h (value_one): Declare.
7924
7925 Fix argument promotion for binary arithmetic ops for C.
7926 * valarith.c (unop_result_type): New fn.
7927 (binop_result_type): New fn.
7928 (value_binop): Move result type computation to binop_result_type.
7929 (value_pos, value_neg, value_complement): Move result type
7930 computation to unop_result_type.
7931
7932 PR 2384
7933 * gdbtypes.c (get_vptr_fieldno): Renamed from fill_in_vptr_fieldno.
7934 Return basetype, fieldno if found. All callers updated.
7935 Don't cache TYPE_VPTR_FIELDNO, TYPE_VPTR_BASETYPE if from different
7936 objfile.
7937 * gdbtypes.h (get_vptr_fieldno): Renamed from fill_in_vptr_fieldno.
7938 * symfile.h (fill_in_vptr_fieldno): Delete.
7939
7940 2008-02-02 Doug Evans <dje@google.com>
7941
7942 * valarith.c (value_binop): Handle unsigned BINOP_REM division by zero.
7943
7944 * typeprint.c (*): Whitespace cleanup.
7945
7946 2008-02-02 Mark Kettenis <kettenis@gnu.org>
7947 Luis Machado <luisgpm@br.ibm.com>
7948 Thiago Jung Bauermann <bauerman@br.ibm.com>
7949
7950 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Pass floats that
7951 don't fit into registerson the stack the way GCC does.
7952
7953 2008-02-01 Joel Brobecker <brobecker@adacore.com>
7954
7955 * symtab.c (symbol_set_names): Do not add an entry in the demangling
7956 hash table for Ada symbols. Just store the linkage name as is,
7957 and leave the demangled_name as NULL.
7958
7959 2007-02-01 Joel Brobecker <brobecker@adacore.com>
7960
7961 * dwarf2read.c (add_partial_symbol): Always store all Ada subprograms
7962 in the global scope.
7963 (new_symbol): Likewise.
7964
7965 2008-02-01 Vladimir Prus <vladimir@codesourcery.com>
7966
7967 * breakpoint.c (break_command_1): Return void.
7968 (break_command_really): Return void. Rethrow
7969 exceptions instead of returning.
7970 (gdb_breakpoint): Remove the error_message parameter.
7971 Return void. Rename to set_breakpoint.
7972 * gdb.h (gdb_breakpoint): Rename and move to...
7973 * breakpoint.h (set_breakpoint): ...here.
7974 * mi/mi-cmb-break.c (mi_cmd_break_insert): Restore
7975 event hooks even if exception is thrown. Adjust to
7976 gdb_breakpoint interface changes.
7977
7978
7979 2008-02-01 Thiago Jung Bauermann <bauerman@br.ibm.com>
7980
7981 * ppc-sysv-tdep.c (ppc64_sysv_abi_push_dummy_call): Write 32-bit
7982 float in both first and second word in the doubleword, to support
7983 old and new ABIs.
7984
7985 2008-02-01 Vladimir Prus <vladimir@codesourcery.com>
7986
7987 Properly rethrow exception. This fixes errors
7988 about non-existent functions for -break-insert.
7989 * breakpoint.c (break_command_really): Use throw_exception
7990 for rethrowing. If rethrowing, don't print the exception.
7991
7992 2008-01-31 Thiago Jung Bauermann <bauerman@br.ibm.com>
7993
7994 * NEWS: Mention Decimal Floating Point support.
7995
7996 2008-01-31 Joel Brobecker <brobecker@adacore.com>
7997
7998 * std-regs.c (value_of_builtin_frame_pc_reg): Change the returned
7999 value type to builtin_type_void_func_ptr.
8000
8001 2008-01-31 Andreas Krebbel <krebbel1@de.ibm.com>
8002
8003 * s390-tdep.c (is_float_singleton, is_float_like,
8004 alignment_of, s390_return_value): Make checks for
8005 TYPE_CODE_FLT to match TYPE_CODE_DECFLOAT as well.
8006
8007 2008-01-31 Luis Machado <luisgpm@br.ibm.com>
8008 Thiago Jung Bauermann <bauerman@br.ibm.com>
8009
8010 * infcmd.c (default_print_registers_info): Also print hex
8011 raw contents for TYPE_CODE_DECFLOAT registers.
8012 * ppc-tdep.h (gdbarch_tdep): Add ppc_dl0_regnum member.
8013 * rs6000-tdep.c (IS_DFP_PSEUDOREG): New macro.
8014 (rs6000_register_name): Add support for DFP pseudo-registers.
8015 (rs6000_pseudo_register_type): Likewise.
8016 rs6000_pseudo_register_reggroup_p): Likewise.
8017 (ppc_pseudo_register_read): New function.
8018 (ppc_pseudo_register_write): Likewise.
8019 (rs6000_pseudo_register_read): Likewise.
8020 (rs6000_pseudo_register_write): Likewise.
8021 (e500_pseudo_register_read): Move checks to
8022 rs6000_pseudo_register_read.
8023 (e500_pseudo_register_write): Move checks to
8024 rs6000_pseudo_register_write.
8025 (rs6000_gdbarch_init): Initialize tdep->ppc_dl0_regnum. Install
8026 rs6000_pseudo_register_read and rs6000_pseudo_register_write
8027 in gdbarch if SPE or DFP is available. Adjust gdbarch's
8028 num_pseudo_regs to account for DFP pseudo regs.
8029
8030 2008-01-31 Thiago Jung Bauermann <bauerman@br.ibm.com>
8031
8032 * ppc-tdep.h (struct gdbarch_tdep): Remove ppc_ev31_regnum member.
8033 * rs6000-tdep.c (IS_SPE_PSEUDOREG): New macro.
8034 (spe_register_p, rs6000_register_name, rs6000_pseudo_register_type,
8035 rs6000_pseudo_register_reggroup_p, e500_move_ev_register,
8036 e500_pseudo_register_read, e500_pseudo_register_write): Use
8037 IS_SPE_PSEUDOREG macro.
8038 (rs6000_frame_cache): Remove use of tdep->ppc_ev31_regnum.
8039 (rs6000_gdbarch_init): Remove unnecessary num_sprs local variable.
8040 Remove initialization of tdep->ppc_ev31_regnum.
8041
8042 2008-01-08 Paul Hilfinger <hilfinger@adacore.com>
8043
8044 * printcmd.c (print_formatted): Handle references as for unformatted
8045 prints.
8046
8047 2008-01-30 Joel Brobecker <brobecker@adacore.com>
8048
8049 * eval.c (evaluate_subexp_standard): Add handling of user
8050 registers when in EVAL_AVOID_SIDE_EFFECTS mode.
8051
8052 2008-01-30 Pierre Muller <muller@ics.u-strasbg.fr>
8053
8054 * eval.c (evaluate_subexp_standard): Support
8055 BINOP_INTDIV opcode.
8056
8057 2008-01-30 Paul N. Hilfinger <hilfinger@adacore.com>
8058
8059 * valarith.c (value_binop): Add floating-point BINOP_MIN and
8060 BINOP_MAX cases.
8061 For BINOP_EXP, use length and signedness of left operand only for
8062 result, as for shifts.
8063 For integral operands to BINOP_EXP, use new integer_pow and
8064 uinteger_pow functions so as to get full range of results.
8065 (integer_pow): New function.
8066 (uinteger_pow): New function.
8067
8068 2008-01-30 Vladimir Prus <vladimir@codesourcery.com>
8069
8070 Use vector for varobj_list_children interface.
8071 * gdb/varobj.c (varobj_list_children): Return vector
8072 of varobjs.
8073 * gdb/varobj.h (varobj_list_children): Adjust
8074 prototype.
8075 (varobj_p): Declare. Declare vector thereof.
8076 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust
8077 for varobj_list_children change.
8078 * Makefile.in (varobj_h): Update dependencies.
8079
8080 2008-01-30 Thiago Jung Bauermann <bauerman@br.ibm.com>
8081
8082 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Add support for
8083 TYPE_CODE_DECFLOAT arguments.
8084 (ppc64_sysv_abi_push_dummy_call) Likewise.
8085 (get_decimal_float_return_value): New function.
8086 (do_ppc_sysv_return_value): Add support for TYPE_CODE_DECFLOAT return
8087 values by calling get_decimal_float_return_value.
8088 (ppc64_sysv_abi_return_value): Likewise.
8089
8090 2008-01-30 Nick Roberts <nickrob@snap.net.nz>
8091
8092 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file): Add field
8093 for preprocessor macro information. Formatting changes.
8094
8095 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
8096
8097 * remote.c (struct remote_state): Add cached_wait_status.
8098 (remote_exec_file): New variable.
8099 (PACKET_vAttach, PACKET_vRun): New constants.
8100 (extended_remote_restart): Do not query for status.
8101 (struct start_remote_args): New.
8102 (remote_start_remote): Take it as a second argument. Check
8103 whether the target is running. Issue an error for non-running
8104 non-extended targets. Cache the wait status. Set inferior_ptid
8105 here.
8106 (remote_open_1): Prompt to disconnect non-running targets. Make
8107 sure the target is marked running. Do not set inferior_ptid here.
8108 Update call to remote_start_remote. Do not call remote_check_symbols
8109 if the target is not running.
8110 (remote_detach_1): Rename from remote_detach. Take an EXTENDED
8111 argument. Handle a non-running target.
8112 (remote_detach): Use it.
8113 (extended_remote_detach): New.
8114 (remote_disconnect): Fix typo. Use remoute_mourn_1.
8115 (extended_remote_attach_1, extended_remote_attach)
8116 (extended_async_remote_attach): New.
8117 (remote_vcont_resume): Remove unused variable.
8118 (remote_wait, remote_async_wait): Use any cached wait status.
8119 (putpkt_binary, getpkt): Clear any cached wait status.
8120 (extended_remoute_mourn_1): New.
8121 (extended_remote_mourn): Use it.
8122 (extended_async_remote_mourn, extended_remote_run): New.
8123 (extended_remote_create_inferior_1): New.
8124 (extended_remote_create_inferior): Use it.
8125 (extended_remote_async_create_inferior): Likewise.
8126 (remote_xfer_partial): Skip for non-executing targets.
8127 (init_extended_remote_ops): Set to_detach and to_attach.
8128 (init_extended_async_remote_ops): Likewise. Use
8129 extended_async_remote_mourn.
8130 (_initialize_remote): Register vAttach, vRun, and
8131 set remote exec-file.
8132 * NEWS: Mention vAttach, vRun, and gdbserver extended-remote support.
8133
8134 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
8135
8136 * Makefile.in (symfile.o): Update.
8137 * NEWS: Mention exec tracing support.
8138 * inf-ttrace.c (inf_ttrace_wait): Return TARGET_WAITKIND_EXECD for
8139 exec events.
8140 * infcmd.c (kill_if_already_running, detach_command)
8141 (disconnect_command): Replace SOLIB_RESTART with no_shared_libraries.
8142 * infrun.c (MAY_FOLLOW_EXEC, may_follow_exec): Delete.
8143 (follow_exec): Do not check may_follow_exec. Do not mourn and push
8144 targets. Apply the sysroot path to the loaded executable. Use
8145 no_shared_libraries.
8146 * linux-nat.c (linux_child_follow_fork): Print fork following
8147 messages if verbose.
8148 (kill_wait_callback): Kill again before waiting a second time.
8149 * symfile.c (symbol_file_clear): Replace SOLIB_RESTART with
8150 no_shared_libraries.
8151
8152 2008-01-29 Joel Brobecker <brobecker@adacore.com>
8153
8154 * amd64-tdep.c (amd64_classify): Add handling of TYPE_CODE_CHAR.
8155
8156 2008-01-29 Joel Brobecker <brobecker@adacore.com>
8157
8158 * nto-tdep.h: Remove #include "defs.h".
8159 * nto-tdep.c: Add #include "defs.h".
8160 * Makefile.in (nto_tdep_h): Update dependencies.
8161 (nto-tdep.o): Likewise.
8162
8163 2008-01-29 Joel Brobecker <brobecker@adacore.com>
8164
8165 * infrun.c (wait_for_inferior): Add treat_exec_as_sigtrap parameter
8166 and use it.
8167 (proceed, start_remote): Update call to wait_for_inferior.
8168 * inferior.h (wait_for_inferior): Update declaration.
8169 * fork-child.c, infcmd.c, solib-irix.c, solib-osf.c, solib-sunos.c,
8170 solib-svr4.c, win32-nat.c: Update calls to wait_for_inferior.
8171 * inf-ttrace.c (inf_ttrace_wait): Report TTEVT_EXEC events as
8172 TARGET_WAITKIND_EXECD instead of TARGET_WAITKIND_STOPPED.
8173
8174 2008-01-29 Aleksandar Ristovski <aristovski@qnx.com>
8175
8176 * varobj (adjust_value_for_child_access): Added checking for
8177 returned value from gdb_value_ind.
8178 (c_describe_child): Likewise.
8179 (cplus_describe_child): Fixed a typo.
8180
8181 2008-01-29 Jim Blandy <jimb@red-bean.com>
8182
8183 * MAINTAINERS: Update my info.
8184
8185 2008-01-29 Vladimir Prus <vladimir@codesourcery.com>
8186
8187 Use multiple locations for hardware watchpoints.
8188 This eliminates the need to traverse value chain, doing
8189 various checks, in three different places.
8190
8191 * breakpoint.h (struct bp_location): New fields
8192 lengths and watchpoint_type.
8193 (struct breakpoint): Remove the val_chain field.
8194 * breakpoint.c (is_hardware_watchpoint): New.
8195 (free_valchain): Remove.
8196 (update_watchpoint): New.
8197 (insert_bp_location): For hardware watchpoint, just
8198 directly insert it.
8199 (insert_breakpoints): Call update_watchpoint_locations
8200 on all watchpoints. If we have failed to insert
8201 any location of a hardware watchpoint, remove all inserted
8202 locations.
8203 (remove_breakpoint): For hardware watchpoints, directly
8204 remove location.
8205 (watchpoints_triggered): Iterate over locations.
8206 (bpstat_stop_status): Use only first location of
8207 a resource watchpoint.
8208 (delete_breakpoint): Don't call free_valchain.
8209 (print_one_breakpoint): Don't print all
8210 locations for watchpoints.
8211 (breakpoint_re_set_one): Use update_watchpoint for
8212 watchpoints.
8213
8214 2008-01-29 Vladimir Prus <vladimir@codesourcery.com>
8215
8216 Don't reset watchpoint block on solib load.
8217
8218 * breakpoint.c (insert_bp_location): For watchpoints,
8219 recompute condition.
8220 (breakpoint_re_set_one): Instead of recomputing value
8221 and condition for watchpoints, just reset value and
8222 let insert_breakpoints/insert_bp_location recompute it.
8223 Don't do anything about disabled watchpoint.
8224
8225 2008-01-29 Pierre Muller <muller@ics.u-strasbg.fr>
8226
8227 * valarith.c (value_binop): Handle unsigned integer
8228 division by zero.
8229
8230 2008-01-28 Kevin Buettner <kevinb@redhat.com>
8231
8232 * mn10300-tdep.c (mn10300_analyze_prologue): Check for an
8233 instruction pattern that appears frequently in position
8234 independent code. Fix bug in code which looks for "fmov" and
8235 backtracks if no "fmov" is found.
8236
8237 2008-01-28 Doug Evans <dje@google.com>
8238
8239 * dbxread.c (read_dbx_symtab): Fix indentation.
8240 Reformat comments to 80 columns.
8241 Move local var def closer to only use.
8242
8243 2008-01-28 Daniel Jacobowitz <dan@codesourcery.com>
8244
8245 * fork-child.c (SHELL_FILE): Remove #ifndef.
8246 (fork_inferior): Remove SHELL_COMMAND_CONCAT.
8247
8248 2008-01-25 Pierre Muller <muller@ics.u-strasbg.fr>
8249
8250 * i386-tdep.c (i386_skip_noop): New function.
8251 (i386_analyze_prologue): Call i386_skip_noop function.
8252
8253 2008-01-24 Michael Snyder <msnyder@specifix.com>
8254
8255 * procfs.c (procfs_xfer_partial): Comment, cut/paste error.
8256 * win32-nat.c (win32_xfer_partial): Ditto.
8257 * target.c (default_xfer_partial): Minor whitespace adjustment.
8258
8259 2008-01-24 Pedro Alves <pedro@codesourcery.com>
8260
8261 * arm-tdep.c (arm_addr_bits_remove): In non 26-bit mode, don't
8262 strip bit 1 even if pc doesn't point to thumb code.
8263
8264 2008-01-23 Daniel Jacobowitz <dan@codesourcery.com>
8265
8266 * remote.c (remote_wait): Handle SIGINT between packets.
8267 (remote_async_wait): Likewise.
8268
8269 2008-01-23 Vladimir Prus <vladimir@codesourcery.com>
8270 Chris Demetriou <cgd@google.com>
8271
8272 * thread.c (add_thread_silent): Renamed
8273 from add_thread.
8274 (print_thread_events): New variable definition.
8275 (show_print_thread_events): New function.
8276 (_initialize_thread): Add "set print thread-events" and
8277 "show print thread-events" commands.
8278 (add_thread): Announce new thread.
8279 * gdbthread.h (add_thread_silent): Declare.
8280 (print_thread_events): New variable declaration.
8281 * inf-ttrace.c (inf_ttrace_wait): Don't
8282 inform about new thread, as add_thread is always
8283 called too, and will take care of that.
8284 * infrun.c (handle_inferior_event): Likewise.
8285 * procfs.c (procfs_wait): Likewise.
8286 * remote.c (remote_currthread): Likewise.
8287 * sol-thread.c (sol_thread_wait): Likewise.
8288 * win32-nat.c (get_win32_debug_event): Likewise.
8289 * linux-thread-db.c (attach_thread): Likewise.
8290 Remove the verbose parameter.
8291 (check_event): Make detach_thread be verbose
8292 only if print_thread_events is set.
8293 * linux-nat.c (lin_lwp_attach_lwp): Don't inform
8294 about new thread. This is called only from
8295 linux-thread-db.c:attach_thread, which will take care.
8296 Remove the verbose parameter.
8297 * linux-nat.h (lin_lwp_attach_lwp): Adjust prototype.
8298
8299 2008-01-23 Nick Roberts <nickrob@snap.net.nz>
8300
8301 * mi/mi-cmd-var.c (mi_cmd_var_set_format): Add value field to output.
8302
8303 2008-01-22 Vladimir Prus <vladimir@codesourcery.com>
8304
8305 * breakpoint.c (break_command_really): New parameter
8306 ignore_count.
8307 (break_command_1): Pass 0 as
8308 ignore_count to break_command_really.
8309 (gdb_breakpoint): Pass ignore_count to
8310 break_command_really.
8311
8312 2008-01-21 Kevin Buettner <kevinb@redhat.com>
8313
8314 * mn10300-linux-tdep.c (am33_linux_sigframe_cache_init): Find
8315 sigcontext struct via pointer.
8316 (struct sigframe comment): Update to show new field `psc'.
8317
8318 2008-01-21 Vladimir Prus <vladimir@codesourcery.com>
8319
8320 * infrun.c (handle_inferior_event): If
8321 we failed to remove breakpoints, error,
8322 don't try to increment PC by hand.
8323
8324 2008-01-18 Nick Hudson <nick.hudson@dsl.pipex.com>
8325
8326 Add NetBSD/hppa target and host support.
8327
8328 * hppabsd-tdep.c (hppabsd_supply_gregset): Move to ...
8329 (hppabsd_gregset): Move to ...
8330 (hppabsd_regset_from_core_section): Rename
8331 hppaobsd_regset_from_core_section and move to ...
8332 (hppabsd_find_global_pointer): Update comment.
8333 (hppabsd_init_abi): Make global. Do not register
8334 hppabsd_regset_from_core_section.
8335 (hppabsd_core_osabi_sniffer): Rename hppaobsd_core_osabi_sniffer and
8336 move to ...
8337 (_initialize_hppabsd_tdep): Move to ...
8338 * hppaobsd-tdep.c: ... here. New file.
8339 * hppnbsd-tdep.c: New file.
8340 * hppnbsd-nat.c: New file.
8341 * Makefile.in (ALL_TARGET_OBS): Add hppanbsd-tdep.o and hppaobsd-tdep.o.
8342 (ALLDEPFILES): Add hppabsd-nat.c and hppabsd-tdep.c.
8343 (hppabsd-nat.o, hppabsd-tdep.o): New dependencies.
8344 (hppabsd-tdep.o, hppaobsd-tdep.o): Update dependencies.
8345 * configure.host (hppa*-*-netbsd*): New entry.
8346 * configure.tgt (hppa*-*-netbsd*): New entry.
8347 (hppa*-*-openbsd*): Update.
8348 * NEWS (New native configuration): Mention NetBSD/hppa.
8349 (New targets): Mention NetBSD/hppa.
8350
8351 2008-01-18 Markus Deuling <deuling@de.ibm.com>
8352
8353 * gdbarch.sh (function_list): Add new property bits_big_endian to
8354 gdbarch structure.
8355 * gdbarch.{c,h}: Regenerate.
8356
8357 * value.c (struct value): Replace BITS_BIG_ENDIAN by
8358 gdbarch_bits_big_endian (comment).
8359 (unpack_field_as_long, modify_field): Likewise.
8360 * value.h: Likewise (comment).
8361 * valops.c (value_slice): Likewise.
8362 * valarith.c (value_subscript, value_bit_index): Likewise.
8363 * gdbtypes.h (field): Likewise (comment).
8364 * eval.c (evaluate_subexp_standard): Likewise.
8365 * dwarf2read.c (dwarf2_add_field): Likewise.
8366 * ada-lang.c (decode_packed_array, ada_value_primitive_packed_val)
8367 (move_bits, ada_value_assign, value_assign_to_component): Likewise.
8368
8369 * defs.h (BITS_BIG_ENDIAN): Remove.
8370
8371 2008-01-18 Markus Deuling <deuling@de.ibm.com>
8372
8373 * jv-exp.y (yylex): Replace DEPRECATED_STREQN with the appropriate
8374 function calls.
8375 * m2-exp.y (yylex): Likewise.
8376 * objc-exp.y (yylex): Likewise.
8377
8378 * defs.h (DEPRECATED_STREQN): Remove.
8379
8380 2008-01-17 H.J. Lu <hjl.tools@gmail.com>
8381
8382 * MAINTAINERS: Update my email address.
8383
8384 2008-01-17 Jim Blandy <jimb@codesourcery.com>
8385
8386 * README: Mention gdbserver/README.
8387
8388 2008-01-17 Pierre Muller <muller@ics.u-strasbg.fr>
8389
8390 * valarith.c (value_binop): Handle BINOP_INTDIV
8391 for unsigned and signed integers.
8392
8393 2008-01-17 Ulrich Weigand <uweigand@de.ibm.com>
8394
8395 * s390-tdep.c (s390_gdbarch_init): Set default long double
8396 type to 128-bit IEEE quad.
8397
8398 2008-01-17 Joel Brobecker <brobecker@adacore.com>
8399
8400 * hpux-thread.c (hpux_thread_resume): Delete commented-out code.
8401
8402 2008-01-16 Mark Kettenis <kettenis@gnu.org>
8403
8404 * auxv.c (fprint_target_auxv): Add support for AT_SUN_AUXFLAGS.
8405
8406 * dfp.c, dfp.h: Rename decimal_to_double to decimal_to_doublest.
8407 * value.c: All callers changed.
8408
8409 2008-01-16 Markus Deuling <deuling@de.ibm.com>
8410
8411 * rs6000-nat.c (add_vmap, vmap_ldinfo, vmap_exec): Replace
8412 DEPRECATED_STREQ by its expression.
8413 * coffread.c (coff_locate_sections, coff_symtab_read): Likewise.
8414 * xcoffread.c (read_xcoff_symtab, read_symbol_lineno, find_linenos)
8415 (scan_xcoff_symtab): Likewise.
8416 * hppa-hpux-tdep.c (hppa_hpux_skip_trampoline_code): Likewise.
8417 * f-lang.c (find_common_for_function): Likewise.
8418 * objc-exp.y (parse_number): Likewise.
8419
8420 * defs.h (DEPRECATED_STREQ): Remove.
8421
8422 2008-01-16 Markus Deuling <deuling@de.ibm.com>
8423
8424 * mn10300-tdep.h (AM33_MODE): Add gdbarch as parameter.
8425 * mn10300-tdep.c (set_reg_offsets, mn10300_analyze_prologue): Use
8426 get_frame_arch to get at the current_architecture. Update AM33_MODE
8427 call.
8428 (mn10300_analyze_prologue): Add gdbarch as parameter. Update caller.
8429 (mn10300_frame_unwind_cache): Use get_frame_arch to get at the current
8430 architecture.
8431 (set_reg_offsets, mn10300_analyze_prologue): Fix indentation.
8432
8433 2008-01-16 Markus Deuling <deuling@de.ibm.com>
8434
8435 * amd64-nat.h (amd64_native_gregset_supplies_p): Add gdbarch as
8436 parameter.
8437 * amd64-nat.c (amd64_native_gregset_supplies_p): Likewise.
8438
8439 (amd64_native_gregset_reg_offset): Add gdbarch as parameter. Replace
8440 current_gdbarch by gdbarch. Update caller.
8441
8442 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers)
8443 (amd64_linux_store_inferior_registers): Use get_regcache_arch to get at
8444 the current architecture. Update calls of
8445 amd64_native_gregset_supplies_p.
8446 * amd64bsd-nat.c (amd64bsd_fetch_inferior_registers)
8447 (amd64bsd_store_inferior_registers): Likewise.
8448
8449 2008-01-16 Markus Deuling <deuling@de.ibm.com>
8450
8451 * ppc-linux-nat.c (ppc_register_u_addr): Add gdbarch as parameter.
8452 Replace current_gdbarch by gdbarch. Update caller.
8453
8454 2008-01-16 Markus Deuling <deuling@de.ibm.com>
8455
8456 * dbxread.c (repeated_header_complaint, dbx_symfile_init)
8457 (read_dbx_dynamic_symtab, function_outside_compilation_unit_complaint)
8458 (read_dbx_symtab, end_psymtab, dbx_psymtab_to_symtab_1)
8459 (dbx_psymtab_to_symtab, read_ofile_symtab, process_one_symbol)
8460 (stabsect_build_psymtabs): Fix indentation.
8461
8462 2008-01-15 Michael Snyder <msnyder@specifix.com>
8463
8464 * corelow.c (core_xfer_partial): Comment, cut/paste error.
8465
8466 2008-01-14 Pierre Muller <muller@ics.u-strasbg.fr>
8467
8468 * win32-nat.c (win32_create_inferior): Restore code calling
8469 CloseHandle on ProcessInformation structure.
8470
8471 2008-01-13 Nick Hudson <nick.hudson@dsl.pipex.com>
8472
8473 * configure.ac: Check for void * as 3 argument of ptrace.
8474 * configure: regenerate.
8475
8476 2008-01-11 Markus Deuling <deuling@de.ibm.com>
8477
8478 * alpha-tdep.c (alpha_heuristic_proc_start)
8479 (alpha_sigtramp_register_address): Add gdbarch as parameter. Replace
8480 current_gdbarch by gdbarch.
8481
8482 (alpha_heuristic_frame_unwind_cache): Use get_frame_arch to get at the
8483 current architecture by frame_info. Update alpha_heuristic_proc_start
8484 call.
8485
8486 (alpha_sigtramp_frame_this_id, alpha_sigtramp_frame_prev_register): Use
8487 get_frame_arch to get at the current architecture by frame_info. Update
8488 alpha_sigtramp_register_address call.
8489
8490 * arm-tdep.c (thumb_scan_prologue): Add gdbarch as parameter and replace
8491 current_gdbarch by gdbarch. Update caller.
8492 (convert_to_extended, convert_from_extended): Add endianess parameter
8493 for comparison. Update caller.
8494 (arm_extract_return_value, arm_store_return_value): Use
8495 get_regcache_arch to get at the current architecture.
8496
8497 * cris-tdep.c (cris_register_size): Add gdbarch as parameter. Replace
8498 current_gdbarch by gdbarch. Update caller.
8499 (cris_gdb_func, move_to_preg_op, none_reg_mode_move_from_preg_op): Add
8500 gdbarch as parameter. Update caller. Replace current_gdbarch by gdbarch.
8501
8502 * h8300-tdep.c (E_PSEUDO_CCR_REGNUM, E_PSEUDO_EXR_REGNUM, BINWORD): Add
8503 gdbarch as parameter. Update caller.
8504 (h8300_init_frame_cache): Add gdbarch as parameter. Replace
8505 current_gdbarch by gdbarch. Update caller.
8506
8507 * hppa-tdep.c (skip_prologue_hard_way): Add gdbarch as parameter and
8508 update caller. Replace current_gdbarch by gdbarch.
8509
8510 * m32c-tdep.c (m32c_skip_trampoline_code): Use get_frame_arch to get at
8511 the current architecture. Replace current_gdbarch by gdbarch.
8512 * m68hc11-tdep.c (m68hc11_frame_unwind_cache): Likewise.
8513 (STACK_CORRECTION, USE_PAGE_REGISTER): Replace M6811_TDEP by its
8514 expression. Add gdbarch as parameter and replace current_gdbarch with
8515 it. Update caller.
8516 (M6811_TDEP): Remove.
8517 (m68hc11_frame_prev_register): Use get_frame_arch to get at the current
8518 architecture.
8519 (m68hc11_scan_prologue): Add gdbarch as parameter. Replace
8520 current_gdbarch by gdbarch. Update caller.
8521
8522 * m68k-tdep.c (m68k_analyze_prologue): Add gdbarch as parameter and
8523 update caller.
8524 (m68k_analyze_register_saves): Likewise. Also replace current_gdbarch
8525 by gdbarch.
8526
8527 * rs6000-tdep.c (skip_prologue): Add gdbarch as parameter and update
8528 caller. Relace current_gdbarch by gdbarch.
8529 (altivec_register_p, spe_register_p): Likewise.
8530 * ppc-tdep.h (altivec_register_p, spe_register_p): Add gdbarch as
8531 parameter.
8532 * ppc-linux-nat.c (fetch_register, store_register): Update caller of
8533 altivec_register_p and spe_register_p.
8534
8535 * score-tdep.c (score_fetch_inst): Add gdbarch as parameter. Update
8536 caller. Replace current_gdbarch by gdbarch.
8537 (score_analyze_prologue): use get_frame_arch to get at the current
8538 architecture.
8539
8540 * sparc-tdep.h (sparc_analyze_prologue): Add gdbarch as parameter.
8541 * sparc-tdep.c (sparc_analyze_prologue): Likewise. Replace
8542 current_gdbarch by gdbarch. Update caller.
8543 (sparc_frame_cache): Use get_frame_arch to get at the current
8544 architecture.
8545 * sparce64-tdep.c (sparc64_skip_prologue): Update call of
8546 sparc_analyze_prologue.
8547
8548 * mn10300-tdep.c (mn10300_dwarf2_reg_to_regnum): Add gdbarch as
8549 parameter.
8550
8551 2008-01-11 Markus Deuling <deuling@de.ibm.com>
8552
8553 * exec.c: #include "arch-utils.h"
8554 (print_section_info): Use gdbarch_from_bfd to get at the
8555 current architecture. Replace current_gdbarch. Fix indention. Replace
8556 deprecated_print_address_numeric by paddress.
8557 * Makefile.in (exec.o) Add dependency to arch-utils.h.
8558
8559 * valprint.c (val_print_string): Replace
8560 deprecated_print_address_numeric.
8561 * tracepoint.c (trace_mention, scope_info): Likewise.
8562 * symmisc.c (dump_msymbols, dump_psymtab, dump_symtab_1, print_symbol)
8563 (print_symbol, print_partial_symbols, maintenance_info_psymtabs)
8564 (maintenance_check_symtabs): Likewise.
8565 * symfile.c (list_overlays_command): Likewise.
8566 * stack.c (frame_info, print_block_frame_labels): Likewise.
8567 * printcmd.c (print_address, print_address_demangle)
8568 (address_info): Likewise.
8569 * corefile.c (memory_error): Likewise.
8570 * infcmd.c (jump_command): Likewise.
8571 * breakpoint.c (insert_bp_location, describe_other_breakpoints)
8572 (mention, delete_breakpoint): Likewise.
8573 * c-valprint.c (print_function_pointer_address, c_val_print): Likewise.
8574 * dwarf2read.c (dump_die): Likewise.
8575 * ada-valprint.c (ada_val_print_1): Likewise.
8576 * f-valprint.c (f_val_print): Likewise.
8577 * linux-fork.c (info_forks_command): Likewise.
8578 * m32r-com.c (m32r_load_section, m32r_load)
8579 (m32r_upload_command): Likewise.
8580
8581 * ui-out.c (ui_out_field_core_addr): Remove unnecessary comment.
8582
8583 2008-01-11 Markus Deuling <deuling@de.ibm.com>
8584
8585 * gdbarch.sh (skip_prologue): Add gdbarch
8586 as parameter.
8587 * gdbarch.{c,h}: Regenerate.
8588
8589 * alpha-tdep.c (alpha_skip_prologue): Add gdbarch as parameter.
8590 * amd64-tdep.c (amd64_skip_prologue): Likewise.
8591 * avr-tdep.c (avr_skip_prologue): Likewise.
8592 * cris-tdep.c (cris_skip_prologue): Likewise.
8593 * frv-tdep.c (frv_skip_prologue): Likewise.
8594 * h8300-tdep.c (h8300_skip_prologue): Likewise.
8595 * hppa-tdep.c (hppa_skip_prologue): Likewise.
8596 * i386-tdep.c (i386_skip_prologue): Likewise.
8597 * ia64-tdep.c (ia64_skip_prologue): Likewise.
8598 * iq2000-tdep.c (iq2000_skip_prologue): Likewise.
8599 * m32r-tdep.c (m32r_skip_prologue): Likewise.
8600 * m68hc11-tdep.c (m68hc11_skip_prologue): Likewise.
8601 * m68k-tdep.c (m68k_skip_prologue): Likewise.
8602 * m88k-tdep.c (m88k_skip_prologue): Likewise.
8603 * mep-tdep.c (mep_skip_prologue): Likewise.
8604 * mips-tdep.c (mips_skip_prologue): Likewise.
8605 * mn10300-tdep.c (mn10300_skip_prologue): Likewise.
8606 * mt-tdep.c (mt_skip_prologue): Likewise.
8607 * rs6000-tdep.c (rs6000_skip_prologue): Likewise.
8608 * score-tdep.c (score_skip_prologue): Likewise.
8609 * sh64-tdep.c (sh64_skip_prologue): Likewise.
8610 * sh-tdep.c (sh_skip_prologue): Likewise.
8611 * sparc64-tdep.c (sparc64_skip_prologue): Likewise.
8612 * sparc-tdep.c (sparc32_skip_prologue): Likewise.
8613 * spu-tdep.c (spu_skip_prologue): Likewise.
8614 * v850-tdep.c (v850_skip_prologue): Likewise.
8615 * vax-tdep.c (vax_skip_prologue): Likewise.
8616 * xstormy16-tdep.c (xstormy16_skip_prologue): Likewise.
8617 * xtensa-tdep.c (xtensa_skip_prologue): Likewise.
8618
8619 * arm-tdep.c (arm_skip_prologue): Add gdbarch as parameter. Replace
8620 current_gdbarch by gdbarch.
8621 * m32c-tdep.c (m32c_skip_prologue): Likewise.
8622 * s390-tdep.c (s390_skip_prologue): Likewise.
8623
8624 2008-01-10 Doug Evans <dje@google.com>
8625
8626 * defs.h (struct continuation_arg): Fix typo in comment.
8627 * target.c (target_translate_tls_address): Fix comment spelling error.
8628
8629 2008-01-09 Thiago Jung Bauermann <bauerman@br.ibm.com>
8630
8631 * doublest.h (DOUBLEST_PRINT_FORMAT): Remove % from string.
8632 (DOUBLEST_SCAN_FORMAT): Likewise.
8633 * dfp.c (decimal_from_floating): Use DOUBLEST_PRINT_FORMAT.
8634 * ada-lex.l (processReal): Prepend "%" to use of DOUBLEST_SCAN_FORMAT.
8635 * c-exp.y (parse_number): Likewise.
8636 * jv-exp.y (parse_number): Likewise.
8637 * objc-exp.y (parse_number): Likewise.
8638 * p-exp.y (parse_number): Likewise.
8639
8640 2008-01-09 Joel Brobecker <brobecker@adacore.com>
8641
8642 * gdbtypes.c (create_array_type): Add handling of null Ada arrays.
8643 (check_typedef): Likewise.
8644
8645 2008-01-09 Luis Machado <luisgpm@br.ibm.com>
8646
8647 * printcmd.c (printf_command): Add seen_big_h, seen_big_d and
8648 seen_double_big_d, treat the new H, D, and DD modifiers as length
8649 modifiers.
8650
8651 2008-01-08 Joel Brobecker <brobecker@adacore.com>
8652
8653 * dwarf2read.c (read_enumeration_type): Add comment.
8654
8655 2008-01-08 Thiago Jung Bauermann <bauerman@br.ibm.com>
8656
8657 * config.in: Regenerate.
8658
8659 2008-01-08 Joel Brobecker <brobecker@adacore.com>
8660
8661 * ada-lang.c (ada_convert_actual): Renames convert_actual.
8662 Make non-static.
8663 (ada_convert_actuals): Delete.
8664 * ada-lang.h (ada_convert_actual): Add declaration.
8665 (ada_convert_actuals): Remove declaration.
8666 * infcall.c: #include "ada-lang.h".
8667 (value_arg_coerce): Add new parameter sp. Update function
8668 documetnation. Add handling of Ada function call parameters.
8669 * Makefile.in (infcall.o): Update dependencies.
8670
8671 2008-01-08 Paul Hilfinger <hilfinger@adacore.com>
8672
8673 * ada-lang.c (ensure_lval): Fix value lval kind.
8674 (convert_actual): Add handling for arguments passed by reference.
8675
8676 2008-01-08 Doug Evans <dje@google.com>
8677
8678 * dbxread.c (read_dbx_symtab): Fix indentation.
8679
8680 2008-01-07 Thiago Jung Bauermann <bauerman@br.ibm.com>
8681
8682 * Makefile.in (dfp.o): Depend on expression.h, gdbtypes.h and value.h.
8683 (valarith.o): Depend on dfp.h.
8684 (valops.o): Likewise.
8685 * dfp.c: Include expression.h, gdbtypes.h, value.h and dfp.h.
8686 (set_decnumber_context): New function.
8687 (decimal_check_errors): Likewise.
8688 (decimal_from_number): Likewise.
8689 (decimal_to_number): Likewise.
8690 (decimal_from_string): Use set_decnumber_context and
8691 decimal_check_errors.
8692 (decimal_from_integral): New function.
8693 (decimal_from_floating): Likewise.
8694 (decimal_to_double): Likewise.
8695 (promote_decimal): Likewise.
8696 (decimal_binop): Likewise.
8697 (decimal_is_zero): Likewise.
8698 (decimal_compare): Likewise.
8699 (decimal_convert): Likewise.
8700 * dfp.h (decimal_from_integral): New prototype.
8701 (decimal_from_floating): Likewise.
8702 (decimal_to_double): Likewise.
8703 (decimal_binop): Likewise.
8704 (decimal_is_zero): Likewise.
8705 (decimal_compare): Likewise.
8706 (decimal_convert): Likewise.
8707 * eval.c (evaluate_subexp_standard): Remove expect_type argument from
8708 call to value_from_decfloat.
8709 * valarith.c: Include dfp.h.
8710 (value_args_as_decimal): New function.
8711 (value_binop): Add if block to handle TYPE_CODE_DECFLOAT values.
8712 (value_logical_not): Likewise.
8713 (value_equal): Likewise.
8714 (value_less): Likewise.
8715 (value_pos): Likewise.
8716 (value_neg): Formatting fix.
8717 * valops.c: Include dfp.h.
8718 (value_cast): Add if block to handle TYPE_CODE_DECFLOAT values.
8719 * value.c (unpack_long): Add case to handle TYPE_CODE_DECFLOAT.
8720 (unpack_double): Add if block to handle TYPE_CODE_DECFLOAT.
8721 (value_from_decfloat): Remove expect_type argument.
8722 * value.h (value_from_decfloat): Update prototype.
8723
8724 2008-01-07 Vladimir Prus <vladimir@codesourcery.com>
8725
8726 Ignore change in name of dynamic linker during
8727 execution on Solaris. This also unbreaks pending breakpoints.
8728
8729 * solist.h (struct target_so_ops): New field same.
8730 * solib-svr4.c (svr4_same): New.
8731 (_initialize_svr4_solib): Register svr4_same.
8732 * solib.c (update_solib_list): Use ops->same, if available.
8733
8734 2008-01-06 Christopher Faylor <me+cygwin@cgf.cx>
8735
8736 * win32-nat.c (win32_make_so): Use cygwin-style path to avoid warnings
8737 when using MS-DOS paths.
8738
8739 2008-01-05 Pedro Alves <pedro@codesourcery.com>
8740
8741 * NEWS: Mention --pid and --core command line behaviour changes.
8742
8743 2008-01-05 Pedro Alves <pedro@codesourcery.com>
8744
8745 * main.c (captured_main): Remove 'count' varible and the
8746 ALIGN_STACK_ON_ENTRY block that used it. Error out if --core and
8747 --pid options were issued simultaneously. If an explicit pid
8748 option was passed, don't fallback to core file. Detect extra
8749 arguments better in the presence of explicit pid or core
8750 arguments.
8751
8752 2008-01-05 Joel Brobecker <brobecker@adacore.com>
8753
8754 * ada-lang.c (ada_which_variant_applies): Correctly compute
8755 the value of the discriminant when the variant record is packed.
8756
8757 2008-01-04 Joel Brobecker <brobecker@adacore.com>
8758
8759 * ada-lang.c (is_name_suffix): Handle middle-name numeric suffixes
8760 that are used to differentiate homonyms.
8761
8762 2008-01-04 Jerome Guitton <guitton@adacore.com>
8763
8764 * ada-lang.c (decode_packed_array_type): Avoid a seg fault
8765 when the type is an anonymous pointer type.
8766 (ada_check_typedef): Avoid a seg fault when the type is null.
8767 * ada-typeprint.c (print_array_type): Add support for pointer
8768 to packed arrays.
8769
8770 2008-01-04 Paul N. Hilfinger <hilfinger@adacore.com>
8771
8772 * ada-exp.y: Allow '{type} ADDRESS' notation on left of assignment.
8773
8774 2008-01-04 Joel Brobecker <brobecker@adacore.com>
8775
8776 * ada-lang.c (ada_evaluate_subexp): Evaluate tagged types in
8777 EVAL_NORMAL mode when noside is EVAL_AVOID_SIDE_EFFECTS.
8778
8779 2008-01-04 Joel Brobecker <brobecker@adacore.com>
8780
8781 * ada-exp.y (chop_separator): New function.
8782 (write_selectors): Rewrite to re-use chop_separator.
8783 (ada_nget_field_index, get_symbol_field_type): New functions.
8784 (write_var_or_type): Add support for "ptype TYPENAME.FIELD"
8785 expressions.
8786
8787 2008-01-03 Thiago Jung Bauermann <bauerman@br.ibm.com>
8788
8789 * symtab.c (find_pc_sect_line): Use SYMBOL_VALUE_ADDRESS instead
8790 of SYMBOL_VALUE when working with function symbols.
8791
8792 2008-01-03 Joel Brobecker <brobecker@adacore.com>
8793
8794 * ada-lang.c (resolve_subexp): Add handling of OP_REGISTER
8795 expressions. These expressions do not need to be rewriten.
8796
8797 2008-01-03 Joel Brobecker <brobecker@adacore.com>
8798
8799 * dwarf2read.c (read_enumeration_type): Flag type as stub if
8800 the given die is a declaration.
8801
8802 2008-01-03 Joel Brobecker <brobecker@adacore.com>
8803
8804 * ada-lang.c (ada_array_bound_from_type): Make non-static.
8805 Handle properly the case when the index type is an enumerated type.
8806 Do not return the subtype of the bounds type, just return the
8807 bounds type directly - this is not needed and is more consistent
8808 with what we do for arrays when no XA parallel type exists.
8809
8810 2008-01-03 Joel Brobecker <brobecker@adacore.com>
8811
8812 * ada-lang.c (static_unwrap_type): Add forward declaration.
8813 (template_to_static_fixed_type): Fields of dynamic types sometimes
8814 also need to be unwrapped. Take this into account.
8815 (ada_to_fixed_type_1): Renamed from ada_to_fixed_type.
8816 (ada_to_fixed_type): New wrapper around ada_to_fixed_type_1.
8817 * ada-typeprint.c (ada_print_type): Get the typename from
8818 the original type, not the base type.
8819
8820 2008-01-03 Jerome Guitton <guitton@adacore.com>
8821
8822 * ada-lang.c (ada_value_struct_elt, to_fixed_array_type)
8823 (to_fixed_array_type, ada_to_fixed_value_create, unwrap_value):
8824 Update calls to ada_to_fixed_type.
8825 (ada_template_to_fixed_record_type_1): Ditto, but without looking
8826 for the tag.
8827 (ada_to_fixed_type): Add check_tag parameter; do not look for
8828 tag if null. When looking for a tag, use a fixed record type.
8829 * ada-lang.h (ada_to_fixed_type): Add check_tag parameter.
8830 * ada-valprint.c (printable_val_type, ada_value_print): Update
8831 calls to ada_to_fixed_type.
8832
8833 2008-01-03 Luis Machado <luisgpm@br.ibm.com>
8834
8835 * doublest.c (convert_floatformat_to_doublest): Call
8836 floatformat_to_doublest instead of floatformat_to_double and use
8837 DOUBLEST variables.
8838 (convert_doublest_to_floatformat): Call floatformat_from_doublest
8839 instead of floatformat_from_double and use DOUBLEST variables.
8840
8841 2008-01-03 Nick Hudson <nick.hudson@dsl.pipex.com>
8842
8843 * MAINTAINERS (Write After Approval): Add self.
8844
8845 2008-01-03 Joel Brobecker <brobecker@adacore.com>
8846
8847 * symfile.c (set_initial_language): Make non-static.
8848 * symfile.h (set_initial_language): Add declaration.
8849 * language.c: #include "symfile.h".
8850 (set_language): Call set_initial_language if the frame language
8851 could not be determined.
8852
8853 2008-01-03 Paul N. Hilfinger <hilfinger@adacore.com>
8854
8855 * eval.c (evaluate_subexp_for_address): Provide frame address to
8856 locate_var_value only if it will be needed.
8857
8858 2008-01-02 Jan Kratochvil <jan.kratochvil@redhat.com>
8859
8860 * linux-nat.c (linux_child_follow_fork): Call also CHECK_FOR_THREAD_DB.
8861
8862 2008-01-02 Joel Brobecker <brobecker@adacore.com>
8863
8864 * ada-lang.c (ada_evaluate_subexp): Modify the value returned
8865 when noside is EVAL_AVOID_SIDE_EFFECTS to be an lval_memory.
8866 This is needed to make sure that any other treatment applied
8867 to the resulting value does not fail for spurious reason,
8868 such as trying to take the address of this value.
8869
8870 2008-01-02 Joel Brobecker <brobecker@adacore.com>
8871
8872 * ada-lang.c (ada_value_equal): Dereference reference types when
8873 comparing arrays.
8874
8875 2008-01-01 Daniel Jacobowitz <dan@codesourcery.com>
8876
8877 Updated copyright notices for most files.
8878
8879 2008-01-01 Christopher Faylor <me+gdb@cgf.cx>
8880
8881 * win32-nat.c (psapi_module_handle): Remove static.
8882 (get_module_name): Rename from psapi_get_dll_name. Revamp slightly to
8883 return first module found if base_address is zero. Don't initialize
8884 psapi function pointers here. Convert to cygwin paths when
8885 appropriate.
8886 (win32_pid_to_exec_file): Use Cygwin's /proc interface to determine
8887 executable name. Use get_module_name when that fails or when
8888 !__CYGWIN__.
8889 (_initialize_psapi): New function. Initialize psapi stuff before it is
8890 needed or issue a warning if it is not found. Move psapi_module_handle
8891 here.
8892
8893 2008-01-01 Joel Brobecker <brobecker@adacore.com>
8894
8895 * ada-lang.c (ada_remove_trailing_digits): New function.
8896 (ada_remove_po_subprogram_suffix): New function.
8897 (ada_decode): Improve. Move the description of the algorithm
8898 directly inside the code, instead of in the function global
8899 description.
8900
8901 2008-01-01 Joel Brobecker <brobecker@adacore.com>
8902
8903 * ada-valprint.c (ada_val_print_1) [TYPE_CODE_REF]: Ignore deref_ref
8904 and always print the dereferenced value.
8905
8906 2008-01-01 Joel Brobecker <brobecker@adacore.com>
8907
8908 * ada-lang.c (ada_evaluate_subexp, case BINOP_SUB): Add handling
8909 of the case where the first argument is a reference.
8910 (ada_evaluate_subexp, case BINOP_ADD): Likewise.
8911
8912 2008-01-01 Joel Brobecker <brobecker@adacore.com>
8913
8914 Implement support for Ada interface types.
8915
8916 * ada-lang.c (ada_is_dispatch_table_ptr_type): New function.
8917 (ada_is_ignored_field): Ignore fields that are a dispatch table
8918 of a tagged type.
8919
8920 2008-01-01 Joel Brobecker <brobecker@adacore.com>
8921
8922 * top.c (print_gdb_version): Update copyright year.
8923
8924 2008-01-01 Joel Brobecker <brobecker@adacore.com>
8925
8926 * ChangeLog-2007: New ChangeLog rotation.
8927 * ChangeLog: Reset for 2008.
8928 * config/djgpp/fnchange.lst: Add entries for ChangeLog-2006 and
8929 ChangeLog-2007.
8930
8931 For older changes see ChangeLog-2007.
8932 \f
8933 Local Variables:
8934 mode: change-log
8935 left-margin: 8
8936 fill-column: 74
8937 version-control: never
8938 coding: utf-8
8939 End:
This page took 0.227035 seconds and 5 git commands to generate.