[PATCH] D116821: [DebugInfo][InstrRef] Move instr-ref controlling flag out of TargetOptions

Alexander Kornienko via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 24 18:40:46 PST 2022


alexfh added a comment.

I found one particularly bad input. Here what `time -v clang -fno-omit-frame-pointer -fcommon -no-canonical-prefixes -fdiagnostics-show-option -fmessage-length=0 -fno-exceptions -fbracket-depth=768 -fno-strict-aliasing -fmerge-all-constants -flax-vector-conversions=all -funsigned-char -Xclang=-fuse-ctor-homing -fcolor-diagnostics --cuda-host-only -faligned-allocation -fnew-alignment=8 -fshow-overloads=best -mllvm -disable-binop-extract-shuffle -fdebug-types-section -O2 -momit-leaf-frame-pointer -ffp-contract=off --target=x86_64-unknown-linux-gnu -fno-unique-section-names -maes -m64 -mcx16 -msse4.2 -mpclmul -mprefer-vector-width=128 -gmlt -gz=zlib -fdebug-default-version=5 -fsanitize=address,bool,bounds,builtin,float-cast-overflow,integer-divide-by-zero,null,return,returns-nonnull-attribute,shift-exponent,signed-integer-overflow,unreachable,vla-bound -fsanitize-address-globals-dead-stripping -fsanitize-trap=null -fno-sanitize-recover=all -fno-omit-frame-pointer -fsized-deallocation -fPIE -fdirect-access-external-data -ffunction-sections -fdata-sections -pthread -fno-sanitize-trap=all -std=gnu++17 -stdlib=libc++ -Wno-deprecated-declarations -Wno-inconsistent-missing-override -save-stats -c q.cc -o q.o` says 1. at rG74db5c8c95e2aed40d288bb2df92eb859b87c827 <https://reviews.llvm.org/rG74db5c8c95e2aed40d288bb2df92eb859b87c827> (with the new behavior disabled) and 2. at rG80532ebb508d0ca62f96df5f253db8caed969397 <https://reviews.llvm.org/rG80532ebb508d0ca62f96df5f253db8caed969397> (right before rG74db5c8c95e2aed40d288bb2df92eb859b87c827 <https://reviews.llvm.org/rG74db5c8c95e2aed40d288bb2df92eb859b87c827>):

1
-

  User time (seconds): 190.92
  System time (seconds): 2.16
  Percent of CPU this job got: 99%
  Elapsed (wall clock) time (h:mm:ss or m:ss): 3:13.10
  Average shared text size (kbytes): 0
  Average unshared data size (kbytes): 0
  Average stack size (kbytes): 0
  Average total size (kbytes): 0
  Maximum resident set size (kbytes): 4926000
  Average resident set size (kbytes): 0
  Major (requiring I/O) page faults: 0
  Minor (reclaiming a frame) page faults: 27080
  Voluntary context switches: 8
  Involuntary context switches: 579
  Swaps: 0
  File system inputs: 0
  File system outputs: 54168
  Socket messages sent: 0
  Socket messages received: 0
  Signals delivered: 0
  Page size (bytes): 4096
  Exit status: 0

2
-

  User time (seconds): 255.60
  System time (seconds): 8.09
  Percent of CPU this job got: 99%
  Elapsed (wall clock) time (h:mm:ss or m:ss): 4:23.71
  Average shared text size (kbytes): 0
  Average unshared data size (kbytes): 0
  Average stack size (kbytes): 0
  Average total size (kbytes): 0
  Maximum resident set size (kbytes): 27272308
  Average resident set size (kbytes): 0
  Major (requiring I/O) page faults: 0
  Minor (reclaiming a frame) page faults: 32213
  Voluntary context switches: 8
  Involuntary context switches: 779
  Swaps: 0
  File system inputs: 0
  File system outputs: 54168
  Socket messages sent: 0
  Socket messages received: 0
  Signals delivered: 0
  Page size (bytes): 4096
  Exit status: 0

The most problematic are `User time (seconds):` 190.92 -> 255.60 (+34%) and `Maximum resident set size (kbytes):` 4926000 -> 27272308 (5.5x).

As for the nature of the code, it's a large generated file (preprocessed size ~22MB) with a few kinds of boilerplate (e.g. a method with a ton of `v->push_back({some, constant});` calls and other stuff). I can try to find out which of them is responsible for most of the increase.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D116821/new/

https://reviews.llvm.org/D116821



More information about the llvm-commits mailing list