[Barrelfish-users] Barrelfish OS-gdb session

Vishwas K.M. vishwaskm2000 at yahoo.com
Thu Mar 13 09:53:19 CET 2014


 
I downloaded the source, edited the program gdb/remote.c and compiled, now I don't see the error.
 
Thanks,
Vishwas K.M


________________________________
From: Vishwas K.M. <vishwaskm2000 at yahoo.com>
To: Kästle Stefan <stefan.kaestle at inf.ethz.ch>; "barrelfish-users at lists.inf.ethz.ch" <barrelfish-users at lists.inf.ethz.ch> 
Sent: Tuesday, March 11, 2014 12:23 PM
Subject: Re: [Barrelfish-users] Barrelfish OS-gdb session



Hello Stefan,
 
I ran few commands and we have gdb version 7.4. I had installed gdb using apt-get. 
 
Please let me know if you suggest to download the source, comment out the file(gdb/remote.c) and compile it.
 
root at bf015:/etc/gdb# cat gdbinit
# System-wide GDB initialization file
set architecture i386:x86-64:intel
#--with-expat
 
root at bf015:/home# whereis gdb
gdb: /usr/bin/gdb /etc/gdb /usr/bin/X11/gdb /usr/share/gdb /usr/share/man/man1/gdb.1.gz
 
root at bf015:/home# gdb -version
GNU gdb (Ubuntu/Linaro 7.4-2012.04-0ubuntu2.1) 7.4-2012.04
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http://bugs.launchpad.net/gdb-linaro/>.
 
root at bf015:/home# sudo apt-get install gdb
Reading package lists... Done
Building dependency tree
Reading state information... Done
gdb is already the newest version.
The following packages were automatically installed and are no longer required:
  linux-headers-3.2.0-58 linux-headers-3.2.0-59 linux-headers-3.2.0-58-generic linux-headers-3.2.0-59-generic
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.
root at bf015:/home#

 
 
 

--------------------
Thanks and Regards, 
Vishwas K.M. 
09448535935


________________________________
From: Kästle Stefan <stefan.kaestle at inf.ethz.ch>
To: Vishwas K. M. <vishwaskm2000 at yahoo.com> 
Sent: Wednesday, March 5, 2014 8:12 PM
Subject: RE: [Barrelfish-users] Barrelfish OS-gdb session


Hello,

I saw this problem before and as far as I remember, you can just comment out the line in the gdb source file and recompile it (gdb/remote.c). Does this work for you?

Cheers,
Stefan

________________________________ 

From: Vishwas K.M. [vishwaskm2000 at yahoo.com]
Sent: Wednesday, March 05, 2014 7:04 AM
To: barrelfish-users at lists.inf.ethz.ch
Subject: Re: [Barrelfish-users] Barrelfish OS-gdb session

Hello Stefan,

Thanks for the info. I progressed few steps and got stuck with  “Remote 'g' packet reply is too long: “

I did the following:

make debugsim
file x86_64/sbin/elver
l
b 1
b 100
info breakpoints
info sources
c

it breaks at execution line 1 and type n to next or s to step into the function -

(gdb) file x86_64/sbin/elver
A program is being debugged already.
Are you sure you want to change the file? (y or n) y
Reading symbols from /home/sarmaji/barrelfish/build/x86_64/sbin/elver...done.
(gdb) b 1
Breakpoint 1 at 0x10000c: file ../tools/elver/boot.S, line 1.
(gdb) b 100
Breakpoint 2 at 0x10006f: file ../tools/elver/boot.S, line 100.
(gdb) info breakpoints
Num    Type          Disp Enb Address    What
1      breakpoint    keep y  0x0010000c ../tools/elver/boot.S:1
2      breakpoint    keep y  0x0010006f ../tools/elver/boot.S:100
(gdb) c
Continuing.
Found Realtek 8029 at 0xc000, ROM address 0xae00
Probing...[Realtek 8029]
NE2000 base 0xc000, addr 52:54:00:12:34:56
Address: 10.0.2.15
Netmask: 255.255.255.0
Server: 10.0.2.2
Gateway: 10.0.2.2
Address: 10.0.2.15
Netmask: 255.255.255.0
Server: 10.0.2.2
Gateway: 10.0.2.2
  Booting 'Chain-load /menu.lst from TFTP'

root  (nd)
Filesystem type is tftp, using whole disk
configfile (nd)/menu.lst
TFTP error 1 (File not found)
  Booting 'Barrelfish'

root (nd)
Filesystem type is tftp, using whole disk
kernel /x86_64/sbin/elver loglevel=5 logmask=1
  [Multiboot-elf, <0x100000:0x2560:0x0>, <0x103fe4:0x1c:0x6000>, shtab=0x10a2f
8, entry=0x10000c]
module /x86_64/sbin/cpu loglevel=5 logmask=1
------------------------
------------------------
------------------------
------------------------
  [Multiboot-module @ 0x5b86000, 0x539760 bytes]
module /x86_64/sbin/fish loglevel=5 logmask=1
  [Multiboot-module @ 0x60c0000, 0x84b1bf bytes]


Breakpoint 1, start () at ../tools/elver/boot.S:39
39              movl    $(stack + STACK_SIZE), %esp
(gdb) n
start () at ../tools/elver/boot.S:42
42              pushl  $0
(gdb) n
start () at ../tools/elver/boot.S:43
43              popf
(gdb) n
start () at ../tools/elver/boot.S:46
46              push    %ebp
(gdb) n
start () at ../tools/elver/boot.S:47
47              mov    %esp, %ebp
(gdb) n
48              push    %ebx            /* Pointer to multiboot info struct */
(gdb) n
start () at ../tools/elver/boot.S:49
49              push    %eax            /* Multiboot magic value */
(gdb) n
start () at ../tools/elver/boot.S:50
50              call    startup
(gdb) n
Remote 'g' packet reply is too long:
 0000000000000000903d26000000000000000000000000003022630000000000c021630000000000903d260000000000902163000000000038216300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003022630000000000000000000000000060d440000000000006020000230000001b00000000000000000000000f0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007f03000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000801f0000
I did google on this error message, they say to set the architecture to x86_64 [set architecture i386:x86-64:intel] - done, still error persists.

(gdb) show arch
The target architecture is set automatically (currently i386:x86-64)
Please assist, also I din't find the gdbinit file to check.



--------------------
Thanks and Regards,
Vishwas K.M.
09448535935

From: Vishwas K.M. <vishwaskm2000 at yahoo.com>
To: "barrelfish-users at lists.inf.ethz.ch" <barrelfish-users at lists.inf.ethz.ch>
Sent: Friday, February 28, 2014 7:07 AM
Subject: Barrelfish OS-gdb session


Hello All,

I have recently stared working on BF OS and need assistance to understand the OS internals.

I am using "make sim" on x86_64 and it compiles and runs the BF till it reachs the fish prompt.

Now to get into the BF internals I am trying to get the compiled BF code into a gdb session and start the run part so that I can get into each module and see the things.

Please assist me a way out..

Thanks,
Vishwas K.M





Hello All,

Thanks a ton!!!! I did what you told and the error vanished.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.inf.ethz.ch/pipermail/barrelfish-users/attachments/20140313/b1fe78d9/attachment-0001.html 


More information about the Barrelfish-users mailing list