This patch is part of supporting -fstack-clash-protection. Implemented probing when emitting prologue.
Details
- Reviewers
hfinkel jonpa serge-sans-paille nemanjai sfertile jsji - Group Reviewers
Restricted Project - Commits
- rGc352e0885a6b: [PowerPC] Implement probing for prologue
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Event Timeline
llvm/lib/Target/PowerPC/PPCFrameLowering.cpp | ||
---|---|---|
679 | We are in prologue, there shouldn't be any use of cr before this, why can't we simply always use CR0 here? | |
1030–1040 | Can we add comments about free probe? | |
1032 | Add comment about why we need this pseudo? and when it will be handled. | |
1372 | Where -> StackAllocAIPos ? | |
1407 | Comments/code mismatch? We are generating RLDICL/RLWINM below, please add comments about the calculation as well.. | |
1437 | What if we can't find CR and we don't build with assert on? | |
1446 | There are several instance of similar code, maybe worth a NFC refactor first. | |
1459 | We have to check. and do Residual block regardless of NumBlocks, please move it out of if/else. | |
1468 | Shall we recomputeLiveIns for both LoopMBB and ExitBB? |
Address @jsji 's comments.
Use CTR loop to synthesize probe loop so that we can use a GPR to materialize large probe size.
clang-format: please reformat the code