Skip to content
This repository was archived by the owner on Feb 5, 2019. It is now read-only.

Commit ae43eea

Browse files
committed
Add the "no-split-stack" attribute
This disable emission of segmented-stack prologues on a per-function basis, even if segmented stacks are turned on globally.
1 parent 12c9f92 commit ae43eea

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/CodeGen/PrologEpilogInserter.cpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -680,7 +680,8 @@ void PEI::insertPrologEpilogCode(MachineFunction &Fn) {
680680
// we've been asked for it. This, when linked with a runtime with support
681681
// for segmented stacks (libgcc is one), will result in allocating stack
682682
// space in small chunks instead of one large contiguous block.
683-
if (Fn.getTarget().Options.EnableSegmentedStacks)
683+
if (Fn.getTarget().Options.EnableSegmentedStacks &&
684+
!Fn.getFunction()->hasFnAttribute("no-split-stack"))
684685
TFI.adjustForSegmentedStacks(Fn);
685686

686687
// Emit additional code that is required to explicitly handle the stack in

0 commit comments

Comments
 (0)