From ba4ad400f1e4f726adb431aedea3c0ddf1e3315a Mon Sep 17 00:00:00 2001 From: David Malcolm Date: Wed, 13 May 2015 13:58:18 +0000 Subject: libcpp/input.c: Add a way to visualize the linemaps (-fdump-internal-locations) gcc/ChangeLog: * common.opt (fdump-internal-locations): New option. * input.c: Include diagnostic-core.h. (get_end_location): New function. (write_digit): New function. (write_digit_row): New function. (dump_location_range): New function. (dump_labelled_location_range): New function. (dump_location_info): New function. * input.h (dump_location_info): New prototype. * toplev.c (compile_file): Handle flag_dump_locations. libcpp/ChangeLog: * include/line-map.h (source_location): Add a reference to location-example.txt to the descriptive comment. * location-example.txt: New file. From-SVN: r223163 --- gcc/common.opt | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'gcc/common.opt') diff --git a/gcc/common.opt b/gcc/common.opt index 6753fd3..859488f 100644 --- a/gcc/common.opt +++ b/gcc/common.opt @@ -1166,6 +1166,10 @@ Common Driver Var(flag_report_bug) Collect and dump debug information into temporary file if ICE in C/C++ compiler occured. +fdump-internal-locations +Common Var(flag_dump_locations) Init(0) +Dump detailed information on GCC's internal representation of source code locations + fdump-passes Common Var(flag_dump_passes) Init(0) Dump optimization passes -- cgit v1.1