public inbox for crossgcc@sourceware.org
 help / color / mirror / Atom feed
* Where are _modsi3.c and/or _modsi3.o?
@ 2000-06-24 16:21 Christopher Bahns
  2000-06-24 16:40 ` Jeff Bevis
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Christopher Bahns @ 2000-06-24 16:21 UTC (permalink / raw)
  To: crossgcc

I built binutils/gcc/newlib on my machine (Windows 98/NT, for m68k-coff
target), and things are basically going ok, but I'm having trouble with
the mod ('%') operator. I looked at the assembly language output and see
that it has a 'jsr __modsi3'. I check the map file and find the
'__modsi3' routine as follows:

 .text          0x00008c9c       x2e
/gcc-m68k/lib/gcc-lib/m68k-coff/2.95.2/libgcc.a(_modsi3.o)
                0x00008c9c                __modsi3

I extracted the source but could not find a file that fit the '_mod*' or
'_mod*.*' patterns, using both the Cygwin/Unix 'find' command and
Microsoft Explorer's find program. I re-built the compiler and also
could find no such object file in the build directory. I'd like to look
at the source code to find out if the arguments are being passed
properly.

I can send more details about my original problem with the mod operator
if you like. I have a very simple program that just does not work right.
If I use a different mathematics operator ('/', '*', etc.) then it's
fine. Also, the same code works perfectly if built with the Microtek
Research (MRI) compiler. If I can solve that problem then perhaps I
don't need to find _modsi3.c/o.

Can anyone help on where to find the code for the __modsi3 function?

Bonus question:
Is there a GCC option to generate an assembly listing without affecting
the build process. I know about the '-S' option, which generates
assembly code INSTEAD of object code (unless I'm just not using it
right). What I want is to generate assembly code IN ADDITION to object
code, and have the compilation process otherwise complete normally. I'd
like to specify a separate directory for the assembly listings and have
them all go there. This way, if I later have trouble and want to know
how a library routine works, I can just look it up instead of rebuilding
the whole damn thing again.

Thanks a lot for any help!
Christopher Bahns
Christopher Bahns Software

^ permalink raw reply	[flat|nested] 8+ messages in thread
[parent not found: <NDBBKHHMCLNIANLKMPHOEEKPCCAA.scott.howard@windriver.com>]

end of thread, other threads:[~2000-06-26 12:32 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-06-24 16:21 Where are _modsi3.c and/or _modsi3.o? Christopher Bahns
2000-06-24 16:40 ` Jeff Bevis
2000-06-24 23:33   ` Doug Evans
2000-06-26 10:19     ` Jeff Bevis
2000-06-26 10:33       ` Doug Evans
2000-06-24 16:46 ` Jeff Bevis
2000-06-24 23:29 ` Doug Evans
     [not found] <NDBBKHHMCLNIANLKMPHOEEKPCCAA.scott.howard@windriver.com>
2000-06-26 12:32 ` Scott Howard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).