[llvm-commits] [llvm] r165814 - /llvm/trunk/docs/BitCodeFormat.rst

Duncan Sands baldrick at free.fr
Sat Oct 13 10:33:11 PDT 2012


Hi Jan,

 > Add bitcode instruction encoding documentation for module version
> 0 and 1.  Followup to 165739.

> --- llvm/trunk/docs/BitCodeFormat.rst (original)
> +++ llvm/trunk/docs/BitCodeFormat.rst Fri Oct 12 13:13:17 2012
> @@ -489,6 +489,8 @@
>   When combined with the bitcode magic number and viewed as bytes, this is
>   ``"BC 0xC0DE"``.
>
> +.. _Signed VBRs:
> +
>   Signed VBRs
>   ^^^^^^^^^^^
>
> @@ -507,6 +509,7 @@
>   With this encoding, small positive and small negative values can both be emitted
>   efficiently. Signed VBR encoding is used in ``CST_CODE_INTEGER`` and
>   ``CST_CODE_WIDE_INTEGER`` records within ``CONSTANTS_BLOCK`` blocks.
> +It is also used for phi instruction operands in `MODULE_CODE_VERSION`_ 1.
>
>   LLVM IR Blocks
>   ^^^^^^^^^^^^^^
> @@ -553,13 +556,57 @@
>   * `FUNCTION_BLOCK`_
>   * `METADATA_BLOCK`_
>
> +.. _MODULE_CODE_VERSION:
> +
>   MODULE_CODE_VERSION Record
>   ^^^^^^^^^^^^^^^^^^^^^^^^^^
>
>   ``[VERSION, version#]``
>
>   The ``VERSION`` record (code 1) contains a single value indicating the format
> -version. Only version 0 is supported at this time.
> +version. Version 0 and 1 are supported at this time. The difference between

Version 0 and 1 -> Versions 0 and 1

> +version 0 and 1 is in the encoding of instruction operands in
> +each `FUNCTION_BLOCK`_.

Ciao, Duncan.




More information about the llvm-commits mailing list