pcc (Peter Collingbourne)
User

Projects

User does not belong to any projects.

User Details

User Since
Dec 28 2012, 2:34 PM (237 w, 6 d)

Recent Activity

Today

pcc added inline comments to D35639: [LTO] Prevent dead stripping and internalization of symbols with sections.
Thu, Jul 20, 3:50 PM
pcc added a comment to D35639: [LTO] Prevent dead stripping and internalization of symbols with sections.

Actually, I have a variant of this that I prefer. Instead of setting VisibleToRegularObj in each linker, we could handle it similar to the way some COFF specific behavior is handled. I.e. when building the symbol table, if isOSBinFormatELF, and the symbol has a C identifier section name, then set a (new) flag on the symbol indicating as such (e.g. ELFHasCIdentifierSectionName). Then in LTO::addModuleToGlobalRes, we add a check of this flag to the conditions under which VisibleOutsideSummary is set. That has the advantage of avoiding the need to add checking to each ELF linker, and also doesn't overload the VisibleToRegularObj flag with a condition that isn't being visible to a regular object, but rather visible outside the summary in a different way. Sound ok?

Note in addModuleToGlobalRes it is also added to the set of conditions where we need to set the Partition to External (similar to the places where we currently check things like VisibleToRegularObj. I have this working for a small test case, testing with my full internal test case. If that works I will clean up and send for review. I like this since it is ELF specific but doesn't require any linker changes.

Thu, Jul 20, 11:32 AM
pcc committed rL308642: LowerTypeTests: Drop function type metadata only if we're going to replace it..
LowerTypeTests: Drop function type metadata only if we're going to replace it.
Thu, Jul 20, 11:02 AM
pcc closed D35604: LowerTypeTests: Drop function type metadata only if we're going to replace it. by committing rL308642: LowerTypeTests: Drop function type metadata only if we're going to replace it..
Thu, Jul 20, 11:02 AM

Yesterday

pcc added a comment to D35639: [LTO] Prevent dead stripping and internalization of symbols with sections.
In D35639#815579, @pcc wrote:
In D35639#815234, @pcc wrote:

Another possibility is to handle this in the client (i.e. the linker) instead. The client has the best idea of whether a given section is a GC root; ELF linkers can set VisibleToRegularObj on any symbol in a section named like a C identifier, and other linkers can do whatever is appropriate for their object format.

I don't see how to get the presence of a section or the section name for a symbol when walking the symbols? I.e. either in gold-plugin via the symbol info from the linker, or in LTO::addModuleToGlobalRes via the InputFile:Symbol?

We'd need to add that information to the irsymtab and expose it via InputFile::Symbol.

That's what I was afraid of. =( That seems quite a bit more extensive than simply checking whether the GV has a section and blocking internalization.
If we were to go the route you are suggesting, it looks like currently we don't iterate through the InputFile until we invoke the LTO API, when adding a module. I guess we would have to then iterate through those and update the global resolutions earlier, e.g. in the gold-plugin? I.e. in order to make it ELF specific.

Wed, Jul 19, 8:02 PM
pcc added a comment to D35639: [LTO] Prevent dead stripping and internalization of symbols with sections.
In D35639#815234, @pcc wrote:

Another possibility is to handle this in the client (i.e. the linker) instead. The client has the best idea of whether a given section is a GC root; ELF linkers can set VisibleToRegularObj on any symbol in a section named like a C identifier, and other linkers can do whatever is appropriate for their object format.

I don't see how to get the presence of a section or the section name for a symbol when walking the symbols? I.e. either in gold-plugin via the symbol info from the linker, or in LTO::addModuleToGlobalRes via the InputFile:Symbol?

Wed, Jul 19, 7:19 PM
pcc accepted D35334: ThinLTO Minimized Bitcode File Size Reduction.

LGTM

Wed, Jul 19, 6:43 PM
pcc updated the diff for D35604: LowerTypeTests: Drop function type metadata only if we're going to replace it..
  • Address review comments
Wed, Jul 19, 5:11 PM
pcc added a comment to D35639: [LTO] Prevent dead stripping and internalization of symbols with sections.

Another possibility is to handle this in the client (i.e. the linker) instead. The client has the best idea of whether a given section is a GC root; ELF linkers can set VisibleToRegularObj on any symbol in a section named like a C identifier, and other linkers can do whatever is appropriate for their object format.

Wed, Jul 19, 2:44 PM
pcc added inline comments to D35604: LowerTypeTests: Drop function type metadata only if we're going to replace it..
Wed, Jul 19, 2:33 PM
pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Wed, Jul 19, 11:52 AM
pcc committed rL308504: LTO: Export functions referenced by the CFI jump table..
LTO: Export functions referenced by the CFI jump table.
Wed, Jul 19, 11:19 AM
pcc closed D35605: LTO: Export functions referenced by the CFI jump table. by committing rL308504: LTO: Export functions referenced by the CFI jump table..
Wed, Jul 19, 11:19 AM
pcc added inline comments to D35605: LTO: Export functions referenced by the CFI jump table..
Wed, Jul 19, 11:19 AM
pcc committed rL308500: ThinLTOBitcodeWriter: Do not rewrite intrinsic functions when splitting modules..
ThinLTOBitcodeWriter: Do not rewrite intrinsic functions when splitting modules.
Wed, Jul 19, 10:55 AM
pcc closed D35593: ThinLTOBitcodeWriter: Do not rewrite intrinsic functions when splitting modules. by committing rL308500: ThinLTOBitcodeWriter: Do not rewrite intrinsic functions when splitting modules..
Wed, Jul 19, 10:54 AM

Tue, Jul 18

pcc created D35605: LTO: Export functions referenced by the CFI jump table..
Tue, Jul 18, 7:41 PM
pcc created D35604: LowerTypeTests: Drop function type metadata only if we're going to replace it..
Tue, Jul 18, 7:34 PM
pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Tue, Jul 18, 5:54 PM
pcc created D35593: ThinLTOBitcodeWriter: Do not rewrite intrinsic functions when splitting modules..
Tue, Jul 18, 5:32 PM
pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Tue, Jul 18, 4:22 PM
pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Tue, Jul 18, 3:34 PM

Fri, Jul 14

pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Fri, Jul 14, 5:03 PM
pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Fri, Jul 14, 3:28 PM
pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Fri, Jul 14, 3:22 PM

Thu, Jul 13

pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Thu, Jul 13, 6:36 PM
pcc committed rL307984: ELF: Exclude dead symbols from -Map output..
ELF: Exclude dead symbols from -Map output.
Thu, Jul 13, 5:32 PM
pcc closed D35397: ELF: Exclude dead symbols from -Map output. by committing rL307984: ELF: Exclude dead symbols from -Map output..
Thu, Jul 13, 5:32 PM
pcc committed rL307983: ELF: Reword a somewhat misleading error message..
ELF: Reword a somewhat misleading error message.
Thu, Jul 13, 5:23 PM
pcc closed D35395: ELF: Reword a somewhat misleading error message. by committing rL307983: ELF: Reword a somewhat misleading error message..
Thu, Jul 13, 5:23 PM
pcc created D35397: ELF: Exclude dead symbols from -Map output..
Thu, Jul 13, 5:21 PM
pcc created D35395: ELF: Reword a somewhat misleading error message..
Thu, Jul 13, 5:13 PM
pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Thu, Jul 13, 4:36 PM
pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Thu, Jul 13, 11:02 AM

Wed, Jul 12

pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Wed, Jul 12, 8:39 PM
pcc added inline comments to D35334: ThinLTO Minimized Bitcode File Size Reduction.
Wed, Jul 12, 6:33 PM
pcc added a comment to D35334: ThinLTO Minimized Bitcode File Size Reduction.

Please add a test that shows that the thinlink files can be read by llvm-lto2.

Wed, Jul 12, 6:11 PM
pcc added a reviewer for D35334: ThinLTO Minimized Bitcode File Size Reduction: pcc.
Wed, Jul 12, 4:26 PM

Tue, Jul 11

pcc committed rL307744: LowerTypeTests: When importing functions skip definitions where the summary….
LowerTypeTests: When importing functions skip definitions where the summary…
Tue, Jul 11, 5:39 PM
pcc closed D35281: LowerTypeTests: When importing functions skip definitions where the summary contains a decl. by committing rL307744: LowerTypeTests: When importing functions skip definitions where the summary….
Tue, Jul 11, 5:39 PM
pcc created D35281: LowerTypeTests: When importing functions skip definitions where the summary contains a decl..
Tue, Jul 11, 5:21 PM

Mon, Jul 10

pcc added a comment to D35189: Add GUID-ValueID map and original name to ThinLTO summary..

the global VST (for the global values we will have in the index) does not.

Mon, Jul 10, 12:30 PM

Thu, Jul 6

pcc accepted D35094: Update Cross-DSO CFI documentation..

LGTM

Thu, Jul 6, 3:58 PM
pcc added inline comments to D35064: [lib/LTO] Fix the interaction between linker redefined symbols and ThinLTO.
Thu, Jul 6, 11:47 AM
pcc committed rL307286: Bitcode: Include any strings added to the string table in the module hash..
Bitcode: Include any strings added to the string table in the module hash.
Thu, Jul 6, 10:56 AM
pcc closed D35037: Bitcode: Include any strings added to the string table in the module hash. by committing rL307286: Bitcode: Include any strings added to the string table in the module hash..
Thu, Jul 6, 10:56 AM
pcc added inline comments to D35037: Bitcode: Include any strings added to the string table in the module hash..
Thu, Jul 6, 10:41 AM

Wed, Jul 5

pcc created D35037: Bitcode: Include any strings added to the string table in the module hash..
Wed, Jul 5, 3:38 PM
pcc added a comment to D34955: [Basic] Detect Git submodule version in CMake.

FYI, I don't think HEAD on its own will work because it is not necessarily updated on every commit, see discussion on D31985.

Wed, Jul 5, 1:30 PM

Fri, Jun 30

pcc edited reviewers for D34854: Allow GHC calling convention to use YMM and ZMM registers, added: RKSimon; removed: pcc.

Simon should probably review this change.

Fri, Jun 30, 1:35 PM
pcc accepted D34560: Completelly disable git/svn version checking if not needed.

LGTM

Fri, Jun 30, 11:03 AM

Tue, Jun 27

pcc committed rL306491: Add missing library dependency..
Add missing library dependency.
Tue, Jun 27, 5:05 PM
pcc committed rL306488: Object: Teach irsymtab::read() to try to use the irsymtab that we wrote to disk..
Object: Teach irsymtab::read() to try to use the irsymtab that we wrote to disk.
Tue, Jun 27, 4:50 PM
pcc committed rL306487: Bitcode: Write the irsymtab to disk..
Bitcode: Write the irsymtab to disk.
Tue, Jun 27, 4:50 PM
pcc closed D33974: Object: Teach irsymtab::read() to try to use the irsymtab that we wrote to disk. by committing rL306488: Object: Teach irsymtab::read() to try to use the irsymtab that we wrote to disk..
Tue, Jun 27, 4:50 PM
pcc committed rL306486: Object: Add version and producer fields to the irsymtab header. NFCI..
Object: Add version and producer fields to the irsymtab header. NFCI.
Tue, Jun 27, 4:50 PM
pcc closed D33973: Bitcode: Write the irsymtab to disk. by committing rL306487: Bitcode: Write the irsymtab to disk..
Tue, Jun 27, 4:50 PM
pcc closed D33972: Object: Add version and producer fields to the irsymtab header. NFCI. by committing rL306486: Object: Add version and producer fields to the irsymtab header. NFCI..
Tue, Jun 27, 4:50 PM
pcc added inline comments to D33974: Object: Teach irsymtab::read() to try to use the irsymtab that we wrote to disk..
Tue, Jun 27, 4:27 PM
pcc added inline comments to D33972: Object: Add version and producer fields to the irsymtab header. NFCI..
Tue, Jun 27, 3:54 PM
pcc updated the diff for D33974: Object: Teach irsymtab::read() to try to use the irsymtab that we wrote to disk..
  • Address review comments
Tue, Jun 27, 3:53 PM
pcc updated the diff for D33973: Bitcode: Write the irsymtab to disk..
  • Address review comments
Tue, Jun 27, 2:45 PM
pcc accepted D34644: Only test sanitizers that are built when COMPILER_RT_SANITIZERS_TO_BUILD is used.

As far as I'm aware, the feature exists both to save time building and testing sanitizers you don't need, and to get around differing build requirements across the sanitizers (it's possible, especially when cross-compiling, that some sanitizers build in a given configuration and others do not).

Tue, Jun 27, 11:23 AM
pcc added a comment to D34644: Only test sanitizers that are built when COMPILER_RT_SANITIZERS_TO_BUILD is used.

I don't understand why we have this COMPILER_RT_SANITIZERS_TO_BUILD feature, but given that we have it, this seems reasonable to me.

Tue, Jun 27, 10:57 AM

Mon, Jun 26

pcc added inline comments to D33974: Object: Teach irsymtab::read() to try to use the irsymtab that we wrote to disk..
Mon, Jun 26, 8:35 PM
pcc added inline comments to D33972: Object: Add version and producer fields to the irsymtab header. NFCI..
Mon, Jun 26, 7:58 PM
pcc added inline comments to D34450: bug33527 - Linker::LinkOnlyNeeded should import AppendingLinkage globals (release_40).
Mon, Jun 26, 9:53 AM

Fri, Jun 23

pcc committed rL306130: Fix a misleading indentation warning..
Fix a misleading indentation warning.
Fri, Jun 23, 10:18 AM
pcc added inline comments to D34547: Add a ThinLTO cache policy for controlling the maximum cache size in bytes..
Fri, Jun 23, 10:15 AM
pcc committed rL306129: Make the size specification for cache_size_bytes case insensitive..
Make the size specification for cache_size_bytes case insensitive.
Fri, Jun 23, 10:14 AM
pcc committed rL306128: Add parens for python3..
Add parens for python3.
Fri, Jun 23, 10:12 AM
pcc committed rL306126: Add a ThinLTO cache policy for controlling the maximum cache size in bytes..
Add a ThinLTO cache policy for controlling the maximum cache size in bytes.
Fri, Jun 23, 10:06 AM
pcc closed D34547: Add a ThinLTO cache policy for controlling the maximum cache size in bytes. by committing rL306126: Add a ThinLTO cache policy for controlling the maximum cache size in bytes..
Fri, Jun 23, 10:06 AM
pcc committed rL306125: docs: Add documentation for the ThinLTO cache pruning policy string..
docs: Add documentation for the ThinLTO cache pruning policy string.
Fri, Jun 23, 9:57 AM
pcc closed D34546: docs: Add documentation for the ThinLTO cache pruning policy string. by committing rL306125: docs: Add documentation for the ThinLTO cache pruning policy string..
Fri, Jun 23, 9:57 AM
pcc updated subscribers of D34560: Completelly disable git/svn version checking if not needed.

Using LLVM_APPEND_VC_REV seems fine to me, but we probably want to update the documentation and most likely change the default because right now the VC revision affects ThinLTO cache invalidation, and we shouldn't silently use stale cache entries when clang is upgraded.

Fri, Jun 23, 9:50 AM

Thu, Jun 22

pcc added inline comments to D34547: Add a ThinLTO cache policy for controlling the maximum cache size in bytes..
Thu, Jun 22, 10:23 PM
pcc added inline comments to D34546: docs: Add documentation for the ThinLTO cache pruning policy string..
Thu, Jun 22, 10:21 PM
pcc added a comment to D34547: Add a ThinLTO cache policy for controlling the maximum cache size in bytes..

Depends on D34546

Thu, Jun 22, 6:57 PM
pcc created D34547: Add a ThinLTO cache policy for controlling the maximum cache size in bytes..
Thu, Jun 22, 6:57 PM
pcc created D34546: docs: Add documentation for the ThinLTO cache pruning policy string..
Thu, Jun 22, 6:56 PM

Wed, Jun 21

pcc committed rL305954: ELF: Don't dereference Repl in MarkLive. NFCI..
ELF: Don't dereference Repl in MarkLive. NFCI.
Wed, Jun 21, 2:30 PM
pcc closed D34465: ELF: Don't dereference Repl in MarkLive. NFCI. by committing rL305954: ELF: Don't dereference Repl in MarkLive. NFCI..
Wed, Jun 21, 2:30 PM
pcc committed rL305937: Object: Have the irsymtab builder take a string table builder. NFCI..
Object: Have the irsymtab builder take a string table builder. NFCI.
Wed, Jun 21, 11:24 AM
pcc closed D33971: Object: Have the irsymtab builder take a string table builder. NFCI. by committing rL305937: Object: Have the irsymtab builder take a string table builder. NFCI..
Wed, Jun 21, 11:24 AM
pcc created D34465: ELF: Don't dereference Repl in MarkLive. NFCI..
Wed, Jun 21, 10:56 AM
pcc added a comment to D34459: [ELF] Better handling of _GLOBAL_OFFSET_TABLE_.

Peter, I tried doing this, but it forces dynamic reloc to .Label, which can reside in RO section.

Wed, Jun 21, 10:51 AM · lld
pcc added inline comments to D34459: [ELF] Better handling of _GLOBAL_OFFSET_TABLE_.
Wed, Jun 21, 10:47 AM · lld

Tue, Jun 20

pcc added inline comments to D33971: Object: Have the irsymtab builder take a string table builder. NFCI..
Tue, Jun 20, 9:54 PM

Jun 19 2017

pcc created D34376: git-llvm: Add a svn2git command..
Jun 19 2017, 6:14 PM
pcc committed rL305741: Revert r305598, "utils: Add a git-r utility for mapping svn revisions to git….
Revert r305598, "utils: Add a git-r utility for mapping svn revisions to git…
Jun 19 2017, 1:43 PM

Jun 16 2017

pcc updated subscribers of D31437: AMDGPU/NFC: Move amdgpu code object metadata to support.

I think @eugenis fixed this in r305584.

Jun 16 2017, 5:35 PM
pcc committed rL305598: utils: Add a git-r utility for mapping svn revisions to git revisions in the….
utils: Add a git-r utility for mapping svn revisions to git revisions in the…
Jun 16 2017, 3:16 PM

Jun 15 2017

pcc accepted D34261: [cfi] Enable icall tests with thinlto..

LGTM

Jun 15 2017, 5:14 PM
pcc added a comment to D34168: [cfi] CFI-ICall for ThinLTO..

Still LGTM

Jun 15 2017, 5:05 PM
pcc committed rL305485: Silence warning with assertions disabled..
Silence warning with assertions disabled.
Jun 15 2017, 10:42 AM
pcc accepted D34156: [LTO] Enable module summary emission by default for regular LTO.

Please confirm that we can still self host with full LTO now that D33922 has landed.

Jun 15 2017, 10:38 AM
pcc added inline comments to D34168: [cfi] CFI-ICall for ThinLTO..
Jun 15 2017, 10:30 AM
pcc committed rL305482: Apply summary-based dead stripping to regular LTO modules with summaries..
Apply summary-based dead stripping to regular LTO modules with summaries.
Jun 15 2017, 10:27 AM
pcc closed D33922: Apply summary-based dead stripping to regular LTO modules with summaries. by committing rL305482: Apply summary-based dead stripping to regular LTO modules with summaries..
Jun 15 2017, 10:26 AM