[LLVMdev] Named Register Implementation
Krzysztof Parzyszek
kparzysz at codeaurora.org
Fri Mar 28 08:56:07 PDT 2014
On 3/28/2014 10:00 AM, Renato Golin wrote:
>
> define i32 @get_stack_pointer_addr() nounwind {
> entry:
> %0 = call i32 @llvm.read_register("sp")
> ret i32 %0
> }
>
> define void @set_stack_pointer_addr(i32 %addr) nounwind {
> entry:
> call void @llvm.write_register("sp", %addr)
> ret void
> }
How are you going to represent the side-effects of such builtins?
-K
--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
hosted by The Linux Foundation
More information about the llvm-dev
mailing list