> What about compiling/linking with the pie flag and then using vm_map +
> execXXX call? Is it too much of a pie in the sky?
>
> 2011/9/13 José Cornado <
email@hidden>
>>
>> Thanks! luckily no mix-and-match planned.
>>
>> The problem I am having is that -image_base, or the way I am using it
>> (just -image_base 0xXXXX to gcc) does not seem to have an effect. Machoview
>> still shows 0x100000000. Any suggestions?
>>
>> Will try again tomorrow with fresher eyes...
>>
>> 2011/9/13 Shantonu Sen <
email@hidden>
>>>
>>> A side effect is that you might not notice truncation of 64-bit pointers
>>> if all of your app's static text and data are below 4GB.
>>>
>>> There's also a performance penalty to linking 64-bit programs in the low
>>> 4GB of the address space when run with the 32-bit kernel, since the kernel
>>> is forced to do TLB flushes on transitions into the kernel. The default
>>> behavior allows for the flush to be avoided.
>>>
>>> Shantonu
>>>
>>> On Sep 12, 2011, at 10:50 PM, comex wrote:
>>>
>>> > 2011/9/12 José Cornado <
email@hidden>:
>>> >> First of all, I apologize if this is not the correct list and if this
>>> >> somehow a novice question. If there is a better suited list, please
>>> >> let me
>>> >> know.
>>> >>
>>> >> If I wanted to change the default initial value of the VM address
>>> >> (executable) from 0x100000000 to another lower number, is this
>>> >> possible? Is
>>> >> this a linker option or compiler option? If possible, which
>>> >> side-effects
>>> >> could have?
>>> >
>>> > You can use this, but why do you want to do it?
>>> >
>>> > -image_base address
>>> > Specifies the perferred load address for a dylib or
>>> > bundle. The argument address is a hexadecimal number with
>>> > an optional leading 0x. By choosing non-overlapping
>>> > address for all dylibs and bundles that a program loads,
>>> > launch time can be improved because dyld will not
>>> > need to "rebase" the image (that is, adjust pointers within
>>> > the image to work at the loaded address). It is
>>> > often easier to not use this option, but instead use the
>>> > rebase(1) tool, and give it a list of dylibs. It
>>> > will then choose non-overlapping addresses for the list and
>>> > rebase them all. This option is also called
>>> > -seg1addr for compatibility.
>>> > _______________________________________________
>>> > Do not post admin requests to the list. They will be ignored.
>>> > Darwin-kernel mailing list (
email@hidden)
>>> > Help/Unsubscribe/Update your Subscription:
>>> >
>>> > This email sent to
email@hidden
>>>
>>
>>
>>
>> --
>> José Cornado
>>
>> --
>>
>> home:
http://www.efekctive.com
>> blog:
http://blogging.efekctive.com
>> ----------------------
>>
>> Everything has been said before, but since nobody listens we have to keep
>> going back and beginning all over again.
>>
>> Andre Gide
>
>
>
> --
> José Cornado
>
> --
>
> home:
http://www.efekctive.com
> blog:
http://blogging.efekctive.com
> ----------------------
>
> Everything has been said before, but since nobody listens we have to keep
> going back and beginning all over again.
>
> Andre Gide
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Darwin-kernel mailing list (
email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to
email@hidden
>
>
Everything has been said before, but since nobody listens we have to keep going back and beginning all over again.