#
c3b2e80b |
| 24-Aug-2016 |
Matthias Braun <matze@braunis.de> |
MachineModuleInfo: Avoid dummy constructor, use INITIALIZE_TM_PASS
Change this pass constructor to just accept a const TargetMachine * and use INITIALIZE_TM_PASS, that way we can get rid of the dumm
MachineModuleInfo: Avoid dummy constructor, use INITIALIZE_TM_PASS
Change this pass constructor to just accept a const TargetMachine * and use INITIALIZE_TM_PASS, that way we can get rid of the dummy constructor. The pass will still fail when calling the default constructor leading to TM == nullptr, this is no different than before but is more in line what other codegen passes are doing and avoids the dummy constructor.
llvm-svn: 279598
show more ...
|
#
8c3fbdc6 |
| 23-Aug-2016 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Revert r279564. It introduces undefined behavior (binding a reference to a dereferenced null pointer) in MachineModuleInfo::MachineModuleInfo that causes -Werror builds (including several buildbots)
Revert r279564. It introduces undefined behavior (binding a reference to a dereferenced null pointer) in MachineModuleInfo::MachineModuleInfo that causes -Werror builds (including several buildbots) to fail.
llvm-svn: 279580
show more ...
|
#
4c1f1f12 |
| 23-Aug-2016 |
Matthias Braun <matze@braunis.de> |
CodeGen: Remove MachineFunctionAnalysis => Enable (Machine)ModulePasses
Re-apply this commit with the deletion of a MachineFunction delegated to a separate pass to avoid use after free when doing th
CodeGen: Remove MachineFunctionAnalysis => Enable (Machine)ModulePasses
Re-apply this commit with the deletion of a MachineFunction delegated to a separate pass to avoid use after free when doing this directly in AsmPrinter.
This patch removes the MachineFunctionAnalysis. Instead we keep a map from IR Function to MachineFunction in the MachineModuleInfo.
This allows the insertion of ModulePasses into the codegen pipeline without breaking it because the MachineFunctionAnalysis gets dropped before a module pass.
Peak memory should stay unchanged without a ModulePass in the codegen pipeline: Previously the MachineFunction was freed at the end of a codegen function pipeline because the MachineFunctionAnalysis was dropped; With this patch the MachineFunction is freed after the AsmPrinter has finished.
Differential Revision: http://reviews.llvm.org/D23736
llvm-svn: 279564
show more ...
|
#
7f66202d |
| 23-Aug-2016 |
Matthias Braun <matze@braunis.de> |
Revert "(HEAD -> master, origin/master, origin/HEAD) CodeGen: Remove MachineFunctionAnalysis => Enable (Machine)ModulePasses"
Reverting while tracking down a use after free.
This reverts commit r27
Revert "(HEAD -> master, origin/master, origin/HEAD) CodeGen: Remove MachineFunctionAnalysis => Enable (Machine)ModulePasses"
Reverting while tracking down a use after free.
This reverts commit r279502.
llvm-svn: 279503
show more ...
|
#
fd936841 |
| 23-Aug-2016 |
Matthias Braun <matze@braunis.de> |
CodeGen: Remove MachineFunctionAnalysis => Enable (Machine)ModulePasses
This patch removes the MachineFunctionAnalysis. Instead we keep a map from IR Function to MachineFunction in the MachineModule
CodeGen: Remove MachineFunctionAnalysis => Enable (Machine)ModulePasses
This patch removes the MachineFunctionAnalysis. Instead we keep a map from IR Function to MachineFunction in the MachineModuleInfo.
This allows the insertion of ModulePasses into the codegen pipeline without breaking it because the MachineFunctionAnalysis gets dropped before a module pass.
Peak memory should stay unchanged without a ModulePass in the codegen pipeline: Previously the MachineFunction was freed at the end of a codegen function pipeline because the MachineFunctionAnalysis was dropped; With this patch the MachineFunction is freed after the AsmPrinter has finished.
Differential Revision: http://reviews.llvm.org/D23736
llvm-svn: 279502
show more ...
|
Revision tags: llvmorg-3.9.0-rc2, llvmorg-3.9.0-rc1, llvmorg-3.8.1, llvmorg-3.8.1-rc1, llvmorg-3.8.0, llvmorg-3.8.0-rc3 |
|
#
7a083814 |
| 18-Feb-2016 |
Richard Trieu <rtrieu@google.com> |
Remove uses of builtin comma operator.
Cleanup for upcoming Clang warning -Wcomma. No functionality change intended.
llvm-svn: 261270
|
Revision tags: llvmorg-3.8.0-rc2, llvmorg-3.8.0-rc1 |
|
#
70497c69 |
| 02-Dec-2015 |
David Majnemer <david.majnemer@gmail.com> |
Move EH-specific helper functions to a more appropriate place
No functionality change is intended.
llvm-svn: 254562
|
Revision tags: llvmorg-3.7.1, llvmorg-3.7.1-rc2 |
|
#
c20276d0 |
| 17-Nov-2015 |
Reid Kleckner <rnk@google.com> |
[WinEH] Move WinEHFuncInfo from MachineModuleInfo to MachineFunction
Summary: Now that there is a one-to-one mapping from MachineFunction to WinEHFuncInfo, we don't need to use a DenseMap to select
[WinEH] Move WinEHFuncInfo from MachineModuleInfo to MachineFunction
Summary: Now that there is a one-to-one mapping from MachineFunction to WinEHFuncInfo, we don't need to use a DenseMap to select the right WinEHFuncInfo for the current funclet.
The main challenge here is that X86WinEHStatePass is an IR pass that doesn't have access to the MachineFunction. I gave it its own WinEHFuncInfo object that it uses to calculate state numbers, which it then throws away. As long as nobody creates or removes EH pads between this pass and SDAG construction, we will get the same state numbers.
The other thing X86WinEHStatePass does is to mark the EH registration node. Instead of communicating which alloca was the registration through WinEHFuncInfo, I added the llvm.x86.seh.ehregnode intrinsic. This intrinsic generates no code and simply marks the alloca in use.
Reviewers: JCTremoulet
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D14668
llvm-svn: 253378
show more ...
|
Revision tags: llvmorg-3.7.1-rc1 |
|
#
bfa5b982 |
| 10-Oct-2015 |
David Majnemer <david.majnemer@gmail.com> |
[WinEH] Remove more dead code
wineh-parent is dead, so is ValueOrMBB.
llvm-svn: 249920
|
#
e00faf8c |
| 31-Aug-2015 |
Reid Kleckner <rnk@google.com> |
[EH] Handle non-Function personalities like unknown personalities
Also delete and simplify a lot of MachineModuleInfo code that used to be needed to handle personalities on landingpads. Now that th
[EH] Handle non-Function personalities like unknown personalities
Also delete and simplify a lot of MachineModuleInfo code that used to be needed to handle personalities on landingpads. Now that the personality is on the LLVM Function, we no longer need to track it this way on MMI. Certainly it should not live on LandingPadInfo.
llvm-svn: 246478
show more ...
|
#
0e288234 |
| 27-Aug-2015 |
Reid Kleckner <rnk@google.com> |
[WinEH] Add some support for code generating catchpad
We can now run 32-bit programs with empty catch bodies. The next step is to change PEI so that we get funclet prologues and epilogues.
llvm-sv
[WinEH] Add some support for code generating catchpad
We can now run 32-bit programs with empty catch bodies. The next step is to change PEI so that we get funclet prologues and epilogues.
llvm-svn: 246235
show more ...
|
Revision tags: llvmorg-3.7.0, llvmorg-3.7.0-rc4, llvmorg-3.7.0-rc3, studio-1.4 |
|
#
774b584f |
| 03-Aug-2015 |
David Blaikie <dblaikie@gmail.com> |
-Wdeprecated-clean: Fix cases of violating the rule of 5 in ways that are deprecated in C++11
Various value handles needed to be copy constructible and copy assignable (mostly for their use in Dense
-Wdeprecated-clean: Fix cases of violating the rule of 5 in ways that are deprecated in C++11
Various value handles needed to be copy constructible and copy assignable (mostly for their use in DenseMap). But to avoid an API that might allow accidental slicing, make these members protected in the base class and make derived classes final (the special members become implicitly public there - but disallowing further derived classes that might be sliced to the intermediate type).
Might be worth having a warning a bit like -Wnon-virtual-dtor that catches public move/copy assign/ctors in classes with virtual functions. (suppressable in the same way - by making them protected in the base, and making the derived classes final) Could be fancier and only diagnose them when they're actually called, potentially.
Also allow a few default implementations where custom implementations (especially with non-standard return types) were implemented.
llvm-svn: 243909
show more ...
|
Revision tags: llvmorg-3.7.0-rc2, llvmorg-3.7.0-rc1 |
|
#
aff703a2 |
| 14-Jul-2015 |
Keno Fischer <kfischer@college.harvard.edu> |
[CodeGen] Force emission of personality directive if explicitly specified
Summary: Before this change, personality directives were not emitted if there was no invoke left in the function (of course
[CodeGen] Force emission of personality directive if explicitly specified
Summary: Before this change, personality directives were not emitted if there was no invoke left in the function (of course until recently this also meant that we couldn't know what the personality actually was). This patch forces personality directives to still be emitted, unless it is known to be a noop in the absence of invokes, or the user explicitly specified `nounwind` (and not `uwtable`) on the function.
Reviewers: majnemer, rnk
Subscribers: rnk, llvm-commits
Differential Revision: http://reviews.llvm.org/D10884
llvm-svn: 242185
show more ...
|
#
5dbf346c |
| 03-Jul-2015 |
Yaron Keren <yaron.keren@gmail.com> |
Initialize booleans CallsUnwindInit and CallsEHReturn with false instead of 0.
llvm-svn: 241324
|
#
6fe4e793 |
| 29-Jun-2015 |
Benjamin Kramer <benny.kra@googlemail.com> |
[MMI] Use TinyPtrVector instead of PointerUnion with vector.
Also simplify duplicated code a bit. No functionality change intended.
llvm-svn: 240990
|
Revision tags: llvmorg-3.6.2, llvmorg-3.6.2-rc1 |
|
#
f00654e3 |
| 23-Jun-2015 |
Alexander Kornienko <alexfh@google.com> |
Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC)
Apparently, the style needs to be agreed upon first.
llvm-svn: 240390
|
#
70bc5f13 |
| 19-Jun-2015 |
Alexander Kornienko <alexfh@google.com> |
Fixed/added namespace ending comments using clang-tidy. NFC
The patch is generated using this command:
tools/clang/tools/extra/clang-tidy/tool/run-clang-tidy.py -fix \ -checks=-*,llvm-namespace-c
Fixed/added namespace ending comments using clang-tidy. NFC
The patch is generated using this command:
tools/clang/tools/extra/clang-tidy/tool/run-clang-tidy.py -fix \ -checks=-*,llvm-namespace-comment -header-filter='llvm/.*|clang/.*' \ llvm/lib/
Thanks to Eugene Kosov for the original patch!
llvm-svn: 240137
show more ...
|
#
7cbe58d3 |
| 11-Jun-2015 |
Pete Cooper <peter_cooper@apple.com> |
Remove MachineModuleInfo::UsedFunctions as it has no users.
It hasn't been used since r130964.
This also removes MachineModuleInfo::isUsedFunction and MachineModuleInfo::AnalyzeModule, both of whic
Remove MachineModuleInfo::UsedFunctions as it has no users.
It hasn't been used since r130964.
This also removes MachineModuleInfo::isUsedFunction and MachineModuleInfo::AnalyzeModule, both of which were only there to support UsedFunctions.
llvm-svn: 239501
show more ...
|
#
f5e2fc47 |
| 29-May-2015 |
Benjamin Kramer <benny.kra@googlemail.com> |
Replace push_back(Constructor(foo)) with emplace_back(foo) for non-trivial types
If the type isn't trivially moveable emplace can skip a potentially expensive move. It also saves a couple of charact
Replace push_back(Constructor(foo)) with emplace_back(foo) for non-trivial types
If the type isn't trivially moveable emplace can skip a potentially expensive move. It also saves a couple of characters.
Call sites were found with the ASTMatcher + some semi-automated cleanup.
memberCallExpr( argumentCountIs(1), callee(methodDecl(hasName("push_back"))), on(hasType(recordDecl(has(namedDecl(hasName("emplace_back")))))), hasArgument(0, bindTemporaryExpr( hasType(recordDecl(hasNonTrivialDestructor())), has(constructExpr()))), unless(isInTemplateInstantiation()))
No functional change intended.
llvm-svn: 238602
show more ...
|
#
1d3d4adb |
| 29-May-2015 |
Reid Kleckner <reid@kleckner.net> |
[WinEH] Emit EH tables for __CxxFrameHandler3 on 32-bit x86
Small (really small!) C++ exception handling examples work on 32-bit x86 now.
This change disables the use of .seh_* directives in WinExc
[WinEH] Emit EH tables for __CxxFrameHandler3 on 32-bit x86
Small (really small!) C++ exception handling examples work on 32-bit x86 now.
This change disables the use of .seh_* directives in WinException when CFI is not in use. It also uses absolute symbol references in the tables instead of imagerel32 relocations.
Also fixes a cache invalidation bug in MMI personality classification.
llvm-svn: 238575
show more ...
|
#
6f482000 |
| 18-May-2015 |
Jim Grosbach <grosbach@apple.com> |
MC: Clean up method names in MCContext.
The naming was a mish-mash of old and new style. Update to be consistent with the new. NFC.
llvm-svn: 237594
|
Revision tags: llvmorg-3.6.1, llvmorg-3.6.1-rc1 |
|
#
5c5facc2 |
| 23-Apr-2015 |
Reid Kleckner <reid@kleckner.net> |
Re-commit "[SEH] Remove the old __C_specific_handler code now that WinEHPrepare works"
This reverts commit r235617.
r235649 should have addressed the problems.
llvm-svn: 235667
|
#
909ea7e6 |
| 23-Apr-2015 |
Reid Kleckner <reid@kleckner.net> |
Revert "[SEH] Remove the old __C_specific_handler code now that WinEHPrepare works"
We still have some "uses remain after removal" issues in -O0 builds.
This reverts commit r235557.
llvm-svn: 2356
Revert "[SEH] Remove the old __C_specific_handler code now that WinEHPrepare works"
We still have some "uses remain after removal" issues in -O0 builds.
This reverts commit r235557.
llvm-svn: 235617
show more ...
|
#
64a2a6a4 |
| 22-Apr-2015 |
Reid Kleckner <reid@kleckner.net> |
[SEH] Remove the old __C_specific_handler code now that WinEHPrepare works
This removes the -sehprepare flag and makes __C_specific_handler functions always to use WinEHPrepare.
This was tested by
[SEH] Remove the old __C_specific_handler code now that WinEHPrepare works
This removes the -sehprepare flag and makes __C_specific_handler functions always to use WinEHPrepare.
This was tested by building all of chromium_builder_tests and running a few tests that use SEH, but if something breaks, we can revert this.
llvm-svn: 235557
show more ...
|
#
d2a1a519 |
| 21-Apr-2015 |
Reid Kleckner <reid@kleckner.net> |
Re-land r235154-r235156 under the existing -sehprepare flag
Keep the old SEH fan-in lowering on by default for now, since projects rely on it. This will make it easy to test this change with a simp
Re-land r235154-r235156 under the existing -sehprepare flag
Keep the old SEH fan-in lowering on by default for now, since projects rely on it. This will make it easy to test this change with a simple flag flip.
llvm-svn: 235399
show more ...
|