search for: get_const

Displaying 4 results from an estimated 4 matches for "get_const".

Did you mean: get_cost
2016 May 31
2
[cfe-dev] How to debug if LTO generate wrong code?
...64 Mac OS X App? Andrew showed me some example code of Mac OS X App as below, which looks to use the small code model but can run at >4GB high address. Small, but PIC. > For example if you read a global like this the compiler will generate this code. > int constant = 0; > > int get_constant(void) > { > return constant; > } Compiling for ELF with -FPIE -Os I get get_constant: # @get_constant # BB#0: # %entry movl constant(%rip), %eax retq Which should also be able to run at any address....
2016 May 31
0
[cfe-dev] How to debug if LTO generate wrong code?
...#39;s the default code model for x86_64 Mac OS X App? Andrew showed me some example code of Mac OS X App as below, which looks to use the small code model but can run at >4GB high address. For example if you read a global like this the compiler will generate this code. int constant = 0; int get_constant(void) { return constant; } (lldb) dis -n get_constant -b a.out`get_constant: a.out[0x100000f8c] <+0>: 55 pushq %rbp a.out[0x100000f8d] <+1>: 48 89 e5 movq %rsp, %rbp a.out[0x100000f90] <+4>: 8b 05 6a 00 00 00 movl 0x6a(%rip)...
2016 May 30
2
[cfe-dev] How to debug if LTO generate wrong code?
On 30 May 2016 at 19:55, Mehdi Amini <mehdi.amini at apple.com> wrote: > > > Sent from my iPhone > >> On May 30, 2016, at 4:52 PM, Rafael EspĂ­ndola <rafael.espindola at gmail.com> wrote: >> >>> On 30 May 2016 at 16:56, Mehdi Amini <mehdi.amini at apple.com> wrote: >>> >>> >>> On 05/30/16 01:34 PM, Rafael EspĂ­ndola
2016 May 31
1
[cfe-dev] How to debug if LTO generate wrong code?
...Mac OS X App as below, which looks to use the > small code model but can run at >4GB high address. > > Small, but PIC. > > > > > For example if you read a global like this the compiler will generate this > code. > > int constant = 0; > > > > int get_constant(void) > > { > > return constant; > > } > > > Compiling for ELF with -FPIE -Os I get > > get_constant: # @get_constant > # BB#0: # %entry > movl constant(%rip), %eax >...