Praveen Velliengiri via llvm-dev
2019-Aug-14 19:22 UTC
[llvm-dev] Can I build llvm with only a handful of source files compiled for debug?
Regarding resource constraint problems, I didn't build llvm on much heavier machine previously, so it is difficult for me to tell whether my build is taking longer than expected trivially, fresh build (+ clang, lldb) takes time. But rebuild are actually fast. I will use -compress-debug-sections with the full build and rebuilds and see how fast it is :) Making an assumption here: since debug-info is compressed, i think it may cause a overhead for the debugger. Is it true? If so, it overhead is observable to some extent ? On Thu, 15 Aug 2019 at 00:33, David Blaikie <dblaikie at gmail.com> wrote:> Are you already using split DWARF & still having resource constraint > problems? (oh, you could also compress debug info, > -Wa,-compress-debug-sections) > > > > On Wed, Aug 14, 2019 at 12:00 PM Praveen Velliengiri < > praveenvelliengiri at gmail.com> wrote: > >> Actually, I have same question, If llvm build provides a option similar >> to that, it will be lot more easier for people doing development in >> relatively less (compute, storage) PC's. >> >> >> On Thu, 15 Aug 2019 at 00:22, David Blaikie via llvm-dev < >> llvm-dev at lists.llvm.org> wrote: >> >>> Nothing supported, though might not be too hard to do by hand. >>> >>> If you're having long link times, lots of disk usage, and slow gdb >>> startup time I'd recommend enabling split DWARF (LLVM_USE_SPLIT_DWARF=ON, >>> and CMAKE_EXE_LINKER_FLAGS_*=-Wl,-gdb-index in cmake) if you haven't >>> already. >>> >>> On Wed, Aug 14, 2019 at 11:40 AM Robert Henry via llvm-dev < >>> llvm-dev at lists.llvm.org> wrote: >>> >>>> In order to minimize edit/compile/debug turn time, is there a way to >>>> compile llvm tools so that the majority of the files are compiled as if for >>>> release (eg, no debug symbols), and only the handful of files that I have >>>> touched are compiled for debugging? This will reduce the load on the file >>>> system, linker and gdb tremendously. At present, AFAICT, it's all or >>>> nothing. >>>> _______________________________________________ >>>> LLVM Developers mailing list >>>> llvm-dev at lists.llvm.org >>>> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev >>>> >>> _______________________________________________ >>> LLVM Developers mailing list >>> llvm-dev at lists.llvm.org >>> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev >>> >>-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20190815/0ec4c428/attachment.html>
David Blaikie via llvm-dev
2019-Aug-14 19:28 UTC
[llvm-dev] Can I build llvm with only a handful of source files compiled for debug?
On Wed, Aug 14, 2019 at 12:22 PM Praveen Velliengiri < praveenvelliengiri at gmail.com> wrote:> Regarding resource constraint problems, I didn't build llvm on much > heavier machine previously, so it is difficult for me to tell whether my > build is taking longer than expected trivially, fresh build (+ clang, lldb) > takes time. But rebuild are actually fast. >Are you already using split DWARF (& gdb-index)?> I will use -compress-debug-sections with the full build and rebuilds and > see how fast it is :) > Making an assumption here: since debug-info is compressed, i think it may > cause a overhead for the debugger. Is it true? If so, it overhead is > observable to some extent ? >Compression will add some CPU compile time (& some link time, technically - since the linker will decompress the sections to link them), but might save time when writing fewer bytes to disk (& save disk usage). Similarly decompression by the debugger might slow things, but reading fewer bytes from disk may speed them up - will depend on the CPU versus disk IO speeds.> > On Thu, 15 Aug 2019 at 00:33, David Blaikie <dblaikie at gmail.com> wrote: > >> Are you already using split DWARF & still having resource constraint >> problems? (oh, you could also compress debug info, >> -Wa,-compress-debug-sections) >> >> >> >> On Wed, Aug 14, 2019 at 12:00 PM Praveen Velliengiri < >> praveenvelliengiri at gmail.com> wrote: >> >>> Actually, I have same question, If llvm build provides a option similar >>> to that, it will be lot more easier for people doing development in >>> relatively less (compute, storage) PC's. >>> >>> >>> On Thu, 15 Aug 2019 at 00:22, David Blaikie via llvm-dev < >>> llvm-dev at lists.llvm.org> wrote: >>> >>>> Nothing supported, though might not be too hard to do by hand. >>>> >>>> If you're having long link times, lots of disk usage, and slow gdb >>>> startup time I'd recommend enabling split DWARF (LLVM_USE_SPLIT_DWARF=ON, >>>> and CMAKE_EXE_LINKER_FLAGS_*=-Wl,-gdb-index in cmake) if you haven't >>>> already. >>>> >>>> On Wed, Aug 14, 2019 at 11:40 AM Robert Henry via llvm-dev < >>>> llvm-dev at lists.llvm.org> wrote: >>>> >>>>> In order to minimize edit/compile/debug turn time, is there a way to >>>>> compile llvm tools so that the majority of the files are compiled as if for >>>>> release (eg, no debug symbols), and only the handful of files that I have >>>>> touched are compiled for debugging? This will reduce the load on the file >>>>> system, linker and gdb tremendously. At present, AFAICT, it's all or >>>>> nothing. >>>>> _______________________________________________ >>>>> LLVM Developers mailing list >>>>> llvm-dev at lists.llvm.org >>>>> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev >>>>> >>>> _______________________________________________ >>>> LLVM Developers mailing list >>>> llvm-dev at lists.llvm.org >>>> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev >>>> >>>-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20190814/dfa2490a/attachment.html>
Praveen Velliengiri via llvm-dev
2019-Aug-14 19:46 UTC
[llvm-dev] Can I build llvm with only a handful of source files compiled for debug?
I used Split Dwarf, but actually in some builds only, I don't know why I stopped using it. Thanks I will use them, and tell you how far it reduces the total time. Yeah, understood that but I use llvm as shared libraries, which already costs me observable overhead while debugging. For what it's worth, I will try my hands on it by compressing debug-info. On Thu, 15 Aug 2019 at 00:58, David Blaikie <dblaikie at gmail.com> wrote:> > > On Wed, Aug 14, 2019 at 12:22 PM Praveen Velliengiri < > praveenvelliengiri at gmail.com> wrote: > >> Regarding resource constraint problems, I didn't build llvm on much >> heavier machine previously, so it is difficult for me to tell whether my >> build is taking longer than expected trivially, fresh build (+ clang, lldb) >> takes time. But rebuild are actually fast. >> > > Are you already using split DWARF (& gdb-index)? > > >> I will use -compress-debug-sections with the full build and rebuilds and >> see how fast it is :) >> Making an assumption here: since debug-info is compressed, i think it may >> cause a overhead for the debugger. Is it true? If so, it overhead is >> observable to some extent ? >> > > Compression will add some CPU compile time (& some link time, technically > - since the linker will decompress the sections to link them), but might > save time when writing fewer bytes to disk (& save disk usage). Similarly > decompression by the debugger might slow things, but reading fewer bytes > from disk may speed them up - will depend on the CPU versus disk IO speeds. > > >> >> On Thu, 15 Aug 2019 at 00:33, David Blaikie <dblaikie at gmail.com> wrote: >> >>> Are you already using split DWARF & still having resource constraint >>> problems? (oh, you could also compress debug info, >>> -Wa,-compress-debug-sections) >>> >>> >>> >>> On Wed, Aug 14, 2019 at 12:00 PM Praveen Velliengiri < >>> praveenvelliengiri at gmail.com> wrote: >>> >>>> Actually, I have same question, If llvm build provides a option similar >>>> to that, it will be lot more easier for people doing development in >>>> relatively less (compute, storage) PC's. >>>> >>>> >>>> On Thu, 15 Aug 2019 at 00:22, David Blaikie via llvm-dev < >>>> llvm-dev at lists.llvm.org> wrote: >>>> >>>>> Nothing supported, though might not be too hard to do by hand. >>>>> >>>>> If you're having long link times, lots of disk usage, and slow gdb >>>>> startup time I'd recommend enabling split DWARF (LLVM_USE_SPLIT_DWARF=ON, >>>>> and CMAKE_EXE_LINKER_FLAGS_*=-Wl,-gdb-index in cmake) if you haven't >>>>> already. >>>>> >>>>> On Wed, Aug 14, 2019 at 11:40 AM Robert Henry via llvm-dev < >>>>> llvm-dev at lists.llvm.org> wrote: >>>>> >>>>>> In order to minimize edit/compile/debug turn time, is there a way to >>>>>> compile llvm tools so that the majority of the files are compiled as if for >>>>>> release (eg, no debug symbols), and only the handful of files that I have >>>>>> touched are compiled for debugging? This will reduce the load on the file >>>>>> system, linker and gdb tremendously. At present, AFAICT, it's all or >>>>>> nothing. >>>>>> _______________________________________________ >>>>>> LLVM Developers mailing list >>>>>> llvm-dev at lists.llvm.org >>>>>> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev >>>>>> >>>>> _______________________________________________ >>>>> LLVM Developers mailing list >>>>> llvm-dev at lists.llvm.org >>>>> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev >>>>> >>>>-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20190815/7910b403/attachment.html>