Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!samsung!mips!rogerk From: rogerk@mips.com (Roger B.A. Klorese) Newsgroups: comp.sys.mips Subject: Re: li.s,li.d Message-ID: <1691@spim.mips.COM> Date: 1 Apr 91 20:28:59 GMT References: <1991Apr1.182811.28382@aero.org> Sender: news@mips.COM Organization: MIPS Computer Systems, Sunnyvale, California Lines: 55 Nntp-Posting-Host: servitude.mips.com In article <1991Apr1.182811.28382@aero.org> jordan@aero.org (Larry M. Jordan) writes: > >Any ideas how these two assembler macros (li.s, li.d) are >really implemented? Yes, they are implemented as load-word-to-coprocessor-1 (lwc1) instructions or pairs. They "immediate" values are stored in the .lit4 (single) and .lit8 (double) sections. >Also, (and this may be the solution to my question) is >there a disassembler for the .o files? The .s files, I'm >afraid, hide too much of what is going on--I really want to >know what machine instructions are generated. Script started on Mon Apr 1 12:24:00 1991 % [tecate:rogerk] 101) cat foo.s .set noreorder li.s $f0, 1.23456e+5 nop li.d $f2, 2.46810121416e+123 % [tecate:rogerk] 102) as foo.s % [tecate:rogerk] 103) size a.out Size of a.out:48 Section Size Physical Address Virtual Address .text 16 0 0 .lit8 16 16 16 .lit4 16 32 32 % [tecate:rogerk] 104) dis a.out 0x0: c7808020 lwc1 $f0,-32736(gp) 0x4: 00000000 nop 0x8: c7838010 lwc1 $f3,-32752(gp) 0xc: c7828014 lwc1 $f2,-32748(gp) % [tecate:rogerk] 105) dis -s .lit8 a.out 0x10: 598dde5b blezl t4,0xffff7980 0x14: ea6964fd swc2 $9,25853(s3) 0x18: 00000000 nop 0x1c: 00000000 nop % [tecate:rogerk] 106) dis -s .lit4 a.out 0x20: 47f12000 0x24: 00000000 nop 0x28: 00000000 nop 0x2c: 00000000 nop % [tecate:rogerk] 107) exit % [tecate:rogerk] 108) script done on Mon Apr 1 12:24:58 1991 -- ROGER B.A. KLORESE MIPS Computer Systems, Inc. MS 6-05 930 DeGuigne Dr. Sunnyvale, CA 94088 +1 408 524-7421 "10 years of Reagan/Bush have brought us to a new place: postconstitutional America." - Jon Carroll rogerk@mips.COM | {ames,decwrl,pyramid}!mips!rogerk