Groups | Search | Server Info | Login | Register


Groups > comp.lang.asm.x86 > #8813

Re: Debugger problems

From Tavis Ormandy <taviso@nospicedham.gmail.com>
Newsgroups comp.lang.asm.x86
Subject Re: Debugger problems
Date 2023-12-02 00:28 +0000
Organization A noiseless patient Spider
Message-ID <ksvc0sFdtc9U1@mid.individual.net> (permalink)
References <fa661ff7-9381-4a32-9802-3d4691627145n@googlegroups.com>

Show all headers | View raw


On 2023-11-30, Martijn Bos wrote:
> Does anyone have any pointers/tips/trics on how to resolve this issue.
>
> (I know myself...I probably oversee the obvious...do not hesitate to point that out)

I would just use the disassembler, for example `x/10i _start` instead of
`list _start`!

I don't think nasm will generate line info automatically (just names),
so you would set breakpoints on symbols `b _start` or addresses `b
*0x401000)

However... gas can do it if you prefer this style. Your code is
basically valid gas syntax already. Just add `.intel_syntax noprefix`
and add a `.` before directives, e.g. .section, .global, etc, and use #
for comments instead of ;.

Then you can use `as -g foo.asm -o foo.o` instead.

Now `b foo.asm:123` should work.

Nasm and gas are both great assemblers, it doesn't make much difference
which one you choose while you're getting started.

Tavis.

-- 
 _o)            $ lynx lock.cmpxchg8b.com
 /\\  _o)  _o)  $ finger taviso@sdf.org
_\_V _( ) _( )  @taviso

Back to comp.lang.asm.x86 | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Debugger problems Martijn Bos <martijnm.bos@gmail.com> - 2023-11-30 01:00 -0800
  Re: Debugger problems Tavis Ormandy <taviso@nospicedham.gmail.com> - 2023-12-02 00:28 +0000
    Re: Debugger problems Borax Man <rotflol2@nospicedham.hotmail.com> - 2023-12-02 09:17 +0000
      Re: Debugger problems Martijn Bos <martijnm.bos@nospicedham.gmail.com> - 2023-12-02 03:04 -0800
      Re: Debugger problems Tavis Ormandy <taviso@nospicedham.gmail.com> - 2023-12-02 17:38 +0000
        Re: Debugger problems Borax Man <rotflol2@nospicedham.hotmail.com> - 2023-12-03 09:30 +0000
          Re: Debugger problems Tavis Ormandy <taviso@nospicedham.gmail.com> - 2023-12-03 16:43 +0000
            Re: Debugger problems Borax Man <rotflol2@nospicedham.hotmail.com> - 2023-12-04 18:10 +1100
              Re: Debugger problems Borax Man <rotflol2@nospicedham.hotmail.com> - 2023-12-04 12:01 +0000
                Re: Debugger problems Martijn Bos <martijnm.bos@nospicedham.gmail.com> - 2023-12-06 03:55 -0800
    Re: Debugger problems Martijn Bos <martijnm.bos@nospicedham.gmail.com> - 2023-12-02 02:12 -0800

csiph-web