Is there a way to hide assembly code when my C code references a library function that deals with memory? (Not showing 'asm' code)?

Is there a way to hide assembly code when my C code references a library function that deals with memory? (Not showing 'asm' code)?

Maybe if you gave us an example of what your trying to accomplish...Because I'm having a hard time understanding what you mean...

What compiler and options are you using?

I know that gcc will output assembly code if you use the -S switch. Perhaps you just need to remove that from your compile step?

putting:

gdb program

example stepping through I see switch between assembly and C.

Current language:  auto; currently asm
(gdb) fin
Run till exit from #0  listen () at ../sysdeps/unix/sysv/linux/i386/socket.S:51
0x08049951 in connect_ftp (options_data=0xbffff618) at example.c:429
429                     if (listen(data_sock,MAX_PENDING_REQUESTS) < 0)
Current language:  auto; currently c

want it to show only C code only and not show assembly. Could be system options somewhere(which I can't directly access)? Using Fedora.

Edited 6 Years Ago by flipjoebanana: n/a

putting:

gdb program

example stepping through I see switch between assembly and C.

Current language:  auto; currently asm
(gdb) fin
Run till exit from #0  listen () at ../sysdeps/unix/sysv/linux/i386/socket.S:51
0x08049951 in connect_ftp (options_data=0xbffff618) at example.c:429
429                     if (listen(data_sock,MAX_PENDING_REQUESTS) < 0)
Current language:  auto; currently c

want it to show only C code only and not show assembly. Could be system options somewhere(which I can't directly access)? Using Fedora.

The thing is, if you have inline assembler or assembler object files then a C translation may not(probably not) possible...You can do things in assembler that have no valid C representation..

This article has been dead for over six months. Start a new discussion instead.