search for: current_stack_point

Displaying 12 results from an estimated 12 matches for "current_stack_point".

Did you mean: current_stack_pointer
2013 Oct 10
0
[LLVMdev] A new builtin: __builtin_stack_pointer()
....com> wrote: > One of the issues the LLVMLinux project is having is with the use of > named registers in the Linux kernel code. The kernel uses something like > this in order to assign a C variable name to a register (one for each > kernel arch). > > register unsigned long current_stack_pointer asm("esp"); > > clang doesn't allow this kind of thing which required a patch which less > efficient: > > #define current_stack_pointer ({ \ > unsigned long esp; \ > asm("mov %%esp, %0" : "=r"(esp)); \ > esp; \ > })...
2013 Oct 10
3
[LLVMdev] A new builtin: __builtin_stack_pointer()
One of the issues the LLVMLinux project is having is with the use of named registers in the Linux kernel code. The kernel uses something like this in order to assign a C variable name to a register (one for each kernel arch). register unsigned long current_stack_pointer asm("esp"); clang doesn't allow this kind of thing which required a patch which less efficient: #define current_stack_pointer ({ \ unsigned long esp; \ asm("mov %%esp, %0" : "=r"(esp)); \ esp; \ }) This works for both gcc and clang, but of...
2013 Nov 05
2
[LLVMdev] A new builtin: __builtin_stack_pointer()
...ne of the issues the LLVMLinux project is having is with the use of >>  named registers in the Linux kernel code. The kernel uses something like >>  this in order to assign a C variable name to a register (one for each >>  kernel arch). >> >>     register unsigned long current_stack_pointer asm("esp"); >> >>  clang doesn't allow this kind of thing which required a patch which less >>  efficient: >> >>  #define current_stack_pointer ({ \ >>        unsigned long esp; \ >>        asm("mov %%esp, %0" : "=r"(esp)...
2013 Oct 20
2
[LLVMdev] A new builtin: __builtin_stack_pointer()
...t; One of the issues the LLVMLinux project is having is with the use of >> named registers in the Linux kernel code. The kernel uses something like >> this in order to assign a C variable name to a register (one for each >> kernel arch). >> >> register unsigned long current_stack_pointer asm("esp"); >> >> clang doesn't allow this kind of thing which required a patch which less >> efficient: >> >> #define current_stack_pointer ({ \ >> unsigned long esp; \ >> asm("mov %%esp, %0" : "=r"(esp)); \...
2013 Nov 05
2
[LLVMdev] A new builtin: __builtin_stack_pointer()
...t is having is with the use of >>>> named registers in the Linux kernel code. The kernel uses something like >>>> this in order to assign a C variable name to a register (one for each >>>> kernel arch). >>>> >>>> register unsigned long current_stack_pointer asm("esp"); >>>> >>>> clang doesn't allow this kind of thing which required a patch which less >>>> efficient: >>>> >>>> #define current_stack_pointer ({ \ >>>> unsigned long esp; \ >>>>...
2013 Nov 05
0
[LLVMdev] A new builtin: __builtin_stack_pointer()
...LLVMLinux project is having is with the use of >>> named registers in the Linux kernel code. The kernel uses something like >>> this in order to assign a C variable name to a register (one for each >>> kernel arch). >>> >>> register unsigned long current_stack_pointer asm("esp"); >>> >>> clang doesn't allow this kind of thing which required a patch which less >>> efficient: >>> >>> #define current_stack_pointer ({ \ >>> unsigned long esp; \ >>> asm("mov %%esp, %0...
2013 Nov 05
0
[LLVMdev] A new builtin: __builtin_stack_pointer()
...the LLVMLinux project is having is with the use of >>> named registers in the Linux kernel code. The kernel uses something like >>> this in order to assign a C variable name to a register (one for each >>> kernel arch). >>> >>> register unsigned long current_stack_pointer asm("esp"); >>> >>> clang doesn't allow this kind of thing which required a patch which less >>> efficient: >>> >>> #define current_stack_pointer ({ \ >>> unsigned long esp; \ >>> asm("mov %%esp, %0&quot...
2013 Nov 06
0
[LLVMdev] A new builtin: __builtin_stack_pointer()
...gt;>> named registers in the Linux kernel code. The kernel uses >>>>> something like >>>>> this in order to assign a C variable name to a register (one for each >>>>> kernel arch). >>>>> >>>>> register unsigned long current_stack_pointer asm("esp"); >>>>> >>>>> clang doesn't allow this kind of thing which required a patch >>>>> which less >>>>> efficient: >>>>> >>>>> #define current_stack_pointer ({ \ >>>>>...
2014 Mar 28
9
[LLVMdev] Named Register Implementation
Folks, So, I think we kind of agree that some named registers could be implemented, and that it should be an intrinsic that passes the name of the register down. This C code: register unsigned long current_stack_pointer asm("sp"); unsigned long get_stack_pointer_addr() { return current_stack_pointer; } void set_stack_pointer_addr(unsigned long addr) { current_stack_pointer = addr; } Would become something like: define i32 @get_stack_pointer_addr() nounwind { entry: %0 = call i32 @llvm.read_regi...
2013 Nov 05
1
[LLVMdev] A new builtin: __builtin_stack_pointer()
...ct is having is with the use of >>>> named registers in the Linux kernel code. The kernel uses something like >>>> this in order to assign a C variable name to a register (one for each >>>> kernel arch). >>>> >>>> register unsigned long current_stack_pointer asm("esp"); >>>> >>>> clang doesn't allow this kind of thing which required a patch which less >>>> efficient: >>>> >>>> #define current_stack_pointer ({ \ >>>> unsigned long esp; \ >>>>...
2018 Aug 10
13
[PATCH 00/10] x86/paravirt: several cleanups
This series removes some no longer needed stuff from paravirt infrastructure and puts large quantities of paravirt ops under a new config option PARAVIRT_XXL which is selected by XEN_PV only. A pvops kernel without XEN_PV being configured is about 2.5% smaller with this series applied. tip commit 5800dc5c19f34e6e03b5adab1282535cb102fafd ("x86/paravirt: Fix spectre-v2 mitigations for
2018 Aug 13
11
[PATCH v2 00/11] x86/paravirt: several cleanups
This series removes some no longer needed stuff from paravirt infrastructure and puts large quantities of paravirt ops under a new config option PARAVIRT_XXL which is selected by XEN_PV only. A pvops kernel without XEN_PV being configured is about 2.5% smaller with this series applied. tip commit 5800dc5c19f34e6e03b5adab1282535cb102fafd ("x86/paravirt: Fix spectre-v2 mitigations for