[PATCH][llvm-c] Create Memory Buffer with memory ranges
Bill Wendling
wendling at apple.com
Wed Feb 13 13:25:56 PST 2013
On Feb 13, 2013, at 11:33 AM, Moritz Maxeiner <moritzmaxeiner at googlemail.com> wrote:
> On 2/13/2013 7:55 PM, Chris Lattner wrote:
>>
>> On Feb 13, 2013, at 3:59 AM, Moritz Maxeiner <moritzmaxeiner at googlemail.com> wrote:
>>
>>> On 2/13/2013 5:46 AM, Chris Lattner wrote:
>>>> On Feb 10, 2013, at 9:13 AM, Moritz Maxeiner <moritzmaxeiner at googlemail.com> wrote:
>>>>
>>>>> Add two new functions to the C API:
>>>>>
>>>>> LLVMCreateMemoryBufferWithMemoryRange - exposes MemoryBuffer::getMemBuffer
>>>>> LLVMCreateMemoryBufferWithMemoryRangeCopy - exposes MemoryBuffer::getMemBufferCopy
>>>> These new APIs should take a "const char*" + length. The memory buffer may have embedded nul's in it.
>>>
>>> Of course, my bad. I assume the BufferName may not contain nuls, so I added the lengths only for the
>>> InputData, if that is not the case - i.e. the BufferName may contain nuls - I'll change that as well.
>>
>> LGTM!
>>
>> -Chris
>>
>
> Awesome!
> So... anything else that I need to/should/can do to get this committed?
> "Developer Policy" - "Making a Patch" more or less only states that commits have to be reviewed before committing them,
> not really who I should talk to for the actual committing.
> Also, will this require a test-case? The developer policy does state that every new feature needs a test-case,
> but technically this is just wrapping existing C++ calls to C calls, so not really a new feature for LLVM per se, only
> for the C API.
>
Hi Moritz,
Once you get approval, you can commit the patch. If you do have tests (or can think up tests) for this feature, please submit them with the patch. I believe that tests can go in after you get general approval.
Lastly, if you don't have commit access you can ask someone who does to commit it for you. :)
-bw
More information about the llvm-commits
mailing list