On ARM (contrary to both x86 and ARM64), this function is available for linking in from kernel32.dll, but it's not allowed to link that function from there in Windows Store apps.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
Microsoft's implementation also checks the stack allocation against the thread's stack limit. Do you care about doing that?
LGTM otherwise, but I'd prefer to wait for @compnerd to take a look. (He's on vacation this week, but he'll be back next week.)
lib/builtins/arm/chkstk.S | ||
---|---|---|
10 ↗ | (On Diff #154503) | It also clobbers the condition codes. We were bitten by this before; see https://reviews.llvm.org/rL311061. |
Comment Actions
That might be neat to do, but we don't do that in the existing implementations of __chkstk* for x86, nor in the aarch64 version I wrote a few months ago (where I justified it to myself with the same reason; it hasn't been done for x86 yet either).
lib/builtins/arm/chkstk.S | ||
---|---|---|
10 ↗ | (On Diff #154503) | Good catch, I'll amend the comment for clarity. |