This is an archive of the discontinued LLVM Phabricator instance.

[Docs] [HLSL] Add note about PCH support
ClosedPublic

Authored by python3kgae on Sep 20 2022, 6:00 PM.

Details

Summary

PCH supported for HLSL is added when compile in -cc1 mode using -include-pch for test AST.
This change add some notes about the support of PCH for HLSL.

Diff Detail

Event Timeline

python3kgae created this revision.Sep 20 2022, 6:00 PM
Herald added a project: Restricted Project. · View Herald TranscriptSep 20 2022, 6:00 PM
Herald added a subscriber: Anastasia. · View Herald Transcript
python3kgae requested review of this revision.Sep 20 2022, 6:00 PM
Herald added a project: Restricted Project. · View Herald TranscriptSep 20 2022, 6:00 PM
Herald added a subscriber: cfe-commits. · View Herald Transcript
beanz added inline comments.Oct 4 2022, 2:23 PM
clang/docs/HLSL/HLSLSupport.rst
98

We can probably generalize this to something like:

When precompiled headers are used compiling HLSL, the ``ExternalSemaSource``
will be a ``MultiplexExternalSemaSource`` which include both the ``ASTReader``
and ``HLSLExternalSemaSource``. For Built-in declarations that are  already
completed in the serialized AST, the ``HLSLExternalSemaSource`` will reuse the
existing declarations and not introduce new declarations. If the built-in types
are not completed in the serialized AST, the ``HLSLExternalSemaSource`` will
create new declarations and connect the de-serialized decls as the previous
declaration.

Update to match comments

beanz accepted this revision.Oct 7 2022, 10:45 AM
This revision is now accepted and ready to land.Oct 7 2022, 10:45 AM
This revision was automatically updated to reflect the committed changes.