diff options
author | Paul Robinson <paul.robinson@sony.com> | 2018-11-19 18:29:28 +0000 |
---|---|---|
committer | Paul Robinson <paul.robinson@sony.com> | 2018-11-19 18:29:28 +0000 |
commit | cda5421016f67236f60bbc1ba9e4e847e6dbeb71 (patch) | |
tree | 4bd81caf1ef021ef98f84e73e902845b359170c4 /llvm/unittests/Transforms/Utils/CloningTest.cpp | |
parent | 1c803f5988af77cc2d1d4ca12b9b4a3e1a094c35 (diff) | |
download | bcm5719-llvm-cda5421016f67236f60bbc1ba9e4e847e6dbeb71.tar.gz bcm5719-llvm-cda5421016f67236f60bbc1ba9e4e847e6dbeb71.zip |
[DebugInfo] DISubprogram flags get their own flags word. NFC.
This will hold flags specific to subprograms. In the future
we could potentially free up scarce bits in DIFlags by moving
subprogram-specific flags from there to the new flags word.
This patch does not change IR/bitcode formats, that will be
done in a follow-up.
Differential Revision: https://reviews.llvm.org/D54597
llvm-svn: 347239
Diffstat (limited to 'llvm/unittests/Transforms/Utils/CloningTest.cpp')
-rw-r--r-- | llvm/unittests/Transforms/Utils/CloningTest.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/llvm/unittests/Transforms/Utils/CloningTest.cpp b/llvm/unittests/Transforms/Utils/CloningTest.cpp index 051e3cd6235..9d6bf0a5a96 100644 --- a/llvm/unittests/Transforms/Utils/CloningTest.cpp +++ b/llvm/unittests/Transforms/Utils/CloningTest.cpp @@ -391,9 +391,9 @@ protected: "/file/dir"), "CloneFunc", false, "", 0); - auto *Subprogram = - DBuilder.createFunction(CU, "f", "f", File, 4, FuncType, true, true, 3, - DINode::FlagZero, false); + auto *Subprogram = DBuilder.createFunction( + CU, "f", "f", File, 4, FuncType, 3, DINode::FlagZero, + DISubprogram::SPFlagLocalToUnit | DISubprogram::SPFlagDefinition); OldFunc->setSubprogram(Subprogram); // Function body @@ -421,9 +421,9 @@ protected: auto *StructType = DICompositeType::getDistinct( C, dwarf::DW_TAG_structure_type, "some_struct", nullptr, 0, nullptr, nullptr, 32, 32, 0, DINode::FlagZero, nullptr, 0, nullptr, nullptr); - auto *InlinedSP = - DBuilder.createFunction(CU, "inlined", "inlined", File, 8, FuncType, - true, true, 9, DINode::FlagZero, false); + auto *InlinedSP = DBuilder.createFunction( + CU, "inlined", "inlined", File, 8, FuncType, 9, DINode::FlagZero, + DISubprogram::SPFlagLocalToUnit | DISubprogram::SPFlagDefinition); auto *InlinedVar = DBuilder.createAutoVariable(InlinedSP, "inlined", File, 5, StructType, true); auto *Scope = DBuilder.createLexicalBlock( @@ -606,9 +606,9 @@ protected: "/file/dir"), "CloneModule", false, "", 0); // Function DI - auto *Subprogram = - DBuilder.createFunction(CU, "f", "f", File, 4, DFuncType, true, true, 3, - DINode::FlagZero, false); + auto *Subprogram = DBuilder.createFunction( + CU, "f", "f", File, 4, DFuncType, 3, DINode::FlagZero, + DISubprogram::SPFlagLocalToUnit | DISubprogram::SPFlagDefinition); F->setSubprogram(Subprogram); // Create and assign DIGlobalVariableExpression to gv |