开发者

Is this a memory address?

开发者 https://www.devze.com 2023-03-15 23:43 出处:网络
I a开发者_运维百科m learning gdb, and I got my first error. This was the error: 0x00007fff83074096 in __kill ()

I a开发者_运维百科m learning gdb, and I got my first error. This was the error:

0x00007fff83074096 in __kill ()

Is the address:

0x00007fff83074096

... a memory address in Hex format? I've converted it to decimal, out of interest, and the number is huge. I fail to believe that so many memory addresses exist.


If you are running on a 64-bit platform, then yes, addresses that large exist. (See also: http://en.wikipedia.org/wiki/Virtual_address.)

Of course, it's possible that you simply have a buffer overflow somewhere, which has corrupted your stack, and overwritten the address with nonsense.


Yup. It is.

It is an address in a 64 bit process's virtual memory space.

Not all of the addresses are in use (that's what an address is: it is a label only).

You can see more about the address by doing

:break 0x00007fff83074096
:list 0x00007fff83074096
:disassemble 0x00007fff83074096

See the whole of the stack bactkrace

 :bt full

In all threads

 :thread apply all bt full


Yes, it is a memory address. Due to paging, there are vastly more memory addresses available than actual memory to back the virtual address space.

You might find running pmap -x 1 or pmap -x $$ instructive, along with looking at /proc/pid/maps contents for different processes. (cat /proc/self/maps is easy to run.)


16 hex digits x 4 (bits represented by one hex digit) = 64 bits. You're using a 64 bit platform, why are you surprised?

0

精彩评论

暂无评论...
验证码 换一张
取 消