summaryrefslogtreecommitdiffstats
path: root/llvm/docs/CommandGuide
Commit message (Collapse)AuthorAgeFilesLines
* [llvm-locstats] Fix the docsDjordje Todorovic2020-01-151-0/+0
| | | | Add the missing picture for the documentation.
* [llvm-locstats] Add the --draw-plot optionDjordje Todorovic2020-01-151-24/+45
| | | | | | | | When using the option, draw the histogram representing the debug location buckets. The resulting histogram will be saved in a png file. Differential Revision: https://reviews.llvm.org/D71869
* [llvm-locstats][NFC] Support OOP conceptDjordje Todorovic2020-01-151-7/+7
| | | | | | | | | | | | | | | Making these changes, the code becomes more robust and easier for adding the new features. -Introduce the LocationStats class representing the statistics -Add the pretty_print() method in the LocationStats class -Add additional '-' for the program options -Add the verify_program_inputs() function -Add the parse_locstats() function -Rename 'results' => 'opts' -Add more comments Differential Revision: https://reviews.llvm.org/D71868
* [llvm-symbolizer] Support reading options from environmentPetr Hosek2019-12-202-0/+8
| | | | | | | | | | | | | llvm-symbolizer is used by sanitizers to symbolize errors discovered by sanitizer, but there's no way to pass options to llvm-symbolizer since the tool is invoked directly by the sanitizer runtime. Therefore, we don't have a way to pass options needed to find debug symbols such as -dsym-hint or -debug-file-directory. This change enables reading options from the LLVM_SYMBOLIZER_OPTS in addition to command line which can be used to pass those additional options to llvm-symbolizer invocations made by sanitizer runtime. Differential Revision: https://reviews.llvm.org/D71668
* llvm-cxxmap: fix support for remapping non-mangled names.Richard Smith2019-12-181-0/+8
| | | | | | | Remappings involving extern "C" names were already supported in the context of <local-name>s, but this support didn't work for remapping the complete mangling itself. (Eg, we would remap X<foo> but not foo itself, if foo is an extern "C" function.)
* [llvm-objcopy][MachO] Implement --add-sectionSeiya Nuta2019-12-161-0/+3
| | | | | | | | | | | | Reviewers: alexshap, rupprecht, jhenderson Reviewed By: alexshap, jhenderson Subscribers: mgorny, jakehehrlich, abrachet, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D66283
* [llvm-dwarfdump][Statistics] Don't count coverage less than 1% as 0%Kristina Bessonova2019-12-131-1/+1
| | | | | | | | | | | | | | | | | | | | | Summary: This is a follow up for D70548. Currently, variables with debug info coverage between 0% and 1% are put into zero-bucket. D70548 changed the way statistics calculate a variable's coverage: we began to use enclosing scope rather than a possible variable life range. Thus more variables might be moved to zero-bucket despite they have some debug info coverage. The patch is to distinguish between a variable that has location info but it's significantly less than its enclosing scope and a variable that doesn't have it at all. Reviewers: djtodoro, aprantl, dblaikie, avl Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D71070
* [llvm-dwarfdump][Statistics] Change the coverage buckets representation. NFCKristina Bessonova2019-12-131-12/+12
| | | | | | | | | | | | | | | | Summary: This changes the representation of 'coverage buckets' in llvm-dwarfdump and llvm-locstats to one that makes more clear what the buckets contain. See some related details in D71070. Reviewers: djtodoro, aprantl, cmtice, jhenderson Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D71366
* [llvm-readobj] - Implement --dependent-libraries flag.Georgii Rymar2019-12-061-0/+4
| | | | | | | | | | There is no way to dump SHT_LLVM_DEPENDENT_LIBRARIES sections currently. This patch implements this. The section is described here: https://llvm.org/docs/Extensions.html#sht-llvm-dependent-libraries-section-dependent-libraries Differential revision: https://reviews.llvm.org/D70665
* [lit] Document the undocumented pre-defined substitutionsDaniel Sanders2019-12-041-11/+32
|
* [llvm-objcopy][MachO] Implement --dump-sectionSeiya Nuta2019-11-251-9/+12
| | | | | | | | | | | | Reviewers: alexshap, rupprecht, jhenderson Reviewed By: alexshap, rupprecht, jhenderson Subscribers: MaskRay, jakehehrlich, abrachet, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D66408
* [llvm-objcopy][MachO] Implement --remove-sectionSeiya Nuta2019-11-151-0/+3
| | | | | | | | | | | | Reviewers: alexshap, rupprecht, jhenderson Reviewed By: rupprecht, jhenderson Subscribers: jakehehrlich, abrachet, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D66282
* [llvm-objcopy][COFF] Implement --redefine-sym and --redefine-symsFangrui Song2019-11-121-13/+13
| | | | | | | | | | | | | The parsing error tests in ELF/redefine-symbols.test are not specific to ELF. Move them to redefine-symbols.test. Add COFF/redefine-symbols.test for COFF specific tests. Also fix the documentation regarding --redefine-syms: the old and new names are separated by whitespace, not an equals sign. Reviewed By: mstorsjo Differential Revision: https://reviews.llvm.org/D70036
* [llvm-objcopy][ELF] Implement --only-keep-debugFangrui Song2019-11-051-5/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --only-keep-debug produces a debug file as the output that only preserves contents of sections useful for debugging purposes (the binutils implementation preserves SHT_NOTE and non-SHF_ALLOC sections), by changing their section types to SHT_NOBITS and rewritting file offsets. See https://sourceware.org/gdb/onlinedocs/gdb/Separate-Debug-Files.html The intended use case is: ``` llvm-objcopy --only-keep-debug a a.dbg llvm-objcopy --strip-debug a b llvm-objcopy --add-gnu-debuglink=a.dbg b ``` The current layout algorithm is incapable of deleting contents and shrinking segments, so it is not suitable for implementing the functionality. This patch adds a new algorithm which assigns sh_offset to sections first, then modifies p_offset/p_filesz of program headers. It bears a resemblance to lld/ELF/Writer.cpp. Reviewed By: jhenderson, jakehehrlich Differential Revision: https://reviews.llvm.org/D67137
* [llvm-objcopy] Preserve .ARM.attributes section when stripping filesJames Henderson2019-10-312-2/+4
| | | | | | | | | | | | | | This works around a bug in Debian's patchset for glibc. The bug is described in detail in the upstream debian bug: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=943798, but the short version of it is that glibc on any Debian based distro don't load libraries unless it has a .ARM.attribute section. Reviewed by: jhenderson, rupprecht, MaskRay, jakehehrlich Differential Revision: https://reviews.llvm.org/D69188 Patch by Tobias Hieta.
* [llvm-objcopy][MachO] Implement --strip-allSeiya Nuta2019-10-311-2/+2
| | | | | | | | | | | | Reviewers: alexshap, rupprecht, jdoerfert, jhenderson Reviewed By: alexshap Subscribers: jakehehrlich, abrachet, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D66281
* Revert "[llvm-cov] Add option to whitelist filenames"Vlad Tsyrklevich2019-10-291-4/+0
| | | | | | This reverts commit bfed824b57d14e2ba98ddbaf1a1410cf04a3e279, the included test fails on many bots including the sanitier bots, e.g. in http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/36140
* [llvm-cov] Add option to whitelist filenamesVedant Kumar2019-10-291-0/+4
| | | | | | | | | Add the `-whitelist-filename-regex` option to restrict coverage reporting to file paths that match a whitelist regex. Patch by Michael Daniels! rdar://56720320
* [Remarks] Remove references to ELF supportFrancis Visoiu Mistrih2019-10-281-2/+2
| | | | | | There is no ELF support at the moment. Remove all the references to the `.remarks` section.
* [llvm-objcopy][MachO] Implement --only-sectionSeiya Nuta2019-10-281-0/+3
| | | | | | | | | | | | Reviewers: alexshap, rupprecht, jdoerfert, jhenderson Reviewed By: alexshap, rupprecht, jhenderson Subscribers: mgorny, jakehehrlich, abrachet, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D65541
* [docs][llvm-ar] Update llvm-ar command guideOwen Reynolds2019-10-211-193/+238
| | | | | | | | | | | | | | | | | The llvm-ar command guide had not been updated in some time, it was missing current functionality and contained information that was out of date. This change: - Updates the use of reStructuredText directives, as seen in other tools command guides. - Updates the command synopsis. - Updates the descriptions of the tool behaviour. - Updates the options section. - Adds details of MRI script functionality. - Removes the sections "Standards" and "File Format" Differential Revision: https://reviews.llvm.org/D68998 llvm-svn: 375412
* [llvm-objcopy] Add support for shell wildcardsJordan Rupprecht2019-10-172-0/+48
| | | | | | | | | | | | | | | | | | | | Summary: GNU objcopy accepts the --wildcard flag to allow wildcard matching on symbol-related flags. (Note: it's implicitly true for section flags). The basic syntax is to allow *, ?, \, and [] which work similarly to how they work in a shell. Additionally, starting a wildcard with ! causes that wildcard to prevent it from matching a flag. Use an updated GlobPattern in libSupport to handle these patterns. It does not fully match the `fnmatch` used by GNU objcopy since named character classes (e.g. `[[:digit:]]`) are not supported, but this should support most existing use cases (mostly just `*` is what's used anyway). Reviewers: jhenderson, MaskRay, evgeny777, espindola, alexshap Reviewed By: MaskRay Subscribers: nickdesaulniers, emaste, arichardson, hiraditya, jakehehrlich, abrachet, seiya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D66613 llvm-svn: 375169
* [docs][llvm-ar] Fix option:: O after r375106Fangrui Song2019-10-171-1/+1
| | | | | | | | docs-llvm-html fails => unknown option: O There are lots of formatting issues in the file but they will be fixed by D68998. llvm-svn: 375107
* [llvm-ar] Implement the O modifier: display member offsets inside the archiveFangrui Song2019-10-171-4/+8
| | | | | | | | | | | | Since GNU ar 2.31, the 't' operation prints member offsets beside file names if the 'O' modifier is specified. 'O' is ignored for thin archives. Reviewed By: gbreynoo, ruiu Differential Revision: https://reviews.llvm.org/D69087 llvm-svn: 375106
* [llvm-ar] Make paths case insensitive when on windowsOwen Reynolds2019-10-161-0/+6
| | | | | | | | | When on windows gnu-ar treats member names as case insensitive. This commit implements the same behaviour. Differential Revision: https://reviews.llvm.org/D68033 llvm-svn: 375002
* [FileCheck] Implement --ignore-case option.Kai Nacke2019-10-111-0/+5
| | | | | | | | | | | | The FileCheck utility is enhanced to support a `--ignore-case` option. This is useful in cases where the output of Unix tools differs in case (e.g. case not specified by Posix). Reviewers: Bigcheese, jakehehrlich, rupprecht, espindola, alexshap, jhenderson, MaskRay Differential Revision: https://reviews.llvm.org/D68146 llvm-svn: 374538
* [lit] Bring back `--threads` option aliasJulian Lettner2019-10-101-1/+1
| | | | | | | | Bring back `--threads` option which was lost in the move of the command line argument parsing code to cl_arguments.py. Update docs since `--workers` is preferred. llvm-svn: 374432
* [MCA] Show aggregate over Average Wait times for the whole snippet (PR43219)Roman Lebedev2019-10-101-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: As disscused in https://bugs.llvm.org/show_bug.cgi?id=43219, i believe it may be somewhat useful to show //some// aggregates over all the sea of statistics provided. Example: ``` Average Wait times (based on the timeline view): [0]: Executions [1]: Average time spent waiting in a scheduler's queue [2]: Average time spent waiting in a scheduler's queue while ready [3]: Average time elapsed from WB until retire stage [0] [1] [2] [3] 0. 3 1.0 1.0 4.7 vmulps %xmm0, %xmm1, %xmm2 1. 3 2.7 0.0 2.3 vhaddps %xmm2, %xmm2, %xmm3 2. 3 6.0 0.0 0.0 vhaddps %xmm3, %xmm3, %xmm4 3 3.2 0.3 2.3 <total> ``` I.e. we average the averages. Reviewers: andreadb, mattd, RKSimon Reviewed By: andreadb Subscribers: gbedwell, arphaman, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D68714 llvm-svn: 374361
* Revert "[FileCheck] Implement --ignore-case option."Dmitri Gribenko2019-10-101-706/+701
| | | | | | | This reverts commit r374339. It broke tests: http://lab.llvm.org:8011/builders/clang-x86_64-debian-fast/builds/19066 llvm-svn: 374359
* [FileCheck] Implement --ignore-case option.Kai Nacke2019-10-101-701/+706
| | | | | | | | | | | | The FileCheck utility is enhanced to support a `--ignore-case` option. This is useful in cases where the output of Unix tools differs in case (e.g. case not specified by Posix). Reviewers: Bigcheese, jakehehrlich, rupprecht, espindola, alexshap, jhenderson, MaskRay Differential Revision: https://reviews.llvm.org/D68146 llvm-svn: 374339
* [llvm-exegesis] Add options to SnippetGenerator.Clement Courbet2019-10-081-1/+13
| | | | | | | | | | | | | | | | Summary: This adds a `-max-configs-per-opcode` option to limit the number of configs per opcode. Reviewers: gchatelet Subscribers: tschuett, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D68642 llvm-svn: 374054
* [llvm-locstats] Fix a typo in the documentation; NFCDjordje Todorovic2019-10-071-1/+1
| | | | llvm-svn: 373880
* [llvm-objcopy] Add --set-section-alignmentFangrui Song2019-10-021-0/+5
| | | | | | | | | | | | | Fixes PR43181. This option was recently added to GNU objcopy (binutils PR24942). `llvm-objcopy -I binary -O elf64-x86-64 --set-section-alignment .data=8` can set the alignment of .data. Reviewed By: grimar, jhenderson, rupprecht Differential Revision: https://reviews.llvm.org/D67656 llvm-svn: 373461
* Reland "[utils] Implement the llvm-locstats tool"Djordje Todorovic2019-10-022-0/+80
| | | | | | | | | | | | | | | | | | The tool reports verbose output for the DWARF debug location coverage. The llvm-locstats for each variable or formal parameter DIE computes what percentage from the code section bytes, where it is in scope, it has location description. The line 0 shows the number (and the percentage) of DIEs with no location information, but the line 100 shows the number (and the percentage) of DIEs where there is location information in all code section bytes (where the variable or parameter is in the scope). The line 50..59 shows the number (and the percentage) of DIEs where the location information is in between 50 and 59 percentage of its scope covered. Differential Revision: https://reviews.llvm.org/D66526 The cause of the test failure was resolved. llvm-svn: 373427
* Revert "Reland "[utils] Implement the llvm-locstats tool""Djordje Todorovic2019-10-012-80/+0
| | | | | | | This reverts commit rL373317 due to test failure on the clang-s390x-linux build bot. llvm-svn: 373336
* Reland "[utils] Implement the llvm-locstats tool"Djordje Todorovic2019-10-012-0/+80
| | | | | | | | | | | | | | | | The tool reports verbose output for the DWARF debug location coverage. The llvm-locstats for each variable or formal parameter DIE computes what percentage from the code section bytes, where it is in scope, it has location description. The line 0 shows the number (and the percentage) of DIEs with no location information, but the line 100 shows the number (and the percentage) of DIEs where there is location information in all code section bytes (where the variable or parameter is in the scope). The line 50..59 shows the number (and the percentage) of DIEs where the location information is in between 50 and 59 percentage of its scope covered. Differential Revision: https://reviews.llvm.org/D66526 llvm-svn: 373317
* [llvm-readobj/llvm-readelf] Delete --arm-attributes (alias for --arch-specific)Fangrui Song2019-10-012-4/+4
| | | | | | | | | | | | | | | | D68110 added --arch-specific (supported by GNU readelf) and made --arm-attributes an alias for it. The tests were later migrated to use --arch-specific. Note, llvm-readelf --arch-specific currently just uses llvm-readobj style output for ARM attributes. The readelf-style output is not implemented. Reviewed By: compnerd, kongyi, rupprecht Differential Revision: https://reviews.llvm.org/D68196 llvm-svn: 373291
* Revert "Reland "[utils] Implement the llvm-locstats tool""Djordje Todorovic2019-09-302-80/+0
| | | | | | This reverts commit rL373183. llvm-svn: 373200
* Reland "[utils] Implement the llvm-locstats tool"Djordje Todorovic2019-09-302-0/+80
| | | | | | | | | | | | | | | | The tool reports verbose output for the DWARF debug location coverage. The llvm-locstats for each variable or formal parameter DIE computes what percentage from the code section bytes, where it is in scope, it has location description. The line 0 shows the number (and the percentage) of DIEs with no location information, but the line 100 shows the number (and the percentage) of DIEs where there is location information in all code section bytes (where the variable or parameter is in the scope). The line 50..59 shows the number (and the percentage) of DIEs where the location information is in between 50 and 59 percentage of its scope covered. Differential Revision: https://reviews.llvm.org/D66526 llvm-svn: 373183
* [docs][llvm-strings] Clarify "printable character" wordingJames Henderson2019-09-251-2/+2
| | | | | | | | | | | | | | The --bytes option uses the phrase "printable ASCII characters", but the description section used simply "printable characters". To avoid any confusion about locale impacts etc, this change adopts the former's phrasing in both places. It also fixes a minor grammar issue in the description. Reviewed by: MaskRay Differential Revision: https://reviews.llvm.org/D68016 llvm-svn: 372865
* [docs][llvm-strip] Update llvm-strip doc to better match llvm-objcopy'sJames Henderson2019-09-251-9/+11
| | | | | | | | | Main changes are mostly wording of some options, but this change also fixes a switch reference so that a link is created and moves --strip-sections into the ELF-specific area since it is only supported for ELF currently. llvm-svn: 372864
* [docs][llvm-strip][llvm-objcopy] Improve wording and fix highlightingJames Henderson2019-09-242-7/+7
| | | | llvm-svn: 372754
* [docs][llvm-size] Fix typoJames Henderson2019-09-241-1/+1
| | | | llvm-svn: 372750
* Revert "Reland "[utils] Implement the llvm-locstats tool""Djordje Todorovic2019-09-232-80/+0
| | | | | | This reverts commit rL372554. llvm-svn: 372580
* Reland "[utils] Implement the llvm-locstats tool"Djordje Todorovic2019-09-232-0/+80
| | | | | | | | | | | | | | | | The tool reports verbose output for the DWARF debug location coverage. The llvm-locstats for each variable or formal parameter DIE computes what percentage from the code section bytes, where it is in scope, it has location description. The line 0 shows the number (and the percentage) of DIEs with no location information, but the line 100 shows the number (and the percentage) of DIEs where there is location information in all code section bytes (where the variable or parameter is in the scope). The line 50..59 shows the number (and the percentage) of DIEs where the location information is in between 50 and 59 percentage of its scope covered. Differential Revision: https://reviews.llvm.org/D66526 llvm-svn: 372554
* [docs] Make --version text more correctJames Henderson2019-09-177-9/+11
| | | | | | | | | | | | | | | Follow-up to r371983. Referring to "this program" in the description of the --version option in the documentation isn't exactly correct, because the docs are not part of the program, and so "this program" doesn't really refer to anything. This patch brings the other users of this terminology into line with the new updates to llvm-size and llvm-strings. Reviewed by: alexshap, MaskRay Differential Revision: https://reviews.llvm.org/D67618 llvm-svn: 372107
* [docs][llvm-strings] Write llvm-strings documentationJames Henderson2019-09-161-3/+118
| | | | | | | | | | Previously we only had a stub document. Reviewed by: MaskRay Differential Revision: https://reviews.llvm.org/D67554 llvm-svn: 371984
* [docs][llvm-size] Write llvm-size documentationJames Henderson2019-09-161-3/+186
| | | | | | | | | | Previously we only had a stub document. Reviewed by: serge-sans-paille, MaskRay Differential Revision: https://reviews.llvm.org/D67555 llvm-svn: 371983
* [llvm-objcopy] Ignore -B --binary-architecture=Fangrui Song2019-09-141-17/+4
| | | | | | | | | | | | | | | | | | | | | | | GNU objcopy documents that -B is only useful with architecture-less input (i.e. "binary" or "ihex"). After D67144, -O defaults to -I, and -B is essentially a NOP. * If -O is binary/ihex, GNU objcopy ignores -B. * If -O is elf*, -B provides the e_machine field in GNU objcopy. So to convert a blob to an ELF, `-I binary -B i386:x86-64 -O elf64-x86-64` has to be specified. `-I binary -B i386:x86-64 -O elf64-x86-64` creates an ELF with its e_machine field set to EM_NONE in GNU objcopy, but a regular x86_64 ELF in elftoolchain elfcopy. Follow the elftoolchain approach (ignoring -B) to simplify code. Users that expect their command line portable should specify -B. Reviewed By: jhenderson Differential Revision: https://reviews.llvm.org/D67215 llvm-svn: 371914
* [llvm-objcopy] Add support for response files in llvm-strip and llvm-objcopyMichael Pozulp2019-09-142-0/+8
| | | | | | | | | | | | | | | | Summary: Addresses https://bugs.llvm.org/show_bug.cgi?id=42671 Reviewers: jhenderson, espindola, alexshap, rupprecht Reviewed By: jhenderson Subscribers: seiya, emaste, arichardson, jakehehrlich, MaskRay, abrachet, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D65372 llvm-svn: 371911
OpenPOWER on IntegriCloud