Page MenuHomePhabricator

Add opaque Handle infrastructure
Needs ReviewPublic

Authored by nhaehnle on Dec 9 2020, 2:44 AM.
This revision needs review, but there are no reviewers specified.

Details

Reviewers
None
Summary

This infrastructure is a foundation for writing some algorithms
generically without resorting to templates, by treating "references"
(usually pointers) to objects such as basic blocks as opaque handles.

Subsequent changes will add more mechanisms to facilitate working with
such handles, and introduce type-erased base classes in some places
(e.g. dominator trees) in terms of handles.

Change-Id: I79e69589e972e97335189f9558ebe44c7b00771b

Diff Detail

Unit TestsFailed

TimeTest
370 msx64 debian > HWAddressSanitizer-x86_64.TestCases::sizes.cpp
Script: -- : 'RUN: at line 3'; /mnt/disks/ssd0/agent/llvm-project/build/./bin/clang --driver-mode=g++ -m64 -gline-tables-only -fsanitize=hwaddress -fuse-ld=lld -mcmodel=large -mllvm -hwasan-globals -mllvm -hwasan-use-short-granules -mllvm -hwasan-instrument-landing-pads=0 -mllvm -hwasan-instrument-personality-functions /mnt/disks/ssd0/agent/llvm-project/compiler-rt/test/hwasan/TestCases/sizes.cpp -nostdlib++ -lstdc++ -o /mnt/disks/ssd0/agent/llvm-project/build/projects/compiler-rt/test/hwasan/X86_64/TestCases/Output/sizes.cpp.tmp
350 msx64 windows > lld.ELF/invalid::symtab-sh-info.s
Script: -- : 'RUN: at line 4'; c:\ws\w16n2-1\llvm-project\premerge-checks\build\bin\yaml2obj.exe --docnum=1 C:\ws\w16n2-1\llvm-project\premerge-checks\lld\test\ELF\invalid\symtab-sh-info.s -o C:\ws\w16n2-1\llvm-project\premerge-checks\build\tools\lld\test\ELF\invalid\Output\symtab-sh-info.s.tmp.o

Event Timeline

nhaehnle created this revision.Dec 9 2020, 2:44 AM
nhaehnle requested review of this revision.Dec 9 2020, 2:44 AM
Herald added a project: Restricted Project. · View Herald TranscriptDec 9 2020, 2:44 AM
nhaehnle updated this revision to Diff 310530.Dec 9 2020, 7:24 AM

Remove HandleWrapperFor which got de facto superseded by SsaContext
(subsequent patch). Update comment slightly to match.