Message ID | 1458838099-12053-1-git-send-email-cardoe@cardoe.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Thu, Mar 24, 2016 at 11:48:18AM -0500, Doug Goldstein wrote: > There are a number of debugging options for Xen so the idea is to have a > menu to group them all together. > > Signed-off-by: Doug Goldstein <cardoe@cardoe.com> > --- > This is more of an RFC than a merge request. If this seems reasonable I'll > add all the other debugging options under this menu as well. Obviously if > this seems reasonable and the patch is fine we can merge it and I'll submit > the others as a follow up. There would be more I presume - the lock profile, gcov, crash, etc.. And with the 'randconfig' that means we can turn on/off various options and find interesting dependencies (if any). Anyhow back to this patch. The usual method for distros of compiling an Xen with and without debug (like Xenserver) is: make %{?_smp_mflags} max_phys_cpus=384 xen tools make %{?_smp_mflags} -C xen clean make %{?_smp_mflags} -C xen debug=y max_phys_cpus=384 It would be preferrable to still have this functionality. As in, if we do 'debug=y' then verbose=y and frame_pointer=y are automatically enabled? Is that something the Kconfig magic can still do? > > > CC: Ian Jackson <ian.jackson@eu.citrix.com> > CC: Jan Beulich <jbeulich@suse.com> > CC: Keir Fraser <keir@xen.org> > CC: Tim Deegan <tim@xen.org> > --- > xen/Kconfig | 2 ++ > xen/Kconfig.debug | 6 ++++++ > 2 files changed, 8 insertions(+) > create mode 100644 xen/Kconfig.debug > > diff --git a/xen/Kconfig b/xen/Kconfig > index fa8b27c..0fe7a1a 100644 > --- a/xen/Kconfig > +++ b/xen/Kconfig > @@ -26,3 +26,5 @@ config DEFCONFIG_LIST > config EXPERT > string > option env="XEN_CONFIG_EXPERT" > + > +source "Kconfig.debug" > diff --git a/xen/Kconfig.debug b/xen/Kconfig.debug > new file mode 100644 > index 0000000..36890bd > --- /dev/null > +++ b/xen/Kconfig.debug > @@ -0,0 +1,6 @@ > + > +menuconfig DEBUG > + bool "Debugging Options" > + ---help--- > + If you want to debug Xen say Y and select any additional debugging > + support options. .. You can also add: Should not be used for production builds. Note that any _ASSERTS_ in the code without debug are emitted. > -- > 2.7.3 > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xen.org > http://lists.xen.org/xen-devel
On 3/25/16 2:42 PM, Konrad Rzeszutek Wilk wrote: > On Thu, Mar 24, 2016 at 11:48:18AM -0500, Doug Goldstein wrote: >> There are a number of debugging options for Xen so the idea is to have a >> menu to group them all together. >> >> Signed-off-by: Doug Goldstein <cardoe@cardoe.com> >> --- >> This is more of an RFC than a merge request. If this seems reasonable I'll >> add all the other debugging options under this menu as well. Obviously if >> this seems reasonable and the patch is fine we can merge it and I'll submit >> the others as a follow up. > > There would be more I presume - the lock profile, gcov, crash, etc.. Yes. I just wanted to do one to get an idea of how people felt about the menu. > > And with the 'randconfig' that means we can turn on/off various options and > find interesting dependencies (if any). Exactly. We've found a number of interesting cases with randconfig already and fixed them. I previously checked some of them against some of the stable trees and found the combos failed so Travis CI + randconfig are finding issues but not commonly used ones. Anyway back to this patch. > > > Anyhow back to this patch. :-D > > The usual method for distros of compiling an Xen with and without debug (like Xenserver) > is: > This feels very... http://xkcd.com/1172/ > make %{?_smp_mflags} max_phys_cpus=384 xen tools So two comments on this line. 1) ick! "xen" and "tools" targets have been marked as Legacy since October 5th 2005! 2) That's been broken since I got rid of max_phys_cpus and moved it to CONFIG_NR_CPUS (I think that's the name). spec files for things like busybox include the config file and just copy it in before running make cp someplace/config.release xen/.config make %{?_smp_mflags} dist-xen dist-tools > > make %{?_smp_mflags} -C xen clean why use the directory here but not in the first step? make %{?_smp_mflags} clean-xen would be the matching target > make %{?_smp_mflags} -C xen debug=y max_phys_cpus=384 ok mind blown. We build xen in the first step with the Legacy target and then changing to the directory here. > > It would be preferrable to still have this functionality. As in, if we > do 'debug=y' then verbose=y and frame_pointer=y are automatically enabled? > > Is that something the Kconfig magic can still do? I could do some wizard-y to allow debug=y to turn things on. Not sure if the lowercase will work but I can definitely think of a way to make the uppercase DEBUG=y work. But at that point I don't see the point. I see the point of debug=y since that's a top level thing. <continuing the conversation in the other patch since you brought up some good points there> >> >> >> CC: Ian Jackson <ian.jackson@eu.citrix.com> >> CC: Jan Beulich <jbeulich@suse.com> >> CC: Keir Fraser <keir@xen.org> >> CC: Tim Deegan <tim@xen.org> >> --- >> xen/Kconfig | 2 ++ >> xen/Kconfig.debug | 6 ++++++ >> 2 files changed, 8 insertions(+) >> create mode 100644 xen/Kconfig.debug >> >> diff --git a/xen/Kconfig b/xen/Kconfig >> index fa8b27c..0fe7a1a 100644 >> --- a/xen/Kconfig >> +++ b/xen/Kconfig >> @@ -26,3 +26,5 @@ config DEFCONFIG_LIST >> config EXPERT >> string >> option env="XEN_CONFIG_EXPERT" >> + >> +source "Kconfig.debug" >> diff --git a/xen/Kconfig.debug b/xen/Kconfig.debug >> new file mode 100644 >> index 0000000..36890bd >> --- /dev/null >> +++ b/xen/Kconfig.debug >> @@ -0,0 +1,6 @@ >> + >> +menuconfig DEBUG >> + bool "Debugging Options" >> + ---help--- >> + If you want to debug Xen say Y and select any additional debugging >> + support options. > > .. You can also add: > > Should not be used for production builds. > > Note that any _ASSERTS_ in the code without debug are emitted. > >> -- >> 2.7.3 >> >> >> _______________________________________________ >> Xen-devel mailing list >> Xen-devel@lists.xen.org >> http://lists.xen.org/xen-devel
On Fri, 2016-03-25 at 15:59 -0500, Doug Goldstein wrote: > On 3/25/16 2:42 PM, Konrad Rzeszutek Wilk wrote: > > > > > This is more of an RFC than a merge request. If this seems > > > reasonable I'll > > > add all the other debugging options under this menu as well. > > > Obviously if > > > this seems reasonable and the patch is fine we can merge it and > > > I'll submit > > > the others as a follow up. > > There would be more I presume - the lock profile, gcov, crash, > > etc.. > Yes. I just wanted to do one to get an idea of how people felt about > the > menu. > Cpupools have some kind of very verbose debugging that could fit in here, and scheduling too. So, FWIW, I indeed like this menu, and am up for plumbing the two components above under it. :-) Thanks and Regards, Dario
>>> On 24.03.16 at 17:48, <cardoe@cardoe.com> wrote: > There are a number of debugging options for Xen so the idea is to have a > menu to group them all together. > > Signed-off-by: Doug Goldstein <cardoe@cardoe.com> > --- > This is more of an RFC than a merge request. If this seems reasonable I'll > add all the other debugging options under this menu as well. Obviously if > this seems reasonable and the patch is fine we can merge it and I'll submit > the others as a follow up. I certainly welcome this, provided a solution to the so far shared meaning of "debug=y" for the xen/ and tools/ subtrees can be found. Allowing them to use different settings is maybe a nice option, but by default the build mode for both subtrees should imo be the same. Jan
diff --git a/xen/Kconfig b/xen/Kconfig index fa8b27c..0fe7a1a 100644 --- a/xen/Kconfig +++ b/xen/Kconfig @@ -26,3 +26,5 @@ config DEFCONFIG_LIST config EXPERT string option env="XEN_CONFIG_EXPERT" + +source "Kconfig.debug" diff --git a/xen/Kconfig.debug b/xen/Kconfig.debug new file mode 100644 index 0000000..36890bd --- /dev/null +++ b/xen/Kconfig.debug @@ -0,0 +1,6 @@ + +menuconfig DEBUG + bool "Debugging Options" + ---help--- + If you want to debug Xen say Y and select any additional debugging + support options.
There are a number of debugging options for Xen so the idea is to have a menu to group them all together. Signed-off-by: Doug Goldstein <cardoe@cardoe.com> --- This is more of an RFC than a merge request. If this seems reasonable I'll add all the other debugging options under this menu as well. Obviously if this seems reasonable and the patch is fine we can merge it and I'll submit the others as a follow up. CC: Ian Jackson <ian.jackson@eu.citrix.com> CC: Jan Beulich <jbeulich@suse.com> CC: Keir Fraser <keir@xen.org> CC: Tim Deegan <tim@xen.org> --- xen/Kconfig | 2 ++ xen/Kconfig.debug | 6 ++++++ 2 files changed, 8 insertions(+) create mode 100644 xen/Kconfig.debug