Akihiko Odaki <akihiko.od...@daynix.com> writes:
> This is a tree-wide change to replace gdb_core_xml_file, the path to > GDB XML file with gdb_core_feature, the pointer to GDBFeature. This > also replaces the values assigned to gdb_num_core_regs with the > num_regs member of GDBFeature where applicable to remove magic numbers. > > A following change will utilize additional information provided by > GDBFeature to simplify XML file lookup. re: other comment about assert(). Maybe gdb_find_static_feature() needs to assert success because: Thread 1 "qemu-loongarch6" received signal SIGSEGV, Segmentation fault. loongarch_cpu_class_init (c=<optimized out>, data=<optimized out>) at ../../target/loongarch/cpu.c:726 726 cc->gdb_num_core_regs = cc->gdb_core_feature->num_regs; (gdb) p/x cc->gdb_core_feature $1 = 0x0 (gdb) l 721 cc->disas_set_info = loongarch_cpu_disas_set_info; 722 cc->gdb_read_register = loongarch_cpu_gdb_read_register; 723 cc->gdb_write_register = loongarch_cpu_gdb_write_register; 724 cc->disas_set_info = loongarch_cpu_disas_set_info; 725 cc->gdb_core_feature = gdb_find_static_feature("loongarch-base64.xml"); 726 cc->gdb_num_core_regs = cc->gdb_core_feature->num_regs; 727 cc->gdb_stop_before_watchpoint = true; 728 cc->gdb_arch_name = loongarch_gdb_arch_name; 729 730 #ifdef CONFIG_TCG -- Alex Bennée Virtualisation Tech Lead @ Linaro