Invention Grant
- Patent Title: Memory management for closures
- Patent Title (中): 关闭内存管理
-
Application No.: US12242519Application Date: 2008-09-30
-
Publication No.: US08341614B2Publication Date: 2012-12-25
- Inventor: Gerald Blaine Garst, Jr. , William Bumgarner , Fariborz Jahanian , Christopher Arthur Lattner
- Applicant: Gerald Blaine Garst, Jr. , William Bumgarner , Fariborz Jahanian , Christopher Arthur Lattner
- Applicant Address: US CA Cupertino
- Assignee: Apple Inc.
- Current Assignee: Apple Inc.
- Current Assignee Address: US CA Cupertino
- Agency: Blakely, Sokoloff, Taylor & Zafman LLP
- Main IPC: G06F9/45
- IPC: G06F9/45

Abstract:
Methods, software media, compilers and programming techniques are described for creating copyable stack-based closures, such as a block, for languages which allocate automatic or local variables on a stack memory structure. In one exemplary method, a data structure of the block is first written to the stack memory structure, and this may be the automatic default operation, at run-time, for the block; then, a block copy instruction, added explicitly (in one embodiment) by a programmer during creation of the block, is executed to copy the block to a heap memory structure. The block includes a function pointer that references a function which uses data in the block.
Public/Granted literature
- US20090307431A1 MEMORY MANAGEMENT FOR CLOSURES Public/Granted day:2009-12-10
Information query