tblgen.rst 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. tblgen - Target Description To C++ Code Generator
  2. =================================================
  3. SYNOPSIS
  4. --------
  5. :program:`tblgen` [*options*] [*filename*]
  6. DESCRIPTION
  7. -----------
  8. :program:`tblgen` translates from target description (``.td``) files into C++
  9. code that can be included in the definition of an LLVM target library. Most
  10. users of LLVM will not need to use this program. It is only for assisting with
  11. writing an LLVM target backend.
  12. The input and output of :program:`tblgen` is beyond the scope of this short
  13. introduction; please see the :doc:`introduction to TableGen
  14. <../TableGen/index>`.
  15. The *filename* argument specifies the name of a Target Description (``.td``)
  16. file to read as input.
  17. OPTIONS
  18. -------
  19. .. program:: tblgen
  20. .. option:: -help
  21. Print a summary of command line options.
  22. .. option:: -o filename
  23. Specify the output file name. If ``filename`` is ``-``, then
  24. :program:`tblgen` sends its output to standard output.
  25. .. option:: -I directory
  26. Specify where to find other target description files for inclusion. The
  27. ``directory`` value should be a full or partial path to a directory that
  28. contains target description files.
  29. .. option:: -asmparsernum N
  30. Make -gen-asm-parser emit assembly writer number ``N``.
  31. .. option:: -asmwriternum N
  32. Make -gen-asm-writer emit assembly writer number ``N``.
  33. .. option:: -class className
  34. Print the enumeration list for this class.
  35. .. option:: -print-records
  36. Print all records to standard output (default).
  37. .. option:: -print-enums
  38. Print enumeration values for a class.
  39. .. option:: -print-sets
  40. Print expanded sets for testing DAG exprs.
  41. .. option:: -gen-emitter
  42. Generate machine code emitter.
  43. .. option:: -gen-register-info
  44. Generate registers and register classes info.
  45. .. option:: -gen-instr-info
  46. Generate instruction descriptions.
  47. .. option:: -gen-asm-writer
  48. Generate the assembly writer.
  49. .. option:: -gen-disassembler
  50. Generate disassembler.
  51. .. option:: -gen-pseudo-lowering
  52. Generate pseudo instruction lowering.
  53. .. option:: -gen-dag-isel
  54. Generate a DAG (Directed Acycle Graph) instruction selector.
  55. .. option:: -gen-asm-matcher
  56. Generate assembly instruction matcher.
  57. .. option:: -gen-dfa-packetizer
  58. Generate DFA Packetizer for VLIW targets.
  59. .. option:: -gen-fast-isel
  60. Generate a "fast" instruction selector.
  61. .. option:: -gen-subtarget
  62. Generate subtarget enumerations.
  63. .. option:: -gen-intrinsic
  64. Generate intrinsic information.
  65. .. option:: -gen-tgt-intrinsic
  66. Generate target intrinsic information.
  67. .. option:: -gen-enhanced-disassembly-info
  68. Generate enhanced disassembly info.
  69. .. option:: -version
  70. Show the version number of this program.
  71. EXIT STATUS
  72. -----------
  73. If :program:`tblgen` succeeds, it will exit with 0. Otherwise, if an error
  74. occurs, it will exit with a non-zero value.